[language] Add new FixedPoint32 module to stdlib

This adds a fixed-point numeric type with 32 fractional bits. This can be used for things like interest rates, conversion rates, etc. Besides functions to create these fixed-point values, this provides basic truncating multiply and divide functions.
Motivation
Add support for non-integer values in a fixed-point representation.
Have you read the Contributing Guidelines on pull requests?
Yes
Test Plan
Added some new tests for this module, including all the interesting corner cases that I could think of.

how are additions and subtractions performed with this model/implementation?
Also is this PR to have a conversation about the fixed point (which is great) or do we intend to commit this in stdlib?

how are additions and subtractions performed with this model/implementation?

We could add functions for those if they are commonly used. In the meantime, you can just add and subtract the raw values. There isn't anything special needed there.

Also is this PR to have a conversation about the fixed point (which is great) or do we intend to commit this in stdlib?

I'd like to commit it as soon as I can get the tests to work.

The switchover has landed! So you should be able to get these working once you get the cycles :)

The switchover has landed! So you should be able to get these working once you get the cycles :)

Yes, I got it working today and I'm in the process of writing more tests.

I've updated this with more tests and comments. I also added an explicit check for underflow in the create_from_rational function, since that seems like it could be a source of unexpected behavior that we can disallow. This is ready for review now.

One more change: I switched to use Transaction::assert and to report an abort code of 16 for the various arithmetic errors here, after I discovered that the abort code of 10 is generally used for "insufficient balance" errors. After we change the VM to fail on overflow with integer type casts (and perhaps pending various discussions of coding style), I am planning to remove the explicit checks for overflows, which will leave only the one explicit Transaction::assert for underflow in create_from_rational.

I updated this PR to take advantage of #2805 to report overflows in the type casts.

I know we probably don't have a use case for now, but do we want to offer something like multiply_fixed32_fixed32 or divide_fixed32_fixed32?

I know we probably don't have a use case for now, but do we want to offer something like multiply_fixed32_fixed32 or divide_fixed32_fixed32

I'd rather wait to see what is needed, but that's just my personal preference.

@bors-libra r=tzakian

:pushpin: Commit 77180b3 has been approved by tzakian

:hourglass: Testing commit 77180b34fa7abe947ca6325a54ddec8540ef7393 with merge cbbd55eb7492c0911f8e918944f48c44de736faa...

:broken_heart: Test failed - checks-circle_commit_workflow

@bors-libra retry

:hourglass: Testing commit 77180b34fa7abe947ca6325a54ddec8540ef7393 with merge 518ad12b17e2871e0b9f6d8f71106113f0debb33...

:sunny: Test successful - checks-actions_land_blocking_test, checks-circle_commit_workflow
Approved by: tzakian
Pushing 518ad12b17e2871e0b9f6d8f71106113f0debb33 to master...


promtool: Speed up checking for duplicate rules

Running promtool check config on large rule files is rather slow. Improve this by adding a testcase, benchmark and changing the algorithm used to find duplicates.
Before:
goos: darwin
goarch: amd64
pkg: github.com/prometheus/prometheus/cmd/promtool
cpu: VirtualApple @ 2.50GHz
BenchmarkCheckDuplicates-8   	       1<PHONE_NUMBER> ns/op

After:
goos: darwin
goarch: amd64
pkg: github.com/prometheus/prometheus/cmd/promtool
cpu: VirtualApple @ 2.50GHz
BenchmarkCheckDuplicates-8   	     187	   6313867 ns/op

@zecke thanks for this, looks good, but there's something strange with CircleCI build, could you merge main into this?

@zecke thanks for this, looks good, but there's something strange with CircleCI build, could you merge main into this?

I lowered the parallelism in circle-ci but now tests fail in code not touched and in go mod sanity checking. I am not sure whether this is related to my changes at all. Needless to say that building locally works.

please revert your circleci changes. it is because you probably also have a circleci account.

the last test failure was done with a run with SSH, so it might have been tampered somehow.

please revert your circleci changes. it is because you probably also have a circleci account.

Reverted. How can we proceed? How can I not associate this with my account?

the last test failure was done with a run with SSH, so it might have been tampered somehow.

I tried to retrigger the build.

Going to merge from my account as CircleCI seems unhappy with @zecke's account.

Thank you @zecke! & sorry for the trouble here, I've asked CircleCI if there's anything we can do better for future contributions.
I've merged your exact branch under #9306.


Open the main app from floating window?

I'm looking for a better solution to open the main application from the floating window, right now I'm only able to archive this by modifying OverlayServices.java and call it as FlutterOverlayWindow.openMainApp();
    private void openMainApp() {
        Intent intent = new Intent();
        intent.setClassName("com.vitinc.myapp", "com.vitinc.myapp.MainActivity");
        intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
        startActivity(intent);
    }

Hi @ducviet321 , Im very interested in your idea / implementation, could not make it work, could you please explain a little more.
The file you are referencing is: OverlayService.java?
In wich line did you add your code?
Do you need to do something else beside calling it as you said?
Thanks in advance!

In /lib/src/overlay_window.dart add to class FlutterOverlayWindow
static Future<bool?> openMainApp() async {
    final bool? _res = await _overlayChannel.invokeMethod<bool?>('openMainApp');
    return _res;
  }

in android/src/main/java/flutter/overlay/window/flutter_overlay_window/OverlayService.java
Find flutterChannel.setMethodCallHandler((call, result) -> { and add below
            } else if (call.method.equals("resizeOverlay")) {
               ...
            } else if (call.method.equals("openMainApp")) {
                Intent intent = new Intent();
                intent.setClassName("com.vitinc.widpet_android", "com.vitinc.widpet_android.MainActivity");
                intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
                startActivity(intent);
            }

@ducviet321  thank you so much for your help!!! it worked but I hag to remove the line
Intent intent = new Intent();
And also, I'd like to know why you added a space in your app namespace, was it a typo o it should be like that.
Thanks again and best regards!

Yeah it was my typo, maybe be you should rename intent variable instead of removing it, I haven't looked, just try to make it work quickly

use https://pub.dev/packages/android_intent_plus with app links

@icanall10 can you share example to open the app using android_intent_plus?

`
AndroidIntent intent = AndroidIntent(
action: 'action_view',
data: 'your-app-link-schema://your-app-link-host/some-path',
);
await intent.launch();
`

@selvam920
`
AndroidIntent intent = AndroidIntent(
action: 'action_view',
data: 'your-app-link-schema://your-app-link-host/some-path',
);
await intent.launch();
`

thanks


CLOUD-42308 azure rm fixes

@keyki pls check this modification

Jenkins build failed.
Refer to this link for build results: http://ci.sequenceiq.com/job/cloudbreak-pull-request/1709/

Jenkins build failed.
Refer to this link for build results: http://ci.sequenceiq.com/job/cloudbreak-pull-request/1710/

Jenkins build finished, all tests passed.
Refer to this link for build results: http://ci.sequenceiq.com/job/cloudbreak-pull-request/1711/

Jenkins build finished, all tests passed.
Refer to this link for build results: http://ci.sequenceiq.com/job/cloudbreak-pull-request/1712/

Jenkins build finished, all tests passed.
Refer to this link for build results: http://ci.sequenceiq.com/job/cloudbreak-pull-request/1713/


feat(popup): Delete time entries

:star2: What does this PR do?
Add delete functionality to the edit entry form.
:bug: Recommendations for testing

Delete a completed entry
Delete a running entry

:memo: Links to relevant issues or information
Closes #1583

:+1:  hidden in the integration popup

Could delete function have a confirmation prompt before deletion?


Test the bot

Changes

[FIX] Replaces double quotes (") with single quotes (') within the slackbot summary to prevent the string and the bot from breaking.

This change is

Works!


email frequency?

probably only send the same email about the same rule once per week? or once every 3 days or so?

https://rubygems.org/gems/sidekiq-status to store jobs, apparently sidekiq doesn't store completed jobs. then do my own calculations about jobs sent and time since


Added a heat map for the instruction hits in the disassembly window

When looking at the disassembly window, users should see which instructions take the most time (occur in most samples), thus this adds a (log-scale) heat map to the left of each code editor. It colors that area red (with transparency) if the instructions occur int the sampling results. In cases like there are no samples, it will just leaf the area in the background color.
In order to get the data, we needed to add a counting map for all "raw" addresses occurring on sampling callstacks (i.e addresses that are not yet resolved to its function address).

@IrinaShkviro This did some minor changes to the SamplingProfiler, can you make sure those are aligned with what you are working on?

This is awesome!
One change I would suggest: There needs to be some numerical indication how many samples fall onto each line. The heat map is great, but we have the numbers and we shouldn't hide them
I think all of the following data would be good:

Total samples on this line.
Percentage of samples on this line (compared with all samples)
Percentage of samples on this line (compared with samples in this function)

Maybe 2) and 3) can be combined by showing the percentage of samples falling into this function at the top and then percentages of samples per line in this function in the heatmap?
Example:
Top line:    37 / 1879 samples  (0.02 of all samples)
Each instruction line:    5 / 37 (0.14 of samples)
WDYT?

@IrinaShkviro This did some minor changes to the SamplingProfiler, can you make sure those are aligned with what you are working on?

It should't cause any problems from my understanding: I'm going to change the class completely to have data and logic in 2 different classes and then change the class for data to proto. But as I'm on initial step of working with this class it would be fair if I rebase my branch when you merge this. But thanks for asking!

This is awesome!
One change I would suggest: There needs to be some numerical indication how many samples fall onto each line. The heat map is great, but we have the numbers and we shouldn't hide them
I think all of the following data would be good:

Total samples on this line.
Percentage of samples on this line (compared with all samples)
Percentage of samples on this line (compared with samples in this function)

Maybe 2) and 3) can be combined by showing the percentage of samples falling into this function at the top and then percentages of samples per line in this function in the heatmap?
Example:
Top line: 37 / 1879 samples (0.02 of all samples)
Each instruction line: 5 / 37 (0.14 of samples)
WDYT?

Thanks for the review. I'll address your comments in a minute.
I totally see you point. My idea was to show the info when hovering over the color. And I planned to add 1., 2. and 3. here. However, I wanted to add this as a separate PR. This PR already is functional without the additional information, so I wanted to keep them clean. Also, I am not sure, whether I can finish the hovering today, and will probably not be able to merge it today.

@IrinaShkviro This did some minor changes to the SamplingProfiler, can you make sure those are aligned with what you are working on?

It should't cause any problems from my understanding: I'm going to change the class completely to have data and logic in 2 different classes and then change the class for data to proto. But as I'm on initial step of working with this class it would be fair if I rebase my branch when you merge this. But thanks for asking!

Okay, thanks.

I totally see you point. My idea was to show the info when hovering over the color. And I planned to add 1., 2. and 3. here. However, I wanted to add this as a separate PR. This PR already is functional without the additional information, so I wanted to keep them clean. Also, I am not sure, whether I can finish the hovering today, and will probably not be able to merge it today.

Totally fine to do this in a later PR. Might be worth adding this to the PR description (that follow-ups are planned).

I totally see you point. My idea was to show the info when hovering over the color. And I planned to add 1., 2. and 3. here. However, I wanted to add this as a separate PR. This PR already is functional without the additional information, so I wanted to keep them clean. Also, I am not sure, whether I can finish the hovering today, and will probably not be able to merge it today.

Totally fine to do this in a later PR. Might be worth adding this to the PR description (that follow-ups are planned).
I would not do this on hover though, as you want to see all numbers at once.

I adjusted the description accordingly. Lets discuss the visualization of this offline.


iptorrents searches return '429 Client Error: Too Many Requests for url' with long lists

Description
When searching with the iptorrents plugin, long lists of movies/series result in 429 Client Error: Too Many Requests for url error responses from IPTorrents. GET requests should be rate-limited for this plugin.
Expected Behavior
Searching with long lists of movies/series will return any discovered entries (or possibly zero entries) without any failed HTTP requests.
Actual Behavior
Searching with long lists of movies/series can result in 429 Client Error: Too Many Requests for url responses after iterating over a portion of the list.
Example with series:
2022-12-02 22:09:54 VERBOSE  discover      SEARCH_TV       Discovering 24 titles ...
2022-12-02 22:09:54 INFO     discover      SEARCH_TV       Ignoring interval because of --discover-now
2022-12-02 22:09:54 VERBOSE  discover      SEARCH_TV       Searching for `Yellowstone (2018) S04E11` with plugin `iptorrents` (1 of 24)
2022-12-02 22:09:56 VERBOSE  discover      SEARCH_TV       No search results for `Yellowstone (2018) S04E11`
2022-12-02 22:09:56 INFO     task          SEARCH_TV       Plugin next_series_episodes has requested task to be ran again after execution has completed. Reason: Look for next season
2022-12-02 22:09:56 VERBOSE  discover      SEARCH_TV       Searching for `What We Do in the Shadows S04E11` with plugin `iptorrents` (2 of 24)
2022-12-02 22:09:57 VERBOSE  discover      SEARCH_TV       No search results for `What We Do in the Shadows S04E11`
2022-12-02 22:09:57 VERBOSE  discover      SEARCH_TV       Searching for `The Righteous Gemstones S02E10` with plugin `iptorrents` (3 of 24)
2022-12-02 22:09:59 VERBOSE  discover      SEARCH_TV       No search results for `The Righteous Gemstones S02E10`
2022-12-02 22:09:59 VERBOSE  discover      SEARCH_TV       Searching for `The Morning Show S02E11` with plugin `iptorrents` (4 of 24)
2022-12-02 22:10:00 VERBOSE  discover      SEARCH_TV       No search results for `The Morning Show S02E11`
2022-12-02 22:10:00 VERBOSE  discover      SEARCH_TV       Searching for `The Boulet Brothers DRAGULA S04E11` with plugin `iptorrents` (5 of 24)
2022-12-02 22:10:01 VERBOSE  discover      SEARCH_TV       No search results for `The Boulet Brothers DRAGULA S04E11`
2022-12-02 22:10:01 VERBOSE  discover      SEARCH_TV       Searching for `The Bear S01E09` with plugin `iptorrents` (6 of 24)
2022-12-02 22:10:03 VERBOSE  discover      SEARCH_TV       Searching for `Ted Lasso S02E13` with plugin `iptorrents` (7 of 24)
2022-12-02 22:10:04 VERBOSE  discover      SEARCH_TV       No search results for `Ted Lasso S02E13`
2022-12-02 22:10:04 VERBOSE  discover      SEARCH_TV       Searching for `Severance S01E10` with plugin `iptorrents` (8 of 24)
2022-12-02 22:10:05 VERBOSE  discover      SEARCH_TV       No search results for `Severance S01E10`
2022-12-02 22:10:05 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Secret Celebrity Drag Race S02E09` with plugin `iptorrents` (9 of 24)
2022-12-02 22:10:07 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Secret Celebrity Drag Race S02E09`
2022-12-02 22:10:07 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Drag Race: Vegas Revue S01E05` with plugin `iptorrents` (10 of 24)
2022-12-02 22:10:08 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Drag Race: Vegas Revue S01E05`
2022-12-02 22:10:08 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Drag Race: Untucked! S14E15` with plugin `iptorrents` (11 of 24)
2022-12-02 22:10:09 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Drag Race: Untucked! S14E15`
2022-12-02 22:10:09 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Drag Race UK vs the World S01E07` with plugin `iptorrents` (12 of 24)
2022-12-02 22:10:10 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=tt16968320+S01E07&qf=
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Drag Race UK vs the World S01E07`
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Drag Race UK S03E11` with plugin `iptorrents` (13 of 24)
2022-12-02 22:10:10 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=RuPauls+Drag+Race+UK+S03E11&qf=
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Drag Race UK S03E11`
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Drag Race Down Under S01E09` with plugin `iptorrents` (14 of 24)
2022-12-02 22:10:10 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=RuPauls+Drag+Race+Down+Under+S01E09&qf=
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Drag Race Down Under S01E09`
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Drag Race All Stars Untucked S07E13` with plugin `iptorrents` (15 of 24)
2022-12-02 22:10:10 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=RuPauls+Drag+Race+All+Stars+Untucked+S07E13&qf=
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Drag Race All Stars Untucked S07E13`
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Drag Race All Stars S07E13` with plugin `iptorrents` (16 of 24)
2022-12-02 22:10:10 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=RuPauls+Drag+Race+All+Stars+S07E13&qf=
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Drag Race All Stars S07E13`
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Drag Race S14E17` with plugin `iptorrents` (17 of 24)
2022-12-02 22:10:10 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=RuPauls+Drag+Race+S14E17&qf=
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Drag Race S14E17`
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       Searching for `Rick and Morty S06E05` with plugin `iptorrents` (18 of 24)
2022-12-02 22:10:10 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=Rick+and+Morty+S06E05&qf=
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       No search results for `Rick and Morty S06E05`
2022-12-02 22:10:10 VERBOSE  discover      SEARCH_TV       Searching for `Peacemaker S01E09` with plugin `iptorrents` (19 of 24)
2022-12-02 22:10:11 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=Peacemaker+S01E09&qf=
2022-12-02 22:10:11 VERBOSE  discover      SEARCH_TV       No search results for `Peacemaker S01E09`
2022-12-02 22:10:11 VERBOSE  discover      SEARCH_TV       Searching for `Drag Race Holland S02E09` with plugin `iptorrents` (20 of 24)
2022-12-02 22:10:11 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=Drag+Race+Holland+S02E09&qf=
2022-12-02 22:10:11 VERBOSE  discover      SEARCH_TV       No search results for `Drag Race Holland S02E09`
2022-12-02 22:10:11 VERBOSE  discover      SEARCH_TV       Searching for `Clarice S01E14` with plugin `iptorrents` (21 of 24)
2022-12-02 22:10:11 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=Clarice+S01E14&qf=
2022-12-02 22:10:11 VERBOSE  discover      SEARCH_TV       No search results for `Clarice S01E14`
2022-12-02 22:10:11 VERBOSE  discover      SEARCH_TV       Searching for `Canadas Drag Race S02E11` with plugin `iptorrents` (22 of 24)
2022-12-02 22:10:11 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=Canadas+Drag+Race+S02E11&qf=
2022-12-02 22:10:11 VERBOSE  discover      SEARCH_TV       No search results for `Canadas Drag Race S02E11`
2022-12-02 22:10:11 VERBOSE  discover      SEARCH_TV       Searching for `Better Call Saul S06E14` with plugin `iptorrents` (23 of 24)
2022-12-02 22:10:11 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=Better+Call+Saul+S06E14&qf=
2022-12-02 22:10:11 VERBOSE  discover      SEARCH_TV       No search results for `Better Call Saul S06E14`
2022-12-02 22:10:11 VERBOSE  discover      SEARCH_TV       Searching for `Alone S09E12` with plugin `iptorrents` (24 of 24)
2022-12-02 22:10:11 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=Alone+S09E12&qf=
2022-12-02 22:10:11 VERBOSE  discover      SEARCH_TV       No search results for `Alone S09E12`
2022-12-02 22:10:11 VERBOSE  details       SEARCH_TV       Produced 2 entries.
*****
2022-12-02 22:10:11 VERBOSE  details       SEARCH_TV       Summary - Accepted: 0 (Rejected: 2 Undecided: 0 Failed: 0)
2022-12-02 22:10:11 INFO     task          SEARCH_TV       Rerunning the task in case better resolution can be achieved.
2022-12-02 22:10:11 VERBOSE  discover      SEARCH_TV       Discovering 24 titles ...
2022-12-02 22:10:11 INFO     discover      SEARCH_TV       Ignoring interval because of --discover-now
2022-12-02 22:10:11 VERBOSE  details       SEARCH_TV       Task didn't produce any entries.
2022-12-02 22:10:11 VERBOSE  details       SEARCH_TV       Summary - Accepted: 0 (Rejected: 0 Undecided: 0 Failed: 0)

FlexGet Version
$ flexget -V
3.5.6
You are on the latest release.

Relevant Config
tasks:
  SEARCH_TV:
    template: tv
    priority: 2
    free_space:
      path: /var/lib/deluge/Downloads
      space: 20000
    limit_new: 5
    discover:
      what:
        - next_series_episodes: yes
      from:
        - iptorrents:
            rss_key: *****
            uid: *****
            password: *****
      release_estimations: ignore

templates:
  tv:
    deluge:
      host: *****
      port: *****
      username: *****
      password: *****
      path: /var/lib/deluge/Downloads/TV
      config_path: /var/lib/deluge/.config/deluge
      action: add
      label: "tv"
    series:
      - "Better Call Saul":
          alternate_name:
            - tt3032476
          exact: yes
          quality: 1080p webdl+
      - "Clarice":
          alternate_name:
            - tt2177268
          exact: yes
          quality: 1080p webdl+
      - "Yellowstone (2018)":
          alternate_name:
            - tt4236770
          exact: yes
          quality: webrip+
      - "Ted Lasso":
          alternate_name:
            - tt10986410
          exact: yes
          quality: 1080p webdl+
      - "What We Do in the Shadows":
          alternate_name:
            - tt7908628
          exact: yes
          quality: 1080p webdl+
      - "Peacemaker":
          alternate_name:
            - tt13146488
          exact: yes
          quality: 1080p webdl+
      - "The Righteous Gemstones":
          alternate_name:
            - tt8634332
          exact: yes
          quality: 1080p webdl+
      - "The Bear":
          alternate_name:
            - tt14452776
          exact: yes
          quality: 1080p webdl+
      - "Alone":
          alternate_name:
            - tt4803766
          exact: yes
          quality: 720p webdl+
      - "The Morning Show":
          alternate_name:
            - tt7203552
          exact: yes
          quality: 1080p webdl+
      - "Severance":
          alternate_name:
            - tt11280740
          exact: yes
          quality: 1080p webdl+
      - "Rick and Morty":
          alternate_name:
            - tt2861424
          exact: yes
          quality: 1080p webdl+
      - "RuPauls Drag Race":
          alternate_name:
            - tt1353056
          exact: yes
          quality: webrip+
      - "RuPauls Drag Race: Untucked!":
          alternate_name:
            - tt1588754
          exact: yes
          quality: webrip+
      - "RuPauls Drag Race All Stars":
          alternate_name:
            - tt2301351
          exact: yes
          quality: webrip+
      - "RuPauls Drag Race All Stars Untucked":
          exact: yes
          quality: webrip+
      - "Canadas Drag Race":
          alternate_name:
            - tt11382554
          exact: yes
          quality: webrip+
      - "RuPauls Drag Race: Vegas Revue":
          alternate_name:
            - tt12937714
          exact: yes
          quality: webrip+
      - "RuPauls Secret Celebrity Drag Race":
          alternate_name:
            - tt11187480
          exact: yes
          quality: webrip+
      - "RuPauls Drag Race UK":
          alternate_name:
            - tt9780442
          exact: yes
          quality: webrip+
      - "Drag Race Holland":
          alternate_name:
            - tt13033136
          exact: yes
          quality: webrip+
      - "RuPauls Drag Race Down Under":
          alternate_name:
            - tt14192040
          exact: yes
          quality: webrip+
      - "The Boulet Brothers DRAGULA":
          alternate_name:
            - tt6289132
          exact: yes
          quality: webrip+
      - "RuPauls Drag Race UK vs the World":
          alternate_name:
            - tt16968320
          exact: yes
          quality: webrip+
    thetvdb_lookup: yes
    regexp:
      from: title
      reject:
        - msd
        - afg
        - line
    content_size:
      min: 0
      max: 10000
      strict: yes
    magnets: no
    torrent_alive: 5

Notes
I think this is triggered in this situation due to the alternate_name setting on many series in this list. Trying one name after another in quick succession could be the issue.
I believe this could be solved with a TimedLimiter.
We would want to use a flexget.utils.requests.Session that is updated via add_domain_limiter with a TimedLimiter instead of the default flexget.utils.requests.get method (also used here).
I think the interval for the TimedLimiter could be 1 second based on the logging that I've shared.
We could also use a session without a TimedLimiter to start, and if a 429 response is received, modify the session to begin limiting the requests from that point forward.

I will hopefully be able to submit a PR for this on my own, but if someone beats me to it, hopefully my notes help. 😄

In the meantime, the domain_delay plugin might be an acceptable workaround

Ah, I had thought I looked everywhere for a plugin that would work around this... thanks for the tip.
I personally still think an intentional rate-limit here would make sense, but open to discussion of course.

Definitely better to have the delay built into the plugin 😄
Just thought it worth mentioning so that your task works until you get around making those changes :+1:

Agreed. Worth it for getting my downloads working again 😄

A PR would be great to build it straight into the plugin. We already have the utility classes to add rate limits.

In the meantime, the domain_delay plugin might be an acceptable workaround

I just tried this workaround, and unfortunately the iptorrents plugin doesn't use the session that's built into the task passed to search. It references the default flexget.utils.requests.get method. For clarity, I can see in the logs that the delay is set:
2022-12-02 22:49:39 DEBUG    domain_delay  SEARCH_TV       Adding minimum interval of 5 seconds between requests to iptorrents.com

However, it isn't respected due to the described reason:
...
2022-12-02 22:58:17 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Drag Race: Untucked! S14E15` with plugin `iptorrents` (11 of 24)
2022-12-02 22:58:18 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=tt1588754+14x15&qf=
2022-12-02 22:58:18 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Drag Race: Untucked! S14E15`
2022-12-02 22:58:18 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Drag Race UK vs the World S01E07` with plugin `iptorrents` (12 of 24)
2022-12-02 22:58:18 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=RuPauls+Drag+Race+UK+vs+the+World+S01E07&qf=
2022-12-02 22:58:18 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Drag Race UK vs the World S01E07`
2022-12-02 22:58:18 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Drag Race UK S03E11` with plugin `iptorrents` (13 of 24)
2022-12-02 22:58:19 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=RuPauls+Drag+Race+UK+S03E11&qf=
2022-12-02 22:58:19 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Drag Race UK S03E11`
2022-12-02 22:58:19 VERBOSE  discover      SEARCH_TV       Searching for `RuPauls Drag Race Down Under S01E09` with plugin `iptorrents` (14 of 24)
2022-12-02 22:58:19 ERROR    discover      SEARCH_TV       Error searching with iptorrents: RequestException: 429 Client Error: Too Many Requests for url: https://iptorrents.com/t?q=RuPauls+Drag+Race+Down+Under+S01E09&qf=
2022-12-02 22:58:19 VERBOSE  discover      SEARCH_TV       No search results for `RuPauls Drag Race Down Under S01E09`
...


[$500] Web - It appears that invisible characters are not being treated as empty

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: <IP_ADDRESS>
Reproducible in staging?: Y
Reproducible in production?: Y
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: Applause - Internal Team
Slack conversation:
Issue found when executing PR https://github.com/Expensify/App/pull/31259
Action Performed:

Go to staging.new.expensify.com
Log in with any account
Go to Setting - Workspace
With workspace selected go to Settings,
Try invisible characters used in emojis (e.g.r \u200D), you can use this tool to copy it (paste the character in the JS/Java/C section, click Convert, and then Copy in Characters section)

Expected Result:
Invisible characters are being treated as empty
Actual Result:
It appears that invisible characters are not being treated as empty
Workaround:
Unknown
Platforms:

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

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

Screenshots/Videos
Add any screenshot/video evidence

https://github.com/Expensify/App/assets/78819774/e740bc49-92a0-4576-b431-189f564d76c0
View all open jobs on GitHub
Upwork Automation - Do Not Edit

Upwork Job URL: https://www.upwork.com/jobs/~017a1d32bde45b040d
Upwork Job ID:<PHONE_NUMBER>470806528
Last Price Increase: 2023-11-15

Closing, reported https://github.com/Expensify/App/issues/31386


Badges

Award badges to teams for various coolness:

Streak (3 months in a row, 6 months in a row, 9 months in a row, 12 months in a row).
Achieving a sub-1h time
Having an alias
One badge for every "completing" a december-year-end puzzle.
"Christmas" badge for completing any of the christmas themed events
A badge for year-X, given 6+ appearances in year=X.
Consistent team size (no of players is same across 4 months)
Special badges for fastest-10 teams (or finishers?) in specific-themed-events. Physicist for Quantum Physics etc.

Started work on this, will hopefully have a few badges by the June event.

Most of the above are implemented. Will go for the "early starter" one next, but running out of ideas. Please suggest more silly non-competitive badges..


Suggested sound_level payload (HA discovery topic) modification for nicer GUI setting

By default, if "home assistant" discovery topic is enabled, the sound_level topic is shown like this (just a number):

homeassistant/sensor/ID/sound_level/config
{
    "~": "nukiopener",
    "cmd_t": "~/configuration/soundLevel",
    "dev": {
        "ids": [
            "nuki_ID"
        ],
        "mdl": "Opener",
        "mf": "Nuki",
        "name": "Intercom"
    },
    "ent_cat": "config",
    "ic": "mdi:volume-source",
    "max": "255",
    "min": "0",
    "name": "Intercom Sound level",
    "stat_t": "~/configuration/soundLevel",
    "unique_id": "ID_sound_level"
}

My proposal is to move the topic from "sensor" to "number" (https://www.home-assistant.io/integrations/number.mqtt/) and include both "step" and "mode" variables like this:
homeassistant/number/ID/sound_level/config
{
    "~": "nukiopener",
    "cmd_t": "~/configuration/soundLevel",
    "dev": {
        "ids": [
            "nuki_ID"
        ],
        "mdl": "Opener",
        "mf": "Nuki",
        "name": "Intercom"
    },
    "ent_cat": "config",
    "ic": "mdi:volume-source",
    "max": "255",
    "min": "0",
    "mode": "slider",
    "step": "50",
    "name": "Intercom Sound level",
    "stat_t": "~/configuration/soundLevel",
    "unique_id": "ID_sound_level"
}

This way, the outcome in Home Assistant will look nicer with an slider (similarly to the way the volume is set into nuki's app):

I'll look into it when I find the time.


Test encoders/decoders with a non-default library context, fix up defects

This PR adds a non-default library context option to endecode_test and fixes issues caused by ciphers/digests being retrieved without a _fetch. It also adds a couple of APIs (b2i_PVK_bio_ex & i2b_PVK_bio_ex) to allow the library context and property query to be passed to where it's needed.
This work also overlaps https://github.com/openssl/openssl/pull/12694

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

Jon - can you check that you cover everything that I did in #12694. If so I will close that one..

I forget, do we have a test of implicit fetching somewhere? I noticed that the PVK code was changed to fetch RC4 explicitly, and am worried that we forget to test the implicit variants.

LGTM

Can you rebase this and clean up the commit messages that you would want to appear into the logs please.

Rebased and squashed/reworded some commits.

Please do rebase -i --autosquash again to avoid touching the fips checksums in the intermediate commits. Otherwise I suspect this will cause issues with ghmerge. Also the commit message of db8ee15 needs a cleanup.

Rebased/squashed. No other changes.

Jon - this still has the checksum in it.. Please remove

Unfortunately conflicts in libcrypto.num after the numbering added are a little bit less trivial. So perhaps another rebase should be done.

Rebased and fixed up libcrypto.num

libcrypto.num needs rebasing again..

Done

At this point, it's up to whoever merges this to clear .num conflicts.

24 hours has passed since 'approval: done' was set, but as this PR has been updated in that time the label 'approval: ready to merge' is not being automatically set.  Please review the updates and set the label manually.

Merging.

Merging.

Aargh, not merging as the conflict is now non-trivial.

Please rebase again. I'm sorry I was not fast enough with the merge.

😿

Please rebase..

Rebased.
I've modified the arguments to endecode_test to add two new named arguments for the ones merged from master (RSA and RSA-PSS key files).

Rebased to drop the spurious fips-sources.checksums change.

No need to reset the timer for the two blank lines added.

Merging

Merged to master, finally. Thank you all!

Thanks!


How do I build  gstreamer in visual studio

Please create a discussion in https://github.com/microsoft/vcpkg/discussions/new instead.

i installed gstream using vcpkg .
But it doesn't build at all in the visual studio.

Make sure the port you download is consistent with the system architecture of your vs (x64/x86).

If you are using MSBuild project, please run the command ./vcpkg integrate install then restart VS and try again.

If you are using VS's cmake project, make sure you add CMAKE_TOOLCHAIN_FILE to CMakeSettings.json , and add gstreamer useage to the top-level CMakeLists.txt.

Please see the documentation for details: https://github.com/microsoft/vcpkg/blob/master/docs/examples/installing-and-using-packages.md

i already did. but it not working

@rinechran Is this issue only for gstreamer? Or all from the ports provided by vcpkg?

i don't know about other vcpkg projects , but i checked is only gstream.

Could you  please try using the port provided by vcpkg according to doc https://github.com/microsoft/vcpkg/blob/master/docs/examples/installing-and-using-packages.md ? Perhaps we missed a step? :)

i did't miss task
After installing x64/x86 version  i did  ./vcpkg integrate install
but the build doesn't work

For port gstreamer, please use #include <gstreamer-1.0/gst/gst.h>

The build doesn't work.

For the integration of vcpkg projects, the default path is {VCPKG_INCLUDE_DIR}/${TRIPLET}/include. For my project, this value is E:\port-update\vcpkg\installed\x64-windows\include, so if you want to use gstreamer header files, each include must contain gstreamer-1.0.
Like : #include <gstreamer-1.0/gst/gstversion.h>

Have you tried compiling the header file?

:\port-update\vcpkg\installed\x64-windows\include, so if you want to use gstreamer header files, each include must contain gstreamer-1.0.

Have you tried compiling the header file?

@rinechran Yes, this is indeed a bug. For upstream behavior, the gstreamer headers should be installed under the outer folder named gst. I will fix it. :)

For me, it's not a bug.
Official builds from upstream are using the include/gstreamer-1.0/gst folder to store the include files.
And the pkgconfig files do point to the right folder:
Cflags: -I"${includedir}/gstreamer-1.0"

Are you using CMake or MSBuild in your project?

i am use MSBuild

Are you using CMake or MSBuild in your project?


fix(IAM Policy Management): add sort query parameter to List V2 Policies

PR summary
Added Sort query parameter to List V2 Policies
PR Checklist
Please make sure that your PR fulfills the following requirements:

[x] The commit message follows the Angular Commit Message Guidelines.
[x] Tests for the changes have been added (for bug fixes / features)
[x] Docs have been added / updated (for bug fixes / features)

Current vs new behavior
Did not have sort functionality for listing v2 policies, now does.
Does this PR introduce a breaking change?

[ ] Yes
[x] No

Other information

:tada: This PR is included in version 0.32.1 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


DataSaturday Edinburgh

eventname
Edinburgh
date
2023-06-03 08:00:00 -17:00
description
With the success of the Data Platform  (SQLSaturday) event on 01st FEB 2020 and to continue the community spirit the Edinburgh Data Platform user group would like to convene another major event on 03rd June 2023.

Data Saturday Edinburgh is a free-to-attend 'in-person' event (one day) for IT professionals who are keen on data platform technologies. This is a community-led event, that offers useful educational & career-supported content across the data platform, cloud computing, analytics, architecture and much more.

Thanks

Satya & Tom
registrationurl
No response
rooms
No response
scheduleurl
No response
sponsors
sponsor1link;sponsor1image;sponsor1height,sponsor2link;sponsor2image;sponsor2height,sponsor3link;sponsor3image;sponsor3height
speakerlisturl
https://sessionize.com/datasaturday-edinburgh/
volunteerrequesturl
<EMAIL_ADDRESS>organizers
Edinburgh Data Platform user group (https://twitter.com/sqlscot) is managed by Satya Jayanty (https://twitter.com/data_geek_ & Thomas Sykes (https://twitter.com/sqltomato).
For further information about the DataSaturday Edinburgh event get in touch with an email to consulting at dbia.uk.

completed by hand


Duplicate module name: react-native

This warning is caused by a @providesModule declaration with the same name across two different files.
jest-haste-map: @providesModule naming collision:
Duplicate module name: react-native
Paths: /Library/WebServer/Documents/cimbrtbmobile/node_modules/react-native/package.json collides with /Library/WebServer/Documents/cimbrtbmobile/node_modules/done-bar/node_modules/react-native/package.json

Now try it. I basically just removed a lot of junk files including the react and react-native dependencies in the package.json. Kinda bad, but you wouldn't install this package anyways if you weren't making something with RN which requires you to install react and react-native.


it's very vague ,   only me ?

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

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

Steps to reproduce the problem:
1.
2.
What is the expected behavior? (add screenshot)
What went wrong? (add screenshot)
Link to a viewer (if hosted on a site other than mozilla.github.io/pdf.js or as Firefox/Chrome extension):

It's vague. What should I do? Are there any partners to solve this problem?


[RFC] Standardized type conversion (From/Into)

I think it would be great if std could provide an answer to the question(s):

"I want type Foo that can be converted into instances of Bar"

or

"I want type Bar that can interpret instances of Bar from Foo"

The general issue is that I believe the language - compiler, std, or documentation - does not advise how to best solve these problems.
Having reviewed shards and answered a lot of questions about Crystal over the years, the lack of guidelines here has caused a bit of a mess, because Crystal gives you a lot of options to do this, and grasping which one is best isn't inferred well, according to my surveys. I feel it has been a sort of "silent issue" as everyone more or less just does their own thing.
Ecosystem Examples
Here's the most common methods that any user might pick - particularly beginners - along with some observations. Each of which may be a pro or con depending on who you ask. This is certainly not exhaustive.
Considering Foo and Bar, which may be fully or only partially compatible field-wise, and the conversion is well defined:
1. T.new(other : U) : T
class Foo
  def self.new(bar : Bar) : Foo
    a = bar.a
    b = bar.b
    # Derived or default value that bar does not provide
    c = "some string"
    Foo.new(a, b, c)
  end
end

Foo.new is overloaded, WYSIWYG (contrast with (2) below).
Private & protected access to Foo's members at the class level.
Public access to Bar's members.
Does not necessarily have to be called new.
Reuses the "default" constructor likely already defined in terms of itself, #initialize(@a, @b, @c)

2. T#initialize(other : U)
class Foo
  def initialize(bar : Bar)
    @a = bar.a
    @b = bar.b
    # Derived or default value that bar does not provide
    @c = "some string"
  end
end

Compiler's initialize magic comes into play: It defines a self.new method for you, all ivars must be initialized, etc.
A lot of users taking this approach will habitually call another initialize method from within this one if setting up the subject type is complicated, or just a lot of lines of code, in the example above they might replace the body with:

def initialize(bar : Bar)
  initialize(bar.a, bar.b, "some string")
end

Sometimes the above leads to a "tree" of initialize methods called.
Unrestricted access to self's members
Public access to Bar's members

3. T#to_u / U#to_t
class Foo
  def to_bar : Bar
    Bar.new(@a, @b)
  end
end

class Bar
  def to_foo : Foo
    Foo.new(@a, @b, "some string")
  end
end

Reserves #to_bar as a method name, since it takes no arguments.
Some users will use different naming convetions: #as_bar, #convert_to_bar, or just #bar
Unrestricted access to self's members

Examples Summary
There are others I've seen, but these are probably the 3 that most people use. My opinions on these approaches:

(1) I don't see too often. It seems to take a while for users to pick up that they can overload .new,  or they often do not end up preferring it over (2). In my opinion, this is the best out of the three. The visibility is acceptable in most if not all cases, and you get good compiler errors if the receiving initialize changes during refactoring. It makes more sense as a static method to me, and infers the existence of a basic provide-each-field constructor.

(2) Is probably the most common, but very prone to "trees of initialize" for complicated types as I mentioned. This is likely most common because that is how new users are taught to write constructors, so they don't treat a conversion like this any differently. This often leads to hard to follow code in constructors, and users running into compiler errors because they forgot to set an ivar - either when writing or in refactoring the type later, sometimes leading to inconsistent solutions. They might set the missing var, defer to another initialize, or do something like add a default argument.

(3) Slightly less common than (2). Often these users saw methods like String#to_i and followed suit for #to_xyz, or JSON::Any's #as_xyz methods. Compiler errors in refactoring should be comparable to (1). I personally don't like this over (1) as every method has a different name, and it's up to the author to be consistent, let alone between multiple authors.

Aside: I also see a lot of users trying things like String.as(Int32) before finding String#to_i. This is of course a different issue entirely, and a small roadbump in learning Crystal, but I think it shows potential value in the proposed solutions below.

Solutions
A. Generic API
My general proposal is that a generic API (as in employing generics) for type conversion should be provided in order to:

Encourage a consistent convention across the ecosystem
Allow conversion to be reasoned about

In short, allowing any library author to provide something like the following:
# Does something.
# Accepts any type that can (perhaps lazily) be converted into `Bar`.
def do_something(subject : Into(Bar))
   bar = subject.into(Bar)
   # Do things with bar
end

wherein the library user would then implement Into(Bar) for their type.
And additionally From to apply conversion the other way around. This is a little more restrictive because of Crystal's generics / inheritance model, it would have to rely on Into:
module From
  def from(other : Into(self))
    other.into(self)
  end
end

module Into(T)
  abstract def into(klass : T.class) : T
end

class Bar; end

class Foo
  extend From
  include Into(Bar)

  def initialize(@string : String)
  end

  def into(bar : Bar.class) : Bar
<EMAIL_ADDRESS>  end
end

class Bar
  extend From
  include Into(Foo)

  def initialize(@int : Int32)
  end

  def into(foo : Foo.class) : Foo
<EMAIL_ADDRESS>  end
end

bar = Bar.new(5)
p(Foo.from(bar))
p(bar.into(Foo))

foo = Foo.new("6")
p(Bar.from(foo))
p(foo.into(Bar))

From(T) would be great, but I don't think this can be expressed reasonably on the metaclass. Please feel free to correct me. I also acknowledge the general attitude towards extend, and perhaps from could be provided by other means (or not at all).
This concept is borrowed from and has been largely successful in Rust:

https://doc.rust-lang.org/stable/std/convert/trait.From.html
https://doc.rust-lang.org/stable/std/convert/trait.Into.html

There are uncountable Rust libraries that reason about From/Into in their interfaces, and it has wholly avoided this situation of "too many solutions" in Crystal.
Common methods
We can keep common conversion methods as delegations to these implementations:
class String
  include Into(Int32)

  def into(klass : Int32.class) : Int32
    # ..
  end

  def to_i
    into(Int32)
  end
end

(De)serialization
This may also help provide a more sustainable API for things like the existing Object.from_json / Object#to_json. Looking in from outside of Crystal, it is awkward having such a "specific" serialization written into every type, which per my examples above, does not set a great standard for others in the ecosystem. ("Does everyone need write #to_my_format on every type?")
I acknowledge how ubiquitous JSON is for many of Crystal's users, but it raises other aforementioned questions.
A similar general Serialize / Deserialize contract would be great to have, but that's tangent to this issue's scope - From/Into(T) could be a suitable, but maybe limiting entrypoint for some use cases:
foo.into(JSONString) # "{ .. }"

B. Improve documentation
It would otherwise go a long way to talk about these concepts in the language reference. Even if we don't conform to something in std, a "best practice" picking from something like the examples 1/2/3 above, discussing their pros/cons, or other guideline would help smooth the disparity across shards and help beginners.
I think the main pattern that should be advised against is multiple (nested) calls through initialize methods, as this has done the most harm in code that I've read in terms of readability and maintenance burden.

That's about it - thanks for reading.
I recognize the current conversion idioms stem from Ruby. As someone who came from Ruby, to Crystal, and then to Rust - coming back to Crystal for some projects has left consistency like this to be desired where it would be possible for std types to do more.

I think one of the problems is communicating the difference between overloading #initialize vs. overloading .new. This should probably be discussed in learning materials. So a big YES to solution B.
Essentially, most overloads should be for .new, especially for the use cases discussed here. However, there might also be rare cases where initializing an instance from a different type requires some customized behaviour that must be implemented in a #initialize. So in general (1) and (2) could be seen as the same thing and (1) should be most commonly used.
At least in theory, (3) should be pretty straightforward actually. The regular naming scheme is to_#{type}. to signals a conversion and is followed by the target of the conversion. Optional qualifiers can be used for clarification.
Such a method should explicitly not be called as, because as is used to describe a cast (i.e. changing the interpretation of a value) whereas to means a conversion (i.e. changing the value). #to_bool returns the value converted to Bool, whereas #as_bool returns the value interpreted as Bool.
IMO both methods are suitable and there's not clear benefit to either of them. I suppose it mostly depends on which side offers the conversion logic, the source or the sink. This is especially relevant when both are in different code bases.
I actually don't see a direct connection between your problem description and solution A. The examples are all about explicit methods for converting between types, but solution A is about a mechanism for implicit conversions. Let's not confuse that. In some cases, explicit conversions might also work implicitly and maybe are only explicit because there's no implicit one. But more often than not, implicit conversions are not a solution. Converting between types usually creates some kind of friction. If the types were equivalent, there wouldn't be a reason to have distinct types.
So I'm not quite sure how useful a generic mechanism for implicit conversions would actually be.
I'd be interested in real world examples for Rust's From and Into, though. The example for From is about error handling, which is already pretty different in Crystal.

I would not agree about a general API to convert between types, it's very easy to lose track of semantics then. Surely there won't always be exactly one way to interpret one type as the other?

@straight-shoota Yep; fully agree on your first two paragraphs. The only way I've come to that same conclusion is just by reading lots and lots of code and feeling the pitfalls of the other methods :smile_cat:
So yeah, an addendum to the language reference I think would be a great minimum action here.

I actually don't see a direct connection between your problem description and solution A.

The connection is just that it bakes a solution for performing conversions into the standard library instead of by having to teach a recommended method and hope that users follow it, as well as being able to reason about conversions.
It takes any question out of something like foo.to_s - what is "s"? and in turn makes it an explicit foo.into(String)
You might have something like a socket wrapper for an API that lets you send some raw data:
def send(data : Into(Bytes))
  # ..
end

Thus clearing the callsite:
socket.send(my_object)

and not relying on duck typing something like #to_slice, since you can only document something like that in a comment.
Even if the compiler tells you "Error: undefined method 'to_slice' for Foo", that doesn't give you enough feedback to know what to_slice needs to return; you have to read the source or documentation. Restricting on Into(T) tells you exactly what you need to implement, and there is no debate about how to implement it, what to name the method, etc.
I'm out of time at the moment so I can't dig out some good rust examples. Will try to check back in later.

Reuses the "default" constructor likely already defined in terms of itself, #initialize

Please note that #initialize isnt a constructor but an initializer; it initializes previously allocated memory. .new is the constructor: it allocates then calls initialize (among other things). There should be as many constructors as needed, but only one (or a few) initializers.
Maybe I don't understand the problem/proposal, but from/into sounds like unrequited complexity. Its moving construction of a type A to another type B (into), but eventually brings it back with a delegation to B constructing A (from -> into) which is working backwards, or is far too formal for Crystal.
Each type should construct/initialize itself, but it all depends on the API logic. Crystal, like Ruby, is very flexible but follows conventional rules:

Do we create A from B? Then we expect A to handle that logic in a constructor (.new, .from or preferably an explicit name), for example Debug::ELF.read(io). Having IO#into(Debug::ELF) would pollute IO, in addition to moving the constructor logic where it doesn't belong.
Do we transform B into A? Then B is responsible to build A (and A doesn't care about B) and we expect B to have a #to_a method that will construct an A, for example Time#to_unix. Having Int64.from(Time) makes no sense (what would we expect the i64 number to be?).
Do we interpret B as being an A? Then similarly we expect B to have a #as_a method that casts B to A, for example JSON::Type#as_s. Again, having a String.from(JSON::Type) would be very confusing (transform? inspect?), and JSON::Type.into(String) would imply a transformation when there is none.

Now, from/into may have some usages, but it's impossible to understand them with generic Foo Bar classes and no concrete use cases. I don't see the benefit. The String to Int32 is hardly convincing, dince there is already the much simpler #to_i idiom and adding #into(Int32) would introduce a duplication...

I believe the purpose of this was to try and find a Crystal solution to the interface problem. Rust solves this problem with Traits, but in Crystal all we have is modules. Modules aren't a terrible solution, but take this example:
require "json"

module Jsonable
  abstract def to_json(json : JSON::Builder)
end

class FooBar
  getter foobar : Array(Jsonable)

  def initialize(@foobar)
  end
end

arr = [] of Jsonable
arr << "Hello"
arr << 3.14
arr << {"1", "2", 3}

fb = FooBar.new(arr)
pp fb

This code will not compile because String, Float64, and Tuple(*T) don't include the Jsonable module. Even though it's very clear to the user what should happen, without explicitly opening every type that fits the interface there's no way to make this code work.
One solution would be to do exactly what's being proposed here, or some variation of it. I kind of like it, because it seems like a more Crystally solution. Another option would be to create an Interface type for generic structures like this. Then you could define interfaces like this:
interface Jsonable
  abstract def to_json(json : JSON::Builder) : String
end

The benefit I see to this approach is that it doesn't really require breaking changes, or any changes really to the standard library besides adding this itself. It puts the burden of implementation itself on the user, which they can do as needed.
In my humble opinion Crystal does need something like this though, as strict as its type system is. I can think of tons of examples off the top of my head where, in my own code, having interfaces would save me a lot of trouble.

Wouldn't you still need to implement this interface on every type that fits it?  At which point you could use a module and get the same effect?

@Blacksmoke16 that's the thing. The whole idea of the interface type would be so you don't have to implement it everywhere. Instead it should be considered a limited subset of all types that define the requisite methods. So in my Jsonable example it would accept any type that has a #to_json method matching the signature provided, and that would be the only method available when using it as a type. So:
interface Numeric
  abstract def to_i : Int32
end

class Foo
  def initialize(@bar : Numeric)
    # this should work
    puts @bar.to_i

    # this should either not work, or be dependent on the types being passed in.
    puts @bar.to_s
  end
end

Ahh, gotcha.  Essentially like a fancy alias that resolves to types that match it.

Essentially yes. This would make some types a lot easier to handle like, as in the above case, the situation where you just want something that resembles an Int32 and can be cast to one. Saves you having to know every possible type that can be cast to an Int32 and make an alias for it.
It could get even more complicated as you add additional types though. To the point where an alias would have to be very specific, and most definitely wouldn't cover user defined types.

The difference with crystal is you can reopen any class and make it implement a module anywhere in your code. You don't need "permission" like in many other languages, so an explicit include is fine.

Relaying a thought from Gitter:
One thought I had at some point was introducing the concept of an actual interface.
interface StringConverter
  def convert(value : String) : String
end

Essentially this would be the same thing as:
module StringConverter
  abstract def convert(value : String) : String
end

but would assume methods to be abstract, and prevent you from defining actual methods/types within it.  Only methods/constants.  Usage would be similar to modules but would be like
class ReverseConverter
  implement StringConverter
end

Benefits are I suppose it makes intent more clear, plus preventing someone from adding stuff to your interface.  If it's worth the extra logic in the compiler and such for, I've yet to be convinced.

My main point is that there are cases in which you don't want to, or aren't able to, monkey patch all the classes you may want. Also monkey patching is considered an anti-pattern is it not? I've heard it both ways.

@Blacksmoke16 I can see litteraly no benefit at all with that approach. It's just another syntax for what already exists and it's only more restrictive, less flexible.
I kind of like the idea of automatically matching interfaces. I'm not sure they make sense even exploring, let alone introducing it to the language. But it may be a useful feature.
It can be understood as an extension to responds_to which takes several methods into account. And that fits pretty well with the duck-typing approach. Often it's not sufficient to see if something can quack but you also need some other properties to treat it as a duck.

That's exactly my point @straight-shoota, thanks for laying it out more eloquently than I could

If we were making crystal from scratch, it'd probably be a good idea.
Unfortunately, it doesn't mean it's a good idea to introduce it unless we remove something else...

Related https://github.com/crystal-lang/crystal/issues/12643

into there refers to this, it has nothing to do with general object conversion.

My example here does not explicitly reference generic object conversion but seemed like it could be generalised with some more thought.
It does look like the From trait in rust does cover conversions between collection types, see this method from an array to HashSet


develop a password toggle icon in signup form

Develop a new password toggle icon for signup form (same as like in login page)
Login page-

Signup page-

Node: The password toggle feature should be there in both,  password field as well as confirm password field.

@SHIVAA17 assigning

is this issue still open ?.

yes go ahead @ramith-kulal


Callfixup for _guard_dispatch_icall on x86-64-win

The added callfixup allows the Decompiler to correctly recognize CFG function targets.
This implements the suggested changes from issue #318.

Sorry, this referenced the wrong file.


Update Hyde::asset() method to consider protocol relative URLs // to be remote

We may also want to check we use this across the board.
The featured image class uses the following: (Maybe we move it to the Hyperlinks class?)
public static function isRemote(string $source): bool
{
    return str_starts_with($source, 'http') || str_starts_with($source, '//');
}

## Claude naming response

Given the context you've provided about HydePHP, its philosophy, and target audience, let's reconsider the method name. The current name `isRemote` is concise, but we might be able to make it even more intuitive and self-explanatory.

Here are some alternative suggestions for the method name, along with their pros and cons:

1. `isExternalUrl`
   Pros: Clearly indicates that it checks if a URL is external to the site.
   Cons: Slightly longer than `isRemote`.

2. `isOffSiteLink`
   Pros: Intuitive for both developers and non-developers.
   Cons: Uses "link" which might be less precise than "URL".

3. `isExternalResource`
   Pros: Comprehensive, covering both URLs and other types of external resources.
   Cons: Might be too broad for its specific function.

4. `pointsToExternalSite`
   Pros: Very descriptive and clear about what it does.
   Cons: Longer than the other options.

5. `isOutboundUrl`
   Pros: Concise while still being clear about its purpose.
   Cons: "Outbound" might be less immediately understood by some users.

Considering HydePHP's motto "Simplicity first. Power when you need it. Quality always." and the focus on intuitive APIs, I would recommend `isExternalUrl` as the best balance between clarity and conciseness.

This name:
1. Is self-explanatory, even for users less familiar with web development terminology.
2. Clearly indicates that it's checking if a URL points to an external resource.
3. Uses "URL" which is more precise than "link" or "resource".
4. Is not overly verbose while still being descriptive.

I think isRemote is best still out of these


jenkins: add jenkinsuriprefix in healthprobes

What this PR does / why we need it:
Add support for the JenkinsUriPrefix within healthprobes
Special notes for your reviewer:

assign @lachie83

/assign @viglesiasce

/lgtm


Bug fix: properly memoize @empty in MessageSet

This tiny pull request fixes that @empty in MessageSet is not properly memoized.

On reflection, the value is only not memoized when it's cheap to compute, so it's not worth the harder to read code.


Increment version for marketplaceordering releases

Increment package version after release of Azure.ResourceManager.MarketplaceOrdering

API change check
API changes are not detected in this pull request.


500 error CSRF with Discord auth at /authenticate/callback/

(mismatching_state) CSRF Warning! State not equal in request and response.

Reported on decksite by<PHONE_NUMBER>61794304
Request Method: GET
Path: /authenticate/callback/?state=bEDHdSXnuqH8xZUEiHIQbBu2zlGg9x&code=uAzfG4130wr7JZJveIdzbonasLW6QQ
Cookies: {'session': '.eJxFT11PgzAU_S_3mZgWCt14dJvzAUSGS0SzkAbKqALFtujYsv--zkT3eM89nydgVSd6CI0auQOighBc7BFC_RlCAaZz4iECDkg2msYttGGGWw5OaLxtmJfj12HZPsRUruOnGakjfOjy4cY38pNb9xOwsuRa_90g2nTj5_G3zCaWRPEiWWc_wTI1Cz312dHq-WEQiuuCGQix7yI6x9Snd64fUIzp7X_tHiBiyzqgeG2h5j_k42Wbd_XmuU7eUjRGXjcdkXxcka9BRb1rQ3QpB7vm3e7mvRH1ZLH9KNpKw86BX5vCTFcK3HOmuIKzhZnac9uqH9v2fAFOwmZq.DX3HzQ.Ftn_UXbJyqmEZLYt0nk_vGJNlBI', 'hide_intro': 'True', '_gid': 'GA1.2.763828725.1519321240', '_ga': 'GA1.2.933953544.1509624455', '__cfduid': 'd06ce468ef6cdfc142fcb630c713ca9071513922051'}
Endpoint: authenticate_callback
View Args: {}
Person:<PHONE_NUMBER>61794304
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.36 Edge/16.16299
Referrer: https://discordapp.com/oauth2/authorize?response_type=code&client_id=338056190779195392&redirect_uri=https%3A%2F%2Fpennydreadfulmagic.com%2Fauthenticate%2Fcallback%2F&scope=identify+guilds&state=bEDHdSXnuqH8xZUEiHIQbBu2zlGg9x
Request Data: {}
MismatchingStateError
Stack Trace:
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1997, in call
return self.wsgi_app(environ, start_response)
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1985, in wsgi_app
response = self.handle_exception(e)
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1982, in wsgi_app
response = self.full_dispatch_request()
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1614, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1517, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/home/discord/.local/lib/python3.6/site-packages/flask/_compat.py", line 33, in reraise
raise value
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1612, in full_dispatch_request
rv = self.dispatch_request()
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1598, in dispatch_request
return self.view_functionsrule.endpoint
File "./decksite/main.py", line 437, in authenticate_callback
auth.setup_session(request.url)
File "./decksite/auth.py", line 26, in setup_session
authorization_response=url)
File "/home/discord/.local/lib/python3.6/site-packages/requests_oauthlib/oauth2_session.py", line 187, in fetch_token
state=self._state)
File "/home/discord/.local/lib/python3.6/site-packages/oauthlib/oauth2/rfc6749/clients/web_application.py", line 174, in parse_request_uri_response
response = parse_authorization_code_response(uri, state=state)
File "/home/discord/.local/lib/python3.6/site-packages/oauthlib/oauth2/rfc6749/parameters.py", line 230, in parse_authorization_code_response
raise MismatchingStateError()

(mismatching_state) CSRF Warning! State not equal in request and response.

Reported on decksite by logged_out
Request Method: GET
Path: /authenticate/callback/?state=0OXiv6rb6oydcZodjLy3ykCKBylc3l&code=Vb0tNh4WxMLi0YfrZ5ljd4Sgp14LIX
Cookies: {'__cfduid': 'd4905adc32b25216588444ef4879c76bb1520090251', '_ga': 'GA1.2.1250417062.1520092435', '_gid': 'GA1.2.322534249.1520092435', 'session': 'eyJvYXV0aDJfc3RhdGUiOiJYZnRHdVRQREFneUlJQXp3Mk9XU3I4dUVrRnRGQ3oiLCJ0YXJnZXQiOiJodHRwczovL3Blbm55ZHJlYWRmdWxtYWdpYy5jb20vcmV0aXJlLyJ9.DX7-FA.mRCss5KHRonccH7IxkjlBPR4dyA'}
Endpoint: authenticate_callback
View Args: {}
Person: logged_out
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.186 Safari/537.36
Referrer: https://discordapp.com/oauth2/authorize?response_type=code&client_id=338056190779195392&redirect_uri=https%3A%2F%2Fpennydreadfulmagic.com%2Fauthenticate%2Fcallback%2F&scope=identify+guilds&state=0OXiv6rb6oydcZodjLy3ykCKBylc3l
Request Data: {}
MismatchingStateError
Stack Trace:
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1997, in call
return self.wsgi_app(environ, start_response)
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1985, in wsgi_app
response = self.handle_exception(e)
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1982, in wsgi_app
response = self.full_dispatch_request()
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1614, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1517, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/home/discord/.local/lib/python3.6/site-packages/flask/_compat.py", line 33, in reraise
raise value
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1612, in full_dispatch_request
rv = self.dispatch_request()
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1598, in dispatch_request
return self.view_functionsrule.endpoint
File "./decksite/main.py", line 437, in authenticate_callback
auth.setup_session(request.url)
File "./decksite/auth.py", line 26, in setup_session
authorization_response=url)
File "/home/discord/.local/lib/python3.6/site-packages/requests_oauthlib/oauth2_session.py", line 187, in fetch_token
state=self._state)
File "/home/discord/.local/lib/python3.6/site-packages/oauthlib/oauth2/rfc6749/clients/web_application.py", line 174, in parse_request_uri_response
response = parse_authorization_code_response(uri, state=state)
File "/home/discord/.local/lib/python3.6/site-packages/oauthlib/oauth2/rfc6749/parameters.py", line 230, in parse_authorization_code_response
raise MismatchingStateError()

First person here was Back_Alley_G so will try and find out from him if he failed to Discord id recently and if he remembers why/what happened. I assume a stale page or some back button shenanigans?

No further occurrences so closing.

500 error at /authenticate/callback/

(mismatching_state) CSRF Warning! State not equal in request and response.

Reported on decksite by tidalslimshady

Request Data ```
Request Method: GET
Path: /authenticate/callback/?state=t0KHgEqfqJVMCD7oMIw5vajfbrnHET&code=5eeuGKWcBG5Kh7HxQC7vLG0U0X7lyJ
Cookies: {'__cfduid': 'd743ebfd29dbccfe3792e8230835e91bd1551782848', 'session': '.eJx9UctugzAQ_BefUQUYgsktSGmolFZNUtKXKuRiA06wobapkkb59y6RWg6Vepyd3dmd2RPKO64lVVxZNLW65w6iTAqFpiVtDCDGpZAtG7EwRatZLqCEAuLGXuD7OAjjyI8D30UO-odRedWLZhRr2qribDjBtOoiiX0ycZC0VZv3hmtFJQc1KxgMNEKamrIjKLW0t7WfG0vtwJcmnT0cnpos2-4if_6x2hdq_XmDH-Vyxb7GftvuOVg7IVoU3JgfjKJ4n22SRWdFP_N3i_fnxFt-RvNtlqUEezDPD53Q3OQUUvLCEAeRhwm5CjCJ4wiP_BDcxAXzroM0L6FU_y5ZX-sdDuMX756E6Ty73Ry3PJkl9fJARHoHSyDYDty8QoLwDlEORi95GfTmoItMbo9DC0o41Vyjs4P-ZGeprjicqfqmOX8DsuaZzA.D3BusA.3W9jLkX9zhsQlE8hkOTpUcvjrak'}
Endpoint: authenticate_callback
View Args: {}
Person:<PHONE_NUMBER>59729420
Referrer: https://discordapp.com/oauth2/authorize?response_type=code&client_id=338056190779195392&redirect_uri=https%3A%2F%2Fpennydreadfulmagic.com%2Fauthenticate%2Fcallback%2F&scope=identify+guilds&state=t0KHgEqfqJVMCD7oMIw5vajfbrnHET
Request Data: {}
Host: pennydreadfulmagic.com
Accept-Encoding: gzip
Cf-Ipcountry: CA
X-Forwarded-For: <IP_ADDRESS>, <IP_ADDRESS>
Cf-Ray: 4b92de554b30ca55-YUL
X-Forwarded-Proto: https
Cf-Visitor: {"scheme":"https"}
Upgrade-Insecure-Requests: 1
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.121 Safari/537.36
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,/;q=0.8
Referer: https://discordapp.com/oauth2/authorize?response_type=code&client_id=338056190779195392&redirect_uri=https%3A%2F%2Fpennydreadfulmagic.com%2Fauthenticate%2Fcallback%2F&scope=identify+guilds&state=t0KHgEqfqJVMCD7oMIw5vajfbrnHET
Accept-Language: en-US,en;q=0.9
Cookie: __cfduid=d743ebfd29dbccfe3792e8230835e91bd1551782848; session=.eJx9UctugzAQ_BefUQUYgsktSGmolFZNUtKXKuRiA06wobapkkb59y6RWg6Vepyd3dmd2RPKO64lVVxZNLW65w6iTAqFpiVtDCDGpZAtG7EwRatZLqCEAuLGXuD7OAjjyI8D30UO-odRedWLZhRr2qribDjBtOoiiX0ycZC0VZv3hmtFJQc1KxgMNEKamrIjKLW0t7WfG0vtwJcmnT0cnpos2-4if_6x2hdq_XmDH-Vyxb7GftvuOVg7IVoU3JgfjKJ4n22SRWdFP_N3i_fnxFt-RvNtlqUEezDPD53Q3OQUUvLCEAeRhwm5CjCJ4wiP_BDcxAXzroM0L6FU_y5ZX-sdDuMX756E6Ty73Ry3PJkl9fJARHoHSyDYDty8QoLwDlEORi95GfTmoItMbo9DC0o41Vyjs4P-ZGeprjicqfqmOX8DsuaZzA.D3BusA.3W9jLkX9zhsQlE8hkOTpUcvjrak
Cf-Connecting-Ip: <IP_ADDRESS>
Cdn-Loop: cloudflare
X-Forwarded-Host: pennydreadfulmagic.com
X-Forwarded-Server: pennydreadfulmagic.com
Connection: Keep-Alive

</details>
--------------------------------------------------------------------------------
<details><summary>
MismatchingStateError
(mismatching_state) CSRF Warning! State not equal in request and response.
</summary>
Stack Trace:
Python traceback
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 2309, in call
return self.wsgi_app(environ, start_response)
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 2295, in wsgi_app
response = self.handle_exception(e)
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 2292, in wsgi_app
response = self.full_dispatch_request()
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1815, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1718, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/home/discord/.local/lib/python3.6/site-packages/flask/_compat.py", line 35, in reraise
raise value
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1813, in full_dispatch_request
rv = self.dispatch_request()
File "/home/discord/.local/lib/python3.6/site-packages/flask/app.py", line 1799, in dispatch_request
return self.view_functionsrule.endpoint
File "./shared_web/flask_app.py", line 97, in authenticate_callback
oauth.setup_session(request.url)
File "./shared_web/oauth.py", line 27, in setup_session
authorization_response=url)
File "/home/discord/.local/lib/python3.6/site-packages/requests_oauthlib/oauth2_session.py", line 208, in fetch_token
state=self._state)
File "/home/discord/.local/lib/python3.6/site-packages/oauthlib/oauth2/rfc6749/clients/web_application.py", line 203, in parse_request_uri_response
response = parse_authorization_code_response(uri, state=state)
File "/home/discord/.local/lib/python3.6/site-packages/oauthlib/oauth2/rfc6749/parameters.py", line 271, in parse_authorization_code_response
raise MismatchingStateError()

</details>
Exception_hash: b1e0b4491d6eb60c6eb30b28b4d0eb6e0ee0982e

Labels: decksite; MismatchingStateError


 This fixes it.

@ryanshrum This is the same fix as https://github.com/ryanshrum/hacksaw/pull/2 (u modifier for preg functions to handle multibyte characters properly) but applied everywhere.


Add back Get-HotFix cmdlet

PR Summary
Re-enable Get-HotFix cmdlet on Windows.  Since the WmiHelper class relies on WMI cmdlets, rewrote the code a bit to not use it.  Added tests that depend on Win32_QuickFixEngineering WMI class returning results.  Removed a bunch of referenced namespaces in the original source file that aren't needed as well as an old comment.
PR Context
Fix https://github.com/PowerShell/PowerShell/issues/2296
PR Checklist

[x] PR has a meaningful title

Use the present tense and imperative mood when describing your changes

[x] Summarized changes
[x] Make sure all .h, .cpp, .cs, .ps1 and .psm1 files have the correct copyright header
[x] This PR is ready to merge and is not Work in Progress.

If the PR is work in progress, please add the prefix WIP: or [ WIP ] to the beginning of the title (the WIP bot will keep its status check at Pending while the prefix is present) and remove the prefix when the PR is ready.

Breaking changes

[x] None
OR
[ ] Experimental feature(s) needed

[ ] Experimental feature name(s):

User-facing changes

[ ] Not Applicable
OR
[x] Documentation needed

[x] Issue filed: https://github.com/MicrosoftDocs/PowerShell-Docs/issues/4908

Testing - New and feature

[ ] N/A or can only be tested interactively
OR
[x] Make sure you've added a new test if existing tests do not effectively test the code changed

Tooling

[x] I have considered the user experience from a tooling perspective and don't believe tooling will be impacted.
OR
[ ] I have considered the user experience from a tooling perspective and enumerated concerns in the summary. This may include:

Impact on PowerShell Editor Services which is used in the PowerShell extension for VSCode (which runs in a different PS Host).
Impact on Completions (both in the console and in editors) - one of PowerShell's most powerful features.
Impact on PSScriptAnalyzer (which provides linting & formatting in the editor extensions).
Impact on EditorSyntax (which provides syntax highlighting with in VSCode, GitHub, and many other editors).

Should this just re-written over MMI / CIM APIs, seems simple enough? It would be like:
[cimsession]::Create('localhost').QueryInstances("root/cimv2", 'WQL', 'select * from Win32_QuickFixEngineering')

or
[cimsession]::Create('localhost').QueryInstances("root/cimv2", 'WQL', 'select * from Win32_QuickFixEngineering where hotfixid="KB4514359"')

@adityapatwardhan doesn't seem to provide much benefit to rewrite.  We could have rewrote it in PS6 timeframe as it would have made sense then.

Tiny Codacy issue in new code should be fixed.
Btw, is there info on when (approximately:year/PSVersion) Get-HotFix was removed?

@anmenaga Get-HofFix was removed from PSCore6.0 because the System.Management namespace wasn't available.

Out of interest: Is there a list of issues or tags for low hanging fruits of cmdlets that can now be brought back relatively easily?

@bergmeister probably this one at least for Utility module: https://github.com/PowerShell/PowerShell/issues/2123, there's a few open issues on specific cmdlets.  I already have a PR open for Clipboard cmdlets.

Updated comment there https://github.com/PowerShell/PowerShell/issues/2123#issuecomment-341996659

Also DefaultCommands.Tests.ps1 is good source.


Add desktop wpf article for templates

Summary
Add new article about templates
Fixes #13471
Internal previews

styles-templates-create-apply-template
styles-templates-overview#visual-states

Todo

[x] Convert code to samples repo
[ ] Remove article (and backlinks) that is redirected to the new one.

@gewarren

Got the code snippets fixed so they render
Edited the TOC for the deleted file to route to the new file
Updated the links to the old file to the new file
Renamed the file to remove the two mentions of template

LGTM!


remove duplicate code for footer in UI, extend common footer template

remove duplicate code for rendering footer and extend common footer template for flexibility for different layout and different logo image

@achen2401  I realize this branch is already merged, but I'm wondering why we have all this footer code in those three files and not in layout.html?

Paul, they should all be in one single file, flask/_macro.html now, instead of all these three different places before.  I removed the duplicate code.  Layout.html call the footer macro from flask/_macro.html.


Omit fractional seconds from date-time format

Motivation and Context
Closes #2831.
Description
Fractional seconds will still be accepted during parsing, but not emitted during serialization.
Testing
./gradlew codegen-core:check codegen-client:check codegen-server:check codegen-client-test:check codegen-server-test:check

Checklist

[x] I have updated CHANGELOG.next.toml if I made changes to the smithy-rs codegen or runtime crates

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

doesn't need to be in this PR, but we should also add an S3-specific protocol test for https://github.com/awslabs/aws-sdk-rust/issues/818
Can you also link to aws-sdk-rust#818 from the changelog?
It would be good to also verify that that API actually works after this change.
We should also contribute a protocol test upstream that mandates this behavior—currently there are non that I'm aware of.


unable to create redis container.

environment:

Ubuntu 20.04

While running this command:  python scripts/initialize_redis_oss.py

Error Path : consoleme\consoleme\celery\celery_tasks.py

Hello, thank you for the issue.
Were you able to successfully start the Redis/Dynamo local docker containers?
First run:
docker-compose -f docker-compose-dependencies.yaml up -d
Then run docker ps and ensure that the two containers are running:

Since you're using Ubuntu, make sure you're following the Docker installation instructions here if you're having trouble with it: https://docs.docker.com/engine/install/ubuntu/

Thanks a lot, @castrapel. It worked... ❤


turn around

Is there a convenient way to rotate a camera around an object/mesh with Makie ?
Not really an issue, sorry.

There is the rotation keyword. I also just added some convenience functionality to create subscenes with shared attributes:
using Makie, GeometryTypes

scene = Scene()

# create a subscene from which the next scenes you will plot
# `inherit` attributes. Need to add the attribute you care about,
# in this case the rotation
sub = Scene(scene, rotation = Vec4f0(0, 0, 0, 1))

meshscatter(sub, rand(30) + 1.0, rand(30), rand(30))
meshscatter(sub, rand(30), rand(30), rand(30) .+ 1.0)
r = linspace(-2, 2, 4)
Makie.axis(r, r, r)
center!(scene)

axis = Vec3f0(0, 0, 1)
io = VideoStream(scene, homedir()*"/Desktop/", "rotation")
for angle = linspace(0, 2pi, 100)
    sub[:rotation] = Makie.qrotation(axis, angle)
    recordframe!(io)
    sleep(1/15)
end
finish(io, "gif")

This is exactly what I was looking for! Wonderful.

Since recent updates, I am not able anymore to produce a video. Above example gives
for angle = linspace(0, 2pi, 100)
           sub[:rotation] = Makie.qrotation(axis, angle)
           recordframe!(io)
           sleep(1/15)
       end
ERROR: write: broken pipe (EPIPE)
Stacktrace:
 [1] try_yieldto(::Base.##296#297{Task}, ::Task) at ./event.jl:189
 [2] wait() at ./event.jl:234
 [3] uv_write(::Base.PipeEndpoint, ::Ptr{UInt8}, ::UInt64) at ./stream.jl:811
 [4] unsafe_write(::Base.PipeEndpoint, ::Ptr{UInt8}, ::UInt64) at ./stream.jl:832
 [5] write(::Pipe, ::Array{ColorTypes.RGB{FixedPointNumbers.Normed{UInt8,8}},2}) at ./io.jl:318
 [6] recordframe!(::Makie.VideoStream) at $HOME/.julia/v0.6/Makie/src/plotsbase/output.jl:92


Create a Iter8 Tekton task

[ ] Similar to the kn task, make sure an Iter8 Tekton task shows up in the public Tekton task catalog, with a clear example

Apparently, there is a separate RH OpenShift Pipelines task catalog. Find out where it is. Find out upstream relationship. Find out how to make Iter8 show up in the RH catalog.

no longer relevant; use helm


jetbrains: add mainPrograms

Motivation for this change
I need to unset DESKTOP_STARTUP_ID on jetbrain IDE startup to make @fctorial's https://github.com/fctorial/enter_nix_shell work to its full potential. In order to do the wrapping in overrides generically, I needed the IDEs' executable names.
Also, did some cleanup.
Things done

[x] Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
Built on platform(s)

[x] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[x] Tested execution of all binary files (usually in ./result/bin/)
[ ] Added a release notes entry if the change is major or breaking
[x] Fits CONTRIBUTING.md.

I have no idea why ofBorg fails to find the attr, nix eval -f . jetbrains.jdk.meta.mainProgram works just fine on my checkout.

/marvin opt-in
/status needs_reviewer

@Atemu please fix the eval error.

The problem is, I can't reproduce the eval error. Are you able to?

The problem is, I can't reproduce the eval error. Are you able to?

I think meta.mainProgram is missing here https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/compilers/openjdk/darwin/11.nix#L73 when evaling on darwin.

Ahh, Darwin's openjdks' meta were basically non-existent; fixed that.


HELP

Sir I also want to make such app, so could you please tell how should I proceed?
Is there any video tutorial for it or something?
Please help sir

There a lot of free resources and courses, choose what works for you and learn after you learn the basics start building simple apps.


Line on bottom of top taskbar when transparent mode is set

Appears when transparent mode is set and maximised window is open.

@VlaDosWOW Yes, this a thing caused by chromium. I can't do anything about that.


Add descriptions to Babel outputs for one data source

This is intended to be an initial attempt to include descriptions in NodeNorm. If we can make this work for one data source, we can extend it to others.

@cbizon recommends MONDO as a good place to start.


Fixed next working on last page table widget

Description
Added the disable condition on onClick event
PR fixes following issue(s)
Fixes #22477
Type of change

Bug fix (non-breaking change which fixes an issue)

Testing

How Has This Been Tested?

[ * ] Manual

Test Plan

Drag & drop a Table widget
Run a server side pagination query SELECT * FROM users ORDER BY id LIMIT {{Table2.selectedRow.pageSize}} offset {{Table2.pageOffset}}
Enable server side pagination and configure onPageChange & Total records
Reach to last page of the table records

Checklist:
Dev activity

[ ] My code follows the style guidelines of this project
[ ] I have performed a self-review of my own code
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
[ ] My changes generate no new warnings
[ ] 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
[ ] PR is being merged under a feature flag

QA activity:

[ ] Speedbreak features have been covered
[ ] Test plan covers all impacted features and areas of interest
[ ] Test plan has been peer reviewed by project stakeholders and other QA members
[ ] Manually tested functionality on DP
[ ] We had an implementation alignment call with stakeholders post QA Round 2
[ ] Cypress test cases have been added and approved by SDET/manual QA
[ ] Added Test Plan Approved label after Cypress tests were reviewed
[ ] Added Test Plan Approved label after JUnit tests were reviewed

@keyurparalkar can you check this pr?

CC @somangshu

@somangshu I will take this up, add a cypress test to it and move it to QA

@keyurparalkar re-raise it internally if required to avoid hassle managing this external PR

/ok-to-test

/build-deploy-preview

@harrybasra95 @keyurparalkar
I can still observe the issue on the generated DP
https://www.loom.com/share/9c41f3a963894fc0a93348b8dc749038?sid=d680eb4d-d528-4b4c-89ee-eeaf29d39cd6

Closing this PR since there wasn't any activity from the contributor. Will raise the PR and move forward.


Numerical Noise buildup in NCERK

The noise in interpolation between timesteps seems to build up over time. This should not happen since the polynomials are fixed.

Numerical noise is highly reduced if Jansen-Rit population potential is plotted instead of rate. This probably means that the error is introduced in the conversion.

A huge part of the numerical error was introduced while streaming to the output file. Setting the precision to the max number of significant digits solved the issue.
Rate (timestep = 2ms):

This was an output bug. Setting the parameters of the oscillators to double does not substantially affect the precision. Parameters are kept to be float.


[Feature Request] Undo last paste/edit to Signature List or Intel

As title says, having an undo of even just a single edit would be useful for accidental pastes or edits. If ctrl-z could be a shortcut, even better.

I second this!

Thanks for the attention. @exodus4d any plans here?


Handle didUpdateWidget for _StackNavigator when using a global key

Problem
We found a bug where using a GlobalKey for the PageStackNavigator.navigatorKey causes the internal _StackNavigator to fail to re-assign itself to the internal page stack. This issue presented itself as the Android back button failing to close non-routemaster routes (like a bottom sheet) and instead just closing the entire app.
Inside the PageStackNavigatorState, any time the PageStack changes, it'll invoke a function that recreates the _StackNavigator widget. Without a key, this would cause the navigator widget to run initState, thus setting itself on the PageStack. However, with a key, the state object is re-used, so initState (and dispose) are never called.
This is problematic because if you provide a navigator key for hooking into the navigator throughout your app, the PageStack can change but the _StackNavigator's state functions are never called and thus pop() calls for non-routemaster routes will ultimately return false, causing the app to close.
Solution
To solve this, all we need to do is override _StackNavigatorState.didUpdateWidget and handle the scenario of the internal stack changing -- if it changes, then drop the old navigator reference and add a new navigator reference to the new page stack.
FYI @tomgilder

Bump @tomgilder

Bump @tomgilder

Bump @tomgilder

Cc @tomgilder