.startsWith function added back

Is your feature request related to a problem? Please describe.
Yes, I have been trying to find a way to add a leaderboard.
Describe the solution you'd like
Readd the .startsWith() function
Describe alternatives you've considered
Searching google for an alternative but all I got was to loop the guild members.
Additional context
None

@Conutik
if (!String.prototype.startsWith) {
    Object.defineProperty(String.prototype, 'startsWith', {
        value: function(search, rawPos) {
            var pos = rawPos > 0 ? rawPos|0 : 0;
            return this.substring(pos, pos + search.length) === search;
        }
    });
}

Try that. It's a polyfill from https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/startsWith

I dont understand hhow to use it

@Conutik
if (!String.prototype.startsWith) {
    Object.defineProperty(String.prototype, 'startsWith', {
        value: function(search, rawPos) {
            var pos = rawPos > 0 ? rawPos|0 : 0;
            return this.substring(pos, pos + search.length) === search;
        }
    });
}

Try that. It's a polyfill from https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/startsWith

In basic terms, copy and paste it in your main file, or before wherever you need to use .startsWith().

ok

`const { MessageEmbed } = require("discord.js")
const { cyan } = require("../../colours.json");
const db = require('quick.db');
module.exports = {
config: {
name: "top",
description: "Test The Bot",
usage: "To annoy kiddoz who want to ping me",
category: "miscellaneous",
accessableby: "Members"
},
run: async (bot, message, args) => {
let money = db.startsWith(`scores_${message.guild.id}`, { sort: '.data'})
let content = "";

if (!String.prototype.startsWith) {
Object.defineProperty(String.prototype, 'startsWith', {
    value: function(search, rawPos) {
        var pos = rawPos > 0 ? rawPos|0 : 0;
        return this.substring(pos, pos + search.length) === search;
    }
});

}
for (let i = 0; i < 10; i++) {
    let user = bot.users.get(scores[i].ID.split('_')[2]).username

    content += `${i+1}. ${user} ~ ${money[i].data}\n`

  }

  const embed = new MessageEmbed()
.setDescription(`**${message.guild.name}'s Coin Leaderboard**\n\n${content}`)
.setColor("#FFFFFF")

message.channel.send(embed)
}

}`

Like this?

No omg. You need to have a basic understanding of JS before asking for help here.

I do but i dont really understand some stuff so plz help

Its easier if they just add .startsWith() back

You can get an array of the entries by using db.all(). Then you can filter and sort the results. You need to change the following line:
let money = db.startsWith(`scores_${message.guild.id}`, { sort: '.data'})

to the following:
let money = db.all().filter(entry => entry.ID.startsWith(`scores_${message.guild.id}`)).sort((a, b) => a.data < b.data);

I'm not sure if this will work with the rest of your code, so you may have to do some modifications.


Add the ability to import and create palette indexed sprites from GIFs

I recently found out that some engines, like MUGEN, have the ability to import GIFs and automatically convert them into animated sprites.  This makes creating and adding 2D animations into the engine incredibly easy and fast.
Mugen also expands on this by allowing the user to edit the indexed palette of sprites to very quickly create palette swapped sprites. Example
You could recolor a sprite with a shader, but it doesn't allow for the same level of fine grained control.

Just a note, with shader you not only have fine grained control (changing all colors if you want and dynamically), you also have non-destructive control, as in, no need to have separate sprites per palette (where a palette is just a texture listing colors in its pixels in the end).
So, while a shader allows all this and more once you have experience, that request mostly sounds like adding tools to do the same thing more easily, as well as supporting GIF.
Also, if Godot does allow indexed colors in import, it could also support PNGs which have indexed colors (so that Aseprite users don't have to use GIF just because it has palette)

I've not looked into shaders too deeply, but I was under the impression that a shader  wouldn't be able to change just one color at a time, instead changing the whole palette.

@Two-Tone it's certainly possible to change a single (or more) specific colors in a shader, either by doing a simple if, threshold, or looking up a palette texture (get pixel color of the sprite, use it as X coordinate in the palette texture, and output that instead). As I said, it's a bit harder to set this up though.

It would certainly be very beneficial to have editor support  to swap palettes of sprites that support it
It is a very easy and useful way to create variation in a game, without bloating it with more resources

@blurymind GIFs and PNGs should both be supported as while PNG is compressed, most people export their actual animations as GIFs since APNG is not widely supported.

The use of indexed color images and pallette swapping without using shaders would make my life so much more easier. I really do hope this is done sometime in the future :)
In the meantime, we can use this for palette swapping https://godotengine.org/asset-library/asset/239

I want to state that the ability to import GIFs into Animated Sprite node or AnimationPlayer would speed up any pixelart workflow and most other 2D workflows a thousandfold. And therefore would make the engine a lot more suitable for fast prototyping. Right now I have to do set timing any keys twice: Once in the Animation tool I use and then again in the Godot Editor.
Color cycling would be also a very very appreciated feature, benefitting everyone doing pixelart, which is a large portion of Godot users. Shaders are really complicated and hard to get into especially for beginners.
What @akien-mga mentioned here sounds like a great proposal!

I think GIF importing into SpriteFrames is totally doable, yet there's no even basic GIF image loader in Godot yet. The palette part is something I'm more interested in, see #28013.
If GIF importing will be a thing, there would be one issue with extracting palette from imported frames, as they will lose palette information in custom stex format used internally. It would need to store palette as well, meaning potentially breaking existing format...
Each palette entry could be modified, and reimported.

Ported this over to godotengine/godot-proposals#475, closing here.


Add ZenCash currency pairs

ZenCash is becoming increasingly popular and is available on an already impressive and growing number of exchanges. We want to use this XChange package in our own projects, and this PR gives us that option.

not that you need those statics, you can just do new Currency("ZEN") and new CurrencyPair("ZEN", "BTC") instead


Add certifi to suppress urllib3 SSL warnings.

See https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning

+1


Resolve error: Can't resolve 'vue'

Description
Trying out TBJS. Created a new project - npx create-sails trying-sails-vue --vue - but it fails when I run the project.
This is the error -  Resolve error: Can't resolve 'vue'
...
Current behavior
Apparently, vue is not added to the dependencies. Some of my findings show that this may not be particular to TBJS. But I think it needs to be looked into.

...
Expected behavior
Vuejs should be listed as a dependency and installed when yarn install is run.
...

Replace space in square bracket with x e.g [x]

[ ] I have checked and this issue does not exist

On second look, you are right @Parallax18 and the new version of mellow-vue I'm releasing this week will fix that

@DominusKelvin Awesome.

This has been resolved so closing now @Parallax18


Missing 0.4.5 tag

You must add tag 0.4.5 to last commit because pod return:
[!] Unable to satisfy the following requirements:

- `ODSAccordionView (~> 0.4.5)` required by `Podfile`

Please use 0.4.4 for now. I am waiting for more feedback before I push a release. If you rely on  the latest changes, use the ":head" version.

Hey @michalciolek, did you find a solution? I've used the head version but I get an error after updating my pods so I can't compile my project anymore

Hey @alecrugar I forked repo and added changes. Now I use:
pod 'ODSAccordionView', :git => 'https://github.com/michalciolek/ODSAccordionView.git'

Thanks you very much @michalciolek ! :)


[stable/sonarqube] Add deployment strategy support and use LTS image

Signed-off-by: Steve Hipwell<EMAIL_ADDRESS>What this PR does / why we need it:
This merge request enables the customisation of the deployment strategy as well as updating the default image to the 7.9 current LTS deployment. The default deployment strategy hasn't been modified so as to ensure compatibility, but a rolling strategy would better suit a single replica deployment like this.
Special notes for your reviewer:
n/a
Checklist
[Place an '[x]' (no spaces) in all applicable fields. Please remove unrelated fields.]

[ ] DCO signed
[ ] Chart Version bumped
[ ] Variables are documented in the README.md
[ ] Title of the PR starts with chart name (e.g. [stable/chart])

/assign @rjkernick


Changes to support Blazor WebAssembly.

Description
This PR addresses a couple of incompatibilities with the Blazor WebAssembly runtime. Specifically:

Exception handling for asynchronous requests goes down a synchronous path terminating in a call to .Result rather than using async/await.
Configuration of the HttpClient properties such as AllowAutoRedirect, AutomaticDecompression, and Proxy aren't supported by the WASM runtime at all (the property setters throw a PlatformNotSupportedException).

Motivation and Context
This change addresses incompatibilities with the Blazor WebAssembly runtime environment.
Issues: #1307 #1474 #1580
Testing
These changes were tested in a Blazor WebAssembly application, testing the paths for valid/invalid credentials passed to Cognito's StartWithSrpAuthAsync method, as well as testing access to DynamoDB using the DocumentModel (minor changes made to the code from #1580)
The testing environment is an integration testing environment comprised of a Blazor WebAssembly app running on Chrome, FireFox, and Microsoft Edge.
This PR changes the following:

Error handling path in sdk/src/Core/Amazon.Runtime/Pipeline/ErrorHandler/ErrorHandler.cs to add a new async ProcessExceptionAsync method.
Error handling path in sdk/src/Core/Amazon.Runtime/Pipeline/ErrorHandler/ExceptionHandler.cs and  sdk/src/Core/Amazon.Runtime/Pipeline/ErrorHandler/IExceptionHandler.cs  to add a new async HandleAsync method.
sdk/src/Core/Amazon.Runtime/Pipeline/ErrorHandler/HttpErrorResponseExceptionHandler.cs to add a new async HandleExceptionAsync method.
sdk/src/Core/Amazon.Runtime/Pipeline/HttpHandler/_mobile/HttpRequestMessageFactory.cs to add a PlatformNotSupportedException handler to CreateManagedHttpClient.

Screenshots (if appropriate)
Types of changes

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

Checklist

[x] My code follows the code style of this project
[ ] My change requires a change to the documentation
[ ] I have updated the documentation accordingly
[x] I have read the README document
[ ] I have added tests to cover my changes
[x] All new and existing tests passed

License

[x] I confirm that this pull request can be released under the Apache 2 license

[issues]:
[license]: http://aws.amazon.com/apache2.0/
[cla]: http://en.wikipedia.org/wiki/Contributor_License_Agreement

I really need this! Can't use any AWS SDK in Blazor right now.

This is super urgent for us. Please get this merged asap!! Currently can't use any SDK in Blazor and will have to use API Gateway to add a message to SNS via a Lambda, seems ludicrous!

This is also a major blocker for one of our projects. Would be very happy if this is addressed ASAP.

Same here. Please get this merged. I am dependent on this change.

I am also trying to use AWS SDKs in Blazor - would LOVE to get this in to avoid creating ApiGateway endpoints to proxy calls to AWS Clients that could be done direct from the Blazor WebAssembly client.

Same issue with Amazon S3 SDK in blazor WebAssembly

How can we please get some progress on this? If S3 SDK is also affected, is it likely that SDK AWS libraries are affected because they are built similarly?

This PR has been released with version 3.5.2 of AWSSDK.Core

This PR has been released with version 3.5.2 of AWSSDK.Core


Move phase plane from intro

Now point to the separate html file so this looks better in the pdf file, addresses #79.

Thanks!  It would be nice if the PDF hyperlink also worked, but we would want a full URL link for that.  Maybe we can point to the gh-pages copy?

@ketch: The link to the phase plane should work once #83 is merged.

I haven't tested this in the pdf yet since bookbook stopped working for me...

I'm not sure why this still shows as open after I merged #83.  There must be some additional commits here?

Yes, this is distinct from #83 -- this modifies two notebooks to point to the webpage.

Oops, I take back my previous comment.  What's different is that this PR merges into master while #83 merged into gh-pages.
Going forward we need to remember to merge master into gh-pages before updating the html files for webpages.


See which type was infered by F*

fstar.exe could have an option that prints the types infered by F*, when none is given by the user (this option is -i for ocaml)

I agree this would be nice, but I think the default style we've adopted at the moment is writing an explicit type annotation to each top-level definition. It would be nice to have this feature not just for top-level definitions though, but for variables in arbitrary contexts. Like writing printType e in the middle of a term and getting the type of e output (this might need to be protected by a flag, because we would be doing console IO in the middle pure computations).

It seems that F* already has something like this. Some of my students, who apparently looked carefully at all the flags of F*, discovered the --log_types flag. They said it doesn't always work well, but was quite efficient at debugging proofs.

It seems that --log_types only prints the type of top-level lets. While that's useful, it's clearly not enough for devising proofs interactively.

Closing this, since --log_types is exactly what Chantal was asking for originally. Filed separate issue for printing the proof context and goal (#219).


Feature/adding stop words

adding the suport to put stop words, si the openIa api could stop , this si going to be usefull for the agents

Thanks for your contribution! this is adding a bit more than I'd expect at a time -> the agent changes alone should be their own proposal. Could you break this down into smaller parts to simplify review? 🙏

Sorry Im goint to create a new PR with just the suport for stopWords


Versions for uint8_t, int8_t, uint16_t and int16_t

This is a fantastic, really fast algorithm, that even seems to beat Vitaut's. Many thanks for making this available.
My issue is actually a feature request. For completion, do you think that beyond the currently available implementations for uint32_t, int32_t, uint64_t and int64_t, would it be possible to add, in the future, implementations also for uint8_t, int8_t, uint16_t and int16_t?
It would be amazing to have those, for really fast conversion of low-latency batches of data.

the current version handles all integer types and produces well optimized code based on the size, signed/unsigned, and other range limits the compiler can detect


Add breadcrumbs to improve navigation

A simple breadcrumb navigation should be added beneath the top nav to help orient users when viewing nested pages.
Requirements

Breadcrumbs should be text only, separated by right-direction carets
Breadcrumbs will not be visible on the home page and editorial workflow

Because the CMS currently has just one layer of navigation depth, breadcrumbs don't seem particularly necessary. @biilmann I know you've mentioned this before, thoughts?


Unseal Publicized Types

Why?

Runtime allows it.
Can ease implementation of types that may closely mimic an existing type that the original developer, though counter-productive to our goals, didn't intend to be inherited.
Sets this Publicizer apart from others so it's not "Just another assembly publicizer" but instead a uniquely valuable resource!

✅  Verified unsealed classes are inheritable with the original dll present in the runtime.

You need to modify/apply the OrginalAttributesAttribute to reflect which types were originally sealed

Tysm @Lordflamespeed

Runtime allows it.

Actually looks like only mono allows it, coreclr fails with System.TypeLoadException: Could not load type 'x' from assembly 'y' because the parent type is sealed.
And even if it was allowed to load, there are many genuine optimizations (https://www.meziantou.net/performance-benefits-of-sealed-class.htm) that would break it silently in many ways. Mono doesn't implement them today but it could in the future, so we shouldn't rely on this working.
This is much better suited for something like a bepinex preloader patcher that affects the runtime aswell. It might not be as convenient, but that could be fixed by improving the tooling and making it possible to run the same patcher both at runtime and in msbuild.


Details View: Fade background image to transparency effect not applied correctly when switching between games with different background image dimensions

Bug Description
The new "Fade background image to transparency" effect for the Details View is applied incorrectly during the transition animation when switching between different games, if those games have background images with different image dimensions.
To Reproduce
Make sure the following two settings are enabled:

Playnite Settings -> Appearance -> General -> Animate background image transitions
ThemeModifier Settings -> Details View  -> Fade background image to transparency effect

Then find two games in your library who's background images have different image dimensions.
Switching between those games should cause the fade to transparency to bug out. It seems the fade is only applied to the image that is (vertically) larger, leaving the smaller image with a harsh cutoff. Once the transition animation ends, it corrects itself, but it still looks jarring.
Extensions log
No response
Screenshots
https://github.com/darklinkpower/Harmony/assets/1278331/6dbf87b6-f65c-4cd6-b6be-f19b589812d9

It's an issue due to how the background image behaves. It works this way:

On first selection, it loads the game background image (1920x1080px)
On second selection and if the animation is enabled this happens simultaneously:
a. First image is transitioned from full opacity -> full transparency
b. Second (new) image (1920x620px) is loaded and changed from full transparency -> Full opacity

Both images are inside the same container/control, which means that this container will be the size of the largest image during this transition, in this case being 1920x1080px. After finalizing the transition I explained, the older image will be removed and the container will adjust to the exact size of the new image (1920x620px). The same happens with the opacity effect used for the background image, after finalizing the animation, it will adjust its size but this will be very noticeable if the images were of different dimensions.
I hope my explanation was clear. Unfortunately this means that there isn't a way to fix this. The only solutions are:

Disable support of using the transition animation
Separate animation setting from the Playnite setting and make it an option ThemeModifier. That way they could be enabled separately and people who use images of different dimensions could keep it disabled.

Thanks for the response, looks like I'll just have to make sure I select images of the same size everywhere lol


Create windows_audit_policy resource

Description

This adds a new native resource for managing Windows Advanced Audit Policy configurations. A user can specify a subcategory of the advanced audit policy to edit either as a string or an array and can set the auditing to Success and/or Failure. It also takes user arguments to apply policies to specific users.  There are options for the four Advanced Audit Policy options managed via auditpol as well. It is idempotent in my testing as well.
Some usage examples are below:
Set Logon and Logoff policy to "Success and Failure":
windows_audit_policy "Set Audit Policy for 'Logon and Logoff' actions to 'Success and Failure' do
  sub_category   %w(Logon Logoff)
  success        true
  failure        true
  action         :set
end

Set Credential Validation policy to "Success":
windows_audit_policy "Set Audit Policy for 'Credential Validation' actions to 'Success' do
  sub_category   'Credential Validation'
  success        true
  failure        false
  action         :set
end

Enable CrashOnAuditFail option:
windows_audit_policy "Enable CrashOnAuditFail option' do
  crash_on_audit_fail        true
  action                     :set
end

Related Issue

#8299
Types of changes

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

Checklist:

[x] I have read the CONTRIBUTING document.
[ ] I have run the pre-merge tests locally and they pass.
[x] I have updated the documentation accordingly.
[x] I have added tests to cover my changes.
[x] All new and existing tests passed.
[x] All commits have been signed-off for the Developer Certificate of Origin.

@phiggins I appreciate all the comments. I'm slammed at the moment but will try to push some updates this weekend to incorporate your suggestions.


Remove unnecessary autotimeout config

autotimeout is not necessary in a spawner because JupyterHub can be extended with services.
https://github.com/jupyterhub/jupyterhub/tree/0.8.1/examples/cull-idle

Codecov Report

Merging #2 into master will increase coverage by 1.05%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master       #2      +/-   ##
==========================================
+ Coverage   59.83%   60.89%   +1.05%
==========================================
  Files          11       11
  Lines         366      358       -8
==========================================
- Hits          219      218       -1
+ Misses        147      140       -7

Impacted Files
Coverage Δ

ucrspawner/ucrspawner.py
36.57% <ø> (+0.85%)
:arrow_up:

Continue to review full report at Codecov.

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


Corrected push-ros-namespace references

@jrgnicho friendly ping

I've opened https://github.com/ros2/launch_ros/issues/142 to track the new feature request.  I'm going to go ahead and merge this.


Please release 4.0.rc2 to solve some of the repeated open issues / allow for further testing

Can we get 4.0.rc2 released so we can further test?  I think a few folks are running into same issues I did which I think are all resolved in 4.0.rc2.  I'd like to test more in large scale projects and I cannot bring in snapshots or clone as needed in the case I need to test.  I'm sure others are in same restricted boat I am :)

Yes will do right away!

Great @mathieucarbou, I'll jump on testing this pretty heaving this coming week and will report back any findings :)  Appreciate it.

done! will be available soon.

Sweet!  Thanks so much!


返回表达式

加「丁」以「戊」。名之曰「己」。 乃得「己」。
似乎可以简化为
加「丁」以「戊」。得之矣。

Great proposal. I'll add it.
Currently you can use 其 to refer to the last temporary variable. However 乃得其 doesn't sound right. I think your solution would be preferable.
Thanks!


[BUG] Qprogram.sync() is not adding the wait instructions properly to the Q1ASM (Qblox)

Expected behavior
The modules should synchronize by using QProgram().sync().
Rabi taken from a well coordinated HW loop:

Actual behavior
When trying to synchronize two modules, for example for a Rabi you need a QCM and a QRM, the QProgram().sync() is not adding the correct wait instructions, as the times it is adding are not synchronizing correctly the two modules, you can measure, but on every iteration of the average, the QRM is 16ns behind, this results in a noisy measurement.
As you can see below, the last timestamp written is just before the loop, and the QRM is 16ns later, this 16ns accumulate on every iteration, I thought about adding then 16ns of delay to the QCM, but by doing so the QProgram().sync() takes it into account and changes the waits again, so it stays behind.
QCM Q1ASM
setup:
                wait_sync        4                          # totals timestamp (instruction time)

main:
                move             1000, R0                   # 4ns (4ns)
avg_0:
                move             41, R1                     # 8ns (4ns)
                move             0, R2                      # 12ns (4ns)
loop_0:
                set_awg_gain     R2, R2                     # 20ns (8ns)
long_wait_10:
                move             3, R3                      # 24ns (4ns)
long_wait_10_loop:
                wait             65532                      # this loop is relax_time (200_000ns)
                loop             R3, @long_wait_10_loop     # loop takes 24ns when jump and 12ns when pass (84ns)
                wait             3404                       # 200_108ns

                play             0, 1, 4                    # 200_112ns (4ns)
long_wait_12:
                wait             2040                       # 202_152ns (2_040ns)

                add              R2, 163, R2                # 202_164ns (add R,I,R 12ns)
                loop             R1, @loop_0
                nop
                loop             R0, @avg_0
                stop

QRM Q1ASM
setup:
                wait_sync        4                          # totals timestamp (instruction time)

main:
                move             1000, R0                   # 4ns (4ns)
avg_0:
                move             0, R1                      # 8ns (4ns)
                move             0, R2                      # 12ns (4ns)
                move             0, R3                      # 16ns (4ns)
                move             41, R4                     # 20ns (4ns)
                move             0, R5                      # 24ns (4ns)
loop_0:
long_wait_9:
                move             3, R6                      # 28ns (4ns)
long_wait_9_loop:
                wait             65532                      # this loop is relax_time (200_000ns)
                loop             R6, @long_wait_9_loop      # loop takes 24ns when jump and 12ns when pass (84ns)
                wait             3404                       # 200_112ns

long_wait_11:
                wait             40                         # 200_152ns (40ns)

                play             0, 1, 4                    # 200_156ns (4ns)
                acquire_weighed  0, R3, R2, R1, 2000        # 202_156ns (2000ns)
                add              R3, 1, R3                  # 202_168ns (12ns)
                add              R5, 163, R5                # 202_180ns (12ns)
                loop             R4, @loop_0
                loop             R0, @avg_0
                stop

Rabi taken with this program (Yeah, still a rabi, but a lot noisier, same parameters and same qubit as the first one):

Additional information
There are other bugs to take into account when trying to reproduce this bug, in the play instruction on the QRM, there's extra wait time between play and acquire, this time should be the time of flight, but it is the waveform duration now, you can hardcode it to 200ns (more or less the tof) by now until it is solved.
Another bug to take into account is that the 2040ns wait of the QCM Q1ASM is coded to be the duration of play+acquire time by the QProgram().sync(), and as it takes the waveform duration as the wait for the play instruction, it takes double the time it should.
It should be just the duration of the readout (2000ns in this case).
Source code
#QProgram used

qp = ql.QProgram()

# Defining the variable Frequency for the driving pulse
amplitude = qp.variable(ql.Domain.Voltage)  # Just for the renormalization for the Q1ASM

with qp.average(HW_AVG):
    # Loop over all frequencies
    with qp.for_loop(variable=amplitude, start=AMP_VALUES[0], stop=AMP_VALUES[-1], step=AMP_VALUES[1]-AMP_VALUES[0]):
        qp.set_gain(bus=f"drive_q{QUBIT_IDX}_bus", gain=amplitude)
        qp.wait(bus=f"readout_bus_{QUBIT_IDX}",duration=REPETITION_DURATION)
        qp.sync()
        qp.play(bus=f"drive_q{QUBIT_IDX}_bus", waveform=drag)
        qp.wait(bus=f"readout_bus_{QUBIT_IDX}",duration=DRAG_DURATION)
        qp.play(bus=f"readout_bus_{QUBIT_IDX}", waveform=square_wf)  # Executing the Square pulse
        qp.acquire(bus=f"readout_bus_{QUBIT_IDX}", weights=ql.IQPair(I=weights_shape, Q=weights_shape))  # Measuring

Tracebacks
No response
System Information
Name: qililab
Version: 0.22.0
Summary: Fundamental package for fast characterization and calibration of quantum chips.
Home-page: https://github.com/qilimanjaro-tech/qililab
Author: Qilimanjaro Quantum Tech
Author-email<EMAIL_ADDRESS>License: Apache License 2.0
Location: /home/anavarro/miniconda3/envs/qililab-main/lib/python3.10/site-packages
Editable project location: /home/anavarro/qililab
Requires: h5py, lmfit, networkx, pandas, papermill, PyVISA-py, PyYAML, qblox-instruments, qcodes, qcodes-contrib-drivers, qibo, qiboconnection, qm-qua, qpysequence, qualang-tools, ruamel.yaml, rustworkx, submitit, tqdm, urllib3
Required-by:

Platform info:             Linux-5.15.0-91-generic-x86_64-with-glibc2.35
Python version:            3.10.11
PyVISA version:            0.7.1
QCodes version:            0.42.0
QCodes Contrib version:    0.18.0
Qblox Instrument version:  0.11.2
Qpysequence version:       0.10.0
Quantum Machines version:  <IP_ADDRESS>
Qibo version:              0.1.12.dev0

Existing GitHub issues

[X] I have searched existing GitHub issues to make sure the issue does not already exist.

I am here interceding because I have been made aware of this problem.
WAIT SYNC (to trigger SYNQ) IS A NON-NEGOTIABLE MUST. Please lets have a meeting to ensure this is properly addressed.

Hello @4dri8 and @rsagas. Thank you for raising this. This kind of detail in bug reporting is exactly what we want in order to be able to investigate more.
First of all, are you using main branch or the development branch of QProgram? Several issues that we found the last two weeks are resolved there.
In that branch, the play operation has an extra parameter wait_time to override the default wait time that is the duration of the pulse. So in order to measure with a time of flight you can do:
qp.play(bus=f"readout_bus_{QUBIT_IDX}", waveform=square_wf, wait_time=time_of_flight)  # Executing the Square pulse
qp.acquire(bus=f"readout_bus_{QUBIT_IDX}", weights=ql.IQPair(I=weights_shape, Q=weights_shape))  # Measuring

In general, using QProgram, all play instructions wait for the whole pulse, so there is no need to add an additional wait instruction afterwards. You are doing
qp.play(bus=f"drive_q{QUBIT_IDX}_bus", waveform=drag)
qp.wait(bus=f"readout_bus_{QUBIT_IDX}",duration=DRAG_DURATION)

and this adds DRAG_DURATION nanoseconds on top of the duration of the drag waveform.
Also, all buses are synchronized at the beginning of each loop iteration, so there is no point of having a sync() there. The sync() should be between the drive pulse and the readout pulse to enforce the second to begin right after the first.
My recommended way of writing the RABI would be:
time_of_flight = 120
qp = ql.QProgram()

# Defining the variable Frequency for the driving pulse
amplitude = qp.variable(ql.Domain.Voltage)  # Just for the renormalization for the Q1ASM

with qp.average(HW_AVG):
    # Loop over all frequencies
    with qp.for_loop(variable=amplitude, start=AMP_VALUES[0], stop=AMP_VALUES[-1], step=AMP_VALUES[1]-AMP_VALUES[0]):
        qp.set_gain(bus=f"drive_q{QUBIT_IDX}_bus", gain=amplitude)

        # play the drive pulse
        qp.play(bus=f"drive_q{QUBIT_IDX}_bus", waveform=drag)

        # sync the two buses
        qp.sync()

        # wait for some time
        qp.wait(bus=f"readout_bus_{QUBIT_IDX}",duration=DRAG_DURATION)

        # start measuring by playing the readout pulse and only wait for a time_of_flight duration
        qp.play(bus=f"readout_bus_{QUBIT_IDX}", waveform=square_wf, wait_time=time_of_flight)

        # acquire results
        qp.acquire(bus=f"readout_bus_{QUBIT_IDX}", weights=ql.IQPair(I=weights_shape, Q=weights_shape))

        # wait qubit to relax. In the next loop iteration buses will be in sync.
        qp.wait(bus=f"readout_bus_{QUBIT_IDX}",duration=REPETITION_DURATION)

Hi @4dri8

Regarding the long wait issue, we are aware of this and have a fix in main by the end of the week.
I have tried running your code, adding the definitions of drag, QUBIT_IDX and so on. The full code looks like this for me:

import numpy as np
import qililab as ql
from qililab.qprogram.blocks import Block
from qpysequence.utils.constants import AWG_MAX_GAIN, INST_MAX_WAIT
from qililab.qprogram.operations import *
from qililab.qprogram import QbloxCompiler
from qililab.waveforms import DragPair
import numpy as np

platform_name = "/home/victor/qililab/examples/runcards/galadriel.yml"
platform = ql.build_platform(runcard=platform_name)

#QProgram used

QUBIT_IDX = 0
AMP_VALUES = np.arange(10,20,1)
HW_AVG = 10
qp = ql.QProgram()
REPETITION_DURATION = 100

# Defining the variable Frequency for the driving pulse
amplitude = qp.variable(ql.Domain.Voltage) # Just for the renormalization for the Q1ASM
DRAG_DURATION = platform.get_parameter(parameter = ql.Parameter.DURATION, alias=f"Drag({QUBIT_IDX})")
drag = DragPair(
        amplitude=platform.get_parameter(parameter = ql.Parameter.AMPLITUDE, alias=f"Drag({QUBIT_IDX})"),
        duration=DRAG_DURATION,
        num_sigmas=platform.get_parameter(parameter = ql.Parameter.NUM_SIGMAS, alias=f"Drag({QUBIT_IDX})"),
        drag_coefficient=platform.get_parameter(parameter = ql.Parameter.DRAG_COEFFICIENT, alias=f"Drag({QUBIT_IDX})"))
t = platform.get_parameter(parameter=ql.Parameter.DURATION, alias=f"M({QUBIT_IDX})")
weights = ql.Square(amplitude=1, duration=t)
square_wf = waveform=ql.Square(
        amplitude=platform.get_parameter(parameter=ql.Parameter.AMPLITUDE, alias=f"M({QUBIT_IDX})"),
        duration=t)

with qp.average(HW_AVG):
    # Loop over all frequencies
    with qp.for_loop(variable=amplitude, start=AMP_VALUES[0], stop=AMP_VALUES[-1], step=AMP_VALUES[1]-AMP_VALUES[0]):
        qp.set_gain(bus=f"drive_q{QUBIT_IDX}_bus", gain=amplitude)
        qp.wait(bus=f"feedline_bus",duration=REPETITION_DURATION)
        qp.sync()
        qp.play(bus=f"drive_q{QUBIT_IDX}_bus", waveform=drag)
        qp.wait(bus=f"feedline_bus",duration=DRAG_DURATION)
        qp.play(bus=f"feedline_bus", waveform=square_wf) # Executing the Square pulse
        qp.acquire(bus=f"feedline_bus", weights=ql.IQPair(I=weights, Q=weights)) # Measuring

qblox_compiler = QbloxCompiler()
sequences = qblox_compiler.compile(qprogram=qp)

for _, sequence in sequences.items():
    print(sequence._program)

*note that you don't need to connect to the instruments to run this
This outputs q1asm programs
setup:
                wait_sync        4

main:
                move             10, R0
avg_0:
                move             0, R1
                move             0, R2
                move             0, R3
                move             10, R4
                move             327670, R5
loop_0:
                wait             100
                wait             20
                play             0, 1, 2000
                acquire_weighed  0, R3, R2, R1, 2000
                add              R3, 1, R3
                add              R5, 32767, R5
                loop             R4, @loop_0
                loop             R0, @avg_0
                stop

setup:
                wait_sync        4

main:
                move             10, R0
avg_0:
                move             10, R1
                move             327670, R2
loop_0:
                set_awg_gain     R2, R2
                wait             100
                play             0, 1, 20
                wait             4000
                add              R2, 32767, R2
                loop             R1, @loop_0
                nop
                loop             R0, @avg_0
                stop

tl;dr I dont see the extra 4ns that you're seeing.
Would you mind providing your full code so I can try to reproduce it?

Hi guys, I want to have a meeting about this.
A while ago i spoke about MULTIDEVICE INSTRUCTIONS in QPysequence. It is the only scalable solution I know for this.
I am also very concerned about issues that I have written and have dissapeared (specifically the one relevant now, for multidevice instructions).

Could it be this one? https://github.com/qilimanjaro-tech/qililab/issues/74
Be mindful that compilation is already outside of the drivers (we changed this a few weeks ago) and it already supports compiling sequences for different QRMs / QCMs for the same program (and the extension to clusters should be quite straight forward)

We should definitely have a discussion about this though

It is not that PR. I searched in the repo, and it is the second time I cannot find an issue on a vision thing I wrote. Do you (team) erase issues ever if you feel they do not point to an action? Cause these ones were preventing issues that are only now coming up.
Anyhow, I do want to discuss the topic, it is about a QPYSEQUENCE improvement.

Hi @4dri8

Regarding the long wait issue, we are aware of this and have a fix in main by the end of the week.
I have tried running your code, adding the definitions of drag, QUBIT_IDX and so on. The full code looks like this for me:

import numpy as np
import qililab as ql
from qililab.qprogram.blocks import Block
from qpysequence.utils.constants import AWG_MAX_GAIN, INST_MAX_WAIT
from qililab.qprogram.operations import *
from qililab.qprogram import QbloxCompiler
from qililab.waveforms import DragPair
import numpy as np

platform_name = "/home/victor/qililab/examples/runcards/galadriel.yml"
platform = ql.build_platform(runcard=platform_name)

#QProgram used

QUBIT_IDX = 0
AMP_VALUES = np.arange(10,20,1)
HW_AVG = 10
qp = ql.QProgram()
REPETITION_DURATION = 100

# Defining the variable Frequency for the driving pulse
amplitude = qp.variable(ql.Domain.Voltage) # Just for the renormalization for the Q1ASM
DRAG_DURATION = platform.get_parameter(parameter = ql.Parameter.DURATION, alias=f"Drag({QUBIT_IDX})")
drag = DragPair(
        amplitude=platform.get_parameter(parameter = ql.Parameter.AMPLITUDE, alias=f"Drag({QUBIT_IDX})"),
        duration=DRAG_DURATION,
        num_sigmas=platform.get_parameter(parameter = ql.Parameter.NUM_SIGMAS, alias=f"Drag({QUBIT_IDX})"),
        drag_coefficient=platform.get_parameter(parameter = ql.Parameter.DRAG_COEFFICIENT, alias=f"Drag({QUBIT_IDX})"))
t = platform.get_parameter(parameter=ql.Parameter.DURATION, alias=f"M({QUBIT_IDX})")
weights = ql.Square(amplitude=1, duration=t)
square_wf = waveform=ql.Square(
        amplitude=platform.get_parameter(parameter=ql.Parameter.AMPLITUDE, alias=f"M({QUBIT_IDX})"),
        duration=t)

with qp.average(HW_AVG):
    # Loop over all frequencies
    with qp.for_loop(variable=amplitude, start=AMP_VALUES[0], stop=AMP_VALUES[-1], step=AMP_VALUES[1]-AMP_VALUES[0]):
        qp.set_gain(bus=f"drive_q{QUBIT_IDX}_bus", gain=amplitude)
        qp.wait(bus=f"feedline_bus",duration=REPETITION_DURATION)
        qp.sync()
        qp.play(bus=f"drive_q{QUBIT_IDX}_bus", waveform=drag)
        qp.wait(bus=f"feedline_bus",duration=DRAG_DURATION)
        qp.play(bus=f"feedline_bus", waveform=square_wf) # Executing the Square pulse
        qp.acquire(bus=f"feedline_bus", weights=ql.IQPair(I=weights, Q=weights)) # Measuring

qblox_compiler = QbloxCompiler()
sequences = qblox_compiler.compile(qprogram=qp)

for _, sequence in sequences.items():
    print(sequence._program)

*note that you don't need to connect to the instruments to run this This outputs q1asm programs
setup:
                wait_sync        4

main:
                move             10, R0
avg_0:
                move             0, R1
                move             0, R2
                move             0, R3
                move             10, R4
                move             327670, R5
loop_0:
                wait             100
                wait             20
                play             0, 1, 2000
                acquire_weighed  0, R3, R2, R1, 2000
                add              R3, 1, R3
                add              R5, 32767, R5
                loop             R4, @loop_0
                loop             R0, @avg_0
                stop

setup:
                wait_sync        4

main:
                move             10, R0
avg_0:
                move             10, R1
                move             327670, R2
loop_0:
                set_awg_gain     R2, R2
                wait             100
                play             0, 1, 20
                wait             4000
                add              R2, 32767, R2
                loop             R1, @loop_0
                nop
                loop             R0, @avg_0
                stop

tl;dr I dont see the extra 4ns that you're seeing. Would you mind providing your full code + runcard, as well as the runcard you're running it from so I can try to reproduce it?

There are 16ns of delay from the qcm (there you have your Q1ASM with the timings), in the Q1ASM below you can see the timings of every instruction, in this way: "#absolute time (instruction time)"
`setup:
wait_sync        4                      #4ns (4)
main:
move             10, R0                 #8ns (4)
avg_0:
move             0, R1                  #12ns (4)
move             0, R2                  #16ns (4)
move             0, R3                  #20ns (4)
move             10, R4                 #24ns (4)
move             327670, R5             #28ns (4)
loop_0:
wait             100                    #128ns (100)
wait             20                     #148ns (20)
play             0, 1, 2000             #152ns (should be 4, already solved)
acquire_weighed  0, R3, R2, R1, 2000    #2152ns (2000)
add              R3, 1, R3              #2164ns (12)
add              R5, 32767, R5          #2176ns (12)
loop             R4, @loop_0
loop             R0, @avg_0
stop
setup:
wait_sync        4                      #4ns (4)
main:
move             10, R0                 #8ns (4)
avg_0:
move             10, R1                 #12ns (4)
move             327670, R2             #16ns (4)
loop_0:
set_awg_gain     R2, R2                 #24ns (8)
wait             100                    #124ns (100)
play             0, 1, 20               #144ns (20)
wait             4000                   #2148ns (should be 4 (qrm play)+2000(qrm acquire))
add              R2, 32767, R2          #2160ns (12)
loop             R1, @loop_0
nop
loop             R0, @avg_0
stop`

Hello @4dri8
The only instructions that add towards timings are play, wait and acquire. These three instructions are run in the "real-time processor" of the sequencer. The rest of the instructions are run in "classical processor". A deeper explanation is given here: https://www.notion.so/qilimanjaro/Q1ASM-timing-d3bb142a450748209e57f2d585fc31f6
So in your example, timings would be:
setup:
                wait_sync        4                      #4ns (4)

main:
                move             10, R0
avg_0:
                move             0, R1
                move             0, R2
                move             0, R3
                move             10, R4
                move             327670, R5
loop_0:
                wait             100                    #104ns (100)
                wait             20                     #124ns (20)
                play             0, 1, 4             #128ns (should be 4, already solved)
                acquire_weighed  0, R3, R2, R1, 2000    #2128ns (2000)
                add              R3, 1, R3
                add              R5, 32767, R5
                loop             R4, @loop_0
                loop             R0, @avg_0
                stop

setup:
                wait_sync        4                      #4ns (4)

main:
                move             10, R0
avg_0:
                move             10, R1
                move             327670, R2
loop_0:
                set_awg_gain     R2, R2
                wait             100                    #104ns (100)
                play             0, 1, 20               #124ns (20)
                wait             2004                   #2128ns (should be 4 (qrm play)+2000(qrm acquire))
                add              R2, 32767, R2
                loop             R1, @loop_0
                nop
                loop             R0, @avg_0
                stop

So at the end the two sequencers are in sync.

Then I cannot identify the problem, but I'm not being able to get a rabi with QProgram, even with the code I showed in the opening of the issue, I'm not able to reproduce it.

I just found an error in the code I was using, I assumed that, as qililab does, qprogram would assume that, if a parameter is not modified in the current code, it is equal to the value in the runcard, as for example frequencies, but this is not done for the amplitudes of the waveforms. Qililab gives all the waveforms' amplitudes equal to 1 and then these are modified in the Q1ASM to the actual value from the runcard, so I did the same with the readout, as I was not modifying it, I gave the amplitude of the readout as 1, and obviously that is too much power. After solving this, it seems to work fine. Sorry for not seeing this before.

Glad to hear it worked! I'll mark this as done then, and if anything else arises you can create a new issue.


Change active tab underline color

Current behaviour
When I switch between tabs, my underline color changes but it disappears when I'm done with pressing tab.
Expected behaviour
I would like to have green underline color of active tab, that will stay there until next tab is clicked
Code sample
renderHeader = (props) => {
return (<TabBar
{...props}
tabStyle={styles.tabBarStyle}
labelStyle={styles.tabBarHeader}
indicatorStyle={styles.tabBarIndicator}
style={styles.tabBar}
data={this.props}
animationEnabled={false}
pressColor={'green'}
/>);
}
renderScene = SceneMap({
first: FirstRoute,
second: SecondRoute,
third: ThirdRoute,
});
Your Environment
| react-native          |
| react-native-tab-view |
| ios                  |
| npm      |

Is there an issue with styling the tab bar?
    <TabBar
      {...props}
      pressColor="rgba(179,229,255, 0.5)"
      scrollEnabled={true}
      style={styles.tabbar}
      indicatorStyle={styles.indicator}
      tabStyle={styles.tab}
      useNativeDriver
    />

In < 1.0.0 version this works for styling but now (1.0.0+) it gives the default blue background, white text etc.

It seems that the api changed from renderHeader to renderTabBar

Same here for me . Did you solve it ?

Hey, I just released a new alpha 2.0.0-alpha.0 of the library. It's rewritten using react-native-gesture-handler and react-native-reanimated addresses a many platform specific bugs and performance problems. The documentation is updated as well.
Please try the new version and see if it addresses your issue. If not, please open a new issue following the issue template.


Network errors always disabled

I've found that the Network errors pages are always disabled.
I think I know why. PR will follow.

See #146


[Add a Play]: URL Shortner

What's the Play about?
✅ An URL shortener play using react
What ReactJS concept will be used to create this play?
✅Components
✅Rest API
✅Axios
✅Custom Hook
Record

[X] I have checked the existing issues
[X] I have read the Contributing Guidelines
[X] I want to work on this issue

Code of Conduct

[X] I agree to follow this project's Code of Conduct

assigned to you


Type hierarchy mapping

public abstract class Base
{
   public int Value1 { get; set; }
}

public class Derived1 : Base
{
   public int Value2 { get; set; }
}

public class Derived2 : Base
{
   public int Value3 { get; set; }
}

public abstract class BaseDto
{
   public int Value1 { get; set; }
}

public class Derived1Dto : BaseDto
{
   public int Value2 { get; set; }
}

public class Derived2Dto : Base
{
   public int Value3 { get; set; }
}

Is it possible to configure some convention based mapping (in this case by name but it's better to have some generic way to configure it) so TinyMapper.Map<BaseDto>(baseObj) will map to Derived1Dto or Derived2Dto depending on baseObj actual type. I can create simple my own helper for it but it will work only for top level objects. And I want some solution to nested complex objects / collections, etc.
So, in general case it should throw exception. But I want to have a way to specify rule to find inheritor by:

TypePair (Base, BaseDto)
Actual object (baseObj)

It should return result type (Derived1Dto or Derived2Dto in the given example).

So, you don't want to set up target type? Target type is required, I can get the target type thru baseObj.GetType()

What I want as result to call mapper with specifying BaseTargetType (abstract class) only. And provide (through some global configuration) some logic to choose concrete target type (by default mapper shouldn't try to find concrete target type and should just map to the given type (or throw exception if it's abstract class). But I want to have ability to inject logic of selecting target type.
In the simple case I can just create my own wrapper method:
public static TTarget Map<TSource, TTarget>(TSource source)
{
   var targetType = FindTargetType(source. typeof (TTarget)); // some custom logic
   return (TTarget) Mapper.Map<TSource>(targetType); // it's just an example, we need not generic call here or we can build generic call through reflection, it isn't important
}

But it wouldn't work for nested objects. So I want to have ability to inject some custom target type selection logic.

I see, what do you think about this signature
public static TTarget Map(TSource source, Func<TSource, Type> targetTypeSelector )

Yeah, something like that.
But this targetTypeSelector should be used for all mapping (including nested objects). So we should correctly cache mappers or introduce some parametering for them.


Create new github issue template for security assessments

Creates a new security assessment Github issue template for making this a self-service request for any sub-projects
/cc @kubernetes/sig-security-leads @rficcaglia @savitharaghunathan @reylejano
/sig security
X-Ref: https://github.com/kubernetes/community/issues/5921

In general this LGTM, one thing do we want to add a field asking the project for contact details of who SIG-Security should get in touch with to progress the request (in case it's not the same as the submitter)

In general this LGTM, one thing do we want to add a field asking the project for contact details of who SIG-Security should get in touch with to progress the request (in case it's not the same as the submitter)

+1. Maybe add a field in the header called 'contact'?

In general this LGTM, one thing do we want to add a field asking the project for contact details of who SIG-Security should get in touch with to progress the request (in case it's not the same as the submitter)

+1. Maybe add a field in the header called 'contact'?

Updated with a new header asking for this information

Lgtm

/lgtm
Thank you for creating this issue template PR

/assign kubernetes/sig-security-pr-reviews

/assign sig-security-pr-reviews

/assign tabbysable coldwater
(because could not get the bot to use the alias of sig-security-pr-reviews)

/assign IanColdwater
(did not use the correct handle earlier)

https://github.com/kubernetes/test-infra/pull/23070 is now merged (Adding label area/security-assessment), so we can use this label in the template.
@tabbysable @IanColdwater looking for /approve. This PR will allow us to start creating a waiting list for security assessments and make it self-service to request one :)

/approve
Thanks all!


AdaptiveAveragePooling: Number of ways to split should evenly divide the split dimension

System information

OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Google Colab
TensorFlow version and how it was installed (source or binary): Google Colab
TensorFlow-Addons version and how it was installed (source or binary): 0.12.0
Python version: 3
Is GPU used? (yes/no): no

Describe the bug
AdaptiveAveragePooling2D fails when input dimension not dividable by pool size
In contrast, PyTorch version of AdaptivePooling2D works well in the same case.
Code to reproduce the issue
import tensorflow as tf
import tensorflow_addons as tfa

layer = tfa.layers.AdaptiveAveragePooling2D(3)
batch = tf.random.uniform((2, 16, 16, 5))
layer(batch)

Other info / logs
---------------------------------------------------------------------------
InvalidArgumentError                      Traceback (most recent call last)
<ipython-input-6-e9a53d37389e> in <module>()
      1 layer = tfa.layers.AdaptiveAveragePooling2D(3)
      2 batch = tf.random.uniform((2, 16, 16, 5))
----> 3 layer(batch)

6 frames
/usr/local/lib/python3.6/dist-packages/six.py in raise_from(value, from_value)

InvalidArgumentError: Number of ways to split should evenly divide the split dimension, but got split_dim 1 (size = 16) and num_split 3 [Op:Split] name: split

/cc @Susmit-A for visibility. Seems that pytorch will have overlapping kernel when the dimension is not divisible by output size. I wonder if this is achievable with python ops.

This was done on purpose, to prevent unexpected behaviour for different input sizes, as well as offer flexibility for shape.
The inputs can be clipped/padded as per requirement before passing to the layer.
Since different models perform differently based on whether access data is clipped or padded, it's better to let the user decide the necessary action.

Hi @Susmit-A, I'd say we should try to support non-divisible case. If not, is there any different between adaptive and original pooling? We can always infer the strides and kernel sizes of tf.nn.{avg,max}_pool to output specific sizes. Maybe
stride = floor(input_size/output_size)
kernel_size = input_size − (output_size −1) * stride

I guess.

https://stackoverflow.com/questions/53841509/how-does-adaptive-pooling-in-pytorch-work

The way PyTorch accomplishes this is well explained here:
https://discuss.pytorch.org/t/what-is-adaptiveavgpool2d/26897
The issue is the rounding, instead of floor/ceil. This gives unequal size pieces that can't be stacked for parallel pooling; each piece needs to be processed individually.
The method mentioned by @WindQAQ does work, but the output is not the same as that of PyTorch, since there is one less or one more value (in 1D arrays, in case of 2D arrays, its one pixel in each dimension) covered by the kernel compared to PyTorch. If that is not an issue, I can implement it in that manner. We can also also give an option to iteratively compute the pooled values to obtain the exact values that PyTorch provides, if the user requires so.

For divisible case, rounding up or down do not matter, which means current adaptive pooling is just a variant for tf.nn.{avg,max}_pool. We should do some benchmarks to see if that will be faster. We do not have to follow PyTorch implementation actually. At least we do not follow it now :-)
For non-divisible case, I agree that it would be much slower if we try to implement with pure python ops. Let's see if the performance degradation is huge first, and improve it latter.

I have created a PR with the updated version of Adaptive Pooling. However, this is an order of magnitude slower than the PyTorch version. Methods to improve performance need to be explored. Specifically, the internal loop needs to be parallelized.


Calculate the self-part of VHF

The current implementation of the VHF allows for the calculation of the self+distinct VHF or the distinct VHF.  The function should be refactored so that only the self-part can be computed.

Inspired by this paper: DOI: 10.1103/PhysRevE.102.032604


Error when using Vite's native WebAssebmly imports

Describe the bug
According to vite's docs, one should be able to import a "*.wasm" file directly, and call an init function, as such:
import init from "./path/to/wasm.wasm";

await init();

If one call's .toString() on the init function, we can see the expected function declaration and body:
opts => __vite_ssr_import_0__.default(opts, "/path/to/wasm.wasm")

However, when run in SSR as follows:
if (!browser) {
  await init();
}

I get a runtime error from node which is down below in the logs section.
I am trying to find a way of running WASM in both SSR and client side. I am able to run on client side no problem, but not in SSR.
Reproduction
Repro link here
A few things of note. I am using wasm-pack with Rust. I am not using any plugins, as none that I've been able to find work well when the code is updated.
Within src/lib/wasm is the browser build and within src/lib/wasm-node is the node build. On their own, I can get the client to use the browser build, and node to use the node build, but I cannot get SSR to work with either of these.
When wasm is loaded, it will simply log to the console "hello".
Logs
Invalid URL
TypeError [ERR_INVALID_URL]: Invalid URL
    at new NodeError (node:internal/errors:372:5)
    at onParseError (node:internal/url:563:9)
    at parse (<anonymous>)
    at new URL (node:internal/url:643:5)
    at new Request (file:///C:/Dev/Commercial/Importadora%20Queara/online-sales-v2/node_modules/@sveltejs/kit/dist/install-fetch.js:5907:16)
    at file:///C:/Dev/Commercial/Importadora%20Queara/online-sales-v2/node_modules/@sveltejs/kit/dist/install-fetch.js:6189:19
    at new Promise (<anonymous>)
    at fetch (file:///C:/Dev/Commercial/Importadora%20Queara/online-sales-v2/node_modules/@sveltejs/kit/dist/install-fetch.js:6187:9)
    at Module.__vite_ssr_exports__.default (/__vite-wasm-helper:20:32)
    at Module.__vite_ssr_exports__.default (/src/lib/wasm/index_bg.wasm:3:32)

### System Info

```shell
System:
    OS: Windows 10 10.0.22000
    CPU: (16) x64 Intel(R) Core(TM) i7-10875H CPU @ 2.30GHz
    Memory: 4.08 GB / 15.75 GB
  Binaries:
    Node: 17.7.1 - C:\Program Files\nodejs\node.EXE
    npm: 8.5.2 - C:\Program Files\nodejs\npm.CMD
  Browsers:
    Edge: Spartan (44.22000.120.0), Chromium (99.0.1150.55)
    Internet Explorer: 11.0.22000.120

Severity
blocking all usage of SvelteKit
Additional Information
No response

Is this unique to SvelteKit, or is this an issue with Vite? If the latter then there's probably nothing we can do, and the issue should be opened on Vite's issue tracker instead

No, this works in Vite

@Rich-Harris I just pulled up a React project using vite-plugin-ssr and was able to get it working there.
Here's the gist of what's going on here.
In order for the native vite wasm behavior to work, we need to look at what's going wrong.
The vite generated init function opts => __vite_ssr_import_0__.default(opts, "/path/to/wasm.wasm")  relies on fetch to work. However, the SvelteKit server is refusing the file, and therefore cannot proceed.
The error above is invalid URL. This is because in SSR, import.meta.url is generating something of the form "file:///blah/path/to/file.wasm, which is being passed into the SvelteKit defined fetch`, which is causing the URL request to fail.
All that needs to happen for this to work, is for the server to successfully respond with queried *.wasm file...perhaps by transforming the "file://" into the actual "http://"schema. and, of course, returning the actual *.wasm file itself.
I believe that it would not work, if for example, fetch tried to read the file directly from disk and return it directly, but I might be wrong.

Are you sure the WASM module is being instantiated server-side in the React project you mention? If I create a simple test like this...
import vite from 'vite';

const server = await vite.createServer();

const { default: init } = await server.ssrLoadModule('/src/whatever.wasm');
const mod = await init();

console.log(mod);

...I get this error:
ReferenceError: fetch is not defined
    at Module.__vite_ssr_exports__.default (/__vite-wasm-helper:22:26)
    at __vite_ssr_exports__.default (/src/whatever.wasm:6:69)

It seems to me that this is a Vite issue, and you'll need to raise it over there.
Side-note: when creating repros, please remove all the extraneous junk (custom aliases, Tailwind config, etc). It might feel harmless but maintainers have to look at a large number of repros, and it takes longer to figure out what's pertinent and what's irrelevant when the repo is full of unnecessary files.

Please read this regarding Vite, SSR, and bug reporting: https://github.com/sveltejs/kit#bug-reporting

Closing as no response, and this seems very likely to be a Vite issue rather than a SvelteKit one

@jquesada2016 did you find a solution? I'm having the same issue and I'm lost scouring the deepest corners of the web trying to find an answer...

@jquesada2016 did you find a solution? I'm having the same issue and I'm lost scouring the deepest corners of the web trying to find an answer...

I did! What I am doing is to check if I'm in the server and passing init the module from disk. The trick is to find out where SvelteKit is going to place your final .wasm file,, because I did not find an easy solution for this one besides checking with the specific integration you're using.


ion-select changes not appearing on page for model-driven form with change detection set to OnPush

Short description of the problem:
<ion-select> changes are not appearing when using a FormBuilder form on a page, when ChangeDetectionStrategy.OnPush is used on a component.
What behavior are you expecting?
<ion-select> changes should appear when using a FormBuilder form on a page, when ChangeDetectionStrategy.OnPush is used on a component.
Steps to reproduce:

Add a component which uses FormBuilder, with an ion-select.
Set the change detection strategy to OnPush.
Try to select an item from the select box.

The plunker below best illustrates the issue.
Which Ionic Version? 1.x or 2.x
Ionic 2 RC2
Plunker that shows an example of your issue
http://plnkr.co/edit/SUhomP6GZ687mvzjA9jd?p=preview
The first three examples show the select box updating correctly after an item is selected, but the 4th does not.
Notice that ngModel-based forms are not affected, only ones built using FormBuilder.
Run ionic info from terminal/cmd prompt: (paste output below)
Your system information:

Cordova CLI: 6.3.1
Ionic Framework Version: 2.0.0-rc.2
Ionic CLI Version: 2.1.8
Ionic App Lib Version: 2.1.4
Ionic App Scripts Version: 0.0.44
ios-deploy version: Not installed
ios-sim version: Not installed
OS: Linux 4.8
Node Version: v6.7.0
Xcode version: Not installed

Have same issue with Range component.
Ionic 2.0.0-rc.3
https://github.com/iron9light/ionic-bug/tree/master/RangeNotUpdateWhenValueChangedByClick

Still no fix, ionic 2.1.0 :(


Added a blog

Read posts from markdown files in the blog folder

If you are planning to continue working on this, it needs to be re-submitted against R2Northstar/NorthstarTF.


Optimization question

Hi!
I'm just confused in how I can implement on a Uber-like system.
Let's say that I have my user geolocated and also I have his h3 index, if I want to find the nearest delivery man, I can do one of the following approaches:
First approach

Get the current h3 index where is located the user (resolution 8)
Search the database (that has h3 index set as the table index)
If no delivery mens are at that h3 index, search in its neighbors, and so on until I find one

can cost a lot
Second approach

Get the current h3 index of the user
Do an h3 radius lookup at resolution 8. The center is set on the user
Sort the results by nearest to farthest
If no delivery mens are found, the search radius in km is increased, until there's a delivery men that is near and has no jobs

i think this is the best approach
Third approach
???
Thank you so much for your time in advance!

So Uber didn't have H3 for a long time after it started. At first it was pretty simple: shard based on political boundaries (city/county/etc) where the pricing differs and keep all of the drivers indexed by that (there weren't really that many). Then take the rider's lat, lng and the drivers' lat, lng values, subtract them to get the delta-lat and delta-lng for each, multiply the delta-latitude by a constant based on one of the latitudes to roughly "square up" versus the longitude to avoid distance distortion (or just ignore it at first if you're relatively close to the equator, it only matters very far north), and then square the deltas and add them together, then sort the drivers by this ranking and you have them by distance from the rider.
With a small number of drivers, doing this in a tight loop is more efficient than any database-driven indexing approach. When you have a ton of potential riders and drivers you can do something trickier, but for Uber-style dispatching, the right next move isn't going to H3, it's using OSRM to calculate ETAs from the drivers to the rider and sorting by that, so you don't accidentally dispatch drivers across a river with few bridges.
Once OSRM is showing some signs of strain would you introduce something like S2 or H3 to do rough bucketing like you've described, but then you just feed that subset of drivers to OSRM because distance "as the crow flies" is not the best approach when cars don't fly.
In conclusion, for actual Uber-style dispatching, H3 is the last kind of micro-optimization you might need when you have a ridiculous volume of requests.

So Uber didn't have H3 for a long time after it started. At first it was pretty simple: shard based on political boundaries (city/county/etc) where the pricing differs and keep all of the drivers indexed by that (there weren't really that many). Then take the rider's lat, lng and the drivers' lat, lng values, subtract them to get the delta-lat and delta-lng for each, multiply the delta-latitude by a constant based on one of the latitudes to roughly "square up" versus the longitude to avoid distance distortion (or just ignore it at first if you're relatively close to the equator, it only matters very far north), and then square the deltas and add them together, then sort the drivers by this ranking and you have them by distance from the rider.
With a small number of drivers, doing this in a tight loop is more efficient than any database-driven indexing approach. When you have a ton of potential riders and drivers you can do something trickier, but for Uber-style dispatching, the right next move isn't going to H3, it's using OSRM to calculate ETAs from the drivers to the rider and sorting by that, so you don't accidentally dispatch drivers across a river with few bridges.
Once OSRM is showing some signs of strain would you introduce something like S2 or H3 to do rough bucketing like you've described, but then you just feed that subset of drivers to OSRM because distance "as the crow flies" is not the best approach when cars don't fly.
In conclusion, for actual Uber-style dispatching, H3 is the last kind of micro-optimization you might need when you have a ridiculous volume of requests.

Thank you A LOT! I was in this dilema hahaha, because I currently plan to have +5000 drivers and the database will be slow when comparing distances between all those drivers. That's why I wondered in those two approaches and then calculate, as you said, the route with OSRM to determine the best driver.
Thank you!!

So Uber didn't have H3 for a long time after it started. At first it was pretty simple: shard based on political boundaries (city/county/etc) where the pricing differs and keep all of the drivers indexed by that (there weren't really that many). Then take the rider's lat, lng and the drivers' lat, lng values, subtract them to get the delta-lat and delta-lng for each, multiply the delta-latitude by a constant based on one of the latitudes to roughly "square up" versus the longitude to avoid distance distortion (or just ignore it at first if you're relatively close to the equator, it only matters very far north), and then square the deltas and add them together, then sort the drivers by this ranking and you have them by distance from the rider.
With a small number of drivers, doing this in a tight loop is more efficient than any database-driven indexing approach. When you have a ton of potential riders and drivers you can do something trickier, but for Uber-style dispatching, the right next move isn't going to H3, it's using OSRM to calculate ETAs from the drivers to the rider and sorting by that, so you don't accidentally dispatch drivers across a river with few bridges.
Once OSRM is showing some signs of strain would you introduce something like S2 or H3 to do rough bucketing like you've described, but then you just feed that subset of drivers to OSRM because distance "as the crow flies" is not the best approach when cars don't fly.
In conclusion, for actual Uber-style dispatching, H3 is the last kind of micro-optimization you might need when you have a ridiculous volume of requests.

Thank you A LOT! I was in this dilema hahaha, because I currently plan to have +5000 drivers and the database will be slow when comparing distances between all those drivers. That's why I wondered in those two approaches and then calculate, as you said, the route with OSRM to determine the best driver.
Thank you!!

No problem. I would also recommend keeping just the driver location data in a fast, simple nosql DB like Redis with their ids grouped by whatever basic sharing strategy you have. It's basically ephemeral data so no point in slamming your main DB that probably persists all updates to disk and killing its performance.


Make the placement build option usable for crate user

Replace $PWD with $CARGO_MANIFEST_DIR which makes the placement build work properly when crate is used in other crates.

Wait, there are still some problems with $CARGO_MANIFEST_DIR. Investigation needed.

Links to https://github.com/rust-lang/cargo/issues/8397.

Oops that my fault, this actually works. But I cannot reopen it because this branch was force-updated.


1.19 crash

I am having crashing issues when I try to load my world with the mod.

You'll need to send your crash logs, otherwise I am not sure since it could be anything.


for #1475, SHOW [FUll] TABLES FROM db_name LIKE 'tb_name' failed to return the logic table

Fixes #1475 .
Changes proposed in this pull request:

when loading default tables ,get db catalog using schema name instead of data source name
parse like clause for ‘show tables’ syntax
modify 'show tables' route select

Pull Request Test Coverage Report for Build 5710

2 of 17 (11.76%)  changed or added relevant lines in 3 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-0.06%) to 70.997%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

sharding-core/src/main/java/io/shardingsphere/core/metadata/table/executor/TableMetaDataInitializer.java
0
4
0.0%

sharding-core/src/main/java/io/shardingsphere/core/parsing/parser/dialect/mysql/sql/MySQLShowParser.java
1
12
8.33%

Totals

Change from base Build 5708:
-0.06%

Covered Lines:
8832

Relevant Lines:
12440

💛  - Coveralls


Fixed flaky test MemoryLimitTest#testRejectMessages (#14220)

Fixes #14220
Motivation
Fixes #14220
Modifications
make sure OpSendMessages will not be sent to broker while sending messages, await util all message send, and await util all message send complete
Documentation
Check the box below or label this PR directly (if you have committer privilege).
Need to update docs?

[x] no-need-doc

bugfix for testcase

@codelipenghui @wuxuanqicn the test is failing on branch-2.8, see https://github.com/apache/pulsar/pull/14628 and https://github.com/apache/pulsar/runs/5961958349?check_suite_focus=true


cleanup messages and imds-tokens

Issue #, if available:
N/A
Description of changes:

Fixes a bug where the imds-token generated during AMI creation time sticks around when the AMI is launched. If the token is still valid, the IMDS call will fail since the token is not associated with the instance id that built the AMI. This is a small annoyance since it only affects instances that are launched within 15 minutes of AMI creation since the default IMDS Token TTL in the imds script is 900s. This is fixed by deleting /tmp/imds-tokens in the cleanup script.
I've already deleted /var/log/messages in the cleanup script to make debugging launch failures easier. Right now you have to find the start of the actual launch rather than the build logs.

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

Testing Done

Reproduced IMDS issue by increasing the token ttl to 6 hours and observing nodes launched w/ that test AMI not going to ready. Cleared the /tmp/imds-tokens and observed nodes launching correctly afterwards.
Built x86 AMI, launched in a cluster and observed nodes going to ready.

See this guide for recommended testing for PRs. Some tests may not apply. Completing tests and providing additional validation steps are not required, but it is recommended and may reduce review time and time to merge.

Nice find!
Could we just change this: https://github.com/awslabs/amazon-eks-ami/pull/1080/files#diff-c583b3c8574c1b8dfc5e9757b31caf1edd06ac89179d8c58d19f67e287a4ae51L8
to be
rm -rf /tmp

?
I don't think we ever want anything in /tmp to persist.

Nice find!
Could we just change this:
https://github.com/awslabs/amazon-eks-ami/blob/1003a8574682f9cc667651778b6732a8ed84cbe7/scripts/cleanup.sh#L8
to be
sudo rm -rf /tmp/*

?
I don't think we ever want anything in /tmp to persist.

Yeah I tried that first and it seems packer uses /tmp:
2022-11-03T14:16:05-05:00:     amazon-ebs: Cleaning repos: amzn2-core amzn2extra-docker amzn2extra-kernel-5.4
2022-11-03T14:16:05-05:00:     amazon-ebs: Cleaning up everything
2022-11-03T14:16:05-05:00:     amazon-ebs: Maybe you want: rm -rf /var/cache/yum, to also free up space taken by orphaned data from disabled or removed repos
2022-11-03T14:16:06-05:00: ==> amazon-ebs: Provisioning with shell script: /Users/wagnerbm/git/amazon-eks-ami/scripts/cleanup_additional_repos.sh
2022-11-03T14:21:07-05:00: ==> amazon-ebs: Provisioning step had errors: Running the cleanup provisioner, if present...
2022-11-03T14:21:07-05:00: ==> amazon-ebs: Terminating the source AWS instance...
2022-11-03T14:21:38-05:00: ==> amazon-ebs: Cleaning up any extra volumes...
2022-11-03T14:21:38-05:00: ==> amazon-ebs: No volumes to clean up, skipping
2022-11-03T14:21:38-05:00: ==> amazon-ebs: Deleting temporary security group...
2022-11-03T14:21:39-05:00: ==> amazon-ebs: Deleting temporary keypair...
2022-11-03T14:21:39-05:00: Build 'amazon-ebs' errored after 10 minutes 23 seconds: Error uploading script: scp: /tmp/script_3101.sh: Permission denied

==> Wait completed after 10 minutes 23 seconds

==> Some builds didn't complete successfully and had errors:
--> amazon-ebs: Error uploading script: scp: /tmp/script_3101.sh: Permission denied

Hm, deleting everything within /tmp could cause other issues too; I think systemd throws stuff in there. I'll ship it

Maybe in the future we can add a reboot at the end of the build process to reset /tmp.


ResourceReader Cannot Read Resource File

We are in the process of migrating an application from the .NET Framework to .NET Core 2, but it looks like the ResourceReader cannot process a valid resx file.
When I create the ResourceReader I get
System.ArgumentException: Stream is not a valid resource file.
   at System.Resources.ResourceReader._ReadResources()
   at System.Resources.ResourceReader.ReadResources()
   at System.Resources.ResourceReader..ctor(String fileName)

Here is a gist to the contents of the resx file.

This repository hosts the reference source for .Net Framework and is not for reporting issues with .Net Core. Can you close the issue here and reopen it in the coreclr repo, which is where the source for the .Net Core version of ResourceReader is located?

Done.  Here is the new issue: https://github.com/dotnet/coreclr/issues/17946
Thanks.


NEXT: App Bar

[!WARNING]
This issue is a work in progress.

This will act as a hub to centralize this information.
Maintainer Requests
The following requests are coming straight from the Skeleton team. These are highly likely be implemented:

[ ] Port forward the prototype iteration. Though note the pending PR feedback not yet implemented.
[ ] See Material Design Top App Bar for reference and guidelines
[ ] Try to keep the positions/slots as simple as possible
[ ] Aim to make layout adjustments as simple as possible (maybe Grid is too difficult?)

Community Requests
The following requests have come from the community and are under consideration:

n/a

Bugs and Issues

n/a

Feedback
If you have additional updates or requests for this feature, please do so in the comments section below.

Reference and inspiration...
Agnostic:

https://m3.material.io/components/top-app-bar/overview
https://tailwindui.com/components/marketing/elements/headers
https://carbondesignsystem.com/components/UI-shell-header/usage/
https://daisyui.com/components/navbar/

React:

https://mui.com/material-ui/react-app-bar/

Svelte

https://melt-ui.com/docs/builders/toolbar
https://www.bits-ui.com/docs/components/toolbar

@Mahmoud-zino I believe @Hugos68 gave his blessing for you to take this over if you wish. The prototype implementation is linked above. Just make sure to implement the feedback present on the PR as you go please! Thanks!


Support for later versions of jquery?

Can you switch to 3.x major version of jquery?

@jonathanbarton Hi, I haven't tried using jQuery 3. I'll investigate compatibility and report back.

At least, could we switch to ~ instead of ^ on the package.json? It helps minimize potential for sibling packages to have peer dependency issues

So https://github.com/nostalgiaz/bootstrap-switch/commit/77c5bd3b7bcda4a8c47f6a7385516091f6f4b7eb ?

Sorry for delay: https://github.com/nostalgiaz/bootstrap-switch/pull/613

+1, the version of jQuery used by this package includes this vulnerability https://github.com/jquery/jquery/issues/2432 , it's the only thing holding up me from using bootstrap-switch

@dLobatog We changes the possible matched versions. Did the change make the library usable with jquery#3.x.x?

Hi, if I understand correctly by changing jquery dependency from >=1.9.0 to ~1.9.0 you've make it more strict. Previously it was able to use 1.13.4 but now only 1.9.0
Could you please revert this restriction back?

Looks like it should be ^1.9
On 28 Feb 2017 1:28 pm, "Alexander Kapelyukhovskiy" <
<EMAIL_ADDRESS>wrote:

Hi, if I understand correctly by changing jquery dependency from >=1.9.0
to ~1.9.0 you've make it more strict. Previously it was able to use 1.13.4
but now only 1.9.0
Could you please revert this restriction back?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/Bttstrp/bootstrap-switch/issues/612#issuecomment-283038348,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAZQTFL21SNwH9JiXyJ1G6Y1loIH-tfcks5rhCDfgaJpZM4L5tXi
.

+1  (using jquery 3.x)

i understand that testing with jquery 3.x is time consuming, but with the last modification bootstrap-switch wants only jquery 1.9.x and it is very annoying considering that works perfectly with jquery 1.12.x (at least in my enviroment).
I have to stick with bootstrap-switch 3.3.3 for this reason

We just came across this after a bower update and a newer angular bootstrap switching being loaded. As version 3.3.2 was allowing installations with jquery 3, it's very likely that it's been used with jquery 3 in the wild. Forcing jquery back 1.9 is going to be unacceptable for many.


[FEATURE]: Do you consider adding plenary.job like feature in a nio way?

Ref: plenary.job.
As title. It'd be awesome if it could be implemented without using callbacks.
-- Just my random thoughts.
nio.run(function()
  local job = nio.job.new("echo foo; echo bar; echo baz 1>&2")
  local iter = job:start()
  for line in iter do
    if line.type == "stdout" then
      on_stdout(line.content)
    elseif line.type == "stderr" then
      on_stderr(line.content)
    elseif line.type == "exit" then
      on_exit(line.exit_stat --[[@as integer]])
    end
  end
end)

Love the idea of having an abstraction over running subprocesses though would prefer a more flexible API.
I've got an initial implementation in #7, feel free to try it out (though it's still WIP)! The docs are quite sparse, I'd like to add more examples, but for now you can see the usage in the tests

I'm not on my pc right now so I can't test it right away but I love the simplicity and also that I have the ability to pipe between multiple commands is absolutely awesome. Great job!!
One FR: would it be possible to loop through each line of stdout without waiting for the command to finish? For example the output from fd can be parsed one line at a time and processing one at a time.

Glad to hear you like it! I'll leave this change as the minimal interface for now. Reading lines (or until any separator) is relatively complex to do efficiently, and relatively trivial to do be not efficient. I'd rather get the interface "right" rather than half baked and have to deprecate things later. PRs welcome of course though
For reference, here's CPython's implementation of readuntil https://github.com/python/cpython/blob/7a470541e2bbc6f3e87a6d813e2ec42cf726de7a/Lib/asyncio/streams.py#L580 :sweat_smile:

Thanks @rcarriga . I can officially recommend to neo-tree now :) https://github.com/nvim-neo-tree/neo-tree.nvim/discussions/1342

For reference, here's CPython's implementation of readuntil<EMAIL_ADDRESS>😅

I'm actually surprised that this mechanism was implemented in python and not directly modifying the stream inside internal C code.
So, from what I understand, in the below code, lua will run until second.stdout without any block, and then blocked at .read()? And this code flow will be blocked until after cat prints a EOF to its stdout?
 local first = nio.process.run({
   cmd = "printf", args = { "hello" }
 })

 local second = nio.process.run({
   cmd = "cat", stdin = first.stdout
 })

 local output = second.stdout.read()
 print(output)

I can officially recommend to neo-tree now :) https://github.com/nvim-neo-tree/neo-tree.nvim/discussions/1342

Awesome, great to see it being used :smile:

So, from what I understand, in the below code, lua will run until second.stdout without any block, and then blocked at .read()? And this code flow will be blocked until after cat prints a EOF to its stdout?

Yep that's correct :ok_hand:


PowerToys Keyboard Manager does not work "in/over" virtual machines in VMware Workstation 16 Player

Microsoft PowerToys version
"0.58.0"
Running as admin

[ ] Yes

Area(s) with issue?
Keyboard Manager
Steps to reproduce
Hi! I have some re-assigned keys and shortcuts. They are not working in virtual machines run on VMware Workstation 16 Player.
✔ Expected Behavior
I expect my re-assigments to follow me into the virtual machines, just like some other keyboard-re-assignment software does (like Logitech G-hub).
❌ Actual Behavior
The input in the VM is as if PowerToys was not running. The re-assigments do not apply when input is directed to it.
Other Software
VMware Workstation 16 Playe

It's likely the virtualization software is also accessing the keys at a low level like it's our case. In this case, installing PowerToys in the VM might be a way around it as well.

Ok. I see other re-assigment software such as "Logitech G-hub" works inside the VM too, as does "SharpKeys" (obviously, as it changes registry values). But "Logitech Options+ Beta" and "Microsoft PowerToys" does however not work in the VM.
They are Linux VM's as well, so using PowerToys in the VM is not a solution, besides the whole point is to not have to use and set up a software for my shortcuts in every VM I create. I've solved my case by using Windows Subsystem for Linux and programming/testing my code there before pasting it into the VM, aka. by doing my work outside the VM.
But the optimal solution would be for PowerToys to work at a lower level like other software's who's reassignments do work everywhere. If this is at all possible in your case. But I also understand if that is too much work to change at this point. You could consider it for later or something maybe though. Good luck with other fixes 👍

Why in the world was this marked as resolved?
This is a fatal flaw for any keyboard manager software, sand other keyboard manager software's does not have it!
How can you mark this as "resolution external".
This shows a really bad spirit from the Devs when it comes to making the PowerToys keyboard manager an actual "proper" keyboard manager software...

I'm having this issue as well.  I've got dozens of VMs.  I'm not going to install power toys in all of them.

I'm having this issue, and I agree that installing PowerToys in the VM isn't a workable solution in many cases.

Hey @jaimecbernardo
Any idea how to proceed with hotkeys, that I want to work on the host?
Current behavior is e.g. that I bind PowerToys Run to win+r.
That works in all windows, but VMware Workstation. When the window is active either (within the VM) nothing happens or (after clicking on the left sidebar) the hotkey will open the run command and bypasses PowerToys Run completly.
The same of course applied to all other PowerToys hotkey bindings.
Maybe @SeraphimaZykova do you know who could address this issue?
Or would we have to contact VMware for a fix?
Thanks in advance!

My guess here is that VM just sends input directly to the VM before it gets to us. Which sort of makes sense. Your input is captured by the VM.
I think there's a feature request to indicate which keys/shortcut VMWare shouldn't capture, but I'm not sure if this was ever included in VMWare.

It's likely the virtualization software is also accessing the keys at a low level like it's our case. In this case, installing PowerToys in the VM might be a way around it as well.

What if the Virtual Machine is Ubuntu? I don't think it's a good solution.

If anyone is still dealing with this issue:
Unchecking "Auto Capture Keyboard" under Input > Keyboard > Keyboard Settings will help

Well, that's just a work around. As soon as you capture the keyboard the host hotkeys stop working.
A bit sad that neither VMware nor Microsoft provided a proper fix for this.
I moved completely to Wayland on Linux  as the hotkeys will be properly intercepted in the host.


Omelette command creates broken symlink inside volto

Tested with @sneridagh , this should be the correct script in package.json:
"omelette": "if [ ! -d omelette ]; then ln -sf node_modules/@plone/volto omelette; fi",

The generators have to be updated as well.

This causes warnings like:
[Error: ENOENT: no such file or directory, stat '/home/tibi/work/rancher/semsearch/node_modules/@plone/volto/volto']

Fixed in #3284


form is not resetting its value

my submit function
   submit = (values) => {
      return axios
         .post('shops', values)
         .then((res) => {
            alert.success('Shop Created.'); // on success, its showing
            this.refs.newShopForm.reset(); // but this is not setting forms value
         })
         .catch((err) => {
            this.refs.newShopForm.updateInputsWithError(err.response.data); // on error, its showing errors
         });
   };

I'm having the same issue. Can't get the form to reset

Cannot for the life of me get the from to reset its values.
Trying:
this.refs.form.reset();

Tried passing value={this.state.something} and then calling this.setState({value: ''}) on submit. That didn't work either.

same here

Me too, using formsy-material-ui. And I'm stuck when it comes to debugging it too.

Me too.
I'm not having the issue with react v0.14.x but having it used with react 15.x

Are you guys using getValue() on your custom input element?

You should always use the getValue() method inside your formsy form element.

In my experience it resets the formsy val, but not the values of the form elements.

I agree with that. Resetting the form values is not same as resetting the form elements. Writing the formsyComponents in such a way that resetting the values using this.refs.form.reset() will reset the value of the element thereby forcing the form elements to change would do.

@brianfegan and @prasanna1211 would you mind providing sample code? In my experience reset works fine but only when you use getValue() in your component.

Where would the getValue() go in the form element component? Currently, I'm just using setValue inside onChange event handlers.
To actually reset the HOC form element value, I pass a callback into HOC form element from the formsy form component that gets called when the HOC form element mounts. That formsy form callback has an  arg that's a ref to a custom HOC form element reset method callback to setValue within the form element component.
It works but its not the cleanest implementation for sure.

@brianfegan as the value attribute itself https://github.com/christianalfoni/formsy-react/blob/master/examples/components/Input.js#L35
Try updating your component to use getValue and let me know how it goes.

Yeah, I'm using that for individual text inputs. But the issue I described deals with multi checkbox values.

...though I suppose based on what you said, the custom reset method in the HOC could call getValue to repopulate the state in the HOC component (currently I pass the new value in as an arg and don't use getValue).

@brianfegan Yeah you really should be using getValue. Would you mind setting up a demo repo of the problem you're facing?

I'm using a very slightly modified version of https://github.com/christianalfoni/formsy-react/blob/master/examples/components/MultiCheckboxSet.js. Just added some markup for styling. As you can see, there's no getValue in that example.

I had the same problem but just with textarea fields. I have a formsy-react wrapper for my input components so I can use them with o without formsy-react. Calling reset was cleaning the values as expected but passing undefined as a value to the children component didn't updated it so I end up passing value={this.getValue() || ''} and that solved the issue

So is there a way to manually set the value of an input of a FormsyText component and have the actual form input get updated?
I have tried setValue through a very ugly way ( something like this.refs.form.inputs[this.refs.form.prevInputNames.indexOf("name")].setValue("TEST") ) and the value is updated when getting it back, for the form UI is never updated, there are no visual changes.
How can this be achieved easier?


[PLAT-27934] Builds and tests as a GH action

This will run builds and tests on PRs for both the launcher and the agent.
I also added a workflow_dispatch event so we can trigger this manually if we want to.

I can't figure out how to run this without merging, so I will merge to see if the "Run workflow" shows up in the actions tab

I can't figure out how to run this without merging, so I will merge to see if the "Run workflow" shows up in the actions tab

https://github.com/databricks/devbox/actions/runs/518075061

https://github.com/databricks/devbox/actions/runs/518075061


Python 3.6 support: sqlite3.OperationalError: Safety level may not be changed inside a transaction

fails in python3.6 with
Exception in thread Thread-2:
Traceback (most recent call last):
File "/usr/lib/python3.6/threading.py", line 916, in _bootstrap_inner
self.run()
File ".../site-packages/sqlitedict.py", line 371, in run
cursor.execute('PRAGMA synchronous=OFF')
sqlite3.OperationalError: Safety level may not be changed inside a transaction

How can this be reproduced? It doesn't come up in Travis Python 3.6 tests

creating a new instance with autocommit=False triggers this here:
test = SqliteDict(autocommit=False)

Looks like travis still does not fail, even without a new test, make test-all fails here on Arch Linux and Debian/unstable with python3.6 and sqlite 3.16.2

Let's check sqlite version used in Travis in https://github.com/RaRe-Technologies/sqlitedict/pull/62

Hmm the sqlite version in travis is really old.

Also fails with Ubuntu 17.04 (sqlite 3.15.2).
Here a Dockerfile to test with Ubuntu 17.04, possibly something like that can be added to travis

Also fails in Ubuntu 16.06 (sqlite 3.14.1 / Python 3.6)


chore: fix lint-staged

PR Checklist
Please check if your PR fulfills the following requirements:

[x] The commit message follows our guidelines: https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/CONTRIBUTING.md#commit
[ ] Tests for the changes have been added (for bug fixes / features)
[ ] Docs have been added / updated (for bug fixes / features)

PR Type
What kind of change does this PR introduce?

[x] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Documentation content changes
[ ] Application (the showcase website) / infrastructure changes
[ ] Other... Please describe:

What is the current behavior?

Issue Number: N/A
What is the new behavior?
Lint checks can now be done correctly for staged changes.
Does this PR introduce a breaking change?
[ ] Yes
[x] No

Other information

LGTM!
testing folders should be linted as well.
BTW, it seems that the tslint-rules has been deperecated for a long time, I think it's time to remove it

I think I'll remove tslint-rules entirely in another PR :)

I think I'll remove tslint-rules entirely in another PR :)

I'am done with pr #8445


Styling all email messages in a consistent manner.

Fix for https://www.pivotaltracker.com/story/show/151427870

We also need the site_persistence PRs to remove styling from the non-LR email content:
ePROMs: https://github.com/uwcirg/ePROMs-site-config/pull/68
TrueNTH: https://github.com/uwcirg/TrueNTH-USA-site-config/pull/58