150539624 secure teacher class

Prevent teachers from accessing classes that belong to other teachers, and setting bookmarks on classes that do not belong to them.

Need to confirm travis tests are working.

Looks like a few test failures.
A few comments:

I'm trying to phase out use of current_visitor. The standard Rails method is current_user. current_user is nil if there is no user logged in.  Our current_visitor method returns a fake user if no one is logged in. So to switch to current_user you should check for nil if the code is going to run even for anonymous users.
we tried to switch everything over to Pundit, but didn't have time to update the clazzes_controller. It is probably too much work to do that now. But I think the bookmarks_controller could use Pundit. A good example of a Pundit Policy is this file: http://github.com/concord-consortium/rigse/blob/eba81f942c90c25542c54527d47228913559f7ee/app/policies/portal/offering_policy.rb it has a method that checks if the current user is a teacher of the class of the offering. A rule of thumb I try to follow for the pundit policies is to keep them mostly self contained. This makes it easier to see what rule applies to what controller action without looking through several files. In other words I've tried to avoid using class hierarchies or includes to consolidate common actions. So this means there is some duplicate code, but I think it makes it easier to maintain. If we could get full Pundit coverage, then we could turn on error checking so new controller actions will automatically throw an error if they don't have a pundit policy.

Cucumber tests are still failing. I will make the changes you suggest above.

I think the bookmarks_controller could use Pundit

From what I have been learning about pundit policies they are tied to models and not controllers.
So for the BookmarksController to call authorize on a model of type Clazz, there would need to exist a ClazzPolicy (we have one, it is empty) which would in turn define methods that exist in the BookmarksController. I.e. index, add, add_padlet. Which seems confusing because if we were to then go and add pundit calls to the ClazzesController it seems like there could be conflicts e.g. index. Also you are not calling add to add a class, rather you are calling add to add a bookmark.
Is this what we want? Or have I misunderstood?
class Portal::ClazzPolicy < ApplicationPolicy

  def index
    user && record && record.is_teacher?(user)
  end

  def add
    user && record && record.is_teacher?(user)
  end

  def add_padlet
    user && record && record.is_teacher?(user)
  end

end

Tests are fixed. @scytacki See comments on pundit and let me know what you prefer.

Since there is a Bookmark model, I think it would make sense that there would be a BookmarkPolicy.
It could be used after the Bookmark model has been initialized before it is saved. So for example just before this line:
http://github.com/concord-consortium/rigse/blob/b11dca8776995a7807b6c1d1a894732b02e42ce8/app/controllers/portal/bookmarks_controller.rb#L29
You could call:
authorize mark
Which ought to look for an add? method in the Portal:GenericBookmarkPolicy
And the record that is available to the add? method will have the class set on it so that class can be used to decide if the user should be able to create this bookmark.
In this BookmarkPolicy approach I'm not sure how best to handle the index action. One way would be to use a Scope. This Scope would limit the bookmarks just to ones associated with the current user's classes. But this would require doing a lot of DB queries to get this list of classes. When really all we need to do is check that the passed in class is valid.  So perhaps the best approach is something like this:
authorize @portal_clazz, :list_bookmarks?
Alternatively you could put all of methods in the ClazzPolicy. So like above, the method name that is checked in the policy can be overridden. So the add checks could be done with authorize get_current_clazz, :add_bookmark?
I'll leave it up to you to pick an approach.
One that you should make sure to check that students still see their bookmarks in their class.

This still needs to be tested. I think I missed this.

Just to be sure, you should check that students still see their bookmarks in their class. If you use the Scope approach that might require allowing students to see bookmarks for their classes in addition to teachers.

Yeah the student view of the bookmarks is fine, since it comes from the classes view.


Update extension for v0.7.0 compatibility

A few changes were made in v0.7.0 of duckdb that impacted this extension:

list_vector changes were merged in https://github.com/duckdb/duckdb/pull/6155/
JSON type was removed https://github.com/duckdb/duckdb/discussions/6288
Some function signatures were changed

Great PR, Thanks @dacort !
LGTM. Pending GHA.

Thanks for the extension! Excited to check out lance some more. 😃

Unfortunately CI still failed. There's an unused import (c_void) in lib.rs but not sure if that's what caused the failure.


feat: add option to connect ddos protection plan

Overview/summary
Allow optional configuration to attach vnets to ddos protection plan
This PR fixes/adds/changes/removes
fixes #125
Testing evidence
Please provide testing evidence to show that your Pull Request works/fixes as described and documented above.
As part of this pull request I have

[X] Checked for duplicate Pull Requests
[X] Associated it with relevant issues, for tracking and closure.
[X] Run and make fmt & make docs to format your code and update documentation.
[ ] Created unit and deployment tests and provided evidence.
[X] Updated relevant and associated documentation.

@ppodevlab thanks for your contribution, it's much appreciated.
I will run some of the static analysis tests first. We also need to add some unit tests to the go test framework before merging. If you would like to do this yourself that's great, if not I can do it.
Meanwhile there's a small change needed to the variable validation error message

This will be merged after #141

Closing as I have pulled your commits into a local branch so that I can create the tests. Thank you for your contribution, your commits will be preserved! @ppodevlabs


How to create a separate chat via API?

import ollama from 'ollama'

const message = { role: 'user', content: 'What color of the sky?' }
const response = await ollama.chat({ model: 'llama2', messages: [message], stream: true })
for await (const part of response) {
  process.stdout.write(part.message.content)
}

const message2 = { role: 'user', content: 'What was my first prompt?' }
const response = await ollama.chat({ model: 'llama2', messages: [message2], stream: true })
for await (const part of response) {
  process.stdout.write(part.message.content)
}
//result: your first prompt was "What color of the sky?"

The documentation is not clear enough,
How am I supposed to save a session of the current conversation (to continue talking later) and create a new separate chat conversation?

Just tested this exact same code and the same doesn't happen for me

for one separate chat (in pseudo code):

create empty chat=[] or [{role:'system', content:'...you system prompt here...'}]
add new message: chat=[...chat, message]
await ollama.chat({ model: 'llama2', messages: chat, stream: true })
after get response add answer: chat=[...chat, answer] (answer must be {role:'assistant', content: 'ai bla-bla-bla'})
goto 2

save this chat for late as you wish

import ollama from 'ollama'

const message = { role: 'user', content: 'What color of the sky?' }
const response = await ollama.chat({ model: 'llama2', messages: [message], stream: true })
for await (const part of response) {
  process.stdout.write(part.message.content)
}

const message2 = { role: 'user', content: 'What was my first prompt?' }
const response = await ollama.chat({ model: 'llama2', messages: [message2], stream: true })
for await (const part of response) {
  process.stdout.write(part.message.content)
}
//result: your first prompt was "What color of the sky?"

The documentation is not clear enough, How am I supposed to save a session of the current conversation (to continue talking later) and create a new separate chat conversation?

What do you mean by your example? Do you mean that even when you do the ollama.chat for the second time, ollama remeber your first prompt? Or you want Ollama to remember the first prompt the second time you call it? Be cause if it's the second case the answer of imareo seem to be what's you need. If it's the first case, well you need aother solution. So please answer back to this issue to we know if your problem is solve or not and what was your need clearly.


Problems identifying attachments Office365

Code to Reproduce
foreach($messages as $message) {
      $counter = 0;
      echo "Counter 01 = " . $message->getAttachments()->count();
      $aAttachment = $message->getAttachments();
      echo "Counter 02 = " . count($aAttachment);
      foreach($aAttachment as $oAttachment) {
            $counter++;
            echo "<p>".$val." ".$oAttachment->name."</p>";
      }
      echo "Counter 03 = " . $counter;
}

Expected behavior
Correct identification of the number of attachments contained in the received email.
Desktop / Server:

PHP: 7.4.28
Version v2.3.1
Provider Outlook

Additional context
I have a problem with looping attachments.
For example, I receive an email with 15 attachments, but in processing the function identifies 14.
I have to reprocess the email to correct one or more missing attachments, and even then the problem can still persist, find 10, 13.
Thanks.

The above code was just the "extra" validations I performed to check the number of attachments.
Basically, all counters match, however all conditions are required in what the function initially identified, i.e. if identified 14, counters will play 14, etc.

I think there is a problem with pushing attachments to the collection, here is a solution. Try it and check if this help you.
https://github.com/Webklex/php-imap/pull/372

Hi @eduardom456 ,
many thanks for your well written report. I very much appreciate it!
Please update to the latest release and give it another try. There has been a ton of changes :)
Once again, thanks for taking the time and effort to make this library better!
Best regards & happy coding,


[enhancement]: don't pass --progress to git fetch

Task name
checkout
Describe your feature request here
The typical git commandline that gets run in the checkout step is: git --config-env=http.extraheader=env_var_http.extraheader fetch --force --tags --prune --prune-tags --progress --no-recurse-submodules origin --depth=1
This just clutters the logs with lots of Receiving objects: and Resolving deltas: lines.
I don't see any reason at all to include --progress here. But at least make it optional like they finally did in https://github.com/actions/checkout?tab=readme-ov-file#usage

Hi @Trass3r, thank you for the suggestion!
The checkout task is a part of the agent, and can't be modified from this repo, could you please create a new issue in the agent's repository?
I'm closing this issue as the task is not a part of the repo.


Misc

Removed noise, made A typeless, changed naming

Maybe you could drop the second argument btw, and just write
T = eltype(A)

in the function body.


Reduce number of SpagEnvironment.get_env calls

Each one of the
def determine_endpoint(f):
def prepare_headers(f):
def request_dir(f):

decorators calls
d = spag_files.SpagEnvironment.get_env()
we should be able to easily reduce this to one call, and save some time.

closing because we decided it wasn't worth it.


Update non-windows.md

added the word antivirus to the document

@JohanFreelancer9 Please copy review

Issue#https://github.com/MicrosoftDocs/microsoft-365-docs/issues/7320

Thank you @msbemba


Feature: Updating apps leads to reorganization of icons in Launchpad

Hi,
I have experienced that when updating apps they get reorganized in the launchpad which is sometimes annoying if you have structure with folders where the applications are inside.
maybe there is a way to make sure that the icons stay where they are ?

Hi,
Applite uses Homebrew as its backend to download and update the apps. I have no way of controlling the update process. This is likely an issue with macOS or Homebrew.


Export choose_fmt

in order to implement format with limited width as described here (https://github.com/SheetJS/sheetjs/issues/2689) externally we need to use "choose_fmt" and "isgeneral".

FWIW isgeneral quite literally checks for the string "General".


GCP Workflows execution URL

GCP Workflows have an implicit execution URL, but that's missing in the Workflow class.
Affected feature
An execution_url Output in the Workflow class would be helpful.
The URL format is described here: https://cloud.google.com/workflows/docs/schedule-workflow
https://workflowexecutions.googleapis.com/v1/projects/PROJECT_NAME/locations/REGION_NAME/workflows/WORKFLOW_NAME/executions

Hi @alexsavio
This provider is based on the terraform-provider-google-beta, I think it would be best if you open an issue upstream.


[GOBBLIN-1611] Fix a wrong value for writer.codec.type in the document

Dear Gobblin maintainers,
Please accept this PR. I understand that it will not be reviewed until I have checked off all the steps below!
JIRA

[x] My PR addresses the following Gobblin JIRA issues and references them in the PR title. For example, "[GOBBLIN-XXX] My Gobblin PR"

https://issues.apache.org/jira/browse/GOBBLIN-1611

Description

[x] Here are some details about my PR, including screenshots (if applicable):

The description about  the writer.codec.type property in the document has a little mistake. This PR corrects it.
Tests

[x] My PR adds the following unit tests OR does not need testing for this extremely good reason:

No additional test, since it's just a documentation fix.
I ran mkdocs serve locally and confirmed the document was modified as expected.
Commits

[x] My commits all reference JIRA issues in their subject lines, and I have squashed multiple commits if they address the same issue. In addition, my commits follow the guidelines from "How to write a good git commit message":

Subject is separated from body by a blank line
Subject is limited to 50 characters
Subject does not end with a period
Subject uses the imperative mood ("add", not "adding")
Body wraps at 72 characters
Body explains "what" and "why", not "how"

Codecov Report

Merging #3470 (dc04999) into master (655826a) will increase coverage by 0.00%.
The diff coverage is n/a.

@@            Coverage Diff            @@
##             master    #3470   +/-   ##
=========================================
  Coverage     46.62%   46.62%
+ Complexity    10352    10351    -1
=========================================
  Files          2076     2076
  Lines         81032    81032
  Branches       9044     9044
=========================================
+ Hits          37778    37781    +3
+ Misses        39774    39772    -2
+ Partials       3480     3479    -1

Impacted Files
Coverage Δ

...gobblin/service/modules/core/GitConfigMonitor.java
81.35% <0.00%> (-1.70%)
:arrow_down:

...anagement/copy/replication/ConfigBasedDataset.java
68.87% <0.00%> (ø)

.../apache/gobblin/runtime/api/JobExecutionState.java
80.37% <0.00%> (+0.93%)
:arrow_up:

...lin/util/filesystem/FileSystemInstrumentation.java
92.85% <0.00%> (+7.14%)
:arrow_up:

...he/gobblin/source/PartitionAwareFileRetriever.java
55.55% <0.00%> (+7.40%)
:arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 655826a...dc04999. Read the comment docs.

Thanks for the contribution! @sekikn


Run CI tests against openssl 1.1.x

Prior to this commit, we only ran tests against 0.9.x
Closes #4

This is failing because options.c in Ponyc right now has:
#define OPENSSL_LEADER "openssl_"
static const char* valid_openssl_flags[] =
  { OPENSSL_LEADER "1.1.0", OPENSSL_LEADER "0.9.0", NULL };

Which confuses me because the ci job to test 1.1.x for ponyc is working and i can't see how it would given that all the ifdef's are for "openssl_1.1.x" which isn't considered valid to pass to ponyc.
Definitely confused.

I have a fix for this that will go onto master after the PR is merged. I'll update the 110 jobs to run against master until the next release then they can go back to running against release.


Add destroy function

Add ability to unload Fluid Player somewhat gracefully. See #119

Note: whitespace edit's in diff due to some random loose whitespaces in the codebase :/

Looks good

destroy() method not working because player not defined inside "destroy" function:
Line 7157: var container = document.getElementById('fluid_video_wrapper_' + player.videoPlayerId);

@HomAfromPTZ if you don't mind creating a pull request, we could publish that fairly quickly.

When  destroy() method  is executed, the scheduled task is not destroyed, but it is always running there and an error is reported.   Uncaught TypeError: Cannot read property 'clientWidth' of null
at Object.checkIfVolumebarIsRendered (fluidplayer.js:4773)
at initiateVolumebar (fluidplayer.js:4724)


(maint) Avoid scoping change in Ruby 2.2

Using Ruby 2.2, the opts assignment in the Windows case of
install_puppet_agent_dev_repo_on overwrites the opts method
argument. This causes installs after Windows to fail in Puppet
acceptance runs. Fix by avoiding using the same variable name.

Refer to this link for build results (access rights to CI server needed):
http://jenkins-beaker.delivery.puppetlabs.net//job/qe_beaker_btc-intn/2361/
Test PASSed.


this.Parameter is detected as undefined

I am using Fuse v. 0.22.0. I was trying to run this example and I got this error:
LOG: InternalError: Script error: Name: TypeError: Cannot read property 'map' of undefined
Error message: Uncaught TypeError: Cannot read property 'map' of undefined
File name: Pages/EditHikePage.js
Line number: 5
Source line: var name = hike.map(function(x) { return x.name; });
JS stack trace: TypeError: Cannot read property 'map' of undefined
at null._moduleFunc (Pages/EditHikePage.js:5:16)
<C:\ProgramData\Uno\Packages\Fuse.Scripting.V8\0.32.11$.uno:135>
LOG: Error: JavaScript error in Pages/EditHikePage.js line 5. Uncaught TypeError: Cannot read property 'map' of undefined in Fuse.Reactive.JavaScript<C:\ProgramData\Uno\Packages\Fuse.Reactive\0.32.11$.uno:1354>

Hi there, this.Parameter was introduced in Fuse 0.24. I recommend upgrading to the latest version (0.25).

I see, thanks for reply

np!

Hello again! I've updated to version 0.25.5 and I have another problem with this.Parameter, now I've changed some code lines. The problem is that I can't retrieve custom parameters that I've passed to the router. These are my changes:
File: HomePage.js
...
function goToHike(arg) {
console.log('Selected index: ' + Context.hikes.indexOf(arg.data)); // This return the index successfully
var params = { "index": Context.hikes.indexOf(arg.data) };

router.push("editHike", params);

}
...
File: EditHikePage.js
...
var index = this.Parameter;
var hike = Observable(Context.hikes.getAt(index.value));
...

Please ask this question on our slack channel or our forums, as this is not an issue with the code provided in this repo.


Add pretty print for logs and diff output

Changes:

Implement logging with zerolog (fix: #55)
Implement colorised Kubernetes objects diffing with dyff
add a global flag for disabling the colorised output and log timestamps --log-pretty=false

With logr you need to format  the message with Sprintf while zerolog it’s just Msgf.

Yes, with reason.
The downside of the current approach is that you have no contextual logging, nor are proving (potential) SDK users with the promise of logr in which they can inject their own implementation without worrying.


get_heat_transfer_sensible query doesn't report heat of reaction source

PyFluent:
>>> solver.settings.results.report.fluxes.get_heat_transfer_sensible(zones="*")
{'Net': -0.5353470934205689, 'air-inlet':<PHONE_NUMBER>580586, 'fuel-inlet': 16.64962057794938, 'nozzle': -0.0, 'outer-wall': -12842.71004368724, 'pressure-outlet-9': -191740.9839789073}

Fluent:

Tutorial to reproduce: https://ansyshelp.ansys.com/public/account/secured?returnurl=/Views/Secured/corp/v242/en/flu_tg/flu_tg_magnus.html

[1178302]


Searches randomly yielding no results, unicode error

I know there isn't any support for this anymore, but I have been getting this error recently, running Kodi 18.6 and latest Elementum. Basically, very random word searches or show / movie searches using their respective categories give me an ASCII error and display no results. If I decide to do a manual search, all is good BUT only if I remove some letters (have not found any pattern). It does not work if I search for "show s01" or anything like that, for example.
I attached a full log, notice the very bottom and the errors there. It seems to be happening because of some of the .py files and it has to do with not being able to encode some characters. I cannot recall this happening before, months ago. My Kodi is in English using the Default character set. I am only using Cyrillic for my Player, so I can get subtitles for some shows in my language on occasion. Anyone encounter such and error?
bundle_2020_5_10_11_0.log.txt

@hitmancho this is a bug in Burst. Will be fixed in the next version of it.

for for me.. disable limetorrents and it works fine!!

I am still getting this error, any chance of getting a fix soon?

@RobP-git @qaron84 @hitmancho still an issue with the latest Burst/Elementum?

@RobP-git @qaron84 @hitmancho still an issue with the latest Burst/Elementum?

Seems to be working fine for me. Tested it again by searching for "rome s01" in Search and it finds torrents no problems. Not had a chance to test if other names and strings could be a problem, but I do no think so.
Only text-related issues I have been seeing is shows with special characters (e.g. 90 day fiance with a diacritic on "e") being scraped from the Shows tab with that letter and getting zero results. Otherwise, searching manually from the Search tab is yielding all relevant torrents. Let me know if you need any further files from my side.

@hitmancho in case you meet this bug again - feel free to raise an issue.

Only text-related issues I have been seeing is shows with special characters (e.g. 90 day fiance with a diacritic on "e") being scraped from the Shows tab with that letter and getting zero results.

Sadly, that is how trackers search such cases, some treat "ę", "é" and "e" as same chars. Some need to have specific "e" char, some just don't find other than simple "e".

Yes also working for me now, thanks!

@RobP-git @qaron84 @hitmancho still an issue with the latest Burst/Elementum?

Yes also working for me, thanks!


enable prettier by default

Summary
same as https://github.com/react-native-community/react-native-blur/pull/351
I removed "requirePragma": true from prettierrc because that option means prettier is not enabled unless explicitly turned on using the @format pragma (as it was in example/index.js).
After that I just ran eslint --fix and the code now follows the specified config.

Test Plan
eslint passes (it does locally :) )

What's required for testing (prerequisites)?
What are the steps to reproduce (after prerequisites)?
Compatibility

OS
Implemented

iOS
✅❌

Android
✅❌

Checklist

[ ] I have tested this on a device and a simulator
[ ] I added the documentation in README.md
[ ] I mentioned this change in CHANGELOG.md
[ ] I updated the typed files (TS and Flow)
[ ] I added a sample use of the API in the example project (example/App.js)

@vonovak Thanks!


File loader doesn't work?

Hi, loading static files does not seem to work for me.
I am not sure If I am using it correctly. Example:
// App.vue
<div id="app" style="background-image: url('../imgs/bg.jpg')">

and I create folder imgs in client and put bg.jpg here.
Webpack dev server does return index.html for this path and production build does not include these files.
Am I missing something? Thanks.

Ehh, Webpack won't parse thing in Vue template. Just set that in CSS.


Running an action with 'requests' as a requirement fails

Checked other resources

[X] I added a very descriptive title to this issue.
[X] I used the GitHub search to find a similar question and didn't find it.
[X] I am sure that this is a bug in Admyral rather than my code.

Example Code
@action(
    display_name="Get findings",
    display_namespace="Defect Dojo",
    description="Retrieve all findings from Defect Dojo",
    requirements=["requests"],
    secrets_placeholders=['DEFECT_DOJO']
)
def get_all_defect_dojo_findings() -> JsonValue:
    secrets = ctx.get().secrets.get("DEFECT_DOJO")
    base_url = secrets['base_url']
    api_key = secrets['api_key']
    headers = {
        "Authorization": f'Token {api_key}',
        "Content-Type": "application/json",
    }
    params = {
        "test__test_type": 56,
        "limit": 50
    }
    url = f"{base_url}/api/v2/findings/"
    findings = []
    while url:
        response = requests.get(url, params=params, headers=headers)
        if response.status_code != 200:
            raise Exception(f"Failed to fetch findings: {response.status_code}")
        data = response.json()
        findings.extend(data['results'])
        url = data['next']
    return findings

Error Message and Stack Trace (if applicable)
flock -x /root/.config/admyral/admyral_default_storage/cache/pip-lock/pip-idna_3_10.lock -c '/usr/local/bin/python -m pip install idna==3.10 --no-deps --no-color --isolated --no-warn-conflicts --disable-pip-version-check --root-user-action=ignore -t /root/.config/admyral/admyral_default_storage/cache/pip/idna==3.10'
flock -x /root/.config/admyral/admyral_default_storage/cache/pip-lock/pip-requests_2_32_3.lock -c '/usr/local/bin/python -m pip install requests==2.32.3 --no-deps --no-color --isolated --no-warn-conflicts --disable-pip-version-check --root-user-action=ignore -t /root/.config/admyral/admyral_default_storage/cache/pip/requests==2.32.3'
Collecting idna==3.10
Downloading idna-3.10-py3-none-any.whl.metadata (10 kB)
Collecting charset-normalizer==3.3.2
Downloading charset_normalizer-3.3.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.metadata (33 kB)
Downloading charset_normalizer-3.3.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (137 kB)
Collecting urllib3==2.2.3
Downloading urllib3-2.2.3-py3-none-any.whl.metadata (6.5 kB)
Downloading urllib3-2.2.3-py3-none-any.whl (126 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 126.3/126.3 kB 1.5 MB/s eta 0:00:00
Installing collected packages: urllib3
Collecting certifi==2024.8.30
Downloading certifi-2024.8.30-py3-none-any.whl.metadata (2.2 kB)
Downloading certifi-2024.8.30-py3-none-any.whl (167 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 167.3/167.3 kB 1.8 MB/s eta 0:00:00
Installing collected packages: certifi
Successfully installed certifi-2024.8.30
Collecting requests==2.32.3
Downloading requests-2.32.3-py3-none-any.whl.metadata (4.6 kB)
Downloading requests-2.32.3-py3-none-any.whl (64 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 64.9/64.9 kB 1.2 MB/s eta 0:00:00
Installing collected packages: requests
Successfully installed requests-2.32.3
Downloading idna-3.10-py3-none-any.whl (70 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 70.4/70.4 kB 1.3 MB/s eta 0:00:00
Installing collected packages: idna
Successfully installed idna-3.10
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 137.3/137.3 kB 2.5 MB/s eta 0:00:00
Installing collected packages: charset-normalizer
Successfully installed charset-normalizer-3.3.2
Successfully installed urllib3-2.2.3

Description
When trying to run an action with requests as a requirement, the system fails to install all dependencies and therefore fails to run.
A temporary workaround is to connect to the worker node and install them manually with pip.
System Info
MacOS Sonoma 14.4.1

It seems it has been fixed on 0.1.29. Thanks!


Fix chat model name

model -> model_name_or_path for chat

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.


[WIP] Snow app version create + version drop

Pre-review checklist

[ ] I've confirmed that instructions included in README.md are still correct after my changes in the codebase.
[ ] I've added or updated automated unit tests to verify correctness of my new code.
[ ] I've added or updated integration tests to verify correctness of my new code.
[ ] I've confirmed that my changes are working by executing CLI's commands manually.
[ ] I've confirmed that my changes are up-to-date with the target branch.
[ ] I've described my changes in the release notes.
[ ] I've described my changes in the section below.

Changes description
...

Re: consistent naming for check vs warn. However, they are doing two different things imo and hence the difference.
E.g. check_index_changes_in_git_repo is checking changes in git and displaying the warning to the user/asking for input.
But warn_user_about_existing_rd is just doing some string manipulation and displaying the warning to the user/asking for input.
Possible consistent corrections can be:
check_index_changes_in_git_repo -> check_index_changes_in_git_repo_and_warn
OR
Remove use of warn_user_about_existing_rd as it only consists of the join and then the call to the user policy, which can be added back to the parent method.
Other methods called get_... have their comments modified now. The intent for these functions is never to interact with the user, but query snowflake and get results.

Edited the policy object after offline discussion with @sfc-gh-bdufour .
Will resolve older comments on this topic. Please create new comments for starting the conversation on the newly pushed changes.

@sfc-gh-bdufour Adding a common comment here after discussion with @sfc-gh-cgorrie on some of the open questions:

The policy on deny by default has been addressed with your suggestion.
Git status check is kept in the code, though it can be omitted by a new flag
Exit codes continue to follow the pattern described in the functional specs.
Executing any commands that have a potential for interactive mode to be invoked will require the use of --force everytime to skip them, such as in a CICD context.


issue with nodejs in windows

after istall all npm packages in windows I face this problem
The system cannot find the path specified.
events.js:180
throw er; // Unhandled 'error' event
^
Error: spawn node_modules\webpack\bin\webpack.js ENOENT
at notFoundError (C:\Users\Eng Omar Alalwi\AppData\Roaming\npm\node_modules\cross-env\node_modules\cross-spawn\lib\enoent.js:6:26)
at verifyENOENT (C:\Users\Eng Omar Alalwi\AppData\Roaming\npm\node_modules\cross-env\node_modules\cross-spawn\lib\enoent.js:40:16)
at ChildProcess.cp.emit (C:\Users\Eng Omar Alalwi\AppData\Roaming\npm\node_modules\cross-env\node_modules\cross-spawn\lib\enoent.js:27:25)
at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
Emitted 'error' event at:
at ChildProcess.cp.emit (C:\Users\Eng Omar Alalwi\AppData\Roaming\npm\node_modules\cross-env\node_modules\cross-spawn\lib\enoent.js:30:37)
at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12) {
code: 'ENOENT',
errno: 'ENOENT',
syscall: 'spawn node_modules\webpack\bin\webpack.js',
path: 'node_modules\webpack\bin\webpack.js',
spawnargs: [
'--watch',
'--progress',
'--hide-modules',
'--config=node_modules/laravel-mix/setup/webpack.config.js'
]
}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @ watch: cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --watch --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @ watch script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR!      C:\Users\Eng Omar Alalwi\AppData\Roaming\npm-cache_logs\2019-10-08T13_56_05_306Z-debug.log
C:\wamp64\www\Logistics_System>

This looks unrelated to cross-env and it's actually related to some file not being found by the script that you're actually trying to run. Sorry.


[FR] Add a dropdown or other type of UI to switch between all set writing goals

Thanks for the great features and updates of Writing goals, it's exactly what I've been missing.
One thing that I think would make the plugin even more streamlined to use is a quick way to switch between set writing goals. My first idea in this regard was a dropdown menu where the goal title is. Here's a quick mockup in Excalidraw:

Another option could be arrows on the left and right of the title, which switched to the next writing goal. To ensure that this wouldn't be arbitrary, the order could be by deadline (yes, not something that's implemented right now, but I think it makes sense to be able to associate goals with deadlines, as many writing projects have those). However, this option is tied to another feature request, namely deadlines as mentioned, so it is more involved and perhaps problematic.

Thanks for the request. My preference is for arrows to cycle through your goals as a dropdown could be unwieldy, particularly if there are a number of goals to select from.
I have a PoC of this with the loaded order of goals but this could be changed in the future based on sorting logic.
I should have this in place in a release over the next couple of days.

Feature added in 0.7.0

Feature added in 0.7.0

Works great so far!


Support for helm upgrade and rollback operations

For the helm module , https://github.com/gruntwork-io/terratest/tree/master/modules/helm
Can we have support for helm upgrade and rollback operations also.
Currently I see support for install and delete only.

That's a good idea to add! We are pretty buried at the moment so won't get to this in the short term, but any PRs if people are willing and able are welcome!

I will try to put up a PR after few rounds of local testing.

This was released in https://github.com/gruntwork-io/terratest/releases/tag/v0.17.6


fix(webapp): remove ripple effect

Remove ripple from button component
What does this PR do?

Resolve #385

Steps to test

make run

why did you decide to disable the ripple effect?


chore(Topology/MetricSpace/PseudoMetric): Split

This reduces the long pole.

Let me cross-reference #13977 which tries the same. (I'll be happy to review either, but submitting my PhD thesis takes priority -> I may take about a week to get to this.)

Ah, a pity, I wish I'd seen this before duplicating the work. I'm perfectly happy to defer to Yael's version if they can fix the merge conflicts. (Although, the import analyzer does seem to rate mine epsilonically better. :-)

bors merge

To add yet another comment: the diff here also had those stray structure-less "structure."!

Oh sorry @semorrison I wanted to compare our two approaches to understand why your PR performs better on import changes. I merely merged master to check the new long pole. 🙈


Uncaught ValidationErrors causing 500 responses

This try/catch block should cover the full function body. The Response constructor can raise a ValidationError if response_data does not have the expected response type.
https://github.com/autotraderuk/fastapi-mlflow/blob/98701a0f5af535ceedda78c07759f5a3b6b62b8e/fastapi_mlflow/predictors.py#L80-L87

Thanks @Andrew-Crosby
Yes, I see. Do you think it would be best to raise the same PyFuncModelPredictError or would something like PyFuncModelPredictionTypeError be better? Either way, I think that this will probably continue to raise a 500 Internal Server Error, as the model is returning data that does not comply with the specified signature (assuming that relevant data types are correctly mapped, see #10 and #11), and there's not much that the fastapi-mlflow code can do to repair or recover.


Preserve Tabs on a new line

Trying to figure out a way to preserve the tab spacing in the editor when creating a new line so the column goes to the last line's tabs from the starting line.  Instead of writing something from scratch, is there something built into the scintilla syntax that does this?

This has been discussed a bit in our forums and a few solutions presented in issue #35.

Thanks, I did eventually find an example I could modify.  Thanks for your hard work on this project!


walker positions not changing in Parallel-Tempering Ensemble MCMC

I construct the sampler object in the usual way: sampler=PTSampler(...) and then iterate over the generator. I am outputting the results of every 10th step to a text file, just for monitoring while testing by doing:
for i, result in enumerate(sampler.sample(position0, interations=1000)):
position_new = result[0]
lnprob_new = result[1]
lnlike_new =  result[2]
This works fine when I use EnsembleSampler, but with PTSampler the position_new never changes. The lnlike_new and lnprob_new change whenever there is an accept and lnprob_new also changes when there is a temperature swap.
@farr @dfm

I also tried running 'sampler.run_mcmc(position, nsteps)',  the printed each step of 'sampler.chain' and 'sampler.lnlikelihood' to a file. I got the same behavior, where the walker positions never change, but lnlikelihood will change whenever there is an accept and lnprob_new also changes when there is a temperature swap.
Has anyone else seen this?

@farr: Any thoughts?
@tinapeters: Can you come up with a minimal example (i.e. no dependencies, etc.) that reproduces this behavior and post that code?

@farr: here's an email from @tinapeters (06-26-2017). I'm not familiar enough with the PTSampler to debug what's going on. Can you take a look?

This is the closest I could get to a minimal example that reproduces this behavior. Lines 20, 21, and 22 are a subset of my data that I'm trying to fit, so you don't have to worry about loading the file.
When I run the example here or run the attached code with ntemps = 1 I don't see the odd behavior I described earlier. However, when I run with ntemps > 1, I do.
Hopefully, this helps us get to the bottom of it.

I'm going to close this issue for now because I've made the executive decision to remove the PTSampler from the next release of emcee. I don't have the expertise or patience to maintain this part of the project. Sorry!

You can check out https://github.com/willvousden/ptemcee for a more or less compatible implementation by people who actually know what they're doing!


Update docker-compose.yml with frequently used environment variables …

…for php container

closes #507
closes #508

Hi, why set log level to 0? We probably do need to change the default to 3

The php image already uses the default log level value if xdebug is enabled.
In case I want to change the log level I'll uncomment the line and set a different log level.
Unless xdebux connection is not configured by a developer default value is enough to help establish it. Once IDE listens to the web server correctly logging is no longer needed.
So frequently used values for xdebug logger level are 3 or 0. That`s why I provided a different to the default value for the xdebug logging level.

Unless xdebux connection is not configured by a developer default value is enough to help establish it.

The current default log level is 7 which information, I guess it makes sense to change it to 3 (warnings), change it directly in the wodby/php image, not just here through env vars

Added related PR https://github.com/wodby/php/pull/184


docs: add note about vscode-vim in on_enter

I found myself search for this, so building off of #3013 and #3308, I
hope this note is useful.

bors r+
changelog fix (first contribution) about vscode-vim in the onEnter docs

Huh, I haven't seen that yet. Thanks much. I had considered a note such as "When using the Vim plugin, append && vim.mode == 'Insert'", but felt it could have been unclear.


Unable to load interface for pkg

I wasn't sure whether I should file this against hsdev or SublimeHaskell, so please let me know if I should refile against the latter.
I've recently been having an issue with hsdev (via SublimeHaskell) reporting that it could not load interfaces for multiple packages. Said packages are available, and managed by stack, so no issues appear when running stack build. However, in the cases where the issue has been appearing, the libraries in question have not been available in cabal. Running cabal install pkgname will prevent the error from occurring.
The hsdev version was built with the system compiler (ghc-8.0.1) as hsdev cannot currently be built with stack (version bounds failures for all recent lts releases, according to stack solver. This seems to imply hsdev is unable to load interfaces from packages in the stack project, but please correct me if I'm wrong.
Are there any expected reasons that hsdev is unable to pick up the stack curated libraries?
Ideally, it would work with stack-managed packages, removing the requirement to maintain multiple unnecessary package versions on the system. It would also be great to be able to install hsdev via stack, removing the need for cabal-install entirely, but that is a separate issue.

I'm experiencing the same issue with hsdev-<IP_ADDRESS> built with stack (using extra-deps).

This seems to be the same problem I opened here: https://github.com/mvoidex/hsdev/issues/59
However, when I try to do a cabal install text to fix the issue described there. Cabal tells me I already have it:
$ cabal install text
Resolving dependencies...
All the requested packages are already installed:
text-<IP_ADDRESS>
Use --reinstall if you want to reinstall anyway.


New sub's don't trigger

Updating to the newest tmi.js should fix this.
https://github.com/tmijs/tmi.js/commit/2d0cbb6ea4e8e82fa80289e90954970eeab0009a

Potentially fixed, will close if works

106d5847882f950da4b08bf75ea0aa83e2f9bbac


Pdfjs find controller search issue

Attach (recommended) or Link to PDF file here:
Configuration:

Web browser and its version:
Operating system and its version:
PDF.js version:
Is a browser extension:

Working Angular 6
searchQuery(newQuery: string, frompage) {
this.pdfComponent.pdfFindController.executeCommand('find', {
caseSensitive: false,
findPrevious: undefined,
highlightAll: true,
phraseSearch: true,
query: ''alubmin'',
});
}
My pdf size is - 59.5MB
Pages - 1203
When I call the searchQuery() for the first time and parallelly load pdf rendering the highlighted text taken a minimum of 1 minute.
What is the reason?
The below screenshot when I search a query as alubmin but on that page, there is no highlighted text like that.
After pdf fully download 59.5 MB then will take 1 minute after that the word alubmin highlighted.

Please give anyone Solution for the above issue?
The Question is not get let me know?

Attach (recommended) or Link to PDF file here:
Configuration:

Web browser and its version:
Operating system and its version:
PDF.js version:
Is a browser extension:

When opening an issue, please provide all of the information requested in https://github.com/mozilla/pdf.js/blob/master/.github/ISSUE_TEMPLATE.md (including clear and concise steps to reproduce the issue); as-is this issue unfortunately isn't actionable/valid and will be closed as INVALID.

Working Angular 6

We don't know anything about "Angular 6" here, and consequently we cannot help with that.

searchQuery(newQuery: string, frompage) {
this.pdfComponent.pdfFindController.executeCommand('find', {
caseSensitive: false,
findPrevious: undefined,
highlightAll: true,
phraseSearch: true,
query: ''alubmin'',
});
}

Furthermore, please see https://github.com/mozilla/pdf.js/blob/master/.github/CONTRIBUTING.md (emphasis mine):

If you are developing a custom solution, first check the examples at https://github.com/mozilla/pdf.js#learning and search existing issues. If this does not help, please prepare a short well-documented example that demonstrates the problem and make it accessible online on your website, JS Bin, GitHub, etc. before opening a new issue or contacting us in the Matrix room -- keep in mind that just code snippets won't help us troubleshoot the problem.

My pdf size is - 59.5MB
Pages - 1203

That's a lot of data, and it's not reasonable to expect that all of it could be parsed immediately.

All-in-all, this issue is missing all of the information required to be valid and it's also somewhat difficult to even understand what (if any) the problem is here.

@Snuffleupagus ok.thanks for your reply. let me know in pdfjs-dist up to how much amount of data size support?
Tel me the pdf size I will be restricted in my application.
Because small size pdf has highlighted my search query immediately but large size pdf file to much amount of time
taken for my search query to highlight the text.

let me know in pdfjs-dist up to how much amount of data size support?

There's no particular restrictions in the PDF.js library; hence performance is simply limited by the speed of your computer.

Because small size pdf has highlighted my search query immediately but large size pdf file to much amount of time
taken for my search query to highlight the text.

It should hopefully be obvious that larger PDF files takes longer to parse than smaller files, however if you don't provide any of the requested data (such that the issue is easily actionable) it's simply impossible for anyone to assist further!
(Also, the screen-shot in https://github.com/mozilla/pdf.js/issues/12565#issue-735113419 doesn't show the default viewer, hence there could e.g. be bugs in your viewer.)

@Snuffleupagus I am using ng2-pdf-viewer
I am using pdfjs-dist is the dependency file for ng2-pdf-viewer
Is That any option to give the solution in the pdfjs-dist directory?

I am using ng2-pdf-viewer

That's a completely different project, which we know nothing about here and consequently cannot provide support for.
Unless you can reproduce the problem using the PDF.js library directly, without another library on top of it, it's unfortunately not possible for anyone here to really help.
Finally, you've still not provided any of the information required for this issue to be actionable/valid; please read through https://github.com/mozilla/pdf.js/issues/12565#issuecomment-721006544 carefully.


Navigation Tabs Border Color

Not sure if this is a 'bug' or 'working as intended', but the border-bottom attribute of inactive navigation tabs might need to be changed from --foreground to --contrast at line 251.
In the official themes, inactive tabs don't have a visible bottom border, which improves contrast when determining which tab is 'active' at a glance. With the current settings, it feels like there may not be enough contrast here:

Fix is done. Waiting for merge to main.


-Make the randfunc to generate a private_key modifiable

I would like to suggest this change as well. It is useful for example when you generate private keys derived from a master secret or want to use another random number generator.  This is a similar syntax to "PyCryptodome/ RSA.generate(self.size, randfunc=randfunc) "

I'd like to think about this a little more. On the one hand flexibility is nice, on the other hand this also lets you use non-cryptographically secure random sources, which gives users a way to shoot themselves in the foot, and it may be "overstepping" the bounds of what this package is trying to accomplish. Any thoughts?

I think it is important to have this. Not specifically for me as I can just copy and modify the function, but the random source is an important design decision which you can't decide for the user (this might even be decided by management, internal regulation, etc..). You can provide a good default value (os.urandom), but they might want to use 1/ a hardware RNG, 2/generate their random by PKDF from a master key (like in my problem, e.g. useful for having an immediately "backuped" key), 3/ trust better the random from openssl than from python 4/ Combine multiple of the previous ones to protect against RNG  security issues.
It can also be useful for testability (see the testcase I attached to this pull request). By writing it I verified the gen_private_key function and it seems correct :)
I think the user error providing an unsecure RNG is very unlikely as 1/ users will  just use the default values and follow the examples, or they will know what they are doing 2/ the "random" module doesn't provide a "rand_bytes" function (just a getrandbits) 3/ "Autoimport" mistakes which can sometimes happen between "random" and "random.SystemRandom()" are not affecting this particular case because the default is called "urandom".
Libraries like PyCryptodome which are the reference also have this feature.
I tried looking at more libraries to see if they allowed it, and funnily enough when looking at "ecdsa-python" I found a far worse issue as they were using unsecure random by default both to generate and to sign with the private key ! I submitted an issue and they will fix it


Implement hook to fetch dataset definition from remote source

Motivation
Personally, I find it more logical to store the definition of datasets that should be accessible through vitessce in the same place as the datasets themselves, e.g. an S3 bucket. Moreover, it is easier to update the dataset definitions because rebuilding vitessce is not necessary. Using an environment variable to define the remote location of the JSON file containing the dataset definitions means that the vitessce code does not need to be touched at all when changing the remote location.
Details of the PR

Move existing/internal/local dataset definition to new file: datasets.js.
Implement new useDatasets() hook that fetches dataset definition from JSON file at remote location.
Remote location containing dataset definition is set through REACT_APP_URL_DATASETS environment variable. If that variable is not set or loading failed, e.g. because the target file does not exist, vitessce will fall back to internal datasets (datasets.js).
A "Loading..." panel is shown while data is being fetched from remote source.
A new <App> component is defined to use the useDatasets() hook within and then decide whether to show a "Loading..." panel, the <Welcome> component or the <Vitessce> component (if a dataset ID is provided in the URL). The createApp() function now returns the <App> component.
The getConfig() and listConfigs() now take the available datasets as an input parameter.

Please let me know what you think about this.

@romanhaa Just trying to understand more about the use case - are you deploying the Vitessce demo website somewhere and you want to have remote datasets from a common URL that is set in the ENV?  I ask because we already support fetching datasets by URL via the http://vitessce.io/?url= URL.

Well, that's awkward, I completely missed that... There might be some parts to recycle but I'll just book this as an exercise.

Ok @romanhaa no worries, it's not super obvious as it's not in the README.md, so I'll add something about that.

I suppose the only real advantage of this implementation is that it can contain multiple datasets. So it's still possible to present the user with a set of datasets to choose from. Because using the http://vitessce.io/?url= mechanism only works with JSON files for a single dataset, right?

@romanhaa That's correct.  The URL can only take one JSON file at a time.  It also doesn't affect what the landing page of vitessce.io looks like - it takes the user straight to the visualization.


graph/encoding/dot: store graph DOT ID if present

Thanks

You can do the merge, but it occurs to me that maybe there should be a graph label on the test cases to check this.

I'll add a test case for it and push sometime next week :)

PTAL


Walkthrough Document: Conditional Transitions has unsupported syntax

Describe the bug
In the walkthrough document: https://github.com/vorteil/direktiv/blob/e86604f/specification/walkthrough/04_conditional-transitions.md , there is a Foreach State example. This example has a foreach state that iterates over array: '{ .names }'. However at this moment, this syntax {.names} is not a supported iterable.
This issue can be fixed by simply changing what array iterates over to .names[] | { name: . }, but this probably needs some additional explanation/context in the documents.
To Reproduce
Just run this workflow:
id: multiposter
functions:
- id: httprequest
  image: vorteil/request
states:
- id: poster
  type: foreach
  array: ".names[] | { name: . }"
  action:
    function: httprequest
    input: '{
      "method": "POST",
      "url": "https://jsonplaceholder.typicode.com/posts",
      "body": {
        "name": .name
      }
    }'
  transform: 'del(.names) | .names = []'

Smartphone (please complete the following information):

Device: iPhone6
OS: iOS8.1

This article also mentions it https://docs.direktiv.io/docs/examples/math.html

Fixed Issue on Docs Repo


[Bug]: compatibility with older TS versions differs between jest and jest-environment-jsdom

Version
latest
Steps to reproduce
See: https://github.com/mrazauskas/x-jest-ts-compat/actions
With "skipLibCheck": false set TypeScript 4.2 compiles the library with only jest installed. Compilation fails if jest-environment-jsdom is added. The culprit is parse5 (a dependency of jsdom), which is using type tokens in import statements:

Hence jest-environment-jsdom requires TypeScript 4.5, if library is build with "skipLibCheck": false set.
Expected behavior
Should this be documented. Perhaps? Nobody complained so far.
Actual behavior
Why TS compatibility test does not cache it? Felt like the script is building Jest repo using TS 4.3? Or I missed something?
Additional context
No response
Environment
System:
    OS: macOS 12.5.1
    CPU: (10) arm64 Apple M1 Pro
  Binaries:
    Node: 18.9.0 - /opt/homebrew/bin/node
    Yarn: 1.22.19 - ~/.yarn/bin/yarn
    npm: 8.19.1 - /opt/homebrew/bin/npm
  npmPackages:
    jest: ^29.0.3 => 29.0.3

It's mentioned in the upgrade guide: https://jestjs.io/docs/next/upgrading-to-jest29#jsdom-upgrade

Ah.. Right! This is what I missed.

We might wanna put it in a more prominent place?

I made few attempts, but couldn’t find better solution. Also I hit this just by experimenting, that did not came from usage. If users don’t complain, all is fine.


Create an intro

Add an intro about yourself: who are you, what is your strength, why are you here.

<p class="intro_text">Hi there! I'm Mohammad Ramdzuanny, and this is my attempt to build a portfolio.                       Might not be much here for now but stay tuned whilst I slowly update this page as I progress through my                       coding journey! Wish me luck!                     </p>


Login error: AxiosError: Request failed with status code 429, reconnect in  120s.

Constantly getting error - Login error: AxiosError: Request failed with status code 429, reconnect in  120s.
Was working fine the other day. I have made no changes. I have tried 150 refresh instead of 120 and still nothing. I have updated to beta 2 and still nothing.
Logs attached.
homebridge.log.txt

Your account is locked, disable plugin for few hours and start again. If you have also other integrations then disable it too.

Disabled it and re-enabled it. Different error now...
TypeError: Cannot read properties of undefined (reading '0')
at MelCloudAtw. (/var/lib/homebridge/node_modules/homebridge-melcloud-control/src/deviceatw.js:315:50)
at MelCloudAtw.emit (node:events:518:28)
at MelCloudAtw. (/var/lib/homebridge/node_modules/homebridge-melcloud-control/src/melcloudatw.js:418:22)

fixed


No support for code indentation in .lang files

Describe the bug
Syntax highlighting for .lang files doesn't support indentation.
To Reproduce
Paste this code to your .lang file.
normal.key=Hello
other.key=Other value

    this.is.intersesting=Wow! That's a lot of errors

Expected behavior
Not getting errors. This is a valid file.
Screenshots

Desktop (please complete the following information):
N/A
Smartphone (please complete the following information):
N/A
Additional context
N/A

Is the problem present in version 1.0.2?
I noticed it myself and uploaded a patch, but I'm unsure if it reached you in time.

Seems to be working now. Thanks.

I think I uploaded the new version at the moment you reported the issue.
Still always good to have people reporting problems! 👍


Refactor lookup table computation in malaria poll to avoid memory spike

In https://github.com/UCL/TLOmodel/issues/1163#issuecomment-1811438520 I noted that from memory profiling of a run of the src/scripts/profiling/scale_run.py script, there appeared to be sharp peaks in memory usage corresponding to Malaria.malaria_poll2 method called at
https://github.com/UCL/TLOmodel/blob/4bffc1a3c8d5ae7336ea4534486830255a0173e1/src/tlo/methods/malaria.py#L652
which is in a monthly scheduled event MalariaPollingEventDistrict, with around ~300MB increase in memory usage during these peaks, as visible in the following plot of overall memory usage:

Looking at the flamegraph representation of the peak memory usage in a narrow window around one of these spikes we get the following breakdown for the Malaria.malaria_poll2 method call

with the width of the bars proportional to the total memory allocated by the function (and each bar a function / method in the call stack with lower bars further 'down' / nested in the call stack).
This suggested it was evaluations of the _draw_incidence_for nested function which was the key culprit, and in particular the line
https://github.com/UCL/TLOmodel/blob/4bffc1a3c8d5ae7336ea4534486830255a0173e1/src/tlo/methods/malaria.py#L306
This line selects a subset of the population dataframe rows, sets the index of this resulting new dataframe to use the values of the district_num_of_residence and ma_age_edited columns, and then gets just the index of this resulting dataframe. As the dataframe returned by the initial indexing by _where to get a row subset will still contain all the columns in the original population dataframe, I suspect this is what is leading to the large memory allocations. As we subsequently only need the district_num_of_residence and ma_age_edited columns, we can use the loc indexer to simultaenously select a subset of rows using _where and the two relevant columns, then reindex this much smaller (in terms of number of columns) dataframe inplace avoiding a further dataframe copy and memory allocation, before extracting the index. With these changes as implemented in this PR we get the following overall memory usage plot

which does seems to have had the desired effect of substantially decreasing the amplitude of the spikes.

Just to note - I don't think this is a significant factor in the out-of-memory issues described in #1163, but I thought it was worth submitting a PR to fix given I'd noticed it as part of the investigations there!


Issue with converting some .med files with results

Meshes.zip
I have encountered some issues using meshio in converting med files (generated by CodeAster) to xdmf. Attached are 4 .med files:
UnitCube.med - the mesh used
Meshanical.med - results for mechanical simulation
Thermal.med - results for thermal simulation
TransientThermal.med - results for time-dependent thermal simulation
UnitCube.med and Thermal.med both convert as expected.
TransientThermal.med converts, however the results for each timestep are stored as individual results, meaning that they can't be viewed as an animation in paraview.
Mechanical.med I receive the error:
"AssertionError: Incompatible cell data. 3 cell blocks, but 'reslin__SIEF_ELGA' has 1 blocks"
I believe this is to do with the fact that the results generated are explicitly for volume elements, so it is only to these that the results are applied, however meshio also looks for results for the remaining elements (faces and edges).
Thanks
Rhydian

Note that the med files created by CodeAster are often output as .rmed files however the extension for these has been changed to .med to use with meshio

Ok will have a look :-)


util: update GCTimeFormat to be the same as the value stored in PD

The GC-related time stored in TiKV is inconsistent with the time stored in PD. The value in TiKV, the time format is "20060102-15:04:05 -0700", and the precision is only seconds. In PD, it stores a uint64 with millisecond precision.
The if we use the value got from TiKV to do some processes, it will got a error like this,
mysql> flashback cluster to timestamp '2022-11-07 10:34:00';
ERROR 9006 (HY000): GC life time is shorter than transaction duration, transaction starts at 2022-11-07 10:34:00 +0800 CST, GC safe point is 2022-11-07 10:34:00.366 +0800 CST

@sticnarf PTAL


Typing my username in the search bar

Hi,
For some reason, the script is automatically typing my username into the search bar on both Reddit and GitHub.

Script Version: 6.0.1
Violentmonkey Version: 2.15.0
Browser: Chrome Version 116.0.5845.141 (Official Build) (64-bit)

Hi,
For some reason, the script is automatically typing my username into the search bar on both Reddit and GitHub.

Script Version: 6.0.1 Violentmonkey Version: 2.15.0 Browser: Chrome Version 116.0.5845.141 (Official Build) (64-bit)

Does this still happen when you disable the script?
From what I recall the script should only auto fill boxes within it's little window

Same here

Does this still happen when you disable the script?

No, It doesn't happen if I disable the script. And, as Trixarn mentioned, that happens on other websites as well.

coming here to report similar issue but already found this.
yeah I also encounter this problem currently. whenever I activate the Magic Userscript+ it autofills my username into the searchbar of most websites (twitter, facebook, reddit, all types of forum sites, etc). problem doesn't occur when the script is disabled.

so am i

same

Yep, and same problem here.

俺也一样

Just to let you know, the issue has not been resolved in the recent update.

Just to let you know, the issue has not been resolved in the recent update.

I have finally identified this bug. Your user name was being typed due to Chromes password manager auto filling any input type="search" with your saved username & input type="password" with your saved password. The userscript injects a password type input. I shall release a fix for this in this next update.


Fragmented object segmentation

I am trying to do non-continuous instance segmentation
also called:

Disconnected instance segmentation
Fragmented object segmentation
Disjoint instance segmentation
preview:

Which models in MMDetection support this kind of data ?

Any model with a 2d mask output rather than a set of points will work with that type of data.  Most methods are compatible.  The MMDetection annotation pipelines should load standard COCO segments with multiple parts.
PolarMask: Single Shot Instance Segmentation with Polar Representation
PointRend: Image Segmentation as Rendering
These are two example of methods that may not be compatible.


Please consider adding a link to my repo

My repo: https://github.com/jqqqqqqqqqq/coolq-telegram-bot
I have fixed some bugs in cqsdk and added a new feature to use multiple function to handle same incoming event in a queue, like what python_telegram_bot did
Also, I added some other class to decode anonymous message or group member's info.
@JogleLew upgraded cqsdk to fit the newest version of socketapi.
We appreciate your amazing work in creating socketapi and we want to help maintaining cqsdk.

Thanks. Seem someone have updated https://github.com/yukixz/cqsocketapi. Could you give me the latest repo that i can update readme of socketapi repo too.

I didn't make any change in socketapi. The new cqsdk is based on your latest cqsocketapi.

OK, thanks for all.


jack no longer ships with tools

Describe the bug
jack2 as of 1.9.22 no longer ships with tools or examples, those now live in a separate repo (https://github.com/jackaudio/jack-example-tools). it doesn't look like these have been packaged yet, removing a bunch of important utilities with no replacement.
Notify maintainers
@cillianderoiste @matthiasbeyer (approved the bot update) @risicle (merged & tested)

Ah semantic versioning, I knew ye well.


Fix measuring lines in presence of pending autoscroll requests

Fixes https://github.com/atom/atom/issues/15168.
Calling pixelPositionForScreenPosition was sometimes throwing an error indicating that the requested position was not rendered and that, as such, could not be measured.
This was caused by trying to measure a line that was visible at the moment of the call while also having a pending autoscroll request that would cause that line to go off-screen. Due to how the code was structured, we would mistakenly detect that line as visible, autoscroll to a different location, re-render a different region of the buffer and then try to measure the now invisible line.
This commit fixes this issue by restructuring and simplifying the logic for rendering invisible lines in order to measure them. Now, every line for which a measurement has been requested is stored in a linesToMeasure map. During the first phase of the update process (after honoring autoscroll requests), we detect which of these lines are currently visible and if some of them are not, we store them into the extraRenderedScreenLines map, which is then used to render lines that are invisible but need measurement.
@Ben3eeE @ungb: I am unable to reproduce the issue after this pull-request. Can you help me ensure this fixes all the reports we've got for this issue so far? They seem to be generated by slightly different reproduction steps, although I think they can all be traced back to the root cause described above.
/cc: @nathansobo for 👀

@as-cii I tested both to scroll while alternating holding page up and page down and to scroll by pasting text and it looks good to me. I am unable to reproduce the issue after this pull-request.

Awesome work @as-cii!


NotImplementedError when projecting during asm

I'm trying to work with something from P0 and something from P1 in the same form. (Specifically, in the form I want to do grad(w['thing_p1']) * w['thing_p0'] as part of a possible solution to https://github.com/kinnala/scikit-fem/issues/821.)
But I've run into a NotImplementedError and I'm not too sure what isn't implemented.
import skfem

mesh = skfem.MeshTri()

basis_p1 = skfem.Basis(mesh, skfem.ElementTriP1())
basis_p0 = basis_p1.with_element(skfem.ElementTriP0())

f1 = basis_p1.zeros()
f0 = basis_p0.zeros()

@skfem.Functional
def issue_demo(w):
    return w.x[0] # arbitrary, just something of the correct shape

skfem.asm(issue_demo, basis_p1, f1=f1, f0=basis_p1.project(f0))

raises
---------------------------------------------------------------------------
NotImplementedError                       Traceback (most recent call last)
~/ipykernel_21860/2766063479.py in <module>
     13     return w.x[0] # arbitrary, just something of the correct shape
     14
---> 15 skfem.asm(issue_demo, basis_p1, f1=f1, f0=basis_p1.project(f0))

\scikit-fem\skfem\assembly\basis\cell_basis.py in project(self, interp, elements)
    229         from skfem.utils import solve, condense
    230
--> 231         M, f = self._projection(interp)
    232
    233         if elements is not None:

\scikit-fem\skfem\assembly\basis\abstract_basis.py in _projection(self, interp)
    432         return (
    433             BilinearForm(lambda u, v, _: inner(u, v)).assemble(self),
--> 434             LinearForm(lambda v, w: inner(interp, v)).assemble(self),
    435         )
    436

\scikit-fem\skfem\assembly\form\form.py in assemble(self, *args, **kwargs)
     77         assert self.form is not None
     78         logger.info("Assembling '{}'.".format(self.form.__name__))
---> 79         out = (COOData(*self._assemble(*args, **kwargs))  # type: ignore
     80                .todefault())
     81         logger.info("Assembling finished.")

\scikit-fem\skfem\assembly\form\linear_form.py in _assemble(self, ubasis, vbasis, **kwargs)
     42             ixs = slice(nt * i, nt * (i + 1))
     43             rows[ixs] = vbasis.element_dofs[i]
---> 44             data[ixs] = self._kernel(vbasis.basis[i], w, dx)
     45
     46         return np.array([rows]), data, (vbasis.N,), (vbasis.Nbfun,)

\scikit-fem\skfem\assembly\form\linear_form.py in _kernel(self, v, w, dx)
     47
     48     def _kernel(self, v, w, dx):
---> 49         return np.sum(self.form(*v, w) * dx, axis=1)

\scikit-fem\skfem\assembly\basis\abstract_basis.py in <lambda>(v, w)
    432         return (
    433             BilinearForm(lambda u, v, _: inner(u, v)).assemble(self),
--> 434             LinearForm(lambda v, w: inner(interp, v)).assemble(self),
    435         )
    436

\scikit-fem\skfem\helpers.py in inner(u, v)
    109     elif len(U.shape) == 4:
    110         return ddot(U, V)
--> 111     raise NotImplementedError
    112
    113

NotImplementedError:

The error is very confusing, I'm sorry about that. This is the fix:
skfem.asm(issue_demo, basis_p1, f1=f1, f0=basis_p1.project(basis_p0.interpolate(f0)))

Moreover, we obviously need some checks in project so that this does not happen.

The thing is that project assumes it needs to call basis_p1.interpolate when calling basis_p1.project even though f0 is defined using basis_p0.

The need for interpolate is confusing because I would have expected basis_p1.with_element to have resolved that. Is the underlying issue the fact that you can't tell what "kind" of  numpy array you're working with? Is it worth considering subclassing ndarray (a non-trivial task to do correctly) so that it can carry some additional attributes, specifically its basis?

I've been considering about the possibility of subclassing ndarray but have so far have decided against it. Working with the native objects of numpy and scipy is somehow fundamental to this library. All other libraries have some kind of GridFunction and BilinearOperator instead of simple ndarray and scipy.sparse. While it would enable many automagic things I'd prefer keeping it this way.

I think this issue and https://github.com/kinnala/scikit-fem/issues/847 are looking like pretty much the same thing now. Not sure if you can merge them... or maybe just close one of them.
I think it boils down to DiscreteField needing a little more to duck type ndarray and/or the question of whether to subclass ndarray for discrete fields and projections.  (Do you think "discrete fields" and "projections" are the right words for the two kinds of data structures we're talking about here?)


fix: apply custom cursor pagination where workflows and archived workflows are merged

Fixes #11715
Motivation

Workflows and archive workflows use different pagination logics.
However, in the current workflow page, if both workflows and archive workflows coexist, we want them to be retrieved together.
The issue arises from passing the pagination options used for workflows pagination directly to archive workflows, causing a mismatch between the types used in archive workflows and workflows, resulting in archive workflows not being retrieved.
Modifications

I have implemented the following logic to resolve this issue:

fetch the entire list of workflows and archived workflows separately.
merge the workflows and archived workflows.
perform cursor pagination on the merged result based on the resourceVersion.

After contemplating on how to address this issue, I concluded that the conventional approach of paginating workflows and archived workflows separately would not easily resolve this problem. Therefore, I implemented it in this manner.

Verification

Confirming the pagination is functioning correctly.
Checking if Archive workflows are retrieved successfully.
Verifying that Workflows are retrieved correctly.
Validating the proper functioning of tests with the 'make test' command.

This is great! Could you also look into adding some tests around cursorPaginationByResourceVersion?

Sure! I'll write a test code and upload a commit tomorrow :)

This looks good once the last comment and the conflicts are resolved. Great work! This should be included in the next RC https://github.com/argoproj/argo-workflows/issues/11381

Need to sort the imports

@sunyeongchoi Looks like the test is flaky. See https://github.com/argoproj/argo-workflows/actions/runs/6166062084/job/16734921912

@sunyeongchoi Looks like the test is flaky. See https://github.com/argoproj/argo-workflows/actions/runs/6166062084/job/16734921912

Oh no, I'll quickly post a PR fixing that test. sorry.

@sunyeongchoi Looks like the test is flaky. See https://github.com/argoproj/argo-workflows/actions/runs/6166062084/job/16734921912

I uploaded bugfix PR about this :) https://github.com/argoproj/argo-workflows/pull/11816
Thaks for your report.


num_adslabs should be removed via refactor

https://github.com/ulissigroup/catlas/blob/main/bin/predictions.py#L359
Must require that user specify options such that num_adslabs is never undefined during execution of catlas

https://github.com/ulissigroup/catlas/pull/155 makes it clear that num_adslabs will always be calculated consistently


Mismatch Types and Documentation for change:source Event

Describe the bug
When compiling OL with typescript and using the "change:source" Event on a Layer I get an unexpected compilation error.
To Reproduce
Steps to reproduce the behavior:

Have a BaseLayer object, and call lyr.on('change:source', ...) which is a valid Event according to the docs at https://openlayers.org/en/latest/apidoc/module-ol_layer_Layer-Layer.html

Typescript compilation error (Tested with ol 8.1.0 and 8.2.0):

     TS2769: No overload matches this call.
  Overload 1 of 3, '(type: EventTypes, listener: (event: BaseEvent) => unknown): EventsKey', gave the following error.
    Argument of type '"change:source"' is not assignable to parameter of type 'EventTypes'.
  Overload 2 of 3, '(type: BaseLayerObjectEventTypes, listener: (event: ObjectEvent) => unknown): EventsKey', gave the following error.
    Argument of type '"change:source"' is not assignable to parameter of type 'BaseLayerObjectEventTypes'.
  Overload 3 of 3, '(type: ("error" | "change" | "propertychange" | "change:extent" | "change:maxResolution" | "change:maxZoom" | "change:minResolution" | "change:minZoom" | "change:opacity" | "change:visible" | "change:zIndex")[], listener: (event: Event | BaseEvent) => unknown): EventsKey[]', gave the following error.
    Argument of type '"change:source"' is not assignable to parameter of type '("error" | "change" | "propertychange" | "change:extent" | "change:maxResolution" | "change:maxZoom" | "change:minResolution" | "change:minZoom" | "change:opacity" | "change:visible" | "change:zIndex")[]'.

Expected behavior
Typecheck succeeds

Thanks for the bug report. Would you be able to provide a pull request with a fix?

BaseLayer does not have a change:source event, only a Layer. My bad


Division operators / s-strings

What's up?
We've recently added an int division operator, and moved some logic from the compiler to s-strings.
Moving logic to s-strings is great – it means when we get an issue "this dialect doesn't work with X", it's really easy for someone to make a contribution.
But it does have a couple downsides — in particular because they're only strings, they don't know about precedence. That means that need to add defensive parentheses per https://github.com/PRQL/prql/pull/2693, meaning we end up with quite an expression (both because of the float coercion and the parentheses, let's just focus on the parentheses here though):
-  ((temp_c - 32) / 1.8 - 0) / 100 AS boiling_proportion
+  ((temp_c - 32 * 1.0 / (1.8)) - 0 * 1.0 / (100 - 0)) AS boiling_proportion

I'm particularly concerned about this with the generic SQL translation that folks first encounter when they're approaching the language — I think it's quite important to signal that PRQL is easy to engage with, inspectable, etc.
One option — parse the s-string into a SQL AST with sqlparser-rs, replacing the variables with $. So
ROUND(ABS(($l) / ($r)) - 0.5) * SIGN(($l) / $r)

...gets parsed into[^1]:

{
  "BinaryOp": {
    "left": {
      "Function": {
        "name": [
          {
            "value": "ROUND",
            "quote_style": null
          }
        ],
        "args": [
          {
            "Unnamed": {
              "Expr": {
                "BinaryOp": {
                  "left": {
                    "Function": {
                      "name": [
                        {
                          "value": "ABS",
                          "quote_style": null
                        }
                      ],
                      "args": [
                        {
                          "Unnamed": {
                            "Expr": {
                              "BinaryOp": {
                                "left": {
                                  "Nested": {
                                    "Value": {
                                      "Placeholder": "$l"
                                    }
                                  }
                                },
                                "op": "Divide",
                                "right": {
                                  "Nested": {
                                    "Value": {
                                      "Placeholder": "$r"
                                    }
                                  }
                                }
                              }
                            }
                          }
                        }
                      ],
                      "over": null,
                      "distinct": false,
                      "special": false,
                      "order_by": []
                    }
                  },
                  "op": "Minus",
                  "right": {
                    "Value": {
                      "Number": [
                        "0.5",
                        false
                      ]
                    }
                  }
                }
              }
            }
          }
        ],
        "over": null,
        "distinct": false,
        "special": false,
        "order_by": []
      }
    },
    "op": "Multiply",
    "right": {
      "Function": {
        "name": [
          {
            "value": "SIGN",
            "quote_style": null
          }
        ],
        "args": [
          {
            "Unnamed": {
              "Expr": {
                "BinaryOp": {
                  "left": {
                    "Nested": {
                      "Value": {
                        "Placeholder": "$l"
                      }
                    }
                  },
                  "op": "Divide",
                  "right": {
                    "Value": {
                      "Placeholder": "$r"
                    }
                  }
                }
              }
            }
          }
        ],
        "over": null,
        "distinct": false,
        "special": false,
        "order_by": []
      }
    }
  }
}

...and then we can replace the $l & $r with the arguments. On constructing the SQL, the precedence is handled without parentheses.
The downside of this is that an s-string like s"{x}_column" no longer works — x needs to be a self-contained expression. (We could have two types of s-string, or two types of variables (e.g. $ vs {}, but then that's more complicated.)
What do folks think?
[^1]:
That comes from this rust:
```rust
fn main() {
use sqlparser::dialect::GenericDialect;
use sqlparser::parser::Parser;
let sql = "ROUND(ABS(($l_column) / ($r)) - 0.5) * SIGN(($l) / $r)";
    let parser = Parser::new(&GenericDialect);
    let mut ast = parser.try_with_sql(sql).unwrap();
    println!(
        "{}",
        serde_json::to_string_pretty(&ast.parse_expr().unwrap()).unwrap()
    );
}
```

I guess we could retain the old behavior with another variant — say a j string (like Jinja) — either with exactly the current s-string semantics, or an actual jinja string.

If I understand correctly, what you describe would have following steps:

compile to SQL, will way too much parenthesis,
parse with sqlparser-rs,
traverse AST and remove unneeded parenthesis,
serialize AST back to SQL.

I was thinking about another approach. We add support for "format" in s-strings: s"{l:3} DIV {r:12}". In this s-string, param l has "format" 3 and r had format 12. We can discuss what format would be for PRQL (date formatting, wink, wink), but for SQL backend, we can change the behavior to always require a number which represents binding strength.
With this, we can move the whole "optional parenthesis depending on required binding strength" mechanism that we currently have in gen_expr.rs into the std.sql.prql.

If I understand correctly, what you describe would have following steps:

Yes!

We add support for "format" in s-strings: s"{l:3} DIV {r:12}". In this s-string, param l has "format" 3 and r had format 12. We can discuss what format would be for PRQL (date formatting, wink, wink), but for SQL backend, we can change the behavior to always require a number which represents binding strength.

Format strings would be good, for sure.
What would we use for precedence there? Presumably we don't know the binding strength of the operators used in r? What would the upside be over the parsing proposal above — presumably we'd have to parse the expressions anyway to evaluate the precedence?

You would have something like this:
#[binding_strength(4)]
let add = l r -> s"{l:4} + {r:4}"

#[binding_strength(4)]
let mul = l r -> s"{l:5} * {r:5}"

#[binding_strength(11)]
let mod = l r -> s"FLOOR(MOD({l:0}, {r:0}))"

So when we need to translate (mul (add 1 2) 3), mul would require left to be of binding strength of at least 5, but add would be only 4. This would cause parenthesis to be inserted.
But when you have (mul (mod 1 2) 3), mod would have binding strength of 11, which is greater than what mul requires, so no parenthesis would be needed.
It is essentially the same algorithm we use now, but using rq-operators (that use syntax of s-strings) instaed of using AST of the sqlparser-rs.
And this would all be implementation detail of SQL backend, I'm not talking about PRQL language.

One minor comment — I think we should try and find a different syntax — it means that # isn't always a comment, it introduces context to the parser. It's fine in Rust because the comment syntax is different. We could use something like @ like python, but that also conflicts with date literals. @[foo] could work?

I'm sure I'm being slow, but I'm struggling to understand parts of this.

So when we need to translate (mul (add 1 2) 3), mul would require left to be of binding strength of at least 5, but add would be only 4. This would cause parenthesis to be inserted.

What's the advantage of having #[binding_strength(4)] on add over just reading the binding strength of * from sqlparser-rs? That was my proposal above.

#[binding_strength(4)]
let add = l r -> s"{l:4} + {r:4}"

- #[binding_strength(4)]
+ #[binding_strength(5)]
let mul = l r -> s"{l:5} * {r:5}"

#[binding_strength(11)]
let mod = l r -> s"FLOOR(MOD({l:0}, {r:0}))"

Super minor clarification — is that change correct? I think so based on https://github.com/PRQL/prql/pull/2709/files#diff-f6d964f7215b03bfdb696d81cf4258db7cf5686558bf44fa627d031f2f474c2eR57 (just trying to understand, not point out typos!)

it means that # isn't always a comment, it introduces context to the parser.

Ideally this file would be a valid PRQL file so the # would actually work as a comment?

Ideally this file would be a valid PRQL file so the # would actually work as a comment?

Yes, the new code adds new syntax to prql files — including that one — so...
# hello

...is a comment but...
#[ hello

...isn't

I had @(binding_strength) before, but it was conflicting with date literals.
Yes, the syntax has actually been added to the language. We can change it easily, we just need to find something that looks reasonable and does not have conflicts.

What's the advantage of having #[binding_strength 4] on add over just reading the binding strength of * from our code in ...

We don't have to parse the s-strings. This way they can contain anything they want and we are not constrained to what sqlparser-rs supports (i.e. integer division operator).
We could, as you point out, remove the binding_strength stuff from gen_expr and use solely what's in std.sql.prql. But you know, why fix if it ain't broke :D To be serious, it would clean up the code a little, but we could not remove it completely, since gen_expr constains special cases for NOT NULL and CONCAT.

Super minor clarification — is that change correct?

I don't know what you mean. mul having binding strength of 5?

I had @(binding_strength) before, but it was conflicting with date literals.
Yes, the syntax has actually been added to the language. We can change it easily, we just need to find something that looks reasonable and does not have conflicts.

Wouldn't parsing @( or @[ be comparable to parsing #[? But with less conflict with comments which often appear as the first character on a line, and have higher "conceptual precedence" in my mind.
(I don't have some strong view on the @, but it seems reasonable? I am more against adding a non-comment #...)

We don't have to parse the s-strings. This way they can contain anything they want and we are not constrained to what sqlparser-rs supports (i.e. integer division operator).

Yes, fair point.
I don't have an immediate outcome that gets worse with this approach. I worry we have multiple places where we handle precedence — even within the std.prql we have multiple places for precedence, given the attribute and the format syntax; and that we're trending back to string futzing (which you've done so much work to take us away from!).
I also though that parsing it would offer an elegant way to avoid formatting the variables, though it's not the only way.
Overall I don't feel strongly.

I don't know what you mean. mul having binding strength of 5?

Right — am I thinking about it correctly — the precedence in the attribute should match the precedence in on each term, for an infix operator?

Syntactically, @ can also appear first in line. A date literal is a valid expression on its own and could be stored into a variable using into.
But maybe I can pull off the same trick I did with #, looking at the following char. Let mi try.

we're trending back to string futzing

That's true, I was also concerned about that. But at the end, sqlparser is just composing strings together, same as we are here. If sqlparser was being a burder in these cases in the compilation process, skipping it won't bring too much harm. I hope.

I don't know what you mean. mul having binding strength of 5?

Right — am I thinking about it correctly — the precedence in the attribute should match the precedence in on each term, for an infix operator?

The infix operator. This is the strength provided by that whole s-string, which is determined by the "top level" operator in the s-string. In your case that's infix operator *, which has bs of 11.

Syntactically, @ can also appear first in line. A date literal is a valid expression on its own and could be stored into a variable using into.

Totally, I just think it's less likely
(FWIW I'm happy to have a go at this, I'm strongly not saying that it rests on you to change things just because others have some view)

The infix operator. This is the strength provided by that whole s-string, which is determined by the "top level" operator in the s-string. In your case that's infix operator *, which has bs of 11.

OK, I think we might have lost the connection to the original example (my diff was based on https://github.com/PRQL/prql/issues/2694#issuecomment-1574909876) — but I'm pretty confident I understand

I also though that parsing it would offer an elegant way to avoid formatting the variables, though it's not the only way.

I guess if we're using s-strings for more things such that "don't format s-strings" is no longer viable, we could consider using annotations to specify not formatting them. It adds another "mode" though.

I also though that parsing it would offer an elegant way to avoid formatting the variables, though it's not the only way.

I guess if we're using s-strings for more things such that "don't format s-strings" is no longer viable, we could consider using annotations to specify not formatting them. It adds another "mode" though.

Technically, we are not using s-strings - they still have a separate code path in the SQL backend. We are just using something that reuses our prql parser to have compilation rules defined in PRQL syntax :D
So it is still possible to implment don't-format-s-strings, just as much as it was before.

Ah great, that makes sense. Thanks!


Repo sync for protected CLA branch

The pull request is created from master637726826230569953 to master to fix git push error for protected CLA branch

@ghogen : Thanks for your contribution! The author(s) have been notified to review your proposed change.


set customer language

According to support there is no way yet to have the SumUp card reader ask the customer to enter pin, wait, sign, ... in another language.
There should be a way towards select a UI-language with every payment request, so that international customers have a clue what the device wants them to do.
This is a huge problem at international events especially with French customers.

Hi Marcus,
Thanks for the suggestion. At the moment the language is determined based on the region of the merchant. Reader support for the language of the customer's card is on our backlog, but it has not been scheduled so it may still be a little while off. So that we can keep track of which integrators are interested in certain features, could you please tell me you are working with?
Thanks,
Angus

We write our own software because nobody else did a Magento 2.0 integration.
POS functionality and payments are but a small part.
We do however also often use your Android App standalone and have the same need there. Without any API involved.

"Reader support for the language of the customer's card is on our backlog, but it has not been scheduled "
Has it been scheduled within the last 7 month?

Hi Marcus,
Unfortunately there are no changes to date, when we start to tackle this issue we'll inform you here.
Angus

It's been 2 years and this is still a huge issue for our customers.

Any update on this issue?
If all else fails, It's not THAT hard to force a different locale on a Context.
(For NumberFormat and DateFormat you have a locale parameter, so that's not a big issue.)
public void forceLocale(@NonNull final Application application, @NonNull final Locale newLocale) {         final Resources resources = application.getBaseContext().getResources();         final Configuration config = resources.getConfiguration();         config.locale = newLocale;         resources.updateConfiguration(config, resources.getDisplayMetrics());     }

@MarcusWolschon Thanks again for following up here.  Unfortunately this improvement is still in our backlog and we have not yet been able to deliver. We will keep you posted.
Thanks

So we have 2019 now. Any change?

We would also be interested in this.

I would need this feature for my customer, too. He can not understand, why it is not possible. The payment builder would only need an additional parameter.

I would need this feature for my customer, too. He can not understand, why it is not possible. The payment builder would only need an additional parameter.

A language parameter?
SumUp knows the language of the customer's card. The app initiating the process doesn't.

Yes but the screen is in the device's language. I need to support different languages at once. So the customer can choose this language.
Example:

MyDevices is in German.
The customer does not under German and presses a button to change the language of myApp to French.
The payment process shown by the sum up SDK shows the screen in German but for the customer expierience, French would be better.

So if there would be a parameter like a language "en", "fr", .... during the SumUpPayment.builder()....               .build(), this would be a great improvement for the end user UX.

Ok, so as a workaround have the customer manually choose a language instead of reading the language from whatever card the user presents and selecting it automatically because for your app more then just the SumUp payment-process should be in the customer's language.
The app I'm working for is for the merchant and with the SumUp terminals the phone needs to be presented to the customer for a signature after a card payment in some cases.
So the user has already inserted the card and the SumUp app has opened.

Still not possible? @jahenry

I really don't believe that this feature is requested 4 years ago and still not implemented. I guess this will never be implemented!

I think SumUp doesn't know that other languages then English exist on this planet or that dealer regularly sell to people from other countries then their own in-person.

I agree, this is unfathomable.
On Fri, Dec 3, 2021 at 5:52 PM Marcus Wolschon @.***>
wrote:

I think SumUp doesn't know that other languages then English exist on this
planet or that dealer regularly sell to people from other countries then
their own in-person.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/sumup/sumup-android-sdk/issues/30#issuecomment-985629388,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABOO3YKSO3DBW6VJYON5VBTUPDRSBANCNFSM4DXO3D4Q
.
Triage notifications on the go with GitHub Mobile for iOS
https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675
or Android
https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

International clients are really confused when they get Dutch instructions on the screen. Please implement this after all.

At the moment the card readers cannot identify the language of the card used to make a payment. They will only show the language of the country where the SumUp account was registered by default However, it is possible to change the language of the terminals. Please contact our support team so that they can make the change.

Will the request for a signature on the phone app be shown in the language the bluetooth terminal is set to, if we go through that procedure?

Hi, this is not true, tatianalizarazo, I'm in France, in my computer, my dashboard is in french BUT the app in my phone is in spanish!!  and the tickets is in spanish... my costumers don't understand spanish and it is not possible to change the language. I contact the support team one year ago and it is not possible.

what about adding a language option to SumUpPayment.builder()?

what about adding a language option to SumUpPayment.builder()?

Yes. That's all we're asking for here.


Api-roll 63: 2018-08-06

Make googleapis and googleapis_beta packages Dart 2 compatible.
This repository contains generated packages googleapis and googleapis_beta in the generated folder, and package googleapis_generator_dependency in the root folder, which generates them.
The package googleapis_generator_dependency is not Dart 2 compatible yet, and its pubspec dependency on sdk: is left at < 2.0.0.
The generated packages are Dart 2 compatible, and their pubspecs give a dependency on sdk: that is < 3.0.0.
This is needed so the new Dart 2 compatible googleapis[_beta] packages can be uploaded to pub.
The generator was run with the same configuration as the last Api-roll, except the incremented version numbers, but the apis online have changed, so the packages have changed.  The commands to run the generator were
dart --no-preview-dart-2 bin/generate.dart run_config download
and
dart --no-preview-dart-2 bin/generate.dart run_config generate

Closing in favor of https://github.com/dart-lang/googleapis/pull/52