[$250] Web - Profile - Notify me about new messages disappears from profile page

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.80-1
Reproducible in staging?: y
Reproducible in production?: y
Issue reported by: Applause - Internal team
Action Performed:

Login with a expensifail account
Go to FAB> Start chat> Search for a expensifail account and create new chat
Click on the header to view user details

Expected Result:
Notify me about new messages option should appear and remain
Actual Result:
Notify me about new messages disappears from profile page
Workaround:
n/a
Platforms:

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

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

Screenshots/Videos
Add any screenshot/video evidence
https://github.com/Expensify/App/assets/93399543/297f6a70-1c5c-45f5-9f68-7d6622497811
View all open jobs on GitHub
Upwork Automation - Do Not Edit

Upwork Job URL: https://www.upwork.com/jobs/~015aa8cecd7682d626
Upwork Job ID:<PHONE_NUMBER>510532413
Last Price Increase: 2024-06-10

Proposal
Please re-state the problem that we are trying to solve in this issue.
Web - Profile - Notify me about new messages disappears from profile page
What is the root cause of that problem?
In the profile page, we only show the notify me menu item based mainly on the user's report.notificationPreference is CONST.REPORT.NOTIFICATION_PREFERENCE.HIDDEN
https://github.com/Expensify/App/blob/4fcc5a9fbef90114ab4f38a1be698c471e3e75d1/src/pages/ProfilePage.tsx#L153-L155
Hence, if the user is new and the personal details get synced from the backend, the notfiy me menu item disappears because the user has never chatted with him.
https://github.com/Expensify/App/blob/4fcc5a9fbef90114ab4f38a1be698c471e3e75d1/src/pages/ProfilePage.tsx#L259-L266
What changes do you think we should make in order to solve the problem?

Therefore, let's remove the condition report.notificationPreference !== CONST.REPORT.NOTIFICATION_PREFERENCE.HIDDEN to make the shouldShowNotificationPreference boolean is true even if the user's report.notificationPreference is  CONST.REPORT.NOTIFICATION_PREFERENCE.HIDDEN
So something like below should work.
const shouldShowNotificationPreference = !isEmptyObject(report) && !isCurrentUser && !!report.notificationPreference;

This looks ok to me. I've added the project and the External label

Thanks for your proposals
@Tony-MK Your change may break other places because we need to hide Notify me about new messages option if notificationPreference is "hidden"
@dominictb Your proposal looks promising if we want to hide Notify me about new messages option for new users.
Note that: this problem happens with all new users while creating a new chat (not only the expensifail account) because we have an inconsistency between BE and FE about the notificationPreference for  the new chat

if we don't send any message in this report. It's the same behavior with iou report or transaction thread report.

Ah, It makes sense to me

Let's go with @dominictb's proposal as explained here
🎀👀🎀 C+ reviewed

While reviewing PR, I see that we don't always want to hide the notificationPreference of the report. It depends on which report.

If the user doesn't exist on the Expensify, the BE return notificationPreference: hidden
If the user exists on the EPSF but the current user has never chatted with them before, the BE returns notificationPreference: always

@dominictb Could you help to confirm that?

@cead22 It is a bit tough if we want to mimic the notificationPreference like the back-end in the optimisticData because in the front-end we can't verify whether the user exists on Expensify or not. Which option should we set for notificationPreference in the optimisticData when creating a new chat?

@JmillsExpensify @luacmartins is that the expected behavior, and if so, do you have a suggestion for solving this? Perhaps we pick one of the options to show as the default, show the option disabled at first until we get the value from the server, and then update the control and enable it

I don't think we'd always want to set the notification preferences to hidden. It seems like that makes sense if the user doesn't exist, but not otherwise. I'd imagine we could hide that preferences menu until we get a response from the backend?

@luacmartins Should we also hide that preferences menu in group chat until we get a response from the backend?

If we're seeing the same behavior there, I think we should.

BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
[@DylanDylann] The PR that introduced the bug has been identified. Link to the PR: NA
[@DylanDylann] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment: NA
[@DylanDylann] A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion: NA
[@DylanDylann] Determine if we should create a regression test for this bug. Yes
[@DylanDylann] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
Regression Test Proposal

Start a new chat/a new group chat
Click on the header of the newly created chat
Verify that the notify me about new messages option should not appear

Do we agree 👍 or 👎

I'd take this a couple of steps further

Start a new chat/a new group chat
Click on the header of the newly created chat
Verify that the notify me about new messages option should not appear
Close the settings pane
Send a mesage
Click on the header of the created chat
Verify that the notify me about new messages option appears

@VictoriaExpensify all yours

This isn't overdue, just waiting for payment

Contributor: @dominictb  paid $250 via Upwork
Contributor+: @DylanDylann due $250 via Upwork

Upwork Job Link Here

Contributor: @dominictb  paid $250 via Upwork
Contributor+: @DylanDylann  due $250 via NewDot
Upwork job here

@dominictb and @DylanDylann have been paid, the contract has been completed, and the Upwork post has been closed.


Snackbar immediately appear if open is initially true

When I mount a new layout, I may have a pending message to show (saved in the browser's cache, from a previous operation) inside a Snackbar component. However, if I initially show that message (create the component with open={ true }), the component will not be animated, but will instead immediately appear on screen. When using a transition from one layout to another, this behavior looks weird and broken.
Expected Behavior
When creating and mounting a new SnakBack component with it's property open set to true, I expect the component to smoothly appear, as if it was updated with the same property value.
Current Behavior
The component immediately appear without any transition, breaking the UX with this unexpected behavior.
Environment

Tech
Version

Material-UI
0.19.4

React
16.0.0

browser
Google Chrome 62.0.3202

Note: When trying the sandbox, Material UI v1-beta does not seem to be affected by this, but I cannot upgrade Material UI for this project, and especially not because of this.

We have the appear property on the v1-beta branch but nothing on the master branch. If you find a solution, feel free to submit a pull request.

Anybody find a workaround outside of v1-beta?


Actually retry LinkSetUp

Please sign your commits following these rules:
https://github.com/docker/docker/blob/master/CONTRIBUTING.md#sign-your-work
The easiest way to do this is to amend the last commit:
$ git clone -b "retry" git@github.com:polachok/libnetwork.git somewhere
$ cd somewhere
$ git commit --amend -s --no-edit
$ git push -f

Ammending updates the existing PR. You DO NOT need to open a new one.

Please sign your commits following these rules:
https://github.com/docker/docker/blob/master/CONTRIBUTING.md#sign-your-work
The easiest way to do this is to amend the last commit:
$ git clone -b "retry" git@github.com:polachok/libnetwork.git somewhere
$ cd somewhere
$ git commit --amend -s --no-edit
$ git push -f

Ammending updates the existing PR. You DO NOT need to open a new one.

LGTM


Laravel 7 support

Hey, I really love this package and I wish that you could add Laravel 7 support because I want to update my project laravel version..
Thank you

Hi @halah-m, thanks for checking out this package! :) Unfortunately we only support the current Laravel version. If you would like to use it with your older Laravel apps, please feel free to fork it and make any necessary adjustments. :)


Docs for Auto Complete is wrong

The Docs for Auto Complete state you should use the SweetPad: Create Build Server Config but this is not available and from what I can it's the SweetPad: Generate Build Server Config:
https://sweetpad.hyzyla.dev/docs/autocomplete/#installation

Thank! 💜


doc/man3/SSL_set_fd.pod: add note about Windows compiler warning

According to an old stackoverflow thread [1], citing an even older comment by
Andy Polyakov (1875e6db29, Pull up Win64 support from 0.9.8., 2005-07-05),
a cast of 'SOCKET' (UINT_PTR) to 'int' does not create a problem, because although
the documentation [2] claims that the upper limit is INVALID_SOCKET-1 (2^64 - 2),
in practice the socket() implementation on Windows returns an index into the kernel
handle table, the size of which is limited to 2^24 [3].
Add this note to the manual page to avoid unnecessary roundtrips to StackOverflow.
[1] https://stackoverflow.com/questions/1953639/is-it-safe-to-cast-socket-to-int-under-win64
[2] https://docs.microsoft.com/en-us/windows/win32/winsock/socket-data-type-2
[3] https://docs.microsoft.com/en-us/windows/win32/sysinfo/kernel-objects
This patch applies cleanly to 3.0 and 1.1.1 as well, so I will cherry-pick it if there are no objections.

Checklist

[x] documentation is added or updated
[ ] tests are added or updated

This pull request is ready to merge

Merged, thank you!
c23abef43e  doc/man3/SSL_set_fd.pod: add note about Windows compiler warning (1.1.1)
d31e951aa4 doc/man3/SSL_set_fd.pod: add note about Windows compiler warning (3.0)
f8dd5869bc doc/man3/SSL_set_fd.pod: add note about Windows compiler warning (master)


fix: match and update maxRevision entries with decoded keys

What does this PR do?
Allows entries in maxRevision.json to be matched and updated by comparing decoded keys.  For example, an entry in maxRevision.json with a key of Layout__Broker__c-v1.1 Broker Layout will match on getSourceMember('Layout__Broker__c-v1%2E1 Broker Layout').  It will also update the existing entry when setMemberRevision('Layout__Broker__c-v1%2E1 Broker Layout', {...changes}) is called.
Also, the populateFilePaths function will match remote changes with local metadata files using decoded metadata fullNames.
This allows (e.g.) sf project retrieve preview to report the correct status, and sf project retrieve start (i.e. "a pull") to update local metadata files correctly.
What issues does this PR fix or reference?
@W-11658886@
https://github.com/forcedotcom/cli/issues/1683
NOTE: for testing, SDR PR 1070 is required as well.

QA notes:
using linked SDR into STL, then SDR and STL linked in PDR (because Steve used plugin-source)
deploy
✅ no changes seen by retrieve preview
original use case
add the title field to the Broker 1.1 layout and save
❌ project retrieve preview does not recognize that the file matches existing source
Will Retrieve [1] files.
 Type   Fullname                       Path
 ────── ────────────────────────────── ─────────────────────────────────────────────────────────────────────────────────
 Layout Broker__c-v1%2E1 Broker Layout src/force-app/main/default/layouts/Broker__c-v1%2E1 Broker Layout.layout-meta.xml
 Layout Broker__c-v1.1 Broker Layout

for reference, without these PRs, the result is still wrong but in a different way
Will Retrieve [1] files.
 Type   Fullname                     Path
 ────── ──────────────────────────── ────
 Layout Broker__c-v1.1 Broker Layout

✅ 🏆  retrieve updates the existing file.
lets try to break it
create new layout for Broker__c named 1.1 año día
project:retrieve:preview
✅ sees Layout Broker__c-1.1 año día ( no path)
modify layout
❌ retrieve preview shows both files. The non-encoded one has no path (like the first one above)
✅ retrieve start updates the correct file
add a new, empty default pkgDir named src/unpackaged2
✅ modified existing layout and doesn't create a new one
Profiles also use encoding
create Shane's new & fancy profile!
✅  preview correctly shows it ignored
Ignored [2] files. These files won't retrieve because they're ignored by your .forceignore file.
 Type    Fullname                     Path
 ─────── ──────────────────────────── ────
 Profile Admin
 Profile Shane's new & fancy profile!

remove profile from forceignore
retrieve start results
| Created Shane%27s new %26 fancy profile%21 Profile src/unpackaged2/main/default/profiles/Shane%27s new %26 fancy profile%21.profile-meta.xml

preview
❌ keeps showing up in preview
Will Retrieve [1] files.
 Type    Fullname                     Path
 ─────── ──────────────────────────── ────
 Profile Shane's new & fancy profile!

create "path": "src/unpackaged3" and make it the default pkgDir.
edit Profile description
❌ retrieves into src/unpackaged3

using latest SDR linked into STL, then STL linked into PDR.
org create
../../plugin-deploy-retrieve/bin/dev project:deploy:start
../../plugin-deploy-retrieve/bin/dev project:retrieve:preview
✅ sees no changes except ignored Profile
add Title field to v1.1 Broker Layout
❌  ../../plugin-deploy-retrieve/bin/dev project:retrieve:preview
Will Retrieve [2] files.
 Type   Fullname                       Path
 ────── ────────────────────────────── ─────────────────────────────────────────────────────────────────────────────────
 Layout Broker__c-v1%2E1 Broker Layout src/force-app/main/default/layouts/Broker__c-v1%2E1 Broker Layout.layout-meta.xml
 Layout Broker__c-v1.1 Broker Layout

QA:
org create
../../plugin-deploy-retrieve/bin/dev project:deploy:start
../../plugin-deploy-retrieve/bin/dev project:retrieve:preview
✅ sees no changes except ignored Profile
add Title field to v1.1 Broker Layout
../../plugin-deploy-retrieve/bin/dev project:retrieve:preview
✅ sees only the layout, knows that it matches existing source
../../plugin-deploy-retrieve/bin/dev project:retrieve:start
✅  successfully retrieves into matching dir
../../plugin-deploy-retrieve/bin/dev project:retrieve:preview
✅ sees no changes
make a local and remote change to create a Conflict
✅  deploy:preview shows conflict
✅  retrieve:preview shows conflict
✅ deploys with --ignore-conflicts
✅  deploy:preview shows no changes
✅  retrieve:preview shows only expected ignored Profile
✅✅✅✅✅✅ works with retrieving conflicts, too.

QA: Profiles
create Shane's new & fancy profile!
remove profiles from forceignore
✅  retrieve:start creates 2 profiles, including src/unpackaged/main/default/profiles/Shane%27s new %26 fancy profile%21.profile-meta.xml
modify Profile description in the org ✅ path matches local
✅ retrieve:start modifies profile locally (also created ProfileSessionSetting and ProfilePasswordPolicy)
modify description locally
deploy:preview
❌ shows as a Conflict
deploy:start --ignore-conflicts
✅ deploys and doesn't create a duplicate profile
✅ deploy preview shows no changes after deploy


New version ExtremeStats: 0.2.1

Registering: ExtremeStats
Repository: https://github.com/juliohm/ExtremeStats.jl
Version: v0.2.1
Commit: d14d13e9f65ab82dfc1c30e498b1221291db5c7a
Proposed by: @juliohm
Reviewed by: @juliohm
Reference: https://github.com/juliohm/ExtremeStats.jl/commit/d14d13e9f65ab82dfc1c30e498b1221291db5c7a#commitcomment-33412227

https://github.com/JuliaRegistries/General/pull/535#issuecomment-489368671


Other misc stuff

While working through the translation comments for #64, I noticed some other, small things not really worthy for a PR of their own xD
So, I bundled them together here as a suggestion.
Should you not want a thing in here, I can easily revert that one commit - that's why I made many small commits instead of just one or two.
I noticed that the GtkGrid in the Save Preset button (preset-popover) has a spacing of 0 between the text and the plus sign. Since all other comparable buttons have a spacing of 6, I changed this one.
I think it would be more sensible to name the Preview menu where you can test the appearance settings "Live Preview Menu" instead of only "Preview menu". This, together with the explanation I provided in my next commit, emphasizes that you can test out the settings in real time.
As the preset-popover is used to load and save a preset, I edited its label accordingly.
I think that "Global Scaling" is a better word there, what do you think? The other string change I made is to look at the German translation and change "Easing" to "Animation", which is IMO the more suitable word here. Or am I wrong? Didn't change "Easing" anywhere else in the code though - only the string displayed in the UI!
Once again, I don't mind if you reject all of these changes - think about it :)

Good suggestions! You're the translation expert: Do you think we should add --no-location to our call of xgettext? Else will will always run into severe merge conflicts...

Oof, that's a tough decision. On the one hand, it causes quite some trouble when merging branches, but on the other hand it's quite useful when you want to see where a particular string comes from (which helped me a lot in #64, you can imagine).
Maybe we could introduce a flag to update-locales.sh? (I love flags, did I ever mention that? I'll put flags everywhere in your project, watch out! xD)
When executed w/o flag, no line numbers are put in the file. This is the standard mode for translation. For work like I did (checking if strings need commenting etc), you can set the flag and generate a pot just to have all translatable strings with pointers to where they come from.
What do you think? Shall we go one step further into flag hell :joy::smiling_imp:

In the meantime, I'll merge develop into this branch

What just came to my mind:
pot and po files are generated from other files, by executing a command (a shell script in our case). Unlike mo files, we do need to keep them in the source tree, but I think we can completely ignore merge conflicts like this one here. What I did right now:

Try to merge develop into feature-branch → Merge conflict, conflicting files are all po and pot.
Accept all changes from one side (develop in my case).
Run update-locales.sh to re-generate flypie.pot and the .po files accordingly. This should meld all changes from feature-branch and develop into valid files, if I'm not wrong.
The feature-branch is ready for merging!

I've just done that and from what I can see, no file seems damaged.
Have I thought this through? Do you see any caveats here?

I think you missed the case in which both branches have new translations for different things. E.g. a new feature got introduced and translated in develop and you implemented another feature in another branch and already translated it. In this case just taking one of the *.mo files would be wrong. The *.pot file on the other hand is completely auto-generated, so here it would be OK to just regenerate is after the merge.
Maybe the best approach would be not to mess with the translations when implementing new features as this will lead to conflicts when features are implemented in parallel. Then we will have rather short-living branches which are dedicated for updating or adding a translation. This way we will never update the same translation in parallel.
We could also consider remove the po/flypie.pot from the source tree as it can be auto-generated anyways. This would eliminate the conflict potential when different languages are updated in parallel.
What do you think?

I think you missed the case in which both branches have new translations for different things.

Good catch! Yeah, this is a possible source of problems.
So, basically:

Add new features to develop, DO NOT touch po or pot whatsoever (apart from checking if translator comments are handled correctly, but then don't commit the file)
When you want to release a new version, you branch develop off to translation (name it whatever you want :wink:). While, theoretically, new features can still be merged into this branch, no new strings should be added (aka String Freeze).
Commit the result of update-locales.sh to translation
Notify translators to get work done
Merge translation into master and upload the translated release.
Merge master into develop to get the updated translations in the development version.

Illustration (the branch is called release here):

Am I getting this right?

We could also consider removing the po/flypie.pot from the source tree as it can be auto-generated anyways.

When I understood your workflow suggestion above correctly, we could as well keep it and only update it on translation. This makes it easy and accessible to new translators who want to start a completely new language.
What do you think?

I'll revert the last commit so that this PR can be merged. We continue the discussion in an issue.

Thank you!


OffscreenCanvas support in Safari 16.4 is partial

OffscreenCanvas support is listed as "yes" (implying full support) for Safari 16.4: https://caniuse.com/offscreencanvas
However Safari 16.4 only ships support for the "2d" context. There is no support for WebGL, as other browsers support. Therefore its status should be changed to "Partial" and a note added explaining this.

Has now been fixed (WebGL support is coming in Safari 17 FYI)


Roll Flutter Engine from 8d51b64e9440 to 16a25b1acaf6 (10 revisions)

https://github.com/flutter/engine/compare/8d51b64e9440...16a25b1acaf6
2023-10-19<EMAIL_ADDRESS>Roll Dart SDK from eb3fb9a13e16 to 1b425a25a6dd (1 revision) (flutter/engine#47092)
2023-10-19<EMAIL_ADDRESS>Roll Skia from 85971b25cf4b to 64c5de6663a4 (2 revisions) (flutter/engine#47091)
2023-10-19<EMAIL_ADDRESS>Roll Fuchsia Mac SDK from PxJM5ivbnbYoVkqBg... to 0hLSNJ_DCTzRvTVJe... (flutter/engine#47090)
2023-10-19<EMAIL_ADDRESS>Roll Dart SDK from d9b1e60fe442 to eb3fb9a13e16 (1 revision) (flutter/engine#47084)
2023-10-18<EMAIL_ADDRESS>Update buildroot to ab76ccba2ca4ce4. (flutter/engine#47078)
2023-10-18<EMAIL_ADDRESS>migrate const_finder to use the implementation from package:kernel (flutter/engine#47077)
2023-10-18<EMAIL_ADDRESS>Roll Skia from d561b276b5d9 to 85971b25cf4b (1 revision) (flutter/engine#47076)
2023-10-18<EMAIL_ADDRESS>[Impeller] Guard execution of ReactorGLES operations with a mutex (flutter/engine#47068)
2023-10-18<EMAIL_ADDRESS>[Impeller] Document ReactorGLES. (flutter/engine#47070)
2023-10-18<EMAIL_ADDRESS>[web] Ensure handled key event is not propagated to IME (flutter/engine#46829)
Also rolling transitive DEPS:
fuchsia/sdk/core/mac-amd64 from PxJM5ivbnbYo to 0hLSNJ_DCTzR
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-engine-flutter-autoroll
Please CC jimgraham@google.com,rmistry<EMAIL_ADDRESS>on the revert to ensure that a human
is aware of the problem.
To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose
To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622
Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Commit queue failed; closing this roll.


Bug when training "translate_enzh_wmt8k"

It seems that there's a filename error
tensorflow.python.framework.errors_impl.NotFoundError: /tmp/t2t_datagen/dev/newsdev2017-zhen-src.en.sgm; No such file or directory

Sorry for the delay. Merged.


fix IOError: cannot open resource

Font generator paths were incorrect

Closing this as there are other issues with font tool that need addressing, see pull request #5


Use lists instead of hashsets for injectable caching

Contributions: We are not currently taking public contributions - see our contributions policy. However, we are accepting issues and we do want your feedback.

Description
Removal of some nasty array magic from the hot loop
Tests
Tested with local deployment, monobehaviour examples and world commands still work
Documentation
Very internal
Primary reviewers
If your change will take a long time to review, you can name at most two primary reviewers who are ultimately responsible for reviewing this request. @ mention them.
@samiwh @zeroZshadow

Can confirm no duplicates.

I assume this was held for the milestone feature freeze, could it be resumed now?

I think so, cc @callumlawson (for when he's back from vacation)

@callumlawson thoughts?

What is happening with this? @firtina-improbable @callumlawson

I'll rebase it

Rebased.

confirming world commands and other monobehaviour bits still work


User should be able to sign up to use the web app

Sign up collects following details from the user:

Name
Phone number
Date of Birth of the user

Authentication enforces uniqueness of phone number + date of birth on the backend.
Ref: #1
Returns a token (cookie or otherwise) stored locally on the device.

@agneym I can pick this up.

Please find the PR for this issue link: https://github.com/coronasafe/journal/pull/17
It includes the basic design for the signup and OTP page
@midhunkrishna @agneym

@midhunkrishna Do check if you are able to use UI from the same.


Update Readme.md

Need to update main readme.

New image examples
Add instructions for functionality such as whitelisting

Yep

I've actually opened this issue as a TODO for myself.
But if you want to do it go right ahead. Thanks!

Can you remove the code from Readme?
My pc keeps getting stuck before copying the following code. If you can not include it in the main page of readme file As my microsoft edge gets stuck because of the long code.

MMm so strange, what specs has your pc?

Can you remove the code from Readme? My pc keeps getting stuck before copying the following code. If you can not include it in the main page of readme file As my microsoft edge gets stuck because of the long code.

MMm so strange, what specs has your pc?

bad i5 + 16GB ram (Just upgraded from 8GB).On 24 Mar 2023, at 20:33, David Arroyo @.***> wrote:
Can you remove the code from Readme? My pc keeps getting stuck before copying the following code. If you can not include it in the main page of readme file As my microsoft edge gets stuck because of the long code.
MMm so strange, what specs has your pc?
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: @.***>

That is very strange.
The code has gotten somewhat larger recently due to a change in the infrastructure and the addition of substantial new features, which in-turn causes the main page in the repo (displaying the readme) to takes a bit longer to load, but I find it weird that it would have that much of an effect on a fully-fledged PC to the point of freezing it, especially one with the specs you've described.

I can send you a video documenting that.
On Sat, Mar 25, 2023 at 3:24 AM Tom Lebeodkin @.***>
wrote:

That is very strange.
The code has gotten somewhat larger recently due to a change in the
infrastructure and the addition of substantial new features, which in-turn
causes the main page in the repo (displaying the readme) to takes a bit
longer to load, but I find it weird that it would have that much of an
effect on a fully-fledged PC to the point of freezing it, especially one
with the specs you've described.
—
Reply to this email directly, view it on GitHub
https://github.com/davidarroyo1234/InstagramUnfollowers/issues/73#issuecomment-1483629258,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/A4MXGIZ77MMLARMQQX6G5RTW5Y3K3ANCNFSM6AAAAAAWAMITFA
.
You are receiving this because you commented.Message ID:
@.***>

Exactly, The old code did not freeze my browser.
On Sat, Mar 25, 2023 at 12:39 PM Yazan Zaid @.***> wrote:

I can send you a video documenting that.
On Sat, Mar 25, 2023 at 3:24 AM Tom Lebeodkin @.***>
wrote:

That is very strange.
The code has gotten somewhat larger recently due to a change in the
infrastructure and the addition of substantial new features, which in-turn
causes the main page in the repo (displaying the readme) to takes a bit
longer to load, but I find it weird that it would have that much of an
effect on a fully-fledged PC to the point of freezing it, especially one
with the specs you've described.
—
Reply to this email directly, view it on GitHub
https://github.com/davidarroyo1234/InstagramUnfollowers/issues/73#issuecomment-1483629258,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/A4MXGIZ77MMLARMQQX6G5RTW5Y3K3ANCNFSM6AAAAAAWAMITFA
.
You are receiving this because you commented.Message ID:
@.***>

Well, as mentioned, introducing new features unfortunately comes with the downside of a slower load time for the file, as more code is being added with every improvement.
If we keep adding more stuff then eventually we will inevitably run into a problem with this, unless we come up with a different way of presenting the script (a browser extension for example).
I think that a significant improvement could be getting rid of the SVGs that were added in one of the recent updates, as though they look nice, they likely add a bunch of code.
I'll check how much it actually reduces and if it's significant I'll probably remove them.
For now, you are more then welcome to use any of the previous version.
For example - https://github.com/davidarroyo1234/InstagramUnfollowers/tree/9aa62a04190f38cf7063606eda2365a68c382ea3


Cronvoy: support pinned Certificates

The Cronet API supports the pinning of certificates: CronetEngine.Builder.addPublicKeyPins
        /**
         *

         * Pins a set of public keys for a given host. By pinning a set of public keys,
         * {@code pinsSha256}, communication with {@code hostName} is required to
         * authenticate with a certificate with a public key from the set of pinned ones.
         * An app can pin the public key of the root certificate, any of the intermediate
         * certificates or the end-entry certificate. Authentication will fail and secure
         * communication will not be established if none of the public keys is present in the
         * host's certificate chain, even if the host attempts to authenticate with a
         * certificate allowed by the device's trusted store of certificates.
         *

         *

         * Calling this method multiple times with the same host name overrides the previously
         * set pins for the host.
         *

         *

         * More information about the public key pinning can be found in
         * RFC 7469.
         *

         *
         * @param hostName name of the host to which the public keys should be pinned. A host that
         *                 consists only of digits and the dot character is treated as invalid.
         * @param pinsSha256 a set of pins. Each pin is the SHA-256 cryptographic
         *                   hash of the DER-encoded ASN.1 representation of the Subject Public
         *                   Key Info (SPKI) of the host's X.509 certificate. Use
         *                   {@link java.security.cert.Certificate#getPublicKey()
         *                   Certificate.getPublicKey()} and
         *                   {@link java.security.Key#getEncoded() Key.getEncoded()}
         *                   to obtain DER-encoded ASN.1 representation of the SPKI.
         *                   Although, the method does not mandate the presence of the backup pin
         *                   that can be used if the control of the primary private key has been
         *                   lost, it is highly recommended to supply one.
         * @param includeSubdomains indicates whether the pinning policy should be applied to
         *                          subdomains of {@code hostName}.
         * @param expirationDate specifies the expiration date for the pins.
         * @return the builder to facilitate chaining.
         * @throws NullPointerException if any of the input parameters are {@code null}.
         * @throws IllegalArgumentException if the given host name is invalid or {@code pinsSha256}
         *                                  contains a byte array that does not represent a valid
         *                                  SHA-256 hash.
         */
        public Builder addPublicKeyPins(String hostName, Set<byte[]> pinsSha256,
                boolean includeSubdomains, Date expirationDate)

Even though this feature is discouraged, not honoring it would presumably break some App Developers.

The good news here is that Envoy already has support for certificate pinning. All that should really be needed to support this is plumbing.


blackgreen: Watch https://hapivpn.page.link

blackgreen requests the watch of the watch_keyword https://hapivpn\.page\.link. See the MS search here and the Stack Exchange search in text, in URLs, and in code.

https://hapivpn\.page\.link has been seen in 0 true positives, 0 false positives, and 0 NAAs.

Rejected by Jeff Schaller in Charcoal HQ. Reason: 'watches should not include the leading http/https'


Added Tajik language

Q
A

Bug fix?
no

New feature?
yes, added Tajik language

BC breaks?
no

Related tickets
no

License
MIT

Thanks @bakhtiyor!


Minor typo fix in bash completion template

Currently, the bash completion generated looks like:
_mycomm_completionetup;

^^ Missing the "s" in setup due to the Python template using the one "s" present.

@davidism completion func now matches zsh per our conversation.


[Circle CI] - Build Failed, but badge shows pass

New Issue Checklist

[x] Updated fastlane to the latest version
[x] I have read the Contribution Guidelines

Issue Description
Pulled down latest code from Github
Executed bundle exec rake test_all
Results
Finished in 98.003 seconds
2211 examples, 1 failure(s)
==========================================
| 1 repo(s) with test failures: snapshot |

Snapshot Snapshot::TestCommandGenerator Valid Configuration default options uses the default parameters on tvOS too
Failure/Error: Snapshot.config = FastlaneCore::Configuration.create(Snapshot::Options.available_options, options)
Device 'Apple TV 1080p' not in list of available simulators 'iPhone 6, iPhone 6s Plus'# snapshot/spec/test_command_generator_spec.rb:11:in `configure'

Failed examples:
snapshot/spec/test_command_generator_spec.rb:37 # Snapshot Snapshot::TestCommandGenerator Valid Configuration default options uses the default parameters on tvOS too

You didn't share all the information that's required by the issue template. Also please share your .circle.yml

You're right, and I now seeing it pass :)

@maschall So glad you got up and running! Always feel free to reach out or contribute. Have a great week 👍


[GHSA-4wrr-9h5r-m92w] Apache Struts Remote Java Code Execution

Updates

Affected products
References
Source code location

Comments
Add source code link and some patch links related to CVE-2012-0391.

Hi @sunSUNQ, only https://github.com/apache/struts/commit/5f54b8d087f5125d96838aafa5f64c2190e6885b and https://github.com/apache/struts/commit/b4265d369dc29d57a9f2846a85b26598e83f3892 appear to be related to CVE-2012-0391, so those are the reference links that we added. Thank you for your contribution!

你好，你发的邮件我已经收到拉~~~


⚠ GitHub has degraded performance

In e42b5c2, GitHub (https://www.githubstatus.com/api/v2/status.json) experienced degraded performance:

HTTP code: 200
Response time: 151 ms

Resolved: GitHub performance has improved in 001f6be.


detect when user has completely losing position and subtract frozen f…

…unds of that position

when market is finalized and user has complete losing positions don't include frozen funds in display value in UI.
added console logs for payment in dai and eth for debugging purposes.
fixed flash script creating orders for scalar markets, bid and ask was backwards.

change made, thx 👍


Massiv-based version

Alexey Kuleshevich published promisimg benchmarks of his Massiv library recently. This may be a good option to base on, maybe?

No evidence that this would be beneficial (yet).


--build-arg causes failed builds in Azure Container Registry

I have been trying to use --build-arg to inject Git hashes and build dates like I do in local builds, but whenever I try to use it it inevitably gives me an error in the build agent:
An image does not exist locally with the tag: acmedockerimages.azurecr.io/youtube-dl
"docker build" requires exactly 1 argument.
See 'docker build --help'.

Usage:  docker build [OPTIONS] PATH | URL | -

Build an image from a Dockerfile

Since the option is documented, I assume it works.

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: c608162e-cf40-9d53-da4a-51f51a0311ea
Version Independent ID: eccbb543-be68-7de2-d41d-abee55c81452
Content: az acr
Content Source: src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/_help.py
Service: container-registry
GitHub Login: @rloutlaw
Microsoft Alias: routlaw

I am also coming across this issue:
az acr build --registry $ACR_NAME --build-arg BUILD_DATE=date -u +"%Y-%m-%dT%H:%M:%SZ" --build-arg VCS_REF=git rev-parse --short HEAD --build-arg IMAGE_TAG_REF=v1 --image test/node-web:v1 .
complains with
"docker build" requires exactly 1 argument.
See 'docker build --help'.
Usage:  docker build [OPTIONS] PATH | URL | -

In general this issue is because of quotes. We interpret the command as if it were written directly to a shell. So if there's a space, or a special character like &, then the shell interprets that and decides how to split args. We have a related issue over at https://github.com/Azure/acr-builder/issues/329 for possibly escaping these to make it easier. In general though you can fix all of these by doing something like foo='bar qux &'

Since this is a shell quoting issue, there is nothing that can be done from the CLI side as the shell interprets the command line before it reaches the CLI. Closing.

I'll leave this to @ehotinger's discretion whether to take further action.

We have released the fix to address the following datetime string parsing issue.
BUILD_DATE=date -u +"%Y-%m-%dT%H:%M:%SZ"

I want to also say that I am having issues with --build-arg.
Doing: az acr build --registry some_registry --image some_image ./modules/SomeModule --secret-build-arg SSH_PRIVATE_KEY="$(cat ~/.ssh/id_rsa)" screws up the id_rsa in that somehow the \n new lines are being removed? (this eventually causes Invalid Format Errors)
I tested: docker build ./modules/SomeModule --build-arg SSH_PRIVATE_KEY="$(cat ~/.ssh/id_rsa)" and everything works. The id_rsa keeps its original formatting.
Why is there a difference? Is anyone able to add an rsa key to the module successfully using --build-args / --secrete-build-args?

For now, I’d suggest you encode such value with multiple lines or spaces to single line base64 string (eg, base64 -w 0) and pass to —build-arg or —set. On your Dockerfile file or build script, decoded it to the original value.

I'm having the same issue with the PIP_EXTRA_INDEX_URL environment variable filled by the PipAuthenticateV0 task, seems like it's adding a whitespace in the front, but when executing the failed generated command and running in local in my laptop it works. Issue with the shell? I'm using bash in Ubuntu...

I'm facing the same problem while passing ssh private key as a build argument.
Any solution or workaround to solve it ?

Tried doing encoding / decoding base64 and still had formatting issues. The \n kept getting ignored. Opted to manually download rsa file and use that instead.

I tried building with docker build command and it ran successfully, so I re-tagged my docker image to acr registry name and then pushed it.
This could be the one of the workaround until acr build command supports complex value in build arg parameter.
What do you think about this approach ? @josiahls
How do you manage to solve ? @josiahlaivins

@amrit143 I think your way is about as good as mine. I did try docker build a while back and it succeeded. Best way might be avoiding acr build and just build docker, use build-args, then push to azure container registry. My solution for using acr was to have a script that downloads the rsa key as a file then have a dockerfile add that file.
So basically, your solution is likely the most elagant. Build via docker and pass the rsa key via build-args (or secret-build-args? idk), then push to acr.

I couldn't get --secret-build-arg or --build-arg to work when passing id_rsa content to the az acr build command (in bash or powershell). I ended up just copying the id_rsa file from within the Dockerfile.

I couldn't get --secret-build-arg or --build-arg to work when passing id_rsa content to the az acr build command (in bash or powershell). I ended up just copying the id_rsa file from within the Dockerfile.

I tried adding a URL with sas-token as build-arg. Couldn't make it work due to the ampersand whatsoever and ended up dropping the build arg... (did't want to use base64 encoding)

This is still an issue for me, any idea on what's going on with this issue?

I'm facing this issue trying to build a Docker instance using PipAuthenticate for serving `arguments: --build-arg 'INDEX_URL=$(PIP_EXTRA_INDEX_URL)'
My Docker@1 build command fails due to "docker build" requires exactly 1 argument. even if I quote the build-args.
I thought these built-in tasks was supposed to support the inputs offered. You clearly have a bug since so many have this issue. Try google around for --build-arg and pipelines, you will find the pattern.

I'm also hitting this and I think the only real solution is for you to fix your az acr build implementation so it packages up the arguments into a file that is then shipped to the server for execution so that any double quoting issues can be handled correctly on your side rather than allowing it to turn into an impossible to debug shell issue on the server side.  For example I have this powershell code:
$rc = az acr build --image snpe/quantizer:v1 --registry $registry_name --resource-group $resource_group `
  --secret-build-arg MODEL_STORAGE_CONNECTION_STRING=$Env:MODEL_STORAGE_CONNECTION_STRING `
  --build-arg SNPE_SDK=$snpe_sdk_url --build-arg SNPE_SDK_FILENAME=$snpe_sdk_filename --build-arg SNPE_ROOT=/home/chris/$snpe_root `
  --build-arg ANDROID_NDK=$android_ndk_url --build-arg ANDROID_NDK_FILENAME=$android_ndk_filename --build-arg ANDROID_NDK_ROOT=/home/chris/$android_ndk_root `
  --secret-build-arg GITHUB_PAT=$Env:GITHUB_PAT .

And I get this completely useless and totally bogus error message:
"docker build" requires exactly 1 argument.
See 'docker build --help'.
Usage:  docker build [OPTIONS] PATH | URL | -
Build an image from a Dockerfile
/bin/sh: 1: --build-arg: not found]

Has there been any progression with this issue? Currently experiencing the same problem.

Same problem here....any ETA to fix this issue?

Hi All! We have the same issue and use the following workaround:
Simply wrap with "' instead of just ' or "
I.e., --build-arg DEMO_PARAM_1="my-value" becomes --build-arg DEMO_PARAM_1="'my-value'"
When debugging this through the --debug param, we can see this being passed as intended. The reason this works is because I assume the shell expansion is being done correctly now.
@ehotinger I am not sure where the shell expansion happens and how it happens, but this seems to be a JSON -> Bash parsing issue rather than a developer problem. If the JSON doesn't get quoted correctly, it goes wrongly at your side. I would personally encode values BASE64 and then decode them on actual docker build reconstruction
{
  "type": "DockerBuildRequest",
  "isArchiveEnabled": false,
  "imageNames": [
    "my/demo/image:1"
  ],
  "isPushEnabled": true,
  "noCache": false,
  "dockerFilePath": "1394f4d81a514acbb3d5e8da7_Dockerfile",
  "arguments": [
    { "name": "DEMO_PARAM_1", "value": "'some_path.tar.gz'", "isSecret": false },
    { "name": "DEMO_PARAM_2", "value": "'My value that is with spaces'", "isSecret": false }
  ],
  "platform": { "os": "linux", "architecture": "amd64" },
  "sourceLocation": "source/masked/masked-cd07-4533-b96b-masked.tar.gz",
  "credentials": {}
}

I don't maintain this repository anymore (I haven't worked at Microsoft/Azure in 5 years!), but yes @XavierGeerinck that should work. The acr build command just gets whatever raw string you pass in and invokes a Linux or Windows shell with a quoted command from whatever string you pass in (you can check out the code at https://github.com/Azure/acr-builder/blob/main/builder/init_shell_linux.go#L7) for example. Wrapping in single quotes, base64 encoding, or escaping quotes in this pattern should all do the trick.

Hi All! We have the same issue and use the following workaround:
Simply wrap with "' instead of just ' or "
I.e., --build-arg DEMO_PARAM_1="my-value" becomes --build-arg DEMO_PARAM_1="'my-value'"
When debugging this through the --debug param, we can see this being passed as intended. The reason this works is because I assume the shell expansion is being done correctly now.
@ehotinger I am not sure where the shell expansion happens and how it happens, but this seems to be a JSON -> Bash parsing issue rather than a developer problem. If the JSON doesn't get quoted correctly, it goes wrongly at your side. I would personally encode values BASE64 and then decode them on actual docker build reconstruction
{
"type": "DockerBuildRequest",
"isArchiveEnabled": false,
"imageNames": [
"my/demo/image:1"
],
"isPushEnabled": true,
"noCache": false,
"dockerFilePath": "1394f4d81a514acbb3d5e8da7_Dockerfile",
"arguments": [
{ "name": "DEMO_PARAM_1", "value": "'some_path.tar.gz'", "isSecret": false },
{ "name": "DEMO_PARAM_2", "value": "'My value that is with spaces'", "isSecret": false }
],
"platform": { "os": "linux", "architecture": "amd64" },
"sourceLocation": "source/masked/masked-cd07-4533-b96b-masked.tar.gz",
"credentials": {}
}

Thank you for your solution. It works


PAN-OS Panorama support for most of the objects "Disable override" - introduce filter and actions

Is your feature request related to a problem?

missing feature to set "Disable override" e.g. for address / service objects
Describe the solution you'd like

bring in action to enable "Disable override" in config, via offline config and API mode
bring in filter to find objects where "Disable override" is enabled

Describe alternatives you've considered

Additional context

check if already implemented filter:

'filter=(object overriden.at.lower.level)'
'filter=(object overrides.upper.level)'

is bringing in this request


#1179: Switch to use core app.services()

As soon as these are in

[x] https://github.com/kalabox/kalabox-cli/pull/16
[x] https://github.com/kalabox/kalabox-app-php/pull/23
[x] https://github.com/kalabox/kalabox-app-pantheon/pull/127

I need a QA and merge on this @reynoldsalec

@reynoldsalec other relevant PRs have been merged in. You need to have HEAD of all the things to test this

Tested it out @pirog and merging.


documentation: must run as root

If you get permission denied when running this, note that it binds to a low port, and thus on most systems should run as root.
Eds-MacBook-Pro:~ ed$ go/bin/ssl-tester
2019/02/02 01:29:56 listen tcp :443: bind: permission denied
Eds-MacBook-Pro:~ ed$ sudo go/bin/ssl-tester
Password:
2019/02/02 01:30:10 open /etc/ssl-tester/fullchain.pem: no such file or directory

I could see a ssl-tester --port 10433 approach - define the port number at run time - that would allow you to test without clobbering an existing service on an existing port, or needing to necessarily be root.


Refresh-then-retry when get online features complains table not found

It's hard to check if the old revision exist or not in some online store, like redis.
switch to #597


Add RequestInterface::getPost to ensure correct code completion in IDE

Fixes #29

This is specific of HTTP requests.


bucket store initial sync: sync block: BaseFetcher: iter bucket: Server not initialized, please try again.

Store initial sync fails on temporary bucket error without retrying.
Bucket: S3.
Repro: I started minio and immediately then Thanos Store and it failed because minio was still starting (despite readiness probe being OK BTW :/ )

29:52 store1: level=info name=store1 ts=2021-07-27T22:29:52.276277542Z caller=http.go:93 service=http/server component=store msg="internal server is shutdown gracefully" err="bucket store initial sync: sync block: BaseFetcher: iter bucket: Server not initialized, please try again."
00:29:52 store1: level=info name=store1 ts=2021-07-27T22:29:52.276295762Z caller=intrumentation.go:66 msg="changing probe status" status=not-healthy reason="bucket store initial sync: sync block: BaseFetcher: iter bucket: Server not initialized, please try again."
00:29:52 store1: level=warn name=store1 ts=2021-07-27T22:29:52.276313798Z caller=intrumentation.go:54 msg="changing probe status" status=not-ready reason="bucket store initial sync: sync block: BaseFetcher: iter bucket: Server not initialized, please try again."
00:29:52 store1: level=info name=store1 ts=2021-07-27T22:29:52.276319904Z caller=grpc.go:130 service=gRPC/server component=store msg="internal server is shutting down" err="bucket store initial sync: sync block: BaseFetcher: iter bucket: Server not initialized, please try again."
00:29:52 store1: level=info name=store1 ts=2021-07-27T22:29:52.276331708Z caller=grpc.go:143 service=gRPC/server component=store msg="gracefully stopping internal server"
00:29:52 store1: level=info name=store1 ts=2021-07-27T22:29:52.276466526Z caller=grpc.go:156 service=gRPC/server component=store msg="internal server is shutdown gracefully" err="bucket store initial sync: sync block: BaseFetcher: iter bucket: Server not initialized, please try again."

^ should fix it I guess :thinking:

Not stale

FYI this is duplicated by https://github.com/thanos-io/thanos/issues/4810


Use batch_size as an init argument (default batch_size=128) to BoundaryAttack and HopSkipJump

Use batch_size as an __init__ argument (default batch_size=128) to BoundaryAttack and HopSkipJump
Signed-off-by: Apostolos Modas<EMAIL_ADDRESS>Description
This pull request improves the execution time of BoundaryAttack and HopSkipJump.
In their current implementation, both BoundaryAttack and HopSkipJump] have a hardcoded batch_size=1 in their code (L107 and L96 respectively). In fact, batch_size is used to inform the classifier how many samples to fit/forward simultaneously, and then return the predictions for all the samples within the batch.
However, the hardcoded value batch_size=1 is inefficient: whenever the attacks want to get the predictions of N samples, the classifier is feeding them one-by-one instead of feeding all N samples simultaneously. As a result, the whole forward process is quite slow, and the main benefit of parallelism in a GPU is technically lost!
I studied the code of both implementations to make sure that there is no specific reason (cases such as vectorization of the returned predictions etc.) for explicitly using batch_size=1. By experimenting only with PyTorch, it turned out that both algorithms should work as expected for any batch_size >= 1. I also believe that changing the backend (i.e., Tensorflow, Keras) will not change the behaviour (at least I do not see any reason why).
To demonstrate the benefit of setting batch_size > 1, I created a simple experiment where I deterministically evaluate both attacks (a) in their current state, and (b) with an increased batch_size. The code and results can be found in the Notebook embedded below (see Appendix).
In short, this pull request introduces the following changes:

The batch_size in both BoundaryAttack and HopSkipJump can now be passed as an argument to __init__.
The default value of batch_size in both BoundaryAttack and HopSkipJump is now: batch_size: int = 128.
The value self.batch_size is not hardcoded to 1 anymore: it gets the value through the __init__.

Fixes #970.
Type of change
Please check all relevant options.

[X] Improvement (non-breaking)
[ ] Bug fix (non-breaking)
[ ] New feature (non-breaking)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] This change requires a documentation update

Testing
Please describe the tests that you ran to verify your changes. Consider listing any relevant details of your test configuration.

[X] (PyTorch) Compare the the execution time of BoundaryAttack before and after increasing the batch_size. The test code and results can be found in Notebook embedded in the Appendix.
[X] (PyTorch) Compare the the execution time of HopSkipJump before and after increasing the batch_size. The test code and results can be found in Notebook embedded in the Appendix.

Test Configuration:

OS: Red Hat Enterprise Linux 8.3 (fedora)
Python version: 3.8.8
ART version or commit number: ART v1.5.3 and ART dev_1.6.1 (commit: ab26b12)
PyTorch v1.6.0+cu92
Note: this PyTorch version, including Torchvision v0.7.0+cu92, are not the ones automatically selected by ART v1.5.3 requirements. Nevertheless, they were chosen as such, in order to test the code changes on a Tesla K40 GPU. The overall behaviour is not expected change if tested with higher version of PyTorch and Torchvision.

Checklist

[X] My code follows the style guidelines of this project
[X] I have performed a self-review of my own code
[X] I have commented my code
[X] I have made corresponding changes to the documentation (docstring in file)
[X] My changes generate no new warnings
[X] I have added tests that prove my fix is effective or that my feature works
[ ] New and existing unit tests pass locally with my changes

Appendix – Notebook
Note: the experiments use PyTorch v1.6.0+cu92 and Torchvision v0.7.0+cu92 since they are conducted on a Tesla K40 GPU. The overall behaviour is not expected to change if tested with higher version of PyTorch and Torchvision.
global_seed = 999

import sys
import sys
!{sys.executable} -m pip install git+https://github.com/nottombrown/imagenet_stubs
sys.path.append('./adversarial-robustness-toolbox')

import imagenet_stubs
import numpy as np
import torch
import torch.nn as nn
import torchvision.models as models
import torchvision.transforms as transforms
import random
import time

import os
os.environ['PYTHONHASHSEED'] = str(global_seed)

from matplotlib import pyplot as plt
from PIL import Image

from art.estimators.classification import PyTorchClassifier
from art.attacks.evasion import BoundaryAttack, HopSkipJump

Collecting git+https://github.com/nottombrown/imagenet_stubs
  Cloning https://github.com/nottombrown/imagenet_stubs to /tmp/pip-req-build-fr1ufr_e
  Running command git clone -q https://github.com/nottombrown/imagenet_stubs /tmp/pip-req-build-fr1ufr_e

Set determinism for reproducibility
def set_global_seed(seed):
    torch.manual_seed(seed)
    torch.cuda.manual_seed(seed)
    torch.cuda.manual_seed_all(seed)
    np.random.seed(seed)
    random.seed(seed)
    torch.manual_seed(seed)
    torch.backends.cudnn.benchmark = False
    torch.backends.cudnn.deterministic = True

Load Torchvision model
model = models.resnet18(pretrained=True).eval()

mean = np.asarray((0.485, 0.456, 0.406), dtype=np.float32).reshape((1, 3, 1, 1))
std = np.asarray((0.229, 0.224, 0.225), dtype=np.float32).reshape((1, 3, 1, 1))

classifier = PyTorchClassifier(
    model=model,
    clip_values=(0.0, 1.0),
    input_shape=(3, 224, 224),
    nb_classes=1000,
    use_amp=False,
    preprocessing=(mean, std),
    channels_first=True,
    loss=nn.CrossEntropyLoss()
)

Define image transformation
def tf(x):
    x = np.expand_dims(x, axis=0)
    return np.transpose(x, (0, 3, 1, 2))

Load image
original_image_name = 'standard_poodle.jpg'
for image_path in imagenet_stubs.get_image_paths():
    if image_path.endswith(original_image_name):
        original_image = Image.open(image_path)
        original_image = original_image.resize((224, 224))
        original_image = np.array(original_image) / 255.0
        original_image = original_image.astype(np.float32)

original_label = np.argmax(classifier.predict(tf(original_image)), axis=1)[0]
print("\nOriginal label is: %d\n" % original_label)

plt.imshow(original_image)
plt.show()

Original label is: 267

BoundaryAttack parameters
max_iterations = 1000
delta = 0.01
epsilon = 0.01
targeted = False

BoundaryAttack (batch_size=1)
set_global_seed(global_seed)

batch_size = 1  # <--- Current implementation (hardcoded) batch size
attack = BoundaryAttack(estimator=classifier,
                        targeted=targeted,
                        max_iter=max_iterations,
                        delta=delta,
                        epsilon=epsilon,
                        verbose=False,
                        batch_size=batch_size,
                        seed=global_seed)

t0 = time.time()
x_adv = attack.generate(x=tf(original_image), x_adv_init=None)
print('Elapsed time (sec):', time.time() - t0)

L2_err = np.linalg.norm(x_adv[0] - tf(original_image)[0])
pred_label = np.argmax(classifier.predict(x_adv)[0])
print("L2 error: %.2f \t | \t Adv. label: %d" % (L2_err, pred_label))

Elapsed time (sec):<PHONE_NUMBER>7654114
L2 error: 31.02 	 | 	 Adv. label: 107

BoundaryAttack (batch_size=128)
set_global_seed(global_seed)

max_iterations = 1000
delta = 0.01
epsilon = 0.01
targeted = False

batch_size = 128  # <--- Increase batch size

attack = BoundaryAttack(estimator=classifier,
                        targeted=targeted,
                        max_iter=max_iterations,
                        delta=delta,
                        epsilon=epsilon,
                        verbose=False,
                        batch_size=batch_size,
                        seed=global_seed)

t0 = time.time()
x_adv = attack.generate(x=tf(original_image), x_adv_init=None)
print('Elapsed time (sec):', time.time() - t0)

L2_err = np.linalg.norm(x_adv[0] - tf(original_image)[0])
pred_label = np.argmax(classifier.predict(x_adv)[0])
print("L2 error: %.2f \t | \t Adv. label: %d" % (L2_err, pred_label))

Elapsed time (sec):<PHONE_NUMBER>55661
L2 error: 31.02 	 | 	 Adv. label: 107

HopSkipJump Attack parameters
max_iterations = 200
max_eval = 1000
init_eval = 10
targeted = False

HopSkipJump Attack (batch_size=1)
set_global_seed(global_seed)

batch_size = 1  # <--- Current implementation (hardcoded) batch size
attack = HopSkipJump(classifier=classifier,
                     targeted=targeted,
                     max_iter=max_iterations,
                     max_eval=max_eval,
                     init_eval=init_eval,
                     verbose=False,
                     batch_size=batch_size,
                     seed=global_seed)

t0 = time.time()
x_adv = attack.generate(x=tf(original_image), x_adv_init=None)
print('Elapsed time (sec):', time.time() - t0)

L2_err = np.linalg.norm(x_adv[0] - tf(original_image)[0])
pred_label = np.argmax(classifier.predict(x_adv)[0])
print("L2 error: %.2f \t | \t Adv. label: %d" % (L2_err, pred_label))

Elapsed time (sec):<PHONE_NUMBER>9638977
L2 error: 0.96 	 | 	 Adv. label: 183

HopSkipJump Attack (batch_size=128)
set_global_seed(global_seed)

batch_size = 128  # <--- Increase batch size
attack = HopSkipJump(classifier=classifier,
                     targeted=targeted,
                     max_iter=max_iterations,
                     max_eval=max_eval,
                     init_eval=init_eval,
                     verbose=False,
                     batch_size=batch_size,
                     seed=global_seed)

t0 = time.time()
x_adv = attack.generate(x=tf(original_image), x_adv_init=None)
print('Elapsed time (sec):', time.time() - t0)

L2_err = np.linalg.norm(x_adv[0] - tf(original_image)[0])
pred_label = np.argmax(classifier.predict(x_adv)[0])
print("L2 error: %.2f \t | \t Adv. label: %d" % (L2_err, pred_label))

Elapsed time (sec):<PHONE_NUMBER>2456665
L2 error: 0.97 	 | 	 Adv. label: 183

Codecov Report

Merging #971 (32f7deb) into dev_1.6.1 (ab26b12) will decrease coverage by 38.64%.
The diff coverage is 0.00%.

@@              Coverage Diff               @@
##           dev_1.6.1     #971       +/-   ##
==============================================
- Coverage      62.89%   24.25%   -38.65%
==============================================
  Files            219      219
  Lines          18874    18874
  Branches        3420     3420
==============================================
- Hits           11871     4577     -7294
- Misses          5693    13953     +8260
+ Partials        1310      344      -966

Impacted Files
Coverage Δ

art/attacks/evasion/boundary.py
13.87% <0.00%> (-63.01%)
:arrow_down:

art/attacks/evasion/hop_skip_jump.py
61.46% <ø> (-27.32%)
:arrow_down:

...rt/defences/detector/poison/clustering_analyzer.py
8.22% <0.00%> (-86.71%)
:arrow_down:

...ces/detector/evasion/subsetscanning/scanningops.py
11.59% <0.00%> (-85.51%)
:arrow_down:

art/attacks/evasion/carlini.py
8.40% <0.00%> (-80.87%)
:arrow_down:

...defences/detector/poison/ground_truth_evaluator.py
17.80% <0.00%> (-79.46%)
:arrow_down:

...ient_descent/projected_gradient_descent_pytorch.py
16.27% <0.00%> (-76.75%)
:arrow_down:

...escent/projected_gradient_descent_tensorflow_v2.py
17.60% <0.00%> (-75.20%)
:arrow_down:

art/metrics/verification_decisions_trees.py
13.75% <0.00%> (-73.02%)
:arrow_down:

art/attacks/evasion/adversarial_patch/utils.py
8.00% <0.00%> (-72.00%)
:arrow_down:

... and 130 more


KIP-597: MirrorMaker2 internal topics Formatters

This PR includes 3 MessageFormatters for MirrorMaker2 internal topics:

HeartbeatFormatter
CheckpointFormatter
OffsetSyncFormatter

This also introduces a new public interface org.apache.kafka.common.MessageFormatter that users can implement to build custom formatters.
Committer Checklist (excluded from commit message)

[ ] Verify design and implementation
[ ] Verify test coverage and CI build status
[ ] Verify documentation (including upgrade notes)

ok to test

@kkonstantine @omkreddy Can you take a look? Thanks

@kkonstantine I see you approved but did not merge. Was there any reason?

If it’s a committer’s PR I think the common practice is to leave the responsibility of merging to the author of the PR.
+1

ok to test

All failures were Streams, merging.

JDK 11 and Scala 2.13:
org.apache.kafka.streams.integration.EosBetaUpgradeIntegrationTest.shouldUpgradeFromEosAlphaToEosBeta[false]
org.apache.kafka.streams.integration.EosBetaUpgradeIntegrationTest.shouldUpgradeFromEosAlphaToEosBeta[true]
org.apache.kafka.streams.integration.EosBetaUpgradeIntegrationTest.shouldUpgradeFromEosAlphaToEosBeta[false]
org.apache.kafka.streams.integration.EosBetaUpgradeIntegrationTest.shouldUpgradeFromEosAlphaToEosBeta[true]

JDK 14 and Scala 2.13:
org.apache.kafka.streams.integration.EosBetaUpgradeIntegrationTest.shouldUpgradeFromEosAlphaToEosBeta[false]
org.apache.kafka.streams.integration.EosBetaUpgradeIntegrationTest.shouldUpgradeFromEosAlphaToEosBeta[true]

JDK 8 and Scala 2.12:
org.apache.kafka.streams.integration.EosBetaUpgradeIntegrationTest.shouldUpgradeFromEosAlphaToEosBeta[false]
org.apache.kafka.streams.integration.EosBetaUpgradeIntegrationTest.shouldUpgradeFromEosAlphaToEosBeta[false]
org.apache.kafka.streams.integration.EosBetaUpgradeIntegrationTest.shouldUpgradeFromEosAlphaToEosBeta[true]
org.apache.kafka.streams.integration.EosBetaUpgradeIntegrationTest.shouldUpgradeFromEosAlphaToEosBeta[true]


rust: cargo and buildRustCrate disagree on escaping of rustc-env directives (and probably more)

Describe the bug
At start of Rust crate build, developers can emit various directives in build.rs that then impact the rest of the build.
It seems that cargo handling of these directives differs from the buildRustCrate handling we have when the values contain spaces.
Steps To Reproduce
Create build.rs like below:
fn main() {
    println!("cargo:rustc-env=SHOULD_BE_THREE_WORDS=first second third")
}

Simple src/main.rs
fn main() {
    let should_be_three_words = env!("SHOULD_BE_THREE_WORDS");
    println!("Expecting three words, got: {}", should_be_three_words);
}

Cargo.toml for completeness
[package]
name = "nix-rustc-env-escape-repro"
version = "0.1.0"
edition = "2021"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]

Create a nix derivation for a create. I'm using crate2nix but you can use whatever, as long as it goes via buildRustCrate in the end.
$ crate2nix -- generate -f ./Cargo.toml

Finally, run both via cargo and via buildRustCrate and see the difference.
[nix-develop]$ $(nix-build -I nixpkgs=/home/shana/programming/nixpkgs Cargo.nix -A rootCrate.build  --no-out-link)/bin/nix-rustc-env-escape-repro
Expecting three words, got: first
[nix-develop]$ cargo run
    Finished dev [unoptimized + debuginfo] target(s) in 0.01s
     Running `target/debug/nix-rustc-env-escape-repro`
Expecting three words, got: first second third

Expected behavior
The nixpkgs builder should have the same semantics as the cargo one.
Notify maintainers

Unsure.
Metadata
nixpkgs 067c3ad6a7963b37d35a1a76b631ac34dc6e6fc7
anything else should be irrelevant here

It appears the issue is in this code in build-rust-crate/configure.nix:
     for env in $(sed -n "s/^cargo:rustc-env=\(.*\)/\1/p" target/build/${crateName}.opt); do
       export $env
     done

In our case, the .opt file still contains the full name and sed manages to extract it:
[shana@aya:~/programming/nixpkgs]$ sed -n "s/^cargo:rustc-env=\(.*\)/\1/p" /tmp/nix-build-rust_nix-rustc-env-escape-repro-0.1.0.drv-0/nix-rustc-env-escape-repro/target/build/nix-rustc-env-escape-repro.opt
SHOULD_BE_THREE_WORDS=first second third

but the export is not escaped at all: so it does export SHOULD_BE_THREE_WORDS=first second third which just exports SHOULD_BE_THREE_WORDS=first and the second and third bits are just ignored.
We can change it to export "$env" and it will work with spaces. I think there's no downside to it. I guess if someone wanted, they could craft a prank on nix users with this... I'll send a patch.

Ah, actually, I was not quite correct! It doesn't run export SHOULD_BE_THREE_WORDS=first second third; it runs
export SHOULD_BE_THREE_WORDS=first
export second
export third

I believe tools like shellcheck catch this very common mistake but all the inline bash isn't checked.


Allow it to pick up all http requests for each scenario

For instance if I did something like:
it 'A user can update their name' do
  put :update, {user: {name: 'michael'}}
  get :show, user
end

both requests should up. I guess this is a really dumb example and you should really be doing more than one request in a spec. (facepalm)


Fix failing test of docker rename

At the time the pull request:
Use spf13/cobra for docker rename #23290
was created, there was an issue in cobra so the test
DockerSuite.TestRenameInvalidName was updated.
Now the issue in cobra has been fixed in:
Use spf13/cobra for docker import #23269
so the test related to  docker rename
(DockerSuite.TestRenameInvalidName) needs to be reverted back.
This fix is related to spf13/cobra #23211.
Signed-off-by: Yong Tang<EMAIL_ADDRESS>

Ping @vdemeester @thaJeztah @dnephin.

Oh! just opened a PR for this; https://github.com/docker/docker/pull/23340, I'll close this one (sorry!)

@thaJeztah no problem. Thanks for taking care of the issue.


Rust wit_bindgen::generate! generates multiple definitions of the same type when importing with use and exporting the interface where the type is defined

Hi, thank you so much for your work!
When using the following wit (full code https://github.com/juancastillo0/wasm_interpreter/blob/ce48f2fe0a888f097df2af3c113ab40ebf9a00c0/packages/wit_component_example/wit/types-example.wit):
default interface types-interface {
  /// a bitflags type
  flags permissions {
    read,
    write,
    exec,
  }
  ...
}

default world types-example {
    use self.types-interface.{t2 as t2-renamed, t10, permissions}
    export types-export: self.types-interface
    ...
}

And generating the Rust code with wit_bindgen::generate!("types-example"); here https://github.com/juancastillo0/wasm_interpreter/blob/ce48f2fe0a888f097df2af3c113ab40ebf9a00c0/packages/wit_component_example/src/lib.rs
The macro gives the following error:
unused macro definition: `export_types_example`
`#[warn(unused_macros)]` on by defaultrustc[Click for full compiler diagnostic](rust-analyzer-diagnostics-view:/diagnostic%20message%20%5B1%5D?1#file%3A%2F%2F%2FUsers%2Fjuanmanuelcastillo%2FDesktop%2Fflutter%2Fwasmi_dart%2Fpackages%2Fwit_component_example%2Fsrc%2Flib.rs)
mismatched types
struct `types_export::Permissions` and struct `types_interface::Permissions` have similar names, but are actually distinct typesrustc[Click for full compiler diagnostic](rust-analyzer-diagnostics-view:/diagnostic%20message%20%5B2%5D?2#file%3A%2F%2F%2FUsers%2Fjuanmanuelcastillo%2FDesktop%2Fflutter%2Fwasmi_dart%2Fpackages%2Fwit_component_example%2Fsrc%2Flib.rs)
public.rs(17, 9): struct `types_export::Permissions` is defined in module `crate::types_export` of the current crate
public.rs(17, 9): struct `types_interface::Permissions` is defined in module `crate::types_interface` of the current crate
lib.rs(8, 1): the type constructed contains `types_export::Permissions` due to the type of the argument passed
option.rs(570, 5): tuple variant defined here
lib.rs(8, 1): parentheses are required to parse this as an expression: `(`, `)`

cargo expand prints the following:
https://github.com/juancastillo0/wasm_interpreter/blob/ce48f2fe0a888f097df2af3c113ab40ebf9a00c0/packages/wit_component_example/src/lib_expand.rs
Permissions is generated twice.
Thanks! Let me know if there is some way I can help

Thanks for the report! This should be fixed in https://github.com/bytecodealliance/wit-bindgen/pull/574.
Note that the duplicate export of Permissions is intentional here, but the problem was that they weren't wired up correctly.


Add type to store UUIDv1 in MySQL-optimized format

This PR attempts to bring feature request #14 to life.
Since nobody else had volunteered to expose a new codec for UUIDv1 via a Doctrine type, I decided to do so. A Hacktoberfest T-Shirt is not going to win it itself, and neither have I anything else interesting to check out a new supposedly awesome keyboard of mine.
Any feedback is appreciated!
I also expect a couple of questions to be asked, so I'll try to address them in advance.
— Why didn't you extend UuidBinaryType?
— Liskov Substitution Principle tells us that a subtype should always be able to replace a type it extends. In other words, an inheriting class' instance should be a drop-in replacement for an instance of its parent, which is not the case here as far as I can tell. Hence, extending UuidBinaryType would be a misuse of inheritance.
— Why did you cut off anything else that is not UUIDv1 (and doesn't reprecent one)?
— It doesn't make sence, does it? Appearing anything else other than UUIDv1 here is likely a result of a mistake; data corruption could accompany such a case. Having an exception is better than trying to do some elaborate insane stuff that messes with one's data, isn't it?
— There're @covers annotations in all other tests, why didn't you add them into yours?
— To be honest, I didn't find a compelling reason to do so and dropped them to increase signal-to-noise ratio and decrease possible maintetnance burden.

Coverage remained the same at 100.0% when pulling c5f50971e5d284c11664ad5dc738aeb436555b54 on kamazee:add_time_ordered_uuidv1 into 9504feb7bc505f09366f62075140ddcf851ab84d on ramsey:master.

Coverage remained the same at 100.0% when pulling c5f50971e5d284c11664ad5dc738aeb436555b54 on kamazee:add_time_ordered_uuidv1 into 9504feb7bc505f09366f62075140ddcf851ab84d on ramsey:master.

Coverage remained the same at 100.0% when pulling dcdb641bc909e585ec0cb57a594f81409c40921b on kamazee:add_time_ordered_uuidv1 into 9504feb7bc505f09366f62075140ddcf851ab84d on ramsey:master.

Coverage remained the same at 100.0% when pulling dcdb641bc909e585ec0cb57a594f81409c40921b on kamazee:add_time_ordered_uuidv1 into 9504feb7bc505f09366f62075140ddcf851ab84d on ramsey:master.

Coverage remained the same at 100.0% when pulling dcdb641bc909e585ec0cb57a594f81409c40921b on kamazee:add_time_ordered_uuidv1 into 9504feb7bc505f09366f62075140ddcf851ab84d on ramsey:master.

Yes. Sorry for the delay. In the middle of moving and will be able to focus on my OSS projects towards the end of next week. Thanks for your patience.

Sorry for the very lengthy delay. Merging this in!


Functional children of suspense never resolve

Describe the bug
If children of suspense is a function they never resolve. Here are some links with a weird fix for it that renders the child but not the fallback, and one where it fixes both. Also a link to the discord
Renders child but not the fallback:
https://playground.solidjs.com/anonymous/75137e0b-da75-46d0-8faa-08d8cff596a4
Renders both but required the children to be invoked
https://playground.solidjs.com/anonymous/76380071-8fb7-48af-898a-7037005658bf
More in depth playground example showing that wrapping the children of the Suspense with a wrapper fixes it, but then when the child falls into suspense it bubbles up to the parent:
https://playground.solidjs.com/anonymous/290e63e2-7873-4a86-8770-cad66bf47ab3
Link to discord where the conversation started with multiple reproductions and ideas:
https://discord.com/channels/722131463138705510/722131463889223772/1073714796710604961
Your Example Website or App
https://playground.solidjs.com/anonymous/a288d594-f9ee-4ddd-ba8c-c85ca8028ad1
Steps to Reproduce the Bug or Issue

Have a reusable Suspense Component
Pass a function into the SuspenseWrapper as the child
Promises are never resolved and it stays in the fallback.

Expected behavior
As a user, I expect to be able to make a reusable suspense wrapper that can accept children as a function and that suspense is able to display fallback's correctly and resolve.
Screenshots or Videos
No response
Platform

OS: [e.g. macOS, Windows, Linux]
Browser: [e.g. Chrome, Safari, Firefox]
Version: [e.g. 91.1]

Additional context
This is for the error boundary ticket, but wrapping the children with the utility children function seems to resolve this issue as well.
https://playground.solidjs.com/anonymous/e787c74b-cbee-427f-9ac0-b845bec1e6a7
No response

I think these issues are by design. Function children aren't suppose to do anything different. If you pass something a function and it returns a function that function isn't called by it.
Like consider:
const a = () => console.log("a");

const b = () => a

Calling b, doesn't execute a simply returns it. Suspense or Error Boundaries should never have function children. It's nonsensical. JSX types don't prevent it. But it is passing straight through. b is your Suspense Component here.
Eventually when you get to the DOM it needs to unwrap all the functions. But not every component is going to do that.
I do think something internal to Suspense is messing up here hence the error. It does unwrap internally I believe. I generally don't entertain this scenario because it is basically invalid. Like would you pass a function to a random component and expect it to work when it isn't expecting one?

Not sure if this is intended or not, but I would avoid passing function children to any control flow component. When function is necessary for creating variables in JSX, I would wrap it in untrack so that it's called immediately when props.children are accessed.

Eventually when you get to the DOM it needs to unwrap all the functions. But not every component is going to do that.

I generally don't entertain this scenario because it is basically invalid.

This explanation doesn't really resonate with me at all.
One core aspect of how reactivity systems work, maybe the main one, is that children are executed inside their parents, if that's not happening the whole thing falls apart.
In Solid we can pass arbitrarily-wrapped children like that kind of everywhere (https://playground.solidjs.com/anonymous/801252a1-734b-413e-86b7-4603cc630512), and they are resolved, because what else is the framework supposed to do with children functions? If children are resolved, but they are not resolved inside their parents, then it just looks like a bug to me.
For context it works like this in Voby (https://codesandbox.io/s/voby-playground-forked-141k8h?file=/src/index.tsx), it doesn't matter how many times a child is wrapped, whatever the child is the framework will resolve it, or it will just be broken.
I don't see why this would work any differently in Solid, it looks to me like children are being resolved, but they are being resolved at the wrong time, sometimes.
I can't think of a scenario where Solid's behavior in this regard leads to more correct output than Voby's, if anybody has one I'd like to see it. Like resolving children inside their parents seems just fundamental to me.

Like would you pass a function to a random component and expect it to work when it isn't expecting one?

What's a component that doesn't expect (also) functions as children? Solid's own JSX types are telling me that passing functions as children like in @Tanner-Scadden's example is valid. Like by definition Solid is telling me that passing a function there is ok.

Why does it execute correctly then if there is a div around the child components?
I'm not sure why the ErrorBoundary ticket #1543 was closed. It has this same issue, and if you wrap the child that's a function in a wrapper or use the children helper, it catches the error correctly.

The only reason this one is open is because it shouldn't get in an infinite loop. Either it should work or it should not trigger Suspense. But the fact it would work is an implementation detail, because the usage is invalid. So I was tempted to close this one as well.
Passing a function to a child that doesn't expect it doesn't make sense.  It is completely different to passing to something that intends a callback. Forget reactivity for a moment or any expectations there and just consider if you were writing code that expects a value and you pass it a function.
Example:
const sum = (a, b) => a + b;

const getNumber = () => 2;

sum(getNumber(), 3) // 5

// would you expect this to work?
sum(getNumber, 3) // 3

Technically they both produce a sum the first is correct and proper usage and gets the right answer. The second works as a necessity of the JavaScript engine but is incorrect usage and produces the wrong sum.
You can think of the control flow as a builder function. It doesn't really care what you pass as the consequence unless it explicitly supports callbacks (like some do). It gets an input and builds it into the right structure to be inserted. You pass invalid input in, you get invalid input out. It might sort of work but that is besides the point.
It'd be interesting to see if we could make TypeScript smarter here but I kind of doubt it can be. We all know TypeScript with JSX is flawed. Maybe there is a way we can use that to our advantage? If it views all component returns as JSX.Element can we tell it functions aren't accepted as JSX.Element and force authors of those components to cast?
The thing is ultimately this expectation of passing an arbitrary function to a Component who has its own logic on handling its props and isn't expecting a function is an incorrect expectation.  @fabiospampinato Voby might work this way because it needs to handle the might be function case always. We don't by design. If TS worked properly this would be very clear.

Ok so if I'm hearing you correctly your position is basically that Solid is using the wrong language, like it's TypeScript's types that are wrong, but they can't be fixed, because TypeScript doesn't allow for that.
Your example with the sum function makes sense to me when viewed through the lens of TS (I see JS as a compilation target at this point), that code wouldn't make sense with TS, because addition isn't defined between functions and numbers, and I'll get an error about it, as expected.
If I'm understanding your reasoning then a similar situation is happening with Solid's components, except that the types that you want to support cannot be written, so what components say they support isn't always actually true, but TS doesn't give the user an error about it.
I still don't understand why components shouldn't always resolve their children though, in your sum example summing a function and a number is undefined so it doesn't make sense, but in this example putting a function inside a parent component could basically always be well defined, as proof of that it just works like that in Voby. But you are saying Solid can't or doesn't want to do that for reasons that I don't entirely understand.
I'd suggest revisiting this decision first of all, and alternatively checking for types at runtime and throwing with a clear error when something doesn't match, and making your case for changing how JSX works in TypeScript in TypeScript's repo.
That's pretty much all I have to add to the discussion I think. This behavior doesn't make sense to me, but it is what it is.

I can understand your logic, and in those cases it makes sense. However, in the cases where the child is not expecting any props, it is just returning a component that is already invoked, I am lost on why it wouldn't work.
Playing around with it more, when I wrap these functional children in my reusable suspense or error boundary component like this:
      {untrack(children(() => props.children))}
    </Suspense>```
It works how I would expect it too. Suspense boundaries are respected and ErrorBoundary is caught within the child.

I'll be adding these wrappers for the children until there is a way to easily warn the user that what they are doing is invalid with resources to understanding why, or the reasoning behind this is rethought. Either way, appreciate your time and enjoy your birthday weekend!

If you wrote a JavaScript library that did a sum and then for some reason TypeScript couldn't type it properly would you blame the library or TypeScript? You'd just think well, I guess TypeScript isn't that useful. And then everyone insists on using it and you are like, alright um sure. I'm very open to anyone helping with the types here.
The reason I'm fixing in on the API is that with Solid 2.0 in the works, yes the implementation will change. Lazy Memos will make it that our mechanisms that rely on eager memos will need to change. This is a small part of end user code but it affects rendering and control flow internals will need a bit of an adjustment. This case might even work unintentionally. That being said what I've said above from an API standpoint is unchanged by that. An event handler expects a callback so you pass it that. A sum expects a number. And an ErrorBoundary/Suspense expects reactive expression or < /> element children.
Honestly, I do wonder if this is fixable with the types. I viewed TypeScript early on the way I viewed typed languages like C#. The truth is sometimes with TS it is better to lie for API surface reasons when dealing with things where DSLs can't perfectly be typed. Things like Proxies and JSX make this much more apparent. End users will get clear and usable types that guide them properly and the internals can contain all the messiness of JavaScript.

I can understand your logic, and in those cases it makes sense. However, in the cases where the child is not expecting any props, it is just returning a component that is already invoked, I am lost on why it wouldn't work.
Playing around with it more, when I wrap these functional children in my reusable suspense or error boundary component like this:
<Suspense fallback={() => Loading...}>
   {untrack(children(() => props.children))}
</Suspense>

It works how I would expect it too. Suspense boundaries are respected and ErrorBoundary catches errors instead of bubbling up.
I'll be adding these wrappers for the children until there is a way to easily warn the user that what they are doing is invalid with resources to understanding why, or the reasoning behind this is rethought. Either way, appreciate your time and enjoy your birthday weekend!

Why would this be necessary? What component that is already invoked is returning a function? Like I'm missing why this whole thing is even a thing. We recommend returning Fragments or Memo's if you must return something dynamic.
Where does this happen? Again why would one expect this to work? The problem is if you start doing this and people use the library then they might have incorrect expectations as well. I'd be interested to see the situation where this came up and determine if there is an easier way to address the confusion upfront.

If you wrote a JavaScript library that did a sum and then for some reason TypeScript couldn't type it properly would you blame the library or TypeScript? You'd just think well, I guess TypeScript isn't that useful. And then everyone insists on using it and you are like, alright um sure. I'm very open to anyone helping with the types here.

I'd be 100% on your same boat in that case. I just see this as a different case, not the same.
Maybe you are even right, I don't entirely understand your reasoning for wanting Solid to work like this after all, but if the resulting code is not understandable by the end user, and if writing a better programming language is out of the question, then bending what you want to satisfy the language you are using may be the best option.
Like as an hypothetical user, in general, unless I'm forced to use a program I won't use it if a) I have no clue about how it works, or b) I understand how it works, and I disagree with it. In this particular example I don't think Solid has cleared that bar for me for example, I don't 100% understand how it works, and I kinda disagree that it should work like that.
Though one can't make everybody happy of course, just saying.

Serious question though.. can we make the types stricter here? What would be the implications. @otonashixav @trusktr.
Like from a JSX standpoint syntactually we never need to pass a function in.
// Show returns a Memo but it could be cast to JSX.Element

  <Show /> // thinks it is JSX.Element

{readSignal()}
 // valid

{readSignal}
 // invalid, technically works but would error for TS

From my standpoint I don't think anyone should consider this valid:

{() => }
 // since when do DOM nodes take functions? Would React let you do this?

I tried it in react and it does not throw a typescript error, but there is an error thrown inside of react to give feedback to the user.
Here is a playground example:
https://playcode.io/1176221

I haven't read the discussion completely, but if you're asking if we could remove functions from JSX.Element and simply cast the return of Show and gang with as unknown as JSX.Element, I personally don't see any issues other than breaking code for people currently returning memos.
One interesting alternative is attaching a fake property to the memo return type, without changing anything at runtime, so that functions would not be usable in TS JSX (without casting), but memos would be typed with the property and be usable.
// dom-expressions

// non-existent symbol
declare const MEMO: unique symbol;
interface FunctionElement {
  (): JSX.Element;
  [MEMO]: never;
}

// solid
type Memo<T> = (() => T) & { [MEMO]: never };
function createMemo(...) {
  //...
  return accessor as Memo<T>;
}

function Show(...) {
  //...
  return createMemo(...); // totally okay

I'm sure this is something most people would be against. It is fun though.

Oh that is interesting. I mean adding it to the Accessor type would be sufficient. Memos and Signals are fine in these cases. Syntactually I'd almost prefer to be strict on all functions but this might ease that migration. Only downside I can see is people opting to overwrapping but at least it would flag that something is wrong. I am very tempted to do this. Maybe we just found a reason to push to a 1.7 release.


Allow text after Background: and Examples:

Currently this crate allows only whitespace after Background:, but any characters should be allowed.
From Gherkin reference
Each line that isn’t a blank line has to start with a Gherkin keyword, followed by any text you like. I have also checked online the the official JS implementation and it allows the text after.
VS code extension also puts there some text by default which is how I stumbled upon this.
I have also added the same for Examples:, all other keywords seem to have names normally so those should be covered.
One more commit I did was overriding the transitive dependency on this crate in the cucumber test so that it uses this version, not anything in crates.io. I also had to update the cucumber version because of the crate name change.

@mladedav thanks for contributing! I've pushed some changes, mainly to reflect Background and Examples names in AST.

FCM
Support for text after `Background` and `Examples` (#32)


Train to be a perfect loop

Train a separate model to perfect the 30-second loop, ensuring it seamlessly folds/loops onto itself. This will make the output easier to use for musicians/producers, even in its current state with all of its limitations.

this would be amazing

What would need to go into this?

https://github.com/chavinlo/musicgen_trainer done


Rapl

Added the following to enable the usage of RAPL metrics in Kind Cluster:

script to change read permissions of RAPL files on host
mount powercap directory into cluster

Maybe should also be adjusted in "kind.sh"?

should I maybe create another manifest for this purpose as this depends on the underlying host and its hardware?


docs: :memo: Added a gif of the demo.aux.yml file to show how it looks when being used

Fixes #6

LGTM


Added square-spin and ball-pulse spiners from loaders.css

You can fix travis-ci?

You can fix travis-ci?

not this task


Cloud / HTTP Provider

There are a lot of free and paid cloud services around.
Implement at least 1 or 2 of them to get started

use PSR-7 for it
https://github.com/php-fig/http-message

https://useragentapi.com
https://www.whatismybrowser.com/
https://udger.com
http://www.useragentstring.com/pages/api.php

All implemented


Mod breaks Tinkers Construct's bronze recipe

This mod currently adds its custom bronze recipe at the same path as Tinkers' recipe. This causes it to override the proper bronze recipe even when the pack includes tin, which has lead to a ton of users being confused and thinking Tinkers is to blame for having a broken recipe. Please create that recipe under your own namespace so it does not delete our recipe.
Really in general, remove all your custom recipes from our namespace. There is no reason your mod should be creating recipes under tconstruct unless they are an override, create new recipes under your mod ID. All our datagenerators support you choosing a mod ID to generate your recipes. Do not use our BaseRecipeProvider, make your own using your own ID, literally the only purpose of that class is to set the output mod ID

Ok, will fix this and push something out soon. Thanks for pointing this out.

I added a conditional for bronze to only show the alternate if zinc is missing. I also moved all recipes into the proper namespace.

@KnightMiner One side note. I actually only intended this mod to be for 1.18.1 temporarily to be able to address overriding diamond/emerald modifiers, as there was no datagen yet, and a recipe for bronze without tin. However, after getting a ton of requests, I eventually added a bunch more stuff. I never did go back and clean up the bronze implementation. Apologies for causing the issue.


iptables: Remove NOTRACK Netfilter target

/test

The two test failures are in unrelated tests:

gke-stable hit known flake https://github.com/cilium/cilium/issues/17661.
k8s-1.22-kernel-4.9 hit https://github.com/cilium/cilium/issues/17766 (failed before in master).

All team review requests are covered except for cilium/ci-structure, but the test changes are trivial and have been reviewed by Gilberto, their original author. Marking ready to merge.


Fix wrong commits count for PR's that have more than 30 commits

Resolves #838 . It turned out that git.log has implicit commits count param. Which equal 30 by default.

This looks good to me 👍


Add python312Packages.crewai and its dependencies: crewai-tools, embedchain, google-cloud-aiplatform, langchain-cohere, langchain-experimental, mem0ai, pyright, agentops

Added these Python modules:

crewai,
crewai-tools,
embedchain,
google-cloud-aiplatform,
langchain-cohere,
langchain-experimental,
mem0ai,
pyright,
agentops

This was all in service of fulfilling CrewAI's transitive dependencies.

Things done

Built on platform(s)

[ ] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[x] aarch64-darwin

For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)

[ ] sandbox = relaxed
[x] sandbox = true

[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[x] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[ ] Tested basic functionality of all binary files (usually in ./result/bin/)
25.05 Release Notes (or backporting 24.11 and 25.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

Add a :+1: reaction to pull requests you find important.

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:
https://discourse.nixos.org/t/building-a-python-package-that-uses-uv/56687/2

Can you please update the PR title according to the contributor guide ? See others PRs to get an idea.


Decode a Morse code message

In this project we:

[x] Created a method to decode a Morse code character, take a string parameter, and return the corresponding character in uppercase
[x] Created a method to decode an entire word in Morse code, take a string parameter, and return the string representation. A single space will separate every character in a word
[x] Create a method to decode the message in Morse code, take a string parameter, and return the string representation. 3 spaces will separate every word

@batoorsohail
Your MIT License is broken, kindly fix it asap!

Thanks, @rloterh 🙌
I fixed the link to the MIT License. 😃


How to add generated types to your MTA archive

Currently there is no description how to get a CAP project with cds-typer running as an MTA application.
After deployment the app crashes because of the missing types. The easiest fix is to add the type generation command to the mta.yaml file and generate the types into the gen/srv folder, to include them into the MTA archive.
Kind regards,
Sebastian

Hi Sebastian,
Thanks a lot for your contribution. I added Daniel for a review. Later on I'll also take a look at how we connect that probably to/from our deployment guide.
Cheers,
René