Support optional GraphQL arguments for QueryValidator

Long story short: GraphQL arguments can be optional without default value.

From GraphQL documentation,

Arguments can be either required or optional. When an argument is optional, we can define a default value - if the unit argument is not passed, it will be set to METER by default.

From GraphQL specification,

Arguments can be required. If the argument type is non‐null the argument is required and furthermore the explicit value null may not be provided. Otherwise, the argument is optional.

But in Hiku there is no way to provide optional arguments, when using QueryValidator cause of,
    def visit_option(self, obj):
        default = _undefined if obj.default is None else obj.default
        value = self._options.get(obj.name, default)
        if value is _undefined:
            node, field = self.for_
            self.errors.report('Required option "{}.{}:{}" is not specified'
                               .format(node, field, obj.name))

Hiku enforces all options to be required or use non-null default values, which not conforms GraphQL specification cited above. As result right now there is impossible to mix QueryValidator and optional arguments.

Code to reproduce,
    Field(
        'count_documents',
        Integer,
        resolve_count_documents,
        options=[
            Option('search', String, default=None),
            Option('folder_id', Integer, default=None),
            Option('status_id', Integer, default=None),
            Option('signatures_to_finish', Integer, default=None),
            Option('gte', String, default=None),
            Option('lte', String, default=None),
        ]),

Works as expected for { count_documents } query without QueryValidator, but returns,
{
    'data': None,
    'errors': [
        {'message': 'Required option "root.count_documents:search" is not specified'},
        {'message': 'Required option "root.count_documents:folder_id" is not specified'},
        {'message': 'Required option "root.count_documents:status_id" is not specified'},
        {'message': 'Required option "root.count_documents:signatures_to_finish" is not specified'},
        {'message': 'Required option "root.count_documents:gte" is not specified'},
        {'message': 'Required option "root.count_documents:lte" is not specified'}
    ]
}

when Hiku handler contains,
        validator = QueryValidator(graph)
        validator.visit(query)
        if validator.errors.list:
            return web.json_response({'data': None, 'errors': ...})

Right now it is possible to handle this case by providing non-null, but some empty values for arguments of count_documents field (like '') or by omitting QueryValidator at all, but I'd prefer if Hiku works with GraphQL arguments due to specification and does not enforce all arguments to be required.

Agreed, the problem is that Hiku uses None as an indicator of that there are no default value. Should be trivial to fix, I will look into this as soon as I can.

Fixed in 7118e406a14ade98959d8629075f0fc1965b25c0, made a release candidate hiku==0.3.9rc1 for you for further testing, here is how to specify properly non-required options for GraphQL:
Option('search', Optional[String], default=None)

And there is an interesting case with default values:
Option('foo', Integer, default=123)

This option is totally valid in Hiku: it is not required, and if it will be missing in query, Hiku will use default value 123 and won't accept null values. But in GraphQL this option will be required. As your quote from specification says:

If the argument type is non‐null the argument is required

So GraphQL here is slightly less flexible and Hiku maybe is slightly more complicated, as it gives you ability to distinguish when value is null and when it is missing.

Updated Hiku to 0.3.9rc1 and can confirm that optional arguments work as expected with query validation.
Thanks!


drivers/timer/cortex_m_systick: Improve clock slippage under irq_lock load

[Not sure if this wants to go in for 1.14 or in a point release thereafter.  The issue is real, but likely hard to hit in practice except for specific apps like the one in the linked bug.]
The SysTick logic looked logically sound, but it was allowing us to
set a LOAD value as low as 512 cycles.  On other platforms, that
minimum future interrupt delay is there to protect the "read, compute,
write, unmask" cycle that sets the new interrupt from trying to set
one sooner than it can handle.
But with SysTick, that value then becomes the value of the LOAD
register, which is effectively the frequency with which timer
interrupts arrive.  This has two side effects:

It opens up the possibility that future code that masks interrupts
longer than 512 cycles will miss more than one overflow, slipping
the clock backward as viewed by z_clock_announce().

The original code only understood one overflow cycle, so in the
event we do set one of these very near timeouts and then mask
interrupts, we'll only add at most one overflow to the "elapsed()"
time, slipping the CURRENT time backward (actually turning it into
a non-monotonic sawtooth which would slip every LOAD cycle) and
thus messing up future scheduled interrupts, slipping those forward
relative to what the ISR was counting.

The symptoms in #15216 seem to match the second of these cases.
This patch simplifies the logic for reading SysTick VAL/CTRL (the loop
wasn't needed), handles the case where we see more than one overflow,
and increases the MIN_DELAY cycles from 512 to 1/16th of a tick.
Signed-off-by: Andy Ross<EMAIL_ADDRESS>

@andyross
I'll do more tests, but this commit seems to solve #15216 !

Updated with a "Fixes #" via @avisconti 's report, and rephrased the comments per review.
It' is VERY late in the process, but I don't see why this can't go in for 1.14 if there's a desire to get that bug closed before release.


Trivial State merge

This won't merge any states other than ones due to for loops.

Would this impact negatively later ability to perform multi‑threading ?

@ytrezq. No, definitely not. The states get glued together forever so we can still parallelise

No, some states get glued together after transaction ends, but yeah i am still tweaking it for other ways, so I can’t say for sure

@norrh : I was saying this in the way that this would introduce additional content that needs to be shared among all threads (especially in the case where each interpreter maintain their own set of variables like in 3.9 and serializing is the only form of communication) and can’t be modified by several threads at the same time.

It depends on how the parallelisation is implemented, If parallelisation of work_list happens per transaction then this won't be a problem.

You mentioned the possibility of segfaults due to big constraints at some point, is this still an issue? When do such cases occur? It's non-deterministic, I checked a bunch of cases, It still seems Probability(rubixi_segfault|state_merge=True) > Probability(rubixi_segfault|state_merge=False), So I should do something about it. by limiting merge state count.

@norhh : please perform the backport work again so I can continue to use this branch as it no longer works because of the new Infura changes.

@norhh does it means you are aborting the change?
At each analysis, Mythril is spending hours analysing the same states.

It can still be used, I am rewriting some stuff here to make it work with the current laser-plugin interface.

@norhh : the problem is not seeing new features and fixes of the main branch to this branch.

@norhh so what s the new pr which works with the laser plugin interface?

We want to make this repo to contain only the symbolic execution and analysis part, all the optimisations are added to mythx.

@norhh so do you mean a business decision happenned where optimizations are only added to the mythx version of mythril compared to the time this pull request was opened?

@ytrezq  yes.


Fix issues with Qt 5.15 where QSocketNotifier.activated became overloaded

After upgrading to Qt 5.15/PySide2 5.15.1 I noticed that the asyncio-Qt mainloop integration was completely broken - websockets stayed hanging in a connecting state, async HTTP requests never returned a response i.e. no callbacks were ever called.
Troubleshooting revealed that the __on_read_activated slots in _unix.py received a PySide2.QtCore.QSocketDescriptor object. Those were obviously not found in the _fd_to_key directory mapping, as the key expected there is the (int) file descriptor.
In the Qt documentation I found that the QSocketNotifier.activated behavior changed with Qt 5.15, whereas previously only the QSocketNotifier::activated(int socket) signal existed, now this signal became overloaded with QSocketNotifier::activated(QSocketDescriptor socket, QSocketNotifier::Type type) as arguments.
Long story short, this pull requests fixes the issue by explicitly connecting the signal with "int" soket fd as argument.

Related merge request in qasync: CabbageDevelopment/qasync#12


Generate zsh completion functions

Is it possible to use argcomplete to generate the actual zsh completion functions for a program? My app startup is quite slow thanks to some imports that take a long time, and that load time finds its way to argcomplete as well. It seems like every time I press tab it's going through my program so it's super slow.

Hello, thanks for your interest in argcomplete.
No, argcomplete does not support the generation of static completions. While possible, this would be a complex set of extra logic and it would lose the key advantage that argcomplete offers and is typically used for (dynamic completion of values).

@mil-ad maybe you have your python startup script inside your module folder.
If you put it outside, and put the app input statements after argcomplete.autocomplete(parser) it works fine and fast :)
I had a similar problem with that


Bonus HP in the HP Line lead to a double import

e.g. "hp 71 (7 HD; 3d10+4d8+32)" will lead to a double import, while "hp 71 (7 HD; 3d10+4d8)" will not.

Fixed in 3.1.1 by changing sbcUtils.sbcSplit(), which had the following errors:

missing global flag for the regex to escape "+" signs in a pattern to remove already parsed strings from a given input
adding resilience towards keeping empty strings out of returned arrays


Update aws-java-sdk-bundle to 1.12.414

Updates com.amazonaws:aws-java-sdk-bundle from 1.12.410 to 1.12.414.
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

Adjust future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "com.amazonaws", artifactId = "aws-java-sdk-bundle" } ]

Or, add this to slow down future updates of this dependency:
dependencyOverrides = [{
  pullRequests = { frequency = "30 days" },
  dependency = { groupId = "com.amazonaws", artifactId = "aws-java-sdk-bundle" }
}]

labels: library-update, early-semver-patch, semver-spec-patch, commit-count:1

Superseded by #2526.


Serposcope 3 survey

Since yesterday there is a "Serposcope 3 survey" showing up at the sidebar 😮 🤩 .
So, what's up with that - will there be a continue in development? 💡💭

it would be great to continue it

yes, definitely

Great news! :)

Maybe a freemium? It is nice to have an open-sourced version for people who want to try and improve the software by contributing to it.. At the same time, having non-techy person to pay for a managed service (Saas).
I think there is so much to improve as a regular user and don't wish to see this project die off.

I second this; a paid saas hosted version for non-techies will help maintain and improve the project while keeping an open-source version for others who want to host it.

any news about the project 3.0? @noguespi

currently building it https://twitter.com/serphacker/status/1605505024112459777

@noguespi will you support Bing search in Serposcope 3?
It would be awesome if you do.

not on the roadmap yet

@noguespi  thanks for the quick reply, with chat gpt being integrated with bing I feel it will get good traction.
In which language web services are being written? I am assuming you're creating REST based APIs which will be consumed by Angular?

The backend is in kotlin and front in angular but it's not a REST API in between.
But I plan to add a REST API, it will be based and documented with openapi/swagger.

Got it, that is great. Thanks

@noguespi wow I didn't realise Bing would integrate chat got so fast, time to take Bing search ranking as a feature. What do you think?

Bing is not planned for the short term. Maybe later.

@noguespi  btw when are you planning to release Serposcope 3?


Game hitch when changing jobs

The latest update seems to cause the game to hang for half a second when switching from DoH/DoL jobs to DoW/DoM jobs and back.
I reinstalled <IP_ADDRESS> to double check and the problem went away.
Is anyone else experiencing this?

no issues here

I can't see XivAlexander affecting this at all. Does this not happen when XivAlexander is not loaded/uninstalled?

I can't see XivAlexander affecting this at all. Does this not happen when XivAlexander is not loaded/uninstalled?

No, it doesn't happen with XivAlexander not loaded, but I think I've figured it out.
The Modding option "Log All Path Plaintext Before Hash" was enabled for whatever reason. Disabling this option seems to fix it.
Oddly enough this doesn't happen with <IP_ADDRESS> or below with the same option ticked.


数据集请求

你好，请问能提供其他几个数据集吗？

We have stated the datasets used in our experiments in README.md, you can directly download those datasets from the instructions and run the codes without modification.


As a student, I can add my friend's contact information

Add Friend’s Contact Information
Add friend’s name, phone number to the application
add_friend [name] -p [phone_number]
name: “<first_name> <last_name>”, case insensitive
phone_number: 8 digit number

Closed by #29


Synthesis failed for Google.Cloud.Spanner.Admin.Database.V1

Hello! Autosynth couldn't regenerate Google.Cloud.Spanner.Admin.Database.V1. :broken_heart:
Please investigate and fix this issue within 5 business days.  While it remains broken,
this library cannot be updated with changes to the Google.Cloud.Spanner.Admin.Database.V1 API, and the library grows
stale.
See https://github.com/googleapis/synthtool/blob/master/autosynth/TroubleShooting.md
for trouble shooting tips.
Here's the output from running synth.py:
2021-03-19 22:46:02,090 autosynth [INFO] > logs will be written to: /tmpfs/src/logs/Google.Cloud.Spanner.Admin.Database.V1
2021-03-19 22:46:02,619 autosynth [DEBUG] > Running: git config --global core.excludesfile /home/kbuilder/.autosynth-gitignore
2021-03-19 22:46:02,623 autosynth [DEBUG] > Running: git config user.name yoshi-automation
2021-03-19 22:46:02,627 autosynth [DEBUG] > Running: git config user.email<EMAIL_ADDRESS>2021-03-19 22:46:02,631 autosynth [DEBUG] > Running: git config push.default simple
2021-03-19 22:46:02,635 autosynth [DEBUG] > Running: git branch -f autosynth-Google.Cloud.Spanner.Admin.Database.V1
2021-03-19 22:46:02,640 autosynth [DEBUG] > Running: git checkout autosynth-Google.Cloud.Spanner.Admin.Database.V1
Switched to branch 'autosynth-Google.Cloud.Spanner.Admin.Database.V1'
2021-03-19 22:46:02,855 autosynth [DEBUG] > Running: git rev-parse --show-toplevel
2021-03-19 22:46:02,861 autosynth [DEBUG] > Running: git log -1 --pretty=%H
2021-03-19 22:46:02,866 autosynth [DEBUG] > Running: git remote get-url origin
2021-03-19 22:46:02,900 synthtool [ERROR] > Failed executing git checkout master:

error: Your local changes to the following files would be overwritten by checkout:
	google/cloud/dialogflow/v2/answer_record.proto
	google/cloud/dialogflow/v2/conversation.proto
	google/cloud/dialogflow/v2/conversation_profile.proto
	google/cloud/dialogflow/v2/participant.proto
Please commit your changes or stash them before you switch branches.
Aborting

Traceback (most recent call last):
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 354, in <module>
    main()
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 189, in main
    return _inner_main(temp_dir)
  File "/tmpfs/src/github/synthtool/autosynth/synth.py", line 312, in _inner_main
    git_source.enumerate_versions(sources, pathlib.Path(temp_dir))
  File "/tmpfs/src/github/synthtool/autosynth/git_source.py", line 202, in enumerate_versions
    source_versions = enumerate_versions_for_source(git_source, temp_dir)
  File "/tmpfs/src/github/synthtool/autosynth/git_source.py", line 166, in enumerate_versions_for_source
    local_repo_dir = str(synthtool_git.clone(remote))
  File "/tmpfs/src/github/synthtool/synthtool/sources/git.py", line 85, in clone
    shell.run(["git", "checkout", "master"], cwd=str(dest), check=True)
  File "/tmpfs/src/github/synthtool/synthtool/shell.py", line 39, in run
    raise exc
  File "/tmpfs/src/github/synthtool/synthtool/shell.py", line 33, in run
    encoding="utf-8",
  File "/home/kbuilder/.pyenv/versions/3.6.9/lib/python3.6/subprocess.py", line 438, in run
    output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['git', 'checkout', 'master']' returned non-zero exit status 1.

Google internal developers can see the full log here.

Autosynth passed, closing! :green_heart:


improve error messages from poll

Poll timeout was returned as timed out waiting for the condition. If the error was checked like this
		Expect(err).NotTo(HaveOccurred())

We got a meaningless message.
I added a new function PollMsg that takes a description of the condition. It is printed in the timeout message.

I updated only a few tests to use PollMsg. But I'm fine with updating others too, later on, if the PR is accepted.

Optional nit: It would be nice if we could have the polling function print out something like
Error: Timeout after %v: last error %v

I'm pretty sure that there's an easier way to achieve this.  Please don't LGTM or merge until I've had a chance to review.  Thanks.

I was confused.  No concerns.  LGTM.

I agree with @bprashanth's nit - will hold off on the LGTM label (and hence merge) until that change is in.

I'd like this one to go in - it's low risk and high value (improved error reporting for tests).  Assigning to @lavalamp for a second "OK to merge" approval.

Sorry, but no :)
I agree with Quinton's initial thought. This is too much machinery to add a message to an error. Go's pattern is not to inject an error message all the way down to the source (that's madness if you do it generally!!), rather it is that each layer passes an error back to the layer above, possibly adding clarifying details.
If you want to add machinery, the proper machinery to add looks like this:
func AddErrorDetail(err error, msg string) error {
  if err == nil {
    return nil
  }
  return fmt.Errorf("%v: %v", msg, err)
}

...

return AddErrorDetails(wait.Poll(...), "the frobber didn't gargle")

But the above can be improved--the error isn't introspectable. That doesn't matter too much for tests, but it matters a lot if you want people to be able to handle the errors programmatically.

And by the way, gomega already has this machinery; IIRC you can just do:
Expect(err).NotTo(HaveOccurred(), "clarifying detail %v", myVariable)

@lavalamp , I agree it can be made in other ways, but I know from my experience that people tend to forget to add proper messages unless they are forced to do so by a required parameter.
Just look at the code - messages are missing in more than a half of the places.
I can move PollMsg to test/e2e/util.go if you prefer it this way.

Ok, let's forget about this patch. I'll put the messages inside the NotTo function.


Train stop train limit not preserve when change blueprint into water placable.

As title

Weird, I'm pretty sure this used to work fine (or maybe I just never noticed), so maybe it's a vanilla bug. Also the train stop limit dosn't get lost when converting to water placeable (if you convert it back it's still there so it's preserved in the blueprint), it get's lost when the ghost get's upgraded back to the normal ghost. It get's lost when you upgrade train stops in general, which might be a bug in Factorio.

Yep it's confirmed to be a bug in Factorio and will be fixed in 1.1.93
https://forums.factorio.com/viewtopic.php?f=7&t=109034


Import table #8 (HBCU enrollment by sex)

See import list at https://github.com/Spelman-College/spelman-dashboard/issues/21

Started iterating on pv map and cleaning script in https://docs.google.com/spreadsheets/d/1skRGRiY5SZx69J2GeSpyAnN3LwZh4_6jRocC1LYAepE/edit#gid=1577041321.

Import doc: https://docs.google.com/document/d/1de2qx18aKV4YBdeEEtxROpzcgZ1qjaOZIGwVlalFXBI/edit

Filed internal bug and sent PR for new enum classes in https://github.com/datacommonsorg/schema/pull/572.

Filtering logic added in #87 .


Leverage Helm hooks to delete and recreate immutable PodDisruptionBudgets

PodDisruptionBudgets are immutable https://github.com/kubernetes/kubernetes/issues/45398 and currently need to be deleted manually and then recreated with Helm in order to change them with Helm.
Using Helm hooks annotations on all the specified PDB's we can delete and recreate it automatically on every helm install/upgrade.
All 3 "pre" hooks have been included with the "before-hook-creation" delete policy so that PodDisruptionBudgets are deleted and recreated before the action applies, rather than after an upgrade/rollback has completed.
This should fix:

https://github.com/istio/istio/issues/11210
https://github.com/istio/istio/issues/9951

[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by: jracollins
To fully approve this pull request, please assign additional approvers.
We suggest the following additional approver: greghanson
If they are not already assigned, you can assign the PR to them by writing /assign @greghanson in a comment when ready.
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

install/OWNERS

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Hi @jracollins. Thanks for your PR.
I'm waiting for a istio member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.
Once the patch is verified, the new status will be reflected by the ok-to-test label.
I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

CLA Signed!

Not sure whether I should have followed the bot advice and assigned when I opened the PR 😅 - assumed auto requests was all that is needed, but just in case:
/assign @greghanson

@morvencao can you review this?  thoughts on using helm hooks?  I thought at one time folks were against it.
cc @sdake

@jracollins I want to thank you for taking the time to do this work and open a PR.
The Istio project has a policy of not using any complex Helm features.  We have been disrupted in the past by the pre and post install hooks and it has cost months of engineering effort to resolve.  Now we simply use Helm as a templating engine only.  Note that install hooks are complicated by the fact that Istio not only uses helm + tiller model, but helm template.  Most of the core team uses helm template.
For 1.2 or 1.3 we plan to move to a new installer here: https://github.com/istio-ecosystem/istio-installer
I'd encourage you to take a look and contribute ideas there.
We have a 1.2/1.3 feature to automate this new installer code via an operator that @ostromart is leading.
Cheers
-steve

/hold

+1 to move https://github.com/istio-ecosystem/istio-installer

Thanks @sdake, and likewise for your considered response.
I can completely understand, helm hooks with Jobs not completing for example can get the state in a right mess!
I saw there were some exiting hooks in the codebase - and not just for tests e.g: https://github.com/istio/istio/blob/152bdea376846356c37be28d327447d2359540cf/install/kubernetes/helm/istio/charts/grafana/templates/create-custom-resources-job.yaml#L62
and I would assume that is because of the "low risk" of those hooks failing? I feel these PDB resources would be in a similar boat regarding potential hook issues?
So from my understanding, helm hooks would just be ignored when using helm template - for those using that this will have no effect (and they will still have to delete PDB's manually in order to then kubectl apply changes to workaround this immutable issue) but for users following the current Istio docs for installing and upgrading and using tiller would be able to avoid the issue.
Thanks for pointing me in the direction of that repo, I had not seen it before - The setup is actually quite similar to how we are deploying our Istio installs and other helm apps. I will try to see if can add some contributions going forward!

Thanks @sdake, and likewise for your considered response.
I can completely understand, helm hooks with Jobs not completing for example can get the state in a right mess!
I saw there were some exiting hooks in the codebase - and not just for tests e.g: https://github.com/istio/istio/blob/152bdea376846356c37be28d327447d2359540cf/install/kubernetes/helm/istio/charts/grafana/templates/create-custom-resources-job.yaml#L62
and I would assume that is because of the "low risk" of those hooks failing? I feel these PDB resources would be in a similar boat regarding potential hook issues?
So from my understanding, helm hooks would just be ignored when using helm template - for those using that this will have no effect (and they will still have to delete PDB's manually in order to then kubectl apply changes to workaround this immutable issue) but for users following the current Istio docs for installing and upgrading and using tiller would be able to avoid the issue.
Thanks for pointing me in the direction of that repo, I had not seen it before - The setup is actually quite similar to how we are deploying our Istio installs and other helm apps. I will try to see if can add some contributions going forward!


[New Feature]: Add a video tutorial for the game

🎮 feature Request
Adding a video guideline for the game to help people who did not understand the guidelines.
Point down the features
This feature will help the users understand the working of the game.
I will add the video on this home page.

Select program in which you are contributing
GSSoC24
Code of Conduct

[X] I follow CONTRIBUTING GUIDELINE of this project.

Assign me this issue

If you have any doubt you can directly send message on our discord (https://discord.gg/rZb46cCMmK), we have created seprate chennals for all projects...
Thank you :)


Sticky header function doesn't update correctly with arrow keys, only scrollbar.

Version and Platform (required):

Binary Ninja Version: 3.4.4271 Personal, b7fd028d
OS: windows
OS Version: 10
CPU Architecture: x86_64

Bug Description:
When scrolling up and down with the arrow keys, the function in the sticky header of the UI doesn't update correctly. Only using the scrollbar/scrollwheel seems to get the correct results.
Steps To Reproduce:

Scroll up or down in any of the views with your up and down arrow keys.

Expected Behavior:
The UI should display the correct function.
Screenshots:
The wrong function is shown after scrolling up with the arrow keys:

Additional Information:
The function in the sticky header will update occasionally when using the arrow keys, at what seems to be random intervals.

Fixed in 3.5.4375-dev


Orchestrator retrieves sources with search score 1.0

All retrieved sources have search score 1.0. Also, the thought process printed in frontend may have missing componets.. User questions and / or Sources utilized.

user query wasn't reaching the body for the search api call


New Azuremonitorreceiver component

Description: Adds support for the azuremonitor receiver from the opentelemetry contrib repo.
Testing: components_test.go has been updated to reflect these changes. Local testing of the azuremonitorreceiver was also successful. We were able to scrape the azuremonitor metrics and send them to Splunk Observability.
Documentation: components.md has been updated to show the new component
Co-author: https://github.com/brendtg @brendtg

I have read the CLA Document and I hereby sign the CLA

Hello @sriniketh923, thanks for your interest and contribution here! It would be best to file a Splunk idea to add this exporter to the Splunk distribution. Thanks again!

It looks like closing and reopening this PR broke the CLA Assistant. We'll have to open a new PR for this change.


Fix Hub Resolver doc typo

This commit fixes the Hub API endpoints configuration to ../config/resolvers/resolvers-deployment.yaml
/kind documentation

Changes

Submitter Checklist
As the author of this PR, please check off the items in this checklist:

[ ] Has Docs included if any changes are user facing
[ ] Has Tests included if any functionality added or changed
[ ] Follows the commit message standard
[ ] Meets the Tekton contributor standards (including
functionality, content, code)
[ ] Has a kind label. You can add one by adding a comment on this PR that contains /kind <type>. Valid types are bug, cleanup, design, documentation, feature, flake, misc, question, tep
[ ] Release notes block below has been updated with any user facing changes (API changes, bug fixes, changes requiring upgrade notices or deprecation warnings)
[ ] Release notes contains the string "action required" if the change requires additional action from users switching to the new release

Release Notes
NONE

/lgtm
Thanks @QuanZhang-William

Yeah, it definitely would!
/lgtm


In the Chinese readme file, modify a punctuation mark

No description provided.

Please add more information .

just add a punctuation mark。at 同时欢迎大家添加推荐书籍，请在此文档 [书籍推荐](./docs/books.md) 中录入。
I think this sentence should end with a full stop

Approved this PR, although this can not be the ticket to enter our developer group

Thanks for PR, you may join our discord


Generated code do not compile on Unix implementation of JDK

Description
Create tests for project in Intellij Idea 2021.1 with JDK 11 for the following class

Actual behavior
Generate code contains the following line that is not appropriate for Unix related JDKs and leads to ClassNotFoundException
Object fs = createInstance("java.io.WinNTFileSystem");

Additional context
Bug was found by Dmitry Fedrushkov wx1076228

import java.io.File;
public class Solution {
/**
* check if a file exists
*/
public boolean func_1(String filePathString) {
File f = new File(filePathString);
return f.exists() && !f.isDirectory();
}
}


size mismatch for rpn

🐛 Describe the bug
I created a Mask R-CNN model using a set of parameters that I saved in a JSON file. Once the model was trained, I saved the weights using torch.save(model.state_dict(), "MaskRCNN.pt"). Later, I recreated the same model and loaded the saved weights model.load_state_dict(torch.load("MaskRCNN.pt", map_location=Device)).
On my laptop (MacBook Pro M2) using Torch 2.2.2, TorchVision 0.17.2 (most up to date for this environment), and CPU only, everything works just fine.
However, on a cluster based on Centos with Torch 2.4, TorchVision 0.19 (most up to date for this environment), and Cuda 12.1.1, I get the following error when loading the weights:
  File "/home/XXX//MaskRCNN.py", line 84, in Load
      model.load_state_dict(torch.load(WeightsPath, map_location=Device))
    File "/home/XXX/torch/nn/modules/module.py", line 2215, in load_state_dict
      raise RuntimeError('Error(s) in loading state_dict for {}:\n\t{}'.format(
  RuntimeError: Error(s) in loading state_dict for MaskRCNN:
  	size mismatch for rpn.head.cls_logits.weight: copying a param with shape torch.Size([6, 256, 1, 1]) from checkpoint, the shape in current model is torch.Size([14, 256, 1, 1]).
  	size mismatch for rpn.head.cls_logits.bias: copying a param with shape torch.Size([6]) from checkpoint, the shape in current model is torch.Size([14]).
  	size mismatch for rpn.head.bbox_pred.weight: copying a param with shape torch.Size([24, 256, 1, 1]) from checkpoint, the shape in current model is torch.Size([56, 256, 1, 1]).
  	size mismatch for rpn.head.bbox_pred.bias: copying a param with shape torch.Size([24]) from checkpoint, the shape in current model is torch.Size([56]).

The code is exactly the same on my laptop and on the cluster.
I double checked, and I used exactly the same parameters to create  ALL the models.
How can I fix this?
Versions
Collecting environment information...
PyTorch version: 2.4.0+cu121
Is debug build: False
CUDA used to build PyTorch: 12.1
ROCM used to build PyTorch: N/A
OS: CentOS Linux release 7.9.2009 (Core) (x86_64)
GCC version: (GCC) 13.2.0
Clang version: Could not collect
CMake version: version <IP_ADDRESS>
Libc version: glibc-2.17
Python version: 3.11.9 (main, Apr 19 2024, 16:48:06) [GCC 11.2.0] (64-bit runtime)
Python platform: Linux-3.10.0-957.10.1.el7.x86_64-x86_64-with-glibc2.17
Is CUDA available: True
CUDA runtime version: 12.1.105
CUDA_MODULE_LOADING set to: LAZY
GPU models and configuration:
GPU 0: Tesla V100-SXM2-32GB
GPU 1: Tesla V100-SXM2-32GB
GPU 2: Tesla V100-SXM2-32GB
GPU 3: Tesla V100-SXM2-32GB
GPU 4: Tesla V100-SXM2-32GB
GPU 5: Tesla V100-SXM2-32GB
GPU 6: Tesla V100-SXM2-32GB
GPU 7: Tesla V100-SXM2-32GB
Nvidia driver version: 550.90.07
cuDNN version: Probably one of the following:
/usr/local/cuda-9.1/targets/x86_64-linux/lib/libcudnn.so.7.0.5
/usr/local/cuda-9.2/targets/x86_64-linux/lib/libcudnn.so.7.2.1
HIP runtime version: N/A
MIOpen runtime version: N/A
Is XNNPACK available: True
CPU:
Architecture:          x86_64
CPU op-mode(s):        32-bit, 64-bit
Byte Order:            Little Endian
CPU(s):                80
On-line CPU(s) list:   0-79
Thread(s) per core:    2
Core(s) per socket:    20
Socket(s):             2
NUMA node(s):          2
Vendor ID:             GenuineIntel
CPU family:            6
Model:                 85
Model name:            Intel(R) Xeon(R) Gold 6148 CPU @ 2.40GHz
Stepping:              4
CPU MHz:               1000.000
CPU max MHz:           2401.0000
CPU min MHz:           1000.0000
BogoMIPS:              4800.00
Virtualization:        VT-x
L1d cache:             32K
L1i cache:             32K
L2 cache:              1024K
L3 cache:              28160K
NUMA node0 CPU(s):     0-19,40-59
NUMA node1 CPU(s):     20-39,60-79
Flags:                 fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc aperfmperf eagerfpu pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch epb cat_l3 cdp_l3 intel_pt ssbd mba ibrs ibpb stibp tpr_shadow vnmi flexpriority ept vpid fsgsbase tsc_adjust bmi1 hle avx2 smep bmi2 erms invpcid rtm cqm mpx rdt_a avx512f avx512dq rdseed adx smap clflushopt clwb avx512cd avx512bw avx512vl xsaveopt xsavec xgetbv1 cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local dtherm ida arat pln pts pku ospke spec_ctrl intel_stibp flush_l1d
Versions of relevant libraries:
[pip3] numpy==1.26.4
[pip3] numpydoc==1.8.0
[pip3] torch==2.4.0
[pip3] torchsummary==1.5.1
[pip3] torchvision==0.19.0
[pip3] triton==3.0.0
[conda] numpy                     1.26.4                   pypi_0    pypi
[conda] numpydoc                  1.8.0                    pypi_0    pypi
[conda] torch                     2.4.0                    pypi_0    pypi
[conda] torchsummary              1.5.1                    pypi_0    pypi
[conda] torchvision               0.19.0                   pypi_0    pypi
[conda] triton                    3.0.0                    pypi_0    pypi
I used modules to load the drivers, so here are more information:
$  nvcc --version
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2023 NVIDIA Corporation
Built on Mon_Apr__3_17:16:06_PDT_2023
Cuda compilation tools, release 12.1, V12.1.105
Build cuda_12.1.r12.1/compiler.32688072_0
nvidia-smi
Wed Aug 14 04:07:42 2024
+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 550.90.07              Driver Version: 550.90.07      CUDA Version: 12.4

I printed the outputs in both environment.
As one has GPUs and the other does not, I removed ,device='cuda:0' from the file exported on the GPUs environment.
Then I didn't find any difference between the files

I printed the models before training and after training (when recreated to load the trained weights).
The RPNs seems to be the same, see attached screenshot.

Mmm... mea culpa.
It seems that a corrupted file appeared in the middle of the wrong directory and replaced the proper weights.
Everything is working fine now.


Support custom anchor specification "?anchor=EXAMPLE" in BibXML Service APIs

From @strogonoff :
Next version uses the following logic:

Take either given anchor GET parameter or docid with scope=anchor (if any) as anchor
Return reference.<anchor>.<serialization format> as filename in the Content-Disposition header, so that it’s suggested to the user as default filename

From @TonyLHansen :
Both the current bibxml-doi and bibxml-iana support "?anchor=EXAMPLE" to override the anchor value that is returned.
This should eventually be extended to all of the bibxml-xyz.
See the web page https://xml2rfc.tools.ietf.org/ for more info.
Originally posted in https://github.com/ietf-ribose/bibxml-service/issues/150#issuecomment-1086645561

@ronaldtse I have stated multiple times over past weeks that this is exactly how it works :) See OpenAPI specification for details:  https://dev.bibxml.org/api/v1/#operation/getBibItemByDocId

Unless you mean this is about the xml2rfc compatibility API. Which I don’t think is the case (why would we spend time getting “anchor” attribute right if we could simply let requester set it, like with the main API).

Not about compatibility. Just wanted to be sure we have this documented that a request can request for an anchor of choice. Thanks.

Okay. Yes, it’s documented and mentioned a few times in this repository in my responses to issue threads regarding anchor attribute behavior.

If the compatibility API (the drop-in replacement for the current URLs) supports anchor=EXAMPLE across the board, that's great!
However, I don't see mention of anchor=EXAMPLE on <openapi_spec_legacy>. Am I looking in the wrong place? If not, I think this needs to be re-opened.

No, compat API doesn’t recognize any GET parameters actually. Not a big change to extend anchor support to that.
Does this mean we can assume all xml2rfc-style XML API consumers will specify anchor, or we need to maintain logic for providing suitable anchors if none is given?

Here are excerpts of the code used for the current bibxml-doi & bibxml-iana:
	cgi_anchor = cgi_arguments["anchor"].value

        self.replacement_anchor = self.munge_anchor(cgi_anchor)

	""" If there is a replacement anchor, use that for the embedded anchor within the text. """
        f"anchor='{self.replacement_anchor}"

    def munge_anchor(self, anchor):
        """ Make sure that an anchor is "safe" by changing to uppercase and remove non-[A-Z0-9_-]. """
        if anchor:
            anchor = re.sub(r"[^-A-Z0-9_]]", "", anchor.upper())
        return anchor

no, the code shows is an excerpt, as stated. There's an if I didn't show -- if the anchor parameter isn't given, it uses the one normally generated.

xml2rfc paths now handle anchor parameter, example:

https://dev.bibxml.org/public/rfc/bibxml-ids/reference.I-D.weis-gdoi-iec62351-9.xml
https://dev.bibxml.org/public/rfc/bibxml-ids/reference.I-D.weis-gdoi-iec62351-9.xml?anchor=foobar

@TonyLHansen, regarding munging the anchor, I see that in reference data it isn’t always uppercase, e.g.: http://xml2rfc.tools.ietf.org/public/rfc/bibxml3/reference.I-D.agl-tls-chacha20poly1305.xml. Is it needed? Should it happen on per-dataset basis or across any xml2rfc path, meaning it would be different at least for documents under bibxml3?

Also, note that the anchor specified in GET query will not have effect on <reference> elements nested within a <referencegroup> (relevant for rfcsubseries and possibly more datasets later).

Thank you @strogonoff ! Quick question -- does this new behavior also apply to non-IETF bibliographic items, e.g. NIST? (I hope it does 😉 )


Make runtime yield delay configurable

When developing the pxt-bedrock target, I was seeing major performance problems when our code ran within Minecraft's JavaScript runtime. The culprit turned out to be this fixed value of 5ms for the yield delay. Lowering the value to zero completely resolved the issue. Would we see similar improvement in pxt-minecraft? The runtime environments are very different. Experimentation will tell.
Making this value configurable so we can adjust it in the pxt-minecraft target.

@mmoskal to take a quick look. I am surprised 5ms to 0ms makes a difference.

@mmoskal to take a quick look. I am surprised 5ms to 0ms makes a difference.

This codepath is hit a lot during script execution, and Minecraft's JS runtime seems to be very lax in trying to honor the value. It seems to be interpreting it as "not less than". Chromium's JS runtime will probably behave better even when hosted in Minecraft. Still, I believe @riknoll experimented setting this to zero in Arcade and saw a slight improvement.

lgtm, but yeah good to wait on michal thoughts here

Happy to wait, no urgency, but just want to clarify that this PR doesn't change current behavior.

lgtm, but yeah good to wait on michal thoughts here

Happy to wait, no urgency, but just want to clarify that this PR doesn't change current behavior.

Oh of course, the default value is the same as it previously was, I meant more in the 'are there any dragons hidden in changing this value that we should track' sense.

I think it should be OK. This code should only kick in when the user script is running without yielding for at least 20ms. You could increase that instead, to say 50ms. But 0 ms yield also sounds good!

I think it should be OK. This code should only kick in when the user script is running without yielding for at least 20ms. You could increase that instead, to say 50ms.

Nice info. Good to know of this behavior, thank you!


fix QR decomp for complex-valued matrix

The QR decomposition for complex matrices can now be performed based on the following line of lubeck.d.
https://github.com/kaleidicassociates/lubeck/blob/master/source/kaleidic/lubeck.d#L2106

v1.5.1


Add requests to requirements.txt

The requests module is not a built-in module in python (currently). Since it is being used in fetch-mirrors.py, I am adding it to the requirements.txt.

Good catch, thanks for that!


Ability to remove Annotations when editing Templates

We are currently not able to delete an Annotation that has already been entered when editing a Template's Questions:
Expected behaviour: Removing the text from an Annotation should make it go away when the Question is saved.
Actual behaviour: Template reloads, and Annotation is still there.
Steps to reproduce:

Edit Template
Edit Question that has Annotation
Delete Annotation text and save

Things to consider:

It's better to replace the text with a blank string ('') rather than delete the original Annotation (that way we can recover user mistakes from the DB - which is a request we often get).
If the above is implemented, we need to insert logic that ignores empty Annotations, so we don't get an annotation with no text appearing during Template preview/Plan editing.

EDIT: @jollopre has found the culprit: https://github.com/DMPRoadmap/roadmap/blob/development/app/controllers/questions_controller.rb#L55

deleting annotations is working as expected now. closing issue.

Looks good - removing from board


At v15.1.5 and beyond tests hang

Current behavior
cypress hang failure.txt
Cypress hangs after version 15.1.4
Desired behavior
not to hang
Versions

Cypress version: >12
Preprocessor version: > 15.1.4
Node version:16.17.1

Checklist

[- ] I've read the FAQ.
[ -] I've read instructions for logging issues.
[ -] I'm not using<EMAIL_ADDRESS>(package name has changed and it is no longer the most recent version, see #689).

Hey, and thanks for reporting this issue. You need however to adhere to the guidelines for reporting issues. Please read through it and update your issue accordingly.

Sure sorry was quite late. Will make a block example over the weekend because it might be a certain configuration.

hey @badeball https://www.loom.com/share/b0e6068b870348d6961eb20890c40d1e I thought I'd give you a loom to show apart of the issue.
 Let me know if theres something I can do to help you reproduce further :)

This isn't what I'm looking for. You need to provide a way for me to reproduce the behavior myself. You can read about this in the contributing guidelines.

Closing due to lack of a reproducible example. Feel free to open up another issue if anything changes in this regard.


Slimming down torchchat: Replace replace_attention_with_custom_sdpa_attention() with ET's implementation

🚀 The feature, motivation and pitch
First surfaced in https://github.com/pytorch/torchchat/pull/1057, the replace_attention_with_custom_sdpa_attention function, used when exporting models in torchchat, can be replaced with the equivalent API provided in the Excecutorch https://github.com/pytorch/executorch/blob/main/examples/models/llama2/source_transformation/sdpa.py
Task: Swap the torchchat implementation with that of ExecuTorch's. Delete the then defunct code from torchchat
Alternatives
No response
Additional context
No response
RFC (Optional)
No response

I think #1057 resolved this.  Can we close?

Not quite, #1057 was the Pr the flagged it
Should be easy PR, just needs testing


[qt] Dynamic decks (add/remove slots; add/remove decks)

Dynamically add/remove slots from decks from the UI; maybe even add new decks?

The modelview interface paradigm makes this ticket obsolete.


hotkeys: Quote selected text when > hotkey is pressed.

Follow up for https://github.com/zulip/zulip/pull/15235 (See this for details on the issue)
Rebased and tested.

CZO link here
Testing plan:
Tested manually selecting and works as shown in the original PR.

Ignore the search | copy that  comes in the gif, it is a browser feature of opera.

This was completed via https://github.com/zulip/zulip/pull/28789.


Add country dropdown to scatterplot

Overview
This was for #1543. I created addCountrySelect.js to inst/utils. This required that we modify inst/htmlwidgets/Widget_ScatterPlot.js and inst/htmlwidgets/Widget_ScatterPlot.yaml to call the addCountrySelect.js function.
Test Notes/Sample Code
To test, run the following after running lines 1-97 on  workflow_reporting_charts.R.
You can see the functionality below:
https://github.com/Gilead-BioStats/gsm/assets/76186904/f6c96e49-8d9b-4704-b2bf-5f7daa6c3003

This looks really nice @taylorrodgers! I dropped a couple comments below and to summarize it's going to be easiest to add both the site highlight and country highlight with a single function (addSiteHighlight say), placing both dropdowns in a single div.
It would also be nice to add this control to the bar chart and time series.

@samussiah, thank you for looking if over! One question: do we want to add this to the bar and time series chart on this issue / PR? Or would that be a separate ticket? #1543 only mentioned scatterplot. No objection from me if we want to expand the issue to those other charts :)

This looks really nice @taylorrodgers! I dropped a couple comments below and to summarize it's going to be easiest to add both the site highlight and country highlight with a single function (addSiteHighlight say), placing both dropdowns in a single div.
It would also be nice to add this control to the bar chart and time series.

@samussiah, thank you for looking if over! One question: do we want to add this to the bar and time series chart on this issue / PR? Or would that be a separate ticket? #1543 only mentioned scatterplot. No objection from me if we want to expand the issue to those other charts :)

Yep, give the other charts the same treatment.


[Admin] Publish

Learn Build status updates of commit 09945cf:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

docs/outlook/autolaunch.md
:white_check_mark:Succeeded
View

docs/outlook/categories.md
:white_check_mark:Succeeded
View

docs/outlook/smart-alerts-onmessagesend-walkthrough.md
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the learn.microsoft.com contributor guidesPost your question in the Learn support channel


Question

What’s is the difference with Fan and FanV2?
And how can use speaker and microphone?

Hi,
I think there is no difference between Fan and FanV2.
Speaker and Microphone are not implemented in that plugin.


fix: some typos in code and comments

Pull Request Test Coverage Report for Build 832

6 of 6 (100.0%)  changed or added relevant lines in 3 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 96.648%

Totals

Change from base Build 134:
0.0%

Covered Lines:
636

Relevant Lines:
661

💛  - Coveralls

Pull Request Test Coverage Report for Build 832

6 of 6 (100.0%)  changed or added relevant lines in 3 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 96.648%

Totals

Change from base Build 134:
0.0%

Covered Lines:
636

Relevant Lines:
661

💛  - Coveralls


[earlgrey_1.0.0,spi_host/rtl] Fix sd_en_o of spi_host_fsm

This partially reverts commit 7eb53da738a770a4cc00153eb7179a2c2d9bdda9, which introduced a glitch on the sd_en_o output of spi_host_fsm. The reversal is partial in order to minimize the netlist diff.  The drive_posedge signal as well as the four sd_en_ff_q flops are now unused.
This is not a cherry pick of a commit on master, where the glitch is planned to be fixed with a full reversal of the commit mentioned above.

The PD team has confirmed that this change can be applied as an ECO to both instances of SPI Host, so this PR should get applied to the release branch instead of #24516.

CHANGE AUTHORIZED: hw/ip/spi_host/rtl/spi_host_fsm.sv
Approved as ECO


Add default background when applying backgroundTint

Description
When we apply a tint to a background that does not exist, the tint is never applied.
I fixed the problem by applying a default background when there is not already one just before applying the tint.
Types of changes

[x] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)

It could have been better by merging the hidden alpha and background from textView to the same code as the view binder.

It could have been better by merging the hidden alpha and background from textView to the same code as the view binder.

I've already answered on Slack, but I'll leave a trace here just in case! ;)
The "hidden" behaviour is not the same in both cases. One can be both "VISIBLE" or "GONE" and the other is always "GONE".


addition of disqus

Is your feature request related to a problem? Please describe.
currently the website is bit simple with the addition of disqus it will be interactive as users can like comment and interact
Describe the solution you'd like
Disqus offers the best add-on tools for websites to increase engagement. We help publishers power online discussions with comments and likes.
Describe alternatives you've considered
if the plugin cant be added then we can work with custom comment section which might be bit complicated

Looking forward to create own custom authentication system with comment section in v2.


World.CreateProp not working?

Hey,
i cant get to work World.CreateProp. I tried it like this for example:
World.CreateProp(new Model(WeaponHash.AdvancedRifle), Game.Player.Character.Position, true, true);

But it just doesnt happen anything... Tried it also with a VehicleHash but same result. Andalso, can i spawn game objects with that, such as trees for example?

Hey,
World.CreateProp is not working that way. You can only spawn "props", which are objects in GTA V. (like a jetski ramp e.g). You can get a full list here
Example:
World.CreateProp(new Model("prop_jetski_ramp_01"), Game.Player.Character.Position, true, true);

Thank you so much for the example, i already tried this:
World.CreateProp(new Model(0xB717705B), Game.Player.Character.Position, true, true);

But this throws a syntax error.
Model 0xB717705B is a object in GTA V: DB_PierlightA_MH11
I will try using its name now. Thank you :)

Btw. you don't need to write "World.CreateProp(new Model(XYZ), ...);". The Model class has an implicit conversion operator, so simply write "World.CreateProp(XYZ, ...);" directly =).

Thankx, works perfectly.


Failing test for issue #204

I'll take a shot at fixing the issue. Help very wanted.

propertyDeclaration is not undefined. What we're doing is pretty insane but yeah. Not sure
You could heck the method visitDecorators https://github.com/babel/babel-eslint/blob/master/index.js#L88-L97 and the call sites - although that is used to fixno-unused-vars (the corresponding rule)

Hmm, I'm doubting this is a real bug. It might actually be a valid warning.
Example:
{
  @readOnly foo
}

is transpiled by babel to
{
  key: 'foo',
  decorators: [readOnly],
  initializer: function initializer() {
    return foo;
  }
}

Which looks like it's just like a shorthand property.
var a = 1;
var b = 2;

var c = { a, b }

c.a // => 1
c.b // => 2

So this would cause a nice subtle bug if we would disable no-undef warnings on this.
var foo = 'bar'

var object = {
  @readOnly foo
};

object.foo // => 'bar'


install-azd.sh fails with "permission denied" if sudo password is disabled

Simplified Repro
$ docker run -it --rm ubuntu

root@3482a89eb56d:/# history
    1  apt-get update
    2  apt-get -y install sudo curl nano
    3  useradd -ms /bin/bash -G sudo newuser
    4  echo 'newuser:newuser' | chpasswd
    5  sudo -u newuser bash

newuser@3482a89eb56d:/$ history
    1  sudo visudo
    2  curl -fsSL https://aka.ms/install-azd.sh | bash

Full Repro
$ docker run -it --rm ubuntu

# Create User
$ apt-get update
$ apt-get -y install sudo curl nano
$ useradd -ms /bin/bash -G sudo newuser
$ echo 'newuser:newuser' | chpasswd
$ sudo -u newuser bash

# Expected
$ curl -fsSL https://aka.ms/install-azd.sh | bash
<prompts for sudo, installs successfully>
$ curl -fsSL https://aka.ms/uninstall-azd.sh | bash
$ exit

# Disable sudo password (https://askubuntu.com/a/147265)
$ sudo -u newuser bash
$ sudo visudo
<add "newuser ALL=(ALL) NOPASSWD:ALL" at end-of-file>

# Fail
$ curl -fsSL https://aka.ms/install-azd.sh | bash
azd-linux-amd64
NOTICE.txt
mkdir: cannot create directory '/opt/microsoft/azd': Permission denied

# Workaround
$ curl -fsSL https://aka.ms/install-azd.sh | sudo bash

The log messages of the install script are misleading; the install does complete successfully.
We don't suppress output from mkdir and so when it attempts to create a dir and fails the user sees the output. The script then elevates using sudo (which will or won't prompt the user depending on the context) and continues the install.
https://github.com/Azure/azure-dev/blob/main/cli/installer/install-azd.sh#L308-L319
if [[ ! -d "$install_folder" ]]; then
    say_verbose "Install folder does not exist: $install_folder. Creating..."

    if ! mkdir -p "$install_folder"; then
        say "Creating $install_folder requires elevated permission. You may be prompted to enter credentials."
        if ! sudo mkdir -p "$install_folder"; then
            say_error "Could not create install folder: $install_folder"
            save_error_report_if_enabled "InstallFailed" "SudoMkdirFailure"
            exit 1
        fi
    fi
fi

The fix here is to send error output of mkdir to /dev/null instead of letting the user see it.
Thanks again @mikeharder for reporting!


add high level API to set priority of system handlers

needed for cortex-m-rtfm v0.4.x (it makes my life easier / it makes it easier to
support ARMv6-M)
r? @rust-embedded/cortex-m (anyone)

Addressed review comments

bors try

bors r+


Add floor and ceil to float w/ tests

Closing as this was not present in CPython 3.8

Oh, it's fine to use stuff from CPython 3.9, if you want to reopen this. We have self-describing fstring specifiers and := as well from 3.9.

Oh, unless there's a issue with CI tests, it seems weird that the test snippets would be affected.

I suppose you could probably comment out the AttributeError test in stdlib_math


Unable to define the configuration_url

Description of the issue
Is it possible to define something in url option of the Z2M frontend configuration so that devices in HomeAssistant have a direct link to the device ?

With a "regular" setup, you would define the base URL http://<IP_ADDRESS>:8080 in Z2M's configuration file, and HA's configuration_url gets defined like this (visible in HA's .storage/core.device_registry file):
        "configuration_url": "http://<IP_ADDRESS>:8080/#/device/0x70ac08fffe87636c/info",
I tried to define the url value to http://myhomeassistant.local:8123/api/hassio_ingress/1234567913521651651/ (where this URL is what i see when opening the Z2M UI into a new tab, i.e. the iframe URL, but it does not work: HA does not seem to update the configuration_url at all, and also the Z2M UI does not show the value after i enter it (but it shows in the zigbee2mqtt/configuration.yaml file).
Worse, because i migrated from a regular deployment, HA keeps the old (now broken) configuration url, and at least i'd like to purge these.
Any hints appreciated
Addon version
1.31.2-1
Platform
Home Assistant 2023.6.3
Supervisor 2023.06.2
OS: https://github.com/foreign-sub/ha_fbx
Logs of the issue (if applicable)
No response

This is the code i'm referring to in Z2M:
        if (settings.get().frontend?.url) {
            const url = settings.get().frontend?.url;
            payload.configuration_url = entity.isDevice() ? `${url}/#/device/${entity.ieeeAddr}/info` :
                `${url}/#/group/${entity.ID}`;
        }

https://github.com/Koenkk/zigbee2mqtt/blob/master/lib/extension/homeassistant.ts#L1465C1-L1469C10

I think i understand what is happening, the /docker-entrypoint.sh script overrides the frontend configuration section:
export ZIGBEE2MQTT_CONFIG_FRONTEND='{"port": 8099}'
https://github.com/zigbee2mqtt/hassio-zigbee2mqtt/blob/master/common/rootfs/docker-entrypoint.sh#L63
What would be needed is that HA provides HA's URL and "ingress code"<PHONE_NUMBER>521651651) as env var, and that the entrypoint script does
export ZIGBEE2MQTT_CONFIG_FRONTEND='{"port": 8099, "url": http://$HA_URL/api/hassio_ingress/$INGRESS_CODE}'

I found out that bashio::addon.ingress_entry provides the appropriate path (i.e. /api/hassio_ingress/$INGRESS_CODE) , so it seems possible !

I think this PR might enable this feature, can anyone help testing (i don't know how) ?
https://github.com/zigbee2mqtt/hassio-zigbee2mqtt/pull/499

I have installed the addon update which causes all devices to become unavailable. The log contains many of the following error messages:
2023-07-01 13:20:20.252 ERROR (MainThread) [homeassistant.components.mqtt.mixins] Error 'invalid url for dictionary value @ data['device']['configuration_url']' when processing MQTT discovery message topic:
'homeassistant/select/0x001788010bd22725/motion_sensitivity/config', message: '{'availability': [{'topic': 'zigbee2mqtt/bridge/state', 'value_template': '{{ value_json.state }}'}, {'topic': 'zigbee2mqtt/Garten Bewegungsmelder/availability', 'value_template': '{{ value_json.state }}'}], 'availability_mode': 'all', 'command_topic': 'zigbee2mqtt/Garten Bewegungsmelder/set/motion_sensitivity', 'device': {'configuration_url': '/api/hassio_ingress/MHPSVu_8PjPBi6vc27fKsyvKTUS4USdVuT5kwq1FwwU/#/device/0x001788010bd22725/info', 'identifiers': ['zigbee2mqtt_0x001788010bd22725'], 'manufacturer': 'Philips', 'model': 'Hue motion outdoor sensor<PHONE_NUMBER>)', 'name': 'Garten Bewegungsmelder', 'sw_version': '2.53.6'}, 'entity_category': 'config', 'icon': 'mdi:tune', 'name': 'Garten Bewegungsmelder motion sensitivity', 'options': ['low', 'medium', 'high', 'very_high', 'max'], 'state_topic': 'zigbee2mqtt/Garten Bewegungsmelder', 'unique_id': '0x001788010bd22725_motion_sensitivity_zigbee2mqtt', 'value_template': '{{ value_json.motion_sensitivity }}', 'platform': 'mqtt'}'

Based on the code in the HA core, the configuration_url must be an absolute URL:
[...]
            vol.Optional(CONF_CONFIGURATION_URL): cv.url,
[...]

# pylint: disable=no-value-for-parameter
def url(value: Any) -> str:
    """Validate an URL."""
    url_in = str(value)

    if urlparse(url_in).scheme in ["http", "https"]:
        return cast(str, vol.Schema(vol.Url())(url_in))

    raise vol.Invalid("invalid url")

I can confirm - after updating to newer version it fails to autodiscovery devices.
`Exception in async_discover when dispatching 'mqtt_discovery_new_select_mqtt': ({'availability': [{'topic': 'zigbee2mqtt/bridge/state'}], 'command_topic': 'zigbee2mqtt/Garden_Sensor2/set/temperature_unit', 'device': {'configuration_url': '/api/hassio_ingress/kIMye0iSR_ZQqqA9fePfYMh-TRvUVqWOV_h2tm4DnD4/#/device/0xa4c1381686efeade/info', 'identifiers': ['zigbee2mqtt_0xa4c1381686efeade'], 'manufacturer': 'TuYa', 'model': 'Soil sensor (TS0601_soil)', 'name': 'Garden_Sensor2'}, 'name': 'Garden_Sensor2_temperature_unit', 'options': ['celsius', 'fahrenheit'], 'state_topic': 'zigbee2mqtt/Garden_Sensor2', 'unique_id': '0xa4c1381686efeade_temperature_unit_zigbee2mqtt', 'value_template': '{{ value_json.temperature_unit }}', 'platform': 'mqtt'},) Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/components/mqtt/mixins.py", line 270, in async_discover config: DiscoveryInfoType = discovery_schema(discovery_payload) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/voluptuous/validators.py", line 232, in __call__ return self._exec((Schema(val) for val in self.validators), v) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/voluptuous/validators.py", line 355, in _exec raise e if self.msg is None else AllInvalid(self.msg, path=path) File "/usr/local/lib/python3.11/site-packages/voluptuous/validators.py", line 351, in _exec v = func(v) ^^^^^^^ File "/usr/local/lib/python3.11/site-packages/voluptuous/schema_builder.py", line 272, in __call__ return self._compiled([], data) ^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/voluptuous/schema_builder.py", line 818, in validate_callable return schema(data) ^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/voluptuous/schema_builder.py", line 272, in __call__ return self._compiled([], data) ^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/voluptuous/schema_builder.py", line 595, in validate_dict return base_validate(path, iteritems(data), out) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/site-packages/voluptuous/schema_builder.py", line 433, in validate_mapping raise er.MultipleInvalid(errors) voluptuous.error.MultipleInvalid: invalid url for dictionary value @ data['device']['configuration_url']
`

Additionally, there is no way to edit the URL trough frontend - it always goes back to the /api/hassio_ingress/............
even if it saves in the congfiguration.yaml

https://github.com/zigbee2mqtt/hassio-zigbee2mqtt/pull/500
we can just delete it from entrypoint for quick fix

same issue here. anyone fixed?

Sorry for the mess i caused with my PR; the change has been reverted with PR https://github.com/zigbee2mqtt/hassio-zigbee2mqtt/pull/500 and koenkk has released  v1.32.0 which fixes the regression.
I still think it's worth digging and will try to have HA tolerate relative URLs.

Not stale

Not stale


Add vscode debugging instructions to repo

Closed by https://github.com/oaeproject/Hilary/pull/2498


docs: Adds useTranslation hook example of usage

Due
https://github.com/isaachinman/next-i18next/issues/814#issuecomment-688382104

Needs a semantic title. Thanks @zarabotaet!

Needs a semantic title. Thanks @zarabo

Needs a semantic title. Thanks @zarabotaet!

done


previousOwner._heroControllerFromScope != newHeroController': is not true

My error is the following:
'package:flutter/src/widgets/navigator.dart': Failed assertion: line 2785 pos 24: 'previousOwner._heroControllerFromScope != newHeroController': is not true.

_updateHeroController(null) only be called in the dispose method,so I think previousOwner._heroControllerFromScope may be equal to newHeroController
My simple demo is: https://github.com/whatscoder/navigator_test, branch is master
flutter doctor is:
[✓] Flutter (Channel stable, 1.22.2, on Mac OS X 10.15.4
    19E287, locale zh-Hans-CN)
    • Flutter version 1.22.2 at
      /Users/mj/Documents/flutter1220
    • Framework revision 84f3d28555 (2 weeks ago), 2020-10-15
      16:26:19 -0700
    • Engine revision b8752bbfff
    • Dart version 2.10.2
    • Pub download mirror https://pub.flutter-io.cn
    • Flutter download mirror https://storage.flutter-io.cn

[✓] Android toolchain - develop for Android devices (Android     SDK version 30.0.0)
    • Android SDK at /Users/mj/Library/Android/sdk
    • Platform android-30, build-tools 30.0.0
    • ANDROID_HOME = /Users/mj/Library/Android/sdk
    • Java binary at: /Applications/Android
      Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build
      1.8.0_212-release-1586-b4-5784211)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 12.0.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 12.0.1, Build version 12A7300
    • CocoaPods version 1.9.3

[✓] Android Studio (version 3.6)
    • Android Studio at /Applications/Android
      Studio.app/Contents
    • Flutter plugin version 47.1.1
    • Dart plugin version 192.8052
    • Java version OpenJDK Runtime Environment (build
      1.8.0_212-release-1586-b4-5784211)

Hi @whatscoder
Can you please isolate the code causes and create a minimal code sample and provide steps to reproduce
Can you please provide flutter run --verbose logs, and a minimal complete reproducible code sample?
Thank you

Hi @TahaTesser
Let me give you a brief account of my operation:
I have a StatefulWidget ，Overlay  is his child，and then I package a navigator as an OverlayEntry and insert into OverlayState。When over one OverlayEntry that packaged navigator are inserted into OverlayState, there is an error: package:flutter/src/widgets/navigator.dart': Failed assertion: line 2785 pos 24: 'previousOwner._heroControllerFromScope != newHeroController': is not true.
flutter run --verbose logs:
[+604284 ms] flutter: ══╡ EXCEPTION CAUGHT BY SCHEDULER LIBRARY ╞═════════════════════════════════════════════════════════
[        ] flutter: The following assertion was thrown during a scheduler callback:
[   +7 ms] flutter: 'package:flutter/src/widgets/navigator.dart': Failed assertion: line 2785 pos 24:
[        ] flutter: 'previousOwner._heroControllerFromScope != newHeroController': is not true.
[        ] flutter:
[        ] flutter: Either the assertion indicates an error in the framework itself, or we should provide substantially
[        ] flutter: more information in this error message to help you determine and fix the underlying cause.
[        ] flutter: In either case, please report this assertion by filing a bug on GitHub:
[        ] flutter:   https://github.com/flutter/flutter/issues/new?template=BUG.md
[        ] flutter:
[        ] flutter: When the exception was thrown, this was the stack:
[        ] flutter: #2      NavigatorState._updateHeroController.<anonymous closure>.<anonymous closure> (package:flutter/src/widgets/navigator.dart:2785:24)
[        ] flutter: #3      SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:1117:15)
[  +19 ms] flutter: #4      SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:1063:9)
[        ] flutter: #5      SchedulerBinding._handleDrawFrame (package:flutter/src/scheduler/binding.dart:971:5)
[        ] flutter: #9      _invoke (dart:ui/hooks.dart:251:10)
[        ] flutter: #10     _drawFrame (dart:ui/hooks.dart:209:3)
[        ] flutter: (elided 5 frames from class _AssertionError and dart:async)
[        ] flutter: ════════════════════════════════════════════════════════════════════════════════════════════════════
[+20133 ms] flutter: Another exception was thrown: 'package:flutter/src/widgets/navigator.dart': Failed assertion: line 2785 pos 24: 'previousOwner._heroControllerFromScope != newHeroController': is not true.

If the description is not clear, please indicate, Thank you

Hi @whatscoder
Thanks for describing the issue, to better address the issue, please provide a minimal code sample
Thank you

Hi @TahaTesser
I have simplified my code sample. https://github.com/whatscoder/navigator_test/    branch is master
The exception is the same as the above.
please check again, Thank you.

Hi @whatscoder
I put all your code in a single main.dart

code sample
import 'package:flutter/material.dart';
import 'package:flutter/scheduler.dart';

final GlobalKey<ContainerManagerState> containerManagerKey =
    GlobalKey<ContainerManagerState>();

void main() => runApp(MyApp());

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Material App',
      builder: (BuildContext context, Widget child) {
        assert(child is Navigator, 'child must be Navigator, what is wrong?');

        return ContainerManager(
          key: containerManagerKey,
          initNavigator: child as Navigator,
        );
      },
      home: Container(
        color: Colors.white,
      ),
    );
  }
}

class ContainerManager extends StatefulWidget {
  const ContainerManager({
    Key key,
    this.initNavigator,
  }) : super(key: key);

  @override
  State<StatefulWidget> createState() => ContainerManagerState();

  final Navigator initNavigator;
}

class ContainerManagerState extends State<ContainerManager> {
  final GlobalKey<OverlayState> _overlayKey = GlobalKey<OverlayState>();
  final List<Navigator> _offstage = <Navigator>[];
  List<OverlayEntry> _leastEntries;
  Navigator _onstage;

  @override
  void initState() {
    super.initState();

    _onstage = Navigator(
      key: GlobalKey<NavigatorState>(),
      onGenerateRoute: (RouteSettings routeSettings) {
        return MaterialPageRoute(builder: (BuildContext context) {
          return FirstWidget();
        });
      },
    );

    WidgetsBinding.instance.addPostFrameCallback((_) {
      setState(() {});
    });
  }

  @override
  void setState(VoidCallback fn) {
    if (SchedulerBinding.instance.schedulerPhase ==
        SchedulerPhase.persistentCallbacks) {
      SchedulerBinding.instance.addPostFrameCallback((Duration duration) {
        _refreshOverlayEntries();
      });
    } else {
      _refreshOverlayEntries();
    }

    fn();
  }

  @override
  Widget build(BuildContext context) {
    return Overlay(
      key: _overlayKey,
      initialEntries: const <OverlayEntry>[],
    );
  }

  void pushContainer(WidgetBuilder builder) {
    _offstage.add(_onstage);

    _onstage = Navigator(
      key: GlobalKey<NavigatorState>(),
      onGenerateRoute: (RouteSettings routeSettings) {
        return MaterialPageRoute(builder: builder);
      },
    );

    setState(() {});
  }

  void _refreshOverlayEntries() {
    final OverlayState overlayState = _overlayKey.currentState;

    if (overlayState == null) return;

    if (_leastEntries != null && _leastEntries.isNotEmpty) {
      for (final OverlayEntry entry in _leastEntries) {
        entry.remove();
      }
    }

    final List<Navigator> containers = <Navigator>[];
    containers.addAll(_offstage);
    containers.add(_onstage);

    _leastEntries = containers
        .map<OverlayEntry>((Navigator container) =>
            OverlayEntry(builder: (BuildContext context) => container))
        .toList(growable: false);

    overlayState.insertAll(_leastEntries);
  }
}

class FirstWidget extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: const Text('first'),
      ),
      body: Center(
          child: RaisedButton(
              child: const Text('click'),
              onPressed: () {
                ContainerManagerState state =
                    context.findAncestorStateOfType<ContainerManagerState>();
                state.pushContainer((context) => SecondWidget());
              })),
    );
  }
}

class SecondWidget extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: const Text('second'),
      ),
      body: Center(
        child: Text('hello'),
      ),
    );
  }
}

logs
Running "flutter pub get" in master_flutter...
Launching lib/main.dart on iPhone 12 in debug mode...
 lib/main.dart
Xcode build done.                                           26.0s
Connecting to VM Service at ws://<IP_ADDRESS>:53074/Ck3KIERTjPI=/ws

════════ Exception caught by scheduler library ═════════════════════════════════
The following assertion was thrown during a scheduler callback:
'package:flutter/src/widgets/navigator.dart': Failed assertion: line 3389 pos 24: '<optimized out>': is not true.

Either the assertion indicates an error in the framework itself, or we should provide substantially more information in this error message to help you determine and fix the underlying cause.
In either case, please report this assertion by filing a bug on GitHub:
  https://github.com/flutter/flutter/issues/new?template=2_bug.md

When the exception was thrown, this was the stack
#2      NavigatorState._updateHeroController.<anonymous closure>.<anonymous closure>
 package:flutter/…/widgets/navigator.dart
#3      SchedulerBinding._invokeFrameCallback
 package:flutter/…/scheduler/binding.dart
#4      SchedulerBinding.handleDrawFrame
 package:flutter/…/scheduler/binding.dart
#5      SchedulerBinding._handleDrawFrame
 package:flutter/…/scheduler/binding.dart
#9      _invoke (dart:ui/hooks.dart:157:10)
...
════════════════════════════════════════════════════════════════════════════════

flutter doctor -v
[✓] Flutter (Channel stable, 1.22.3, on Mac OS X 10.15.7 19H2, locale en-GB)
    • Flutter version 1.22.3 at /Users/tahatesser/Code/flutter_stable
    • Framework revision 8874f21e79 (4 days ago), 2020-10-29 14:14:35 -0700
    • Engine revision a1440ca392
    • Dart version 2.10.3

[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
    • Android SDK at /Users/tahatesser/Code/sdk
    • Platform android-30, build-tools 30.0.2
    • ANDROID_HOME = /Users/tahatesser/Code/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 12.1)
    • Xcode at /Volumes/Extreme/Xcode.app/Contents/Developer
    • Xcode 12.1, Build version 12A7403
    • CocoaPods version 1.10.0

[!] Android Studio (version 4.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    ✗ Flutter plugin not installed; this adds Flutter specific functionality.
    ✗ Dart plugin not installed; this adds Dart specific functionality.
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)

[✓] VS Code (version 1.50.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.16.0

[✓] Connected device (1 available)
    • iPhone 12 (mobile) • 572593A3-647B-413C-9188-B91DD07DEAF0 • ios •
      com.apple.CoreSimulator.SimRuntime.iOS-14-1 (simulator)

! Doctor found issues in 1 category.

[✓] Flutter (Channel beta, 1.23.0-18.1.pre, on Mac OS X 10.15.7 19H2 x86_64, locale en-GB)
    • Flutter version 1.23.0-18.1.pre at /Users/tahatesser/Code/flutter_beta
    • Framework revision 198df796aa (3 weeks ago), 2020-10-15 12:04:33 -0700
    • Engine revision 1d12d82d9c
    • Dart version 2.11.0 (build 2.11.0-213.1.beta)

[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
    • Android SDK at /Users/tahatesser/Code/sdk
    • Platform android-30, build-tools 30.0.2
    • ANDROID_HOME = /Users/tahatesser/Code/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 12.1)
    • Xcode at /Volumes/Extreme/Xcode.app/Contents/Developer
    • Xcode 12.1, Build version 12A7403
    • CocoaPods version 1.10.0

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 4.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)

[✓] VS Code (version 1.50.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.16.0

[✓] Connected device (3 available)
    • iPhone 12 (mobile) • 572593A3-647B-413C-9188-B91DD07DEAF0 • ios            •
      com.apple.CoreSimulator.SimRuntime.iOS-14-1 (simulator)
    • Web Server (web)   • web-server                           • web-javascript • Flutter Tools
    • Chrome (web)       • chrome                               • web-javascript • Google Chrome
      86.0.4240.183

• No issues found!

[✓] Flutter (Channel master, 1.24.0-7.0.pre.73, on Mac OS X 10.15.7 19H2 darwin-x64, locale en-GB)
    • Flutter version 1.24.0-7.0.pre.73 at /Users/tahatesser/Code/flutter_master
    • Framework revision fb90544cab (2 hours ago), 2020-11-02 22:48:03 -0800
    • Engine revision<PHONE_NUMBER>
    • Dart version 2.12.0 (build 2.12.0-3.0.dev)

[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
    • Android SDK at /Users/tahatesser/Code/sdk
    • Platform android-30, build-tools 30.0.2
    • ANDROID_HOME = /Users/tahatesser/Code/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 12.1)
    • Xcode at /Volumes/Extreme/Xcode.app/Contents/Developer
    • Xcode 12.1, Build version 12A7403
    • CocoaPods version 1.10.0

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 4.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6222593)

[✓] VS Code (version 1.50.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.16.0

[✓] Connected device (4 available)
    • iPhone 12 (mobile) • 572593A3-647B-413C-9188-B91DD07DEAF0 • ios            •
      com.apple.CoreSimulator.SimRuntime.iOS-14-1 (simulator)
    • macOS (desktop)    • macos                                • darwin-x64     • Mac OS X 10.15.7 19H2
      darwin-x64
    • Web Server (web)   • web-server                           • web-javascript • Flutter Tools
    • Chrome (web)       • chrome                               • web-javascript • Google Chrome
      86.0.4240.183

• No issues found!

Hi @TahaTesser
I got it, after running, you need to click the button named 'click' of the FirstWidget, push to the SecondWidget,  and then the exception log is shown in the console.
I have put all my code in a single main.dart, https://github.com/whatscoder/navigator_test.git, branch is master
exception logs:
════════ Exception caught by scheduler library ═════════════════════════════════
The following assertion was thrown during a scheduler callback:
'package:flutter/src/widgets/navigator.dart': Failed assertion: line 2785 pos 24: 'previousOwner._heroControllerFromScope != newHeroController': is not true.

Either the assertion indicates an error in the framework itself, or we should provide substantially more information in this error message to help you determine and fix the underlying cause.
In either case, please report this assertion by filing a bug on GitHub:
  https://github.com/flutter/flutter/issues/new?template=BUG.md

When the exception was thrown, this was the stack
#2      NavigatorState._updateHeroController.<anonymous closure>.<anonymous closure>
package:flutter/…/widgets/navigator.dart:2785
#3      SchedulerBinding._invokeFrameCallback
package:flutter/…/scheduler/binding.dart:1117
#4      SchedulerBinding.handleDrawFrame
package:flutter/…/scheduler/binding.dart:1063
#5      SchedulerBinding._handleDrawFrame
package:flutter/…/scheduler/binding.dart:971
#9      _invoke (dart:ui/hooks.dart:251:10)

/cc @chunhtai

The hero controller cannot be shared across the multiple navigator,  you can fix this by wrapping each container with their own herocontrollerscope
import 'package:flutter/material.dart';
import 'package:flutter/scheduler.dart';

final GlobalKey<ContainerManagerState> containerManagerKey =
GlobalKey<ContainerManagerState>();

void main() => runApp(MyApp());

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Material App',
      builder: (BuildContext context, Widget child) {
        assert(child is Navigator, 'child must be Navigator, what is wrong?');

        return ContainerManager(
          key: containerManagerKey,
          initNavigator: child as Navigator,
        );
      },
      home: Container(
        color: Colors.white,
      ),
    );
  }
}

class ContainerManager extends StatefulWidget {
  const ContainerManager({
    Key key,
    this.initNavigator,
  }) : super(key: key);

  @override
  State<StatefulWidget> createState() => ContainerManagerState();

  final Navigator initNavigator;
}

class ContainerManagerState extends State<ContainerManager> {
  final GlobalKey<OverlayState> _overlayKey = GlobalKey<OverlayState>();
  final List<Widget> _offstage = <Widget>[];
  List<OverlayEntry> _leastEntries;
  Widget _onstage;

  @override
  void initState() {
    super.initState();

    _onstage = HeroControllerScope(controller: HeroController(), child: Navigator(
      key: GlobalKey<NavigatorState>(),
      onGenerateRoute: (RouteSettings routeSettings) {
        return MaterialPageRoute(builder: (BuildContext context) {
          return FirstWidget();
        });
      },
    ));

    WidgetsBinding.instance.addPostFrameCallback((_) {
      setState(() {});
    });
  }

  @override
  void setState(VoidCallback fn) {
    if (SchedulerBinding.instance.schedulerPhase ==
        SchedulerPhase.persistentCallbacks) {
      SchedulerBinding.instance.addPostFrameCallback((Duration duration) {
        _refreshOverlayEntries();
      });
    } else {
      _refreshOverlayEntries();
    }

    fn();
  }

  @override
  Widget build(BuildContext context) {
    return Overlay(
      key: _overlayKey,
      initialEntries: const <OverlayEntry>[],
    );
  }

  void pushContainer(WidgetBuilder builder) {
    _offstage.add(_onstage);

    _onstage = Navigator(
      key: GlobalKey<NavigatorState>(),
      onGenerateRoute: (RouteSettings routeSettings) {
        return MaterialPageRoute(builder: builder);
      },
    );

    setState(() {});
  }

  void _refreshOverlayEntries() {
    final OverlayState overlayState = _overlayKey.currentState;

    if (overlayState == null) return;

    if (_leastEntries != null && _leastEntries.isNotEmpty) {
      for (final OverlayEntry entry in _leastEntries) {
        entry.remove();
      }
    }

    final List<Widget> containers = <Widget>[];
    containers.addAll(_offstage);
    containers.add(_onstage);

    _leastEntries = containers
        .map<OverlayEntry>((Widget container) =>
        OverlayEntry(builder: (BuildContext context) => container))
        .toList(growable: false);

    overlayState.insertAll(_leastEntries);
  }
}

class FirstWidget extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: const Text('first'),
      ),
      body: Center(
          child: RaisedButton(
              child: const Text('click'),
              onPressed: () {
                ContainerManagerState state =
                context.findAncestorStateOfType<ContainerManagerState>();
                state.pushContainer((context) => SecondWidget());
              })),
    );
  }
}

class SecondWidget extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: const Text('second'),
      ),
      body: Center(
        child: Text('hello'),
      ),
    );
  }
}

I will put up a pr to improve the error message


Post-ODHack refactoring

Hi guys! In this PR I've refactored the code contributed during the ODHack event to fix some minor issues and make the code better aligned with our codebase. Also, it's a great opportunity to provide you with more detailed review than it was possible during finite time of the event.
@bigherc18 and the Aerich integration. It's a really great integration! We managed to make it as unobtrusive as possible, which was one of the main goals of this task. A single important addition I've made to the code is if 'schema' in sys.argv check. Without it when aerich is installed every command became 0.45 s slower. As a side effect this check removes aerich commands from the Sphinx CLI reference. I don't know if it's good or bad; might fix later.
@bigherc18 another task, Prometheus refactoring. I've created a script to dump a table for docs as planned. All the metric types seem to be in place. And the backward compatibility was kept. Additional typehints with int/float union are required until (if) this feature will be implemented in mypy: https://github.com/python/mypy/issues/13071.
@JoE11-y and the interactive config generator. The diff in my PR is big, but it's only the codestyle improvements without changing the logic. Survey item indexes in checks were replaced with values to improve readability. I also have removed the unused render abi part (some leftover?) and hid the survey results from replay.yaml file.
@MrRoudyk and the version check improvements. The code is great. But I felt that it's too much of it to keep in dipdup.cli, so I moved it to a separate module and added some OOP.
@tosoham and hiding tables in Hasura. The only thing I changed is added "_is_ignored" helper. After the end of hackathon I've also realized that we actually want not to skip these tables completely, but rather make them private, hiding from unauthorized users. But it was not part of the task. I'm going to implement this logic adjustment before 8.1.0.
Finally, some tips for all the participants:

Run CI checks on branch before opening the pull request. Linters and typecheckers when used appropriately help to find a great ratio of errors in code. And maintainers will ask you to make the checks green anyway.
Lazy imports are important for Python CLI applications, especially for ones with many dependencies. In DipDup the entrypoint is dipdup.cli module, where imports are separated per command. Currently, it takes about 0.25s to initialize this module, which is okay.
Try to do reduce the depth of nested blocks. For example, if you see a huge block after the "if" inside the loop, try reverting the condition like if not X: continue. It greatly increases readability.

Thanks for participating! 8.1.0 is going to be released and announced until the end of the week.

Thank you for your feedback @droserasprout, I really enjoyed working on dipdup, such a great code base !


Documentation Issues

Description

Extra whitespace in logger help after "trx"
https://github.com/Microsoft/vstest/blob/77f351fd73adf6b70be8f1912d1891c9cf0f5a52/src/vstest.console/Resources/Resources.resx#L237
 /logger:trx [;LogFileName=<Defaults to unique file name>]

Add sample usage for cli runsettings arguments. Additionally improve the documentation of cli runsettings arguments.

Support dotnet vstest -h
Currently typing this command gives this message:

Microsoft (R) Test Execution Command Line Tool Version <IP_ADDRESS>
Copyright (c) Microsoft Corporation.  All rights reserved.

Error: The test source file "-h" provided was not found.

There are 3 issues here:
(1) The extra white space after /logger:trx: this causes a malformed commandline if you then provide a LogFileName. Therefore, Fix this by just removing that extra space.
(2) Add sample usage for the CLI runsettings arguments: Only the most common arguments ought to be shown on the command line help. Providing runsettings arguments in the commandline is arguably an advanced scenario and the user ought to consult our documentation for that. Therefore, Won't Fix here.
(3) Support dotnet vstest -h: If you provide -h in addition to the error mentioned above, we also emit the over help content. That is fine. Therefore, Wont'fix here.

Issue (1) is already fixed.


error running filter

Hi,
I am getting this error when rendering the filters (scholarly-metadata and author-info-blocks) that previously worked.
scholarly-metadata.lua:95: not a named object: List: 0x7fc1a771ecf0
stack traceback:
...d /scholarly-metadata.lua:95: in function 'to_named_object'
[C]: in function 'pandoc.List.map'
...d /scholarly-metadata.lua:144: in upvalue 'canonicalize'
...d /scholarly-metadata.lua:176: in function <...d /scholarly-metadata.lua:175>
Error: pandoc document conversion failed with error 83
Execution halted
I did not change the code, is the code I had and worked
output:
bookdown::word_document2:
pandoc_args:
- --lua-filter=/scholarly-metadata.lua
- --lua-filter=/author-info-blocks.lua
- --reference-doc=/style_template_manuscript.docx
SESSION INFO
R version 4.2.1 (2022-06-23)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Big Sur 11.4
Matrix products: default
LAPACK: /Library/Frameworks/R.framework/Versions/4.2/Resources/lib/libRlapack.dylib
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base
loaded via a namespace (and not attached):
[1] compiler_4.2.1  bookdown_0.29   fastmap_1.1.0   htmltools_0.5.3 tools_4.2.1
[6] yaml_2.3.5      rmarkdown_2.16  knitr_1.40      xfun_0.33       digest_0.6.29
[11] rlang_1.0.6     evaluate_0.16
Any suggestion?
Is it possible to use these filters in Quarto?
Pablo

It might be possible to get those to work in Quarto, but Quarto has its own mechanism for author names and affiliations. It is based on these filters AFAIK, and I'd recommend to use that if possible. In fact, I'm planning to deprecate the two filters here in the future. Let us know if there a blockers that prevent you from using Quarto for this and we can try to find ways to make it work.
Cc @cderv

Thank you for your response. I haven't switched to quarto yet but I have tried. There are templates for different journals that allow to include author affiliations but I haven't been able to get them printed and they are set for pdf or html output (not MS Word). Unfortunately, most of the journals I submit require that the manuscript be in MS word (and I have to say that the filters are great).
Also, it is possible to include the filters in quarto as they are (so I hope you don't deprecate them) including the following in the YAML (see also https://github.com/quarto-dev/quarto-cli/issues/287)
filters:

scholarly-metadata.lua
author-info-blocks.lua
quarto

but I get the same error as in Rmarkdown.
Any idea about this error? any idea on how to make them work (at least in Rmarkdown)?
scholarly-metadata.lua:95: not a named object: List: 0x7fc1a771ecf0
stack traceback:
...d /scholarly-metadata.lua:95: in function 'to_named_object'
[C]: in function 'pandoc.List.map'
...d /scholarly-metadata.lua:144: in upvalue 'canonicalize'
...d /scholarly-metadata.lua:176: in function <...d /scholarly-metadata.lua:175>
Error: pandoc document conversion failed with error 83
Execution halted

@pavilaalo can you open an issue in https://github.com/rstudio/bookdown/ and share an example I can use to reproduce ?
bookdown uses some filters too for some features, and maybe there is a conflict. Thank you

Thank you very much for your interest and help.
The issue is open, see https://github.com/rstudio/bookdown/issues/1390
However, I get the same error when using default word/pdf, bookdown or even
quarto
On Mon, 3 Oct 2022 at 18:13, Christophe Dervieux @.***>
wrote:

@pavilaalo https://github.com/pavilaalo can you open an issue in
https://github.com/rstudio/bookdown/ and share an example I can use to
reproduce ?
bookdown uses some filters too for some features, and maybe there is a
conflict. Thank you
—
Reply to this email directly, view it on GitHub
https://github.com/pandoc/lua-filters/issues/252#issuecomment-1265699742,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ASSGXE6QAL6FUYEHSTRU2RLWBMA4LANCNFSM6AAAAAAQ2TFK2M
.
You are receiving this because you were mentioned.Message ID:
@.***>

The problem has been identified in the linked issue. Closing here


Upgrade should support --virtualbox-boot2docker-url

The upgrade docs imply it supports specifying the iso https://docs.docker.com/machine/, but that option only appears to work with create. Seems useful and consistent to allow a specific iso to be specified, e.g. to easily upgrade your docker server to an RC build.
$ docker-machine -v
docker-machine version 0.3.0 (HEAD)

$ docker-machine upgrade --virtualbox-boot2docker-url https://github.com/tianon/boot2docker/releases/download/v1.7.1-rc1/boot2docker.iso dev
Incorrect Usage.
Usage: docker-machine upgrade [arg...]
Upgrade a machine to the latest version of Docker
Description:
   Argument(s) are one or more machine names.

Thanks @jamshid !

Bumping since it affected me too. A note on the docs would be helpful at least.

Linking #2203 because it's a possible solution/fix for this issue.


[$500] Request Money - Scan request created using corrupt pdf displays incorrect error message

If you haven’t already, check out our contributing guidelines for onboarding and email<EMAIL_ADDRESS>to request to join our Slack channel!

Version Number: 1.4.22
Reproducible in staging?: y
Reproducible in production?: y
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: Applause - Internal Team
Slack conversation:
Action Performed:

Go to https://staging.new.expensify.com/
Tap fab --- Request money ---Scan
Upload a corrupt pdf
Select a contact
Tap request
Note no error displayed for uploading corrupt pdf
Tap on created scan request
Enter all fields required

Expected Result:
Scan request created using corrupt pdf must display correct error message " Receipt didn't upload".
Actual Result:
Scan request created using corrupt pdf displays incorrect error message " unexpected error, please try again".
Workaround:
Unknown
Platforms:

Which of our officially supported platforms is this issue occurring on?

[x] Android: Native
[x] Android: mWeb Chrome
[ ] iOS: Native
[ ] iOS: mWeb Safari
[ ] MacOS: Chrome / Safari
[ ] MacOS: Desktop

Screenshots/Videos
Add any screenshot/video evidence
https://github.com/Expensify/App/assets/93399543/01980846-4992-433a-82db-aca2b8378356
View all open jobs on GitHub
Upwork Automation - Do Not Edit

Upwork Job URL: https://www.upwork.com/jobs/~01b4b9e55e201f79ea
Upwork Job ID:<PHONE_NUMBER>598800896
Last Price Increase: 2024-01-05

I believe this is a duplicate of #34032.

Reached out to @situchan to see if this is a duplicate of https://github.com/Expensify/App/issues/34032#issuecomment-1880205362
I'm going to be ooo next week so going to add another BZ teammate to monitor this. Status- we're checking to see if this can be closed as a duplicate of https://github.com/Expensify/App/issues/34032#issuecomment-1880205362

@Christinadobrzyn @c3024 what's the technology stack/ language it's built?

Please close this issue as this is a dupe @Christinadobrzyn

closing issue per https://github.com/Expensify/App/issues/34068#issuecomment-1888537463


Bump up BanyanDB 0.3.0 client.

[ ] If this pull request closes/resolves/fixes an existing issue, replace the issue number. Closes #.
[x] Update the CHANGES log.

Follow the latest BanyanDB release.

@lujiajing1126 @hanahmily 0.3.0 DB or client may have issues. I have tried to rerun, but still fail in e2e.


How can i use external variable in transactions?

hello everyone.
I need your help and i hope to get solution of it.
I tried below code.
$userid = "test";
\QB::transaction(function ($qb) {
echo $userid;
$qb->table("user_table")->where("userid","=",$userid)->update(array('user_status'=>'1'));
});
i can't get $userid
let me kinda know how can i get external variable.
best regards.

You need to assign global
So code need to be:
$userid = "test";
\QB::transaction(function ($qb) {
global $userid;
echo $userid;
$qb->table("user_table")->where("userid","=",$userid)->update(array('user_status'=>'1'));
});

Thank you for reply.