added coinbase wallet option

Added @web3-react/walletlink-connector package to add Coinbase Wallet option.  Metamask and Coinbase prompt pops up when you click Metamask.
Walletlink connector implementation was borrowed from the way Uniswap does their connections.
Also tested on Brave and it works out of the box.

If you made a contract change, make sure to complete the checklist below before merging it in master.
Refer to our documentation for more details about contract security best practices.
Contract change checklist:

[ ] Code reviewed by 2 reviewers. See template and example.
[ ] Unit tests pass
[ ] Slither tests pass with no warning
[ ] Echidna tests pass if PR includes changes to OUSD contract (not automated, run manually on local)

We shouldn't need to introduce WalletLink for this, should we? What do we gain by doing that?

@micahalcorn I noticed that with WalletLink, only the Coinbase prompt pops up when you connect a Coinbase wallet. Thought that UX was better than using the same connector as MM and having both prompt pop up for connecting MM and/or Coinbase.
Another UX benefit with WalletLink, if the user tries to connect with Coinbase and doesn't have the extension installed, it will pop up a Coinbase modal asking to install the extension or scan QR code with phone.
If we used the MM connector instead and the user doesn't have Coinbase extension, then it'll pop up a MM prompt instead (assuming user has MM extension installed), which doesn't make sense to me.

@micahalcorn I noticed that with WalletLink, only the Coinbase prompt pops up when you connect a Coinbase wallet. Thought that UX was better than using the same connector as MM and having both prompt pop up for connecting MM and/or Coinbase.
Another UX benefit with WalletLink, if the user tries to connect with Coinbase and doesn't have the extension installed, it will pop up a Coinbase modal asking to install the extension or scan QR code with phone. If we used the MM connector instead and the user doesn't have Coinbase extension, then it'll pop up a MM prompt instead (assuming user has MM extension installed), which doesn't make sense to me.

Okay, as you point out, it still gives you redundant popups when clicking MetaMask, so I'm not sure if it's worth the additional dependency or not. I'll defer to @sparrowDom and @tomlinton. It would also be good to confirm that it plays nicely with WalletConnect.

I might be missing what was the goal with this PR. The Coinbase wallet connects nicely to what is currently in production:

I might be missing what was the goal with this PR. The Coinbase wallet connects nicely to what is currently in production:

See https://github.com/OriginProtocol/origin-dollar/issues/634 🙂 Users were complaining because they thought we didn't support it. If you're in a desktop environment, you have to explicitly click a button and they didn't know to click the MetaMask option. So I was proposing that we just add a button, particularly now that Coinbase Wallet has a browser extension.

I might be missing what was the goal with this PR. The Coinbase wallet connects nicely to what is currently in production:

See #634 🙂 Users were complaining because they thought we didn't support it. If you're in a desktop environment, you have to explicitly click a button and they didn't know to click the MetaMask option. So I was proposing that we just add a button, particularly now that Coinbase Wallet has a browser extension.

Thanks, I should have figured that out :)

Thanks for the fixes @calvintoes. Looks good to me.
The dependencies of walletlink are a bit rough, preact and rxjs? I wonder why it requires that.

Closing this PR since @calvintoes mentioned to me he won't be able to bring it to the finish line...


support/fuzz: Add xdr.ClaimPredicate JSON fuzzing

What
Add support/fuzz package and the first fuzzer for xdr.ClaimPredicate JSON methods.
Why
A bug in xdr.ClaimPredicate.MarshalJSON (https://github.com/stellar/go/pull/3179) stopped ingestion in testnet. I wrote a fuzzer to ensure there are no more bugs. Added files to separate support/fuzz package to add more fuzzers in the future.
Known limitations
Do we want to add fuzzers here or to separate repo?

how did you generate the corpus?

I created just one file (0) from unit tests. The rest was found by go-fuzz.

I moved the file to xdr/fuzz/jsonclaimpredicate. The reason for this location is that in case there are multiple fuzzing function per package they will have different corpus dirs. It will be much easier to run this way (using default values for CLI params so with go-fuzz).


Blinkenlights

Color build button based on build status.
Fixes #433

SonarQube analysis reported 1 issue
Note: The following issues were found on lines that were not modified in the pull request. Because these issues can't be reported as line comments, they are summarized here:

 AncientFungus:LGEPR: Cppcheck cannot find all the include files (use --check-config for details)


[iOS] matrix path not found in json

Describe the bug
I see the following warning for all shards in the flank ouput matrix path not found in json ...
To Reproduce
Steps to reproduce the behaviour:

Run ios test suite via flank
See warning in the output

Expected behaviour
none warning should be shown
Details (please complete the following information):

Have you tested on the latest Flank snapshot? no
flank version: v20.06.0
revision: 77f18db6109b49496fe82c99a553f16414f7366a

Can you attach your flank.yml? I want to be sure we going to the right side.
Thanks! @andreschab90

@piotradamczyk5
gcloud:
results-bucket: testlab
record-video: true
timeout: 30m
async: false
results-history-name: PROD
num-flaky-test-attempts: 1
test: $BITRISE_TEST_BUNDLE_ZIP_PATH
xctestrun-file: $BITRISE_XCTESTRUN_FILE_PATH
device:

model: iphonexr
version: 13.2
locale: en
orientation: portrait
flank:
max-test-shards: 15
shard-time: -1
num-test-runs: 1
smart-flank-gcs-path: gs://testlab-/firebase-test-calculation/results.xml
smart-flank-disable-upload: true
disable-sharding: false
project: testing


Qt problem

Excuse me, I try to run demo but got the Qt problem. Do you know how to fix it? Thanks.
This application failed to start because it could not find or load the Qt platform plugin "xcb"
in "".

Available platform plugins are: eglfs, minimal, minimalegl, offscreen, vnc, xcb.

Reinstalling the application may fix this problem.

problem fixed by reinstall fontconfig.


Setup circleci / travis builds

The advantage of doing this instead of your current cron job is that you get to verify that it works on OS X as well with clang.

@alexanderkjeldaas do you want builds on all lts?

I think just some lts is good.  Probably best to track the newest ones.


Consider cleanup of com.bol.util

Utilities currently assume behavior which is subject to change in a future version (e.g. Java 9, 10, …). Consider removing final field modification in favor of requiring a proper runtime setup.
Also, implementing a sneaky throws behavior isn't something that belongs into a library as it can cause quite some surprise during runtime.

Agreed on both points.
I've replaced Thrower with a properly phrased RuntimeException in release 1.1.0.
As for the crypt, since restricted mode has just been enabled in java8u162 (see https://bugs.openjdk.java.net/browse/JDK-8170157), I've deprecated it spring-data-mongodb-encrypt and changed to log a warning on failure instead of throwing an exception. I will remove it later on.
Thanks for your feedback!


asyncio.gather tracing produces nested spans

I've got the following code:
import asyncio
import sentry_sdk

async def foo():
    with sentry_sdk.start_span(op="foo"):
        await asyncio.sleep(1)

async def bar():
    with sentry_sdk.start_span(op="bar"):
        await asyncio.sleep(1)

with sentry_sdk.start_span(op="root"):
    await asyncio.gather(foo(), bar(), return_exceptions=True)

I see that bar is nested under foo, and foo is nested under root in the Performance UI.
root
    |- foo
         |- bar

Expected behavior: both foo and bar are nested under root and are on the same level.
root
    |- foo
    |- bar

yes, our asyncio support is somewhat limited at the moment. As a workaround you can do:
import asyncio
import sentry_sdk

async def foo():
    with sentry_sdk.Hub(sentry_sdk.Hub.current):
        with sentry_sdk.start_span(op="foo"):
            await asyncio.sleep(1)

async def bar():
    with sentry_sdk.Hub(sentry_sdk.Hub.current):
        with sentry_sdk.start_span(op="bar"):
            await asyncio.sleep(1)

with sentry_sdk.start_span(op="root"):
    await asyncio.gather(asyncio.create_task(foo()), asyncio.create_task(bar()), return_exceptions=True)

I am not sure if create_task is strictly necessary or if gather does that for you.

Yes, asyncio.gather launches new Task-s, via https://docs.python.org/3/library/asyncio-task.html#asyncio.gather

If any awaitable in aws is a coroutine, it is automatically scheduled as a Task.

All right, thanks for the workaround!

@untitaker do you have any plans to add this as first-class support? we are heavy users of this asyncio and this creates unreadable traces

@yoav-orca not at the moment. It would also require heavy monkeypatching of the asyncio runtime afaik

We're currently looking into this and as far as I can tell we can tell asyncio to use a custom task factory which will wrap all tasks with hub cloning and that should fix this issue.
https://docs.python.org/3/library/asyncio-eventloop.html#asyncio.loop.set_task_factory
We just have to be careful to take into account if there's another factory override and be good citizens on our end in both cases (default/existing custom factory).

I have now created a reproduction repo:
https://github.com/getsentry/minimum_python_async/blob/main/task1.py
And I created a new AsyncioIntegration that produces now this output:

Which is the output we want to have :)

To anyone still facing this issue, you may be initializing sentry incorrectly. I published a blog post explaining the reason and the fix
https://www.bhandarkar.me/blog/setup-sentry-with-asyncio


common dynamic redirects - www, bare domain, https

I took a look at redir, but the docs appear to only address the issue of a pathname, not host.
Is there currently a way to handle any of these common redirects?

HSTS redirect all http to https
nowww redirect all www prefixed domains to their bare domain
yeswww redirect all bare domains (without www) to a domain with www

HSTS is just adding a header.
nowww:
www.example.com {
    redir https://example.com
}

yeswww:
example.com {
   redir http://www.example.com
}

There's an HSTS header, but you are also required to redirect http to https. The header doesn't do that for you (except in some browsers that are HSTS aware and choose to be forgiving of your forgetfulness).
Are you showing that if I omit the http/https prefix that it will auto redirect to https when http is encountered?
Still no way to handle domains en masse on the yeswww nowww though?
Hmmm... I keep running into this issue of needing blanket configuration using a hostname template rather than individual entries on a domain-by-domain basis.
My particular use case at the moment is redirect-www.org. I was going to switch to hosting it with caddy, but I can't yet.

Are you showing that if I omit the http/https prefix that it will auto redirect to https when http is encountered?

If you use 0.8 beta's managed SSL, you don't have to set up redirects at all. It does it for you. In which case you just set the HSTS header yourself -- though perhaps some security middleware could help with that; #312)...

Matt and I chatted on slack about this and the hsts header did work. SSL Labs recognized the additional header.

Care to document what that (typical) header configuration line was exactly please?

@kaihendry I haven't tried it myself yet but in theory it should simply be the standard HSTS header which looks something like this.
header / Strict-Transport-Security "max-age=31536000"

Which would set it to 365 days.


documented the 'blessed' way to import dax extras

Implements https://github.com/impactaky/dax_extras/issues/2#issuecomment-1620274572
Requires that you push a new tag 2.2.0-0.32.0
Pros:

feels intuitive, its more obvious that we're extending dax not a different library
theoretically this approach allows the user to use other libraries that also extend dax, at the same time

Cons:

nothing comes to mind

Codecov Report

Merging #25 (6df9f04) into main (b3fcea3) will not change coverage.
The diff coverage is n/a.

:exclamation: Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.
@@           Coverage Diff           @@
##             main      #25   +/-   ##
=======================================
  Coverage   81.81%   81.81%
=======================================
  Files           6        6
  Lines         275      275
  Branches        8        8
=======================================
  Hits          225      225
  Misses         50       50

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

I also removed the export $ so we have only one way to import

Since I remove the export, I changed the proposed version to 3.0.0-0.32.0

I want to use one line import

Ok, what do you think about the part of  releasing the new versions with dax suffixes appended ?

If that's an acceptable idea, I update the pr to only update the readme

Done<EMAIL_ADDRESS>

thanks!


Add include_keys and exclude_keys options to sink

Description
Add include_keys and exclude_keys options to sink
Issues Resolved
Resolve #2975
Check List

[x] New functionality includes testing.
[ ] New functionality has been documented.

[x] New functionality has javadoc added

[x]  Commits are signed with a real name per the DCO

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@daixba , Thank you for this submission. I'd like to discuss some in the original issue about finding a way to solve this with multiple pipelines. That is largely what pipeline connectors are to help solve, and I'm concerned that this approach will grow such that we have two sets of processors - the normal processors and sink processors.


project information panel should support context menu

There are likely other places that need the same

How are you imagining this for the project information tile? Keep in mind that the project information screen will be improved

How are you imagining this for the project information tile?

It is normal to expect to be able to copy the information from that tile - so the context menu should support that operation. That remains true regardless of the future improvement, unless that improvement includes something like this:

Just to be safe: something like this is a reference to the button that copies something to the clipboard.

:+1: lets find a small javascript context menu library to help us

Yep, let me do that, so I can crack the ice (so far, I am just circling around like a dog that wants to lay down)

I will use this (https://github.com/electron/electron/blob/master/docs/api/menu.md) to implement the context menus.
I am assuming that all plugins run as renderer threads

@adriatic instead of using electron (because then monterey will have a dependency on electron, and we'd need to go through the PAL if we're being consistent) perhaps a browser javascript library is better.

perhaps a browser javascript library is better

Which confirms my approach that (unless I am an absolute ruler) it is a lot better to signal my intents before doing anything.

Choice number 2: https://www.sitepoint.com/building-custom-right-click-context-menu-javascript/

@adriatic
Dunno if you can use any of this, but Ill paste in in anyway
Some parts are tied into the grid, and some parts isnt really good, so might be easier to make something from scratch :smile:
Attribute class.
https://github.com/vegarringdal/aurelia-v-grid-TOOLKIT_FORK/blob/master/src/vGrid/v-grid-attributes-contextmenu.js
Baseclass
https://github.com/vegarringdal/aurelia-v-grid-TOOLKIT_FORK/blob/master/src/vGrid/v-grid-contextmenu.js
css:
https://github.com/aurelia-ui-toolkits/aurelia-v-grid/blob/master/src/vGrid/styles/v-grid-contextmenu.css

@adriatic sounds like a good option. Also consider https://github.com/aantthony/contextmenu which seems to have a nice API to work with

My tendency after seeing all these alternatives is to look at  https://github.com/aantthony/contextmenu first (seems to have a nice API to work with) :-)

i'm not sure if we should add a context menu just for this feature, as the same can be accomplished with a button:

(used clipboard.js for this). Going to track all use cases that might benefit from a context menu in this issue https://github.com/monterey-framework/monterey/issues/61


Change default head/tail scope to be line bounded by matching pairs

If no scope is specified for head/tail instead of defaulting to just line we now use the smallest of line or surrounding pair interior. This means that "take head" would be bounded by the surrounding pair just like "short paint". If there is no surrounding pair the line is used just like today. You can also override this behavior by specifying line. "take head line" would always use the line regardless if you are in a surrounding pair or not.
Fixes #2434
The issue mentions a tag for this. I guess since this change is fully extension side it would be a vscode setting, but in tempted to just have this be enabled by default since it's a really useful feature.
Checklist

[x] I have added tests
[/] I have updated the docs and cheatsheet
[/] I have not broken the cheatsheet

Do we have a feeling for how many users would be surprised by change to the take head / take tail default behavior?

I misunderstood, in my head I was thinking of pre line or just the commonly defined head or tail commands to go to the beginning or the end the line, which won't be affected by this.
I agree it's much more likely that people will want to select up to the bounding of a surrounding pair if they're in one, rather than the beginning of the line. Andreas has mentioned the use case of inside of a Python docstring, which is a good example. The fact that they can still use take head line to get the original behavior seems like a reasonable compromise if anyone is annoyed by that.
As a bonus you can also now say pre head to go to the beginning of either the surrounding pair interior or the line, which now behaves more like a smart selector, instead of having to think about whether you want pre line or pre core (interior, etc)

Also note: it won't always select the surrounding pair; it will select the containing scope that's smaller. So if the surrounding pair covers multiple lines the line will always be smaller.

Let's add this to release notes because it's a useful change


Added python code for Least Number of Unique Integers after K Removals

Hey there!, Thanks for submitting a PR to this repo :smiley:
Please complete the following checklist for your PR to be approved. Mark the items by adding an x.
Example:  - [ ] Mark me as completed
To mark: - [x] Mark me as completed

[x] My Pull Request adheres to the Contribution guidelines.
[x] I have added problem.md and solution files in the appropriate folder.
[x] In problem.md I have provided a correct link to the problem.
(In case you are not adding a problem, you can freely mark this as complete)
[x] The solution I have given is my own and not plagiarized in any form.
[x] My solution passes all the testcases within the given constraints.
[x] I have properly indented and documented my solution using comments.
[x] I agree that all the above marked are true to the best of my knowledge and my PR can be closed if found otherwise.

If any of the above is unmarked, please make the necessary changes and then mark them so that you're PR can be approved and merged.
(Only completed checklist PRs will be reviewed)

Please add the problem link in problem.md. This is clearly mentioned in the contribution guidelines as well as in your PR

Added Now


tweetLink filter href has no value and target is missing when rendered.

Just pic.twitter... link. The rest works fine!

Somehow the code seems to be working fine when the URL Regex is passing so this means its not the filter, Need to look into why this is causing a problem when executing it.

Maybe the filters after this are causing it? Try removing all filters after this one and check if it happens?

Will be fixed with the next merge.


Re-enable leader election test

This may have been fixed by PR #2418.

@jwilder

This may fix issue #2303 .

:+1:

OK, we havd 5 passes, 1 failure (unrelated test). This test does look more stable -- merging now.


IDE gets slower and slower over time until it stops working

$ flutter --version

Flutter 1.6.0 • channel dev • git@github.com:flutter/flutter.git
Framework • revision ed90d05596 (9 days ago) • 2019-05-14 17:09:29 -0700
Engine • revision 832cdacc6f
Tools • Dart 2.3.1 (build 2.3.1-dev.0.0 a0290f823c)

I am using:

Visual Studio Code (Version 1.33.1 (1.33.1))
Dart and Flutter Plugins (3.0.2)

I have a moderate-sized Flutter application (hobby app). I can't reproduce this with a specific series of steps, but generally this happens every single time:

I run the application and use hot reload (on save) to debug/iterate.
The analyzer/auto-complete gets slower and slower until it does nothing.

For example, here is what the IDE shows:

You can see the following diagnostic being shown:
{
	"resource": "/Users/.../lib/src/pages/squads.dart",
	"owner": "dart",
	"code": "missing_function_body",
	"severity": 8,
	"message": "A function body must be provided.\nTry adding a function body.",
	"source": "dart",
	"startLineNumber": 65,
	"startColumn": 3,
	"endLineNumber": 65,
	"endColumn": 4,
	"tags": []
}

This is wrong, and is based on what I wrote 30+ seconds ago, and isn't updating. Even closing/opening the file again does nothing (the same diagnostics show up).
Once I get to this state, hot reload/restart and even the "stop" button also stop functioning, so it's possible this is some sort of bug/leak on the IDE side instead of the analyzer, I can't exactly tell. Even killall dart does not work. I can close the IDE and re-open it, but that's it.
Note that I see Analyzing... in the lower bottom-left corner during this.

OK, so I already hit this again 30 minutes later. In this case, the IDE again is still functioning (including hot reload on save), but anything that seems to use the analyzer does not function:

FWIW, VS Code detected a crash:

After this, hot reload/restart also stopped functioning.

cc @DanTup @devoncarew

Note that I see Analyzing... in the lower bottom-left corner during this.

I wonder if you're seeing https://github.com/Dart-Code/Dart-Code/issues/1692. Do you have the dart.analyzerObservatoryPort setting set? If so, try removing it and see if the issue goes away (if so, you can install vNext beta for a better fix). That issue is caused by the VM sometimes unexpectedly pausing on handled exceptions (https://github.com/dart-lang/sdk/issues/36911) when we use --observe (which should only pause on unhandled exceptions) - but since we really want pausing on uncaught ones either, vNext switches from --observe to --enable-vm-service.
If that doesn't help, please enable the analysis server log file. It'll overwrite itself on each load of VS and log all communication with the server. Then when you next see it, grab a copy of the log.

Interesting, because I explicitly chose Start Without Debugging.
I'll try anyway @DanTup and report back.

So, I ran and checked the ideas you had. I don't see anything suspicious, though, and the slow downs (and eventually crapping out) still happens. Is there anything specific I should be looking for in any of these logs?

Start Without Debugging

The Observatory setting I mentioned is for the analyzer server (we have it to help debug the server) and not the project you're running directly. However, it may be unrelated - I think I saw this behaviour last night. I'd been working for a couple of hours and the editor started to feel laggy. I didn't have that setting enabled. I grabbed a copy of my log (which unfortunately is massive because it's about 6 hours of hacking) and will dig through it soon.

Is there anything specific I should be looking for in any of these logs?

I'm not entirely sure yet, as I'm still not sure what sort of thing could cause things like this. My guess is that it's a Dart-Code issue (and the same reported at https://github.com/Dart-Code/Dart-Code/issues/1721), but I'll leave this issue open here until I've done some a little digging.

I saw this again last night, but the extension host crashed and restarted right as I tried to take a profile (possibly enabling profiling pushed it over the edge). I posted more details in https://github.com/Dart-Code/Dart-Code/issues/1721#issuecomment-496120647.. there were warnings in the dev console about possible leaked handlers, so I'll see if I can track this down.
The only significant thing I'm aware that's changed recently is the support for completing unimported symbols, so I wonder if there are bugs in my handling of that.

I've been doing some testing today, and although I can't reproduce memory running away, the performance of completions in large projects (esp. those refrencing Flutter) is unacceptably bad. In the next release (expected to ship at the end of the week) I'm disabling completion for unimported files by default (you can still opt-in if you really want) while I work on improving the performance and reducing memory allocations.
Until the release ships, you can set "dart.autoImportCompletions": false in your settings to disable ot yourself.
If you do see this behaviour even with it disabled, please let me know!
I'll close this a a dupe of https://github.com/Dart-Code/Dart-Code/issues/1721/https://github.com/Dart-Code/Dart-Code/issues/1750 because I don't think there's anything to do in Dart/Flutter here, I think it's entirely down to the VS Code extension.

FWIW, I found what seems like a leak in VS Code (https://github.com/microsoft/vscode/issues/74446). Turning off auto-import completions will not solve it, but it should reduce its impact (due to less completions). I'm reverting my change to automatically disable them for the next release, as I expect VS Code will ship a fix for this very soon after (I believe their release is 1-2 weeks away, and this is being looked at now).

(Hopefully) Final update: This has been fixed in VS Code. I've verified it in the Insiders build and they're targeting Jun 6th for release.


Dependencies upgrade

Dependencies upgrade, most notably security https://github.com/advisories/GHSA-cgp8-4m63-fhh5
commons-net:commons-net, < 3.9.0

Dependencies upgrade

4b1057e Merge pull request #5 from leo-jeff-app/dependabot/gradle/org.slf4j-slf4j-simple-2.0.7
e0c8c1e Merge pull request #11 from leo-jeff-app/dependabot/github_actions/actions/upload-artifact-3
5178c83 Merge pull request #8 from leo-jeff-app/dependabot/gradle/com.squareup.okhttp3-okhttp-4.11.0
01e1030 Merge pull request #9 from leo-jeff-app/dependabot/gradle/org.apache.httpcomponents-httpclient-4.5.14
7751b65 Merge pull request #7 from leo-jeff-app/dependabot/gradle/commons-net-commons-net-3.9.0
7f40fda Merge pull request #6 from leo-jeff-app/dependabot/gradle/org.junit.jupiter-junit-jupiter-api-5.9.2
01b6730 Merge pull request #4 from leo-jeff-app/dependabot/gradle/com.fasterxml.jackson.core-jackson-databind-2.15.0
fbc8eff Merge pull request #3 from leo-jeff-app/dependabot/gradle/com.squareup.okhttp3-mockwebserver-4.11.0
c8d8dd5 Merge pull request #2 from leo-jeff-app/dependabot/gradle/org.slf4j-slf4j-api-2.0.7
78b29a6 Merge pull request #1 from leo-jeff-app/dependabot/gradle/io.github.gradle-nexus.publish-plugin-1.3.0
fac83b7 Merge pull request #10 from leo-jeff-app/dependabot/github_actions/actions/setup-java-3
aee02e3 Merge pull request #13 from leo-jeff-app/dependabot/github_actions/actions/cache-3
66c585a Merge pull request #12 from leo-jeff-app/dependabot/github_actions/actions/checkout-3

Thanks for your pull request. Is this your first contribution to a Snowplow open source project? Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).
:memo: Please visit https://docs.snowplowanalytics.com/docs/contributing/contributor-license-agreement/ to learn more and sign.
Once you've signed, please reply here (e.g. I signed it!) and we'll verify. Thanks.

Thanks for your pull request. Is this your first contribution to a Snowplow open source project? Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).
📝 Please visit https://docs.snowplowanalytics.com/docs/contributing/contributor-license-agreement/ to learn more and sign.
Once you've signed, please reply here (e.g. I signed it!) and we'll verify. Thanks.

I signed it

Please state if I should rebase/squash / drop something there.


Typescript support

Curious on everyone's thoughts on supporting types for this library-- useful, or not useful? I'm using this project for something I'm building, and having more type security would be nice. Happy to take a crack at it if anyone's interested! I'm also looking into seeing how we could use @types/draft-js to do this.

Useful. Would like to have a @types/medium-draft or similar package to define types rather than just setting to any like I'm doing now


added --date-title-folders and --title-folders options, BibLaTex Support

In this pull request, I am addressing an open issue for academic-admin by making changes to cli.py that accomplish the following:
(1)  Introduce two flags:
--date-title-folders - this will generate folders for BibTex/BibLaTex based on the date and title of the resource, for example 2020-02-02-mary-had-a-little-lamb.
--title-folders - similar to above, but folder names only include the title.
(2) Added the --biblatex FILE command which is identical to the --bibtex command except a separate list of publication types is used based on the Zotero BibLaTex translator.  This allows for the support of publication types such as "report," "video" etc.  Note that implementing this requires that you also make changes to the local copies (not within the theme itself) of both your language packs as well the publication_types.toml file.

I am writing in response to the "stale" notification I received.   I submitted this code because I agreed with the need that someone else articulated.   I hope you will consider accepting my pull request.

I have developed this code in response to an open request.


Delete LICENSE

You've re-licensed your code. Just keep the COPYING file and add new copyright lines there.
BTW I'm Buer from PIVX, the crypto project you forked your code from and developers of which you're now infringing upon.

Alright, merged. Is all correct now @Iconoclasta ?


Bug Report - Issue with Curl after updating new build introding curl 7.88.1

Bug Description:
It appears that the latest update of the Dockerfile-8.1 has upgraded Curl to version 7.88.1. Previously, the version was 7.74.0. However, after this update, an error is encountered when using Curl in PHP-FPM. When attempting, for example, to execute the command curl https://google.com, the following error message is displayed: curl: (6) getaddrinfo() thread failed to start.
Additional Information:
Output of the command curl -V within the PHP-FPM environment:
curl 7.88.1 (x86_64-pc-linux-gnu) libcurl/7.88.1 OpenSSL/3.0.9 zlib/1.2.13 brotli/1.0.9 zstd/1.5.4 libidn2/2.3.3 libpsl/0.21.2 (+libidn2/2.3.3) libssh2/1.10.0 nghttp2/1.52.0 librtmp/2.3
Release-Date: 2023-02-20
Protocols: dict file ftp ftps gopher gophers http https imap imaps ldap ldaps mqtt pop3 pop3s rtmp rtsp scp sftp smb smbs smtp smtps telnet tftp
Features: alt-svc AsynchDNS brotli GSS-API HSTS HTTP2 HTTPS-proxy IDN IPv6 Kerberos Largefile libz NTLM NTLM_WB PSL SPNEGO SSL threadsafe TLS-SRP UnixSockets zstd

Problem solved, I updated docker to 20.10.16 and issue is gone.
Also had issue with docker socket so I also did: systemctl stop docker.socket


Questions on the operator

Forgive me for raising the PR, but cannot think of another way to do this.

Can you elaborate on roadmap/plans for this project? How do you perceive community contributions/adoption?
Is there a space to collaborate? Slack channels are the norm these days
Whats a good avenue for raising feature requests?

Hi and thank you for your interest!
The operator is only a part of our effort in "kubernetizing" WordPress using an open approach: https://www.presslabs.com/news/mysql-operator/ We already use the current version in our dashboard app.
Did you take a look at the list of open issues?
We're considering using for chat Gitter instead of Slack as it seems slightly friendlier and more open. If you want to start as of now, please feel free to open an issue right here, or even to make pull requests implementing the issues already open.


Add initial release flow for dsm

We would like to release new versions of dsm by creating a tag in git and pushing it up to GitHub. When the tag is pushed, it should create a GitHub Release. In that release, it should have all of the binary artifacts needed to install the cli on the platforms that we target.
Checklist

[x] Add a GitHub workflow called release.yml that runs when a git tag is pushed
[x] Create a GitHub release with the name of the tag
[x] Upload built binaries that run on MacOS and WSL2

Links & Resources

[ ] Helix editor release process: Link
[ ] Ripgrep release process: Link
[ ] bat release process: Link
[ ] sd release process: Link

Finished!


Websocket Attestation

Initial
Since WSee is Focused on WebSocket, it might be a good idea to add some Attestation feature to detect any WebSocket Vulnerability.
Implementation
A new Section for WebSocket Attestation:

Origin: Test if WebSocket accept any Origins
Custom Method: Check If Supports WildCard Method #5
Referer: Check if Accept Custom Referer
Ports: Test WebSocket against Series of Ports
etc.

Custom Method are now scraped from the list, as CloudFlare no longer supports it because the death of CloudFlare SSL Proxy. Currently being discussed in CloudFlare Forum:
https://community.cloudflare.com/t/cloudflare-reject-websockets/444865

Added on Dev Version


CTC Decoder test

int compareNoScoreStates(const LexiconDecoderState* node) const {
int lmCmp = lmState->compare(node->lmState);
if (lmCmp != 0) {
  return lmCmp > 0 ? 1 : -1;
} else if (lex != node->lex) {
  return lex > node->lex ? 1 : -1;
} else if (token != node->token) {
  return token > node->token ? 1 : -1;
} else if (prevBlank != node->prevBlank) {
  return prevBlank > node->prevBlank ? 1 : -1;
}
return 0;}

This is the comparison used  before the merging the same candidates, in this comparison the candidate that end blank and the candidate that end without blank are considered different but for example if there are two labels 'thee' and 'the_' both represents the same word 'the' but as per this comparison they are considered different.This type of comparison will help when the same character has to be repeated to form the word like the repeated character 'e' in the word 'three'. For now i am comparing the output of this decoder with https://github.com/parlance/ctcdecode, the outputs are different. So is there a test for the CTC Decoder.

@tlikhomanenko, @xuqiantong will you please comment about this decoder change ?

Hey, you link seems to be broken. But you can probably use any of the recipes in https://github.com/facebookresearch/wav2letter/tree/master/recipes/sota/2019/librispeech as ground truth, to test your decoder.


Publish container app yaml specification

Please provide us with the following information:

This issue is a: (mark with an x)

[x] bug report -> please search issues before submitting
[x] documentation issue or request
[ ] regression (a behavior that used to work and stopped in a new release)

Issue description
we need the YAML specification for using the --yaml flag with az containerapp
Additional context
discussed here: https://github.com/microsoft/azure-container-apps/issues/9
requested again here:https://github.com/microsoft/azure-container-apps/issues/15 (but closed without actually solving the problem)

YAML has the same schema as JSON and is documented here:

Apps
Jobs


Fixed bad link, updated Readme

Types of changes

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

Description
See commit messages.
Checklist:

My change requires a change to the documentation.
I have updated the documentation accordingly.
I have added tests to cover my changes (if not applicable, please state why)

Thanks for you work 💚


WIP: Spike into using single ActionView::Base for all node presenters

This turned out to be quite awkward with the current structure of the code.
With the changes as they stand, all the regression tests pass, but I haven't
fixed up any of the other tests. Also there are two other places where we use
node presenters which will also need attention:

GraphPresenter
FlowRegistrationPresenter

The biggest problem I ran into was the content in content_for blocks for
different node presenters, but the same key were appended to each other. I got
round this by doing the rendering in the node presenter constructor and using
a different instance of ActionView::OutputFlow for each presenter.
This means the node presenters don't need to hang on to a reference to the
(now shared) instance of ActionView::Base.
Other downsides of this approach are:

I had to include all helper modules in the one instance of ActionView::Base.
However, we could still feasibly restrict this to the generic helper modules
and one flow-specific helper module relating to the "current" flow.

I ended up adding the flow directory and both the questions & outcomes
sub-directories to the view path. I assume this might cause problems if we
had a question and an outcome template with the same name for the same flow.
Thankfully this doesn't seem to be a problem at the moment, but it would be
good to understand what would happen if this were the case. There might well
be a better way of setting up the view paths, but I couldn't find it.

Note: It wouldn't be a big step to use Rails' instance of ActionView::Base
instead of our own special instance. However, I decided not to do this, to avoid
running into more problems with sharing helpers and view paths with the main
Rails app.

I'm a bit less convinced about the approach I've taken in this spike and in any case the code needs a lot of work to make it merge-able. So I'm going to close this PR for now.


Binary mask needs to be converted into 0 and 255 instead of 0 and 1 to extract features

I got an error as:  "Non-contiguous masks are not supported" when the mask values were binary-0 and 1.
When I changed the values to 0 and 255, the code worked!

@pranjalvaidya should we assume the mask is zero vs non-zero? Is that standard?

Add warning if more than 2 values in binary mask. Also detect if there is no zero values.

Are we yet detecting zero vs non-zero, @nathanhillyer? Or is that still pending?

@nathanhillyer It's done, but not pushed yet.

@robtoth It's done locally, but not pushed yet. Have a slew of changes I'll be getting up today.

@pranjalvaidya This is now fixed. We will support binary masks of 0 and any other value. Please pull the latest docker image and verify on your end.


Kanban project setup

https://github.com/sajid-munawar/Capstone_Javascript/projects/1
Note:

We are two members in the team

Hi Team,
Good job so far!
There are some issues that you still need to work on to go to the next project but you are almost there!
Required Changes ♻

[ ] all the cards have been added twice, please remove all the duplicate cards.
[ ] all cards should be assigned to team members. You should see a circle with the user's avatar on each card
Cheers and Happy coding!👏👏👏

Feel free to leave any questions or comments in the PR thread if something is not 100% clear.
Please, remember to tag me in your question so I can receive the notification.
Please, do not open a new Pull Request for re-reviews. You should use the same Pull Request submitted for the first review, either valid or invalid unless it is requested otherwise.

As described in the Code reviews limits policy you have a limited number of reviews per project (check the exact number in your Dashboard). If you think that the code review was not fair, you can request a second opinion using this form.

Hi @sajid-munawar and @Basir-Mohammadi,
Your project is complete!  There is nothing else to say other than... it's time to merge it :shipit:
Congratulations! 🎉
Optional suggestions
Every comment with the [OPTIONAL] prefix won't stop the approval of this PR. However, I strongly recommend you to take them into account as they can make your code better. Some of them were simply missed by the previous reviewer and addressing them will really improve your application.
Cheers and Happy coding!👏👏👏
Feel free to leave any questions or comments in the PR thread if something is not 100% clear.
Please, remember to tag me in your question so I can receive the notification.

As described in the Code reviews limits policy  you have a limited number of reviews per project (check the exact number in your Dashboard). If you think that the code review was not fair, you can request a second opinion using this form.


Bug on Android with Timeout/Interval first trigger

[x] Review the documentation: https://facebook.github.io/react-native
[x] Search for existing issues: https://github.com/facebook/react-native/issues
[x] Use the latest React Native release: https://github.com/facebook/react-native/releases

Environment
Environment:
OS: macOS High Sierra 10.13.4
Node: 8.11.2
Yarn: 1.6.0
npm: 6.1.0
Watchman: 4.9.0
Xcode: Xcode 9.4.1 Build version 9F2000
Android Studio: 3.1 AI-173.4819257
Packages: (wanted => installed)
react: ^16.3.2 => 16.3.2
react-native: ^0.55.4 => 0.55.4
(I can't upgrade react-native to latest version yet due to babel errors)
Description
On Android, when I set a Timeout or an Interval via setTimeout / setInterval, the first call will be triggered much earlier than the given timeout. The subsequent calls for an Interval are triggered at the right timing.
Reproducible Demo
Here is a minimal code sample. To reproduce : run in debug mode, press the start button and read the console log.
import { Button, View } from "react-native"

class Test extends React.Component {
    timer = 0
    scheduleTime = 0

    componentWillUnmount() {
        this.stop()
    }

    schedule() {
        this.scheduleTime = (new Date()).getTime()
        console.log(`schedule: ${this.scheduleTime}`)
        this.timer = setInterval(() => this.trigger(), 3000)
    }

    trigger() {
        const triggerTime = (new Date()).getTime()
        console.log(`triggered: ${triggerTime}`)
        console.log(`duration: ${triggerTime - this.scheduleTime}`)
    }

    stop() {
        console.log("stop")
        clearInterval(this.timer);
        this.timer = 0;
    }

    render() {
        return <View>
            <Button title="start" onPress={() => this.schedule()} />
            <Button title="stop" onPress={() => this.stop()} />
        </View>
    }
}

The console log through chrome debugger is:
triggered:<PHONE_NUMBER>130
duration: 793
triggered:<PHONE_NUMBER>141
duration: 3804
triggered:<PHONE_NUMBER>169
duration: 6832
triggered:<PHONE_NUMBER>164
duration: 9827
stop

If I set the interval time parameter to 5000ms, the first duration is ~2790, with 10 000 it becomes ~7800, which is better but for smaller durations it is very problematic.
I am going to try with timer-mixin and react-native-timer later.

Update: I tried on another Android device and it works normally... I am not sure what is wrong with the first one. It is a Samsung Galaxy S6 running Android 7.0


Add a general setup context which is only ran once

It would be nice to have some sort of setup that gets just run once at the beggining of the execution (kinda off like a lazy_static) but that has all of the great properties that the async_traits provide with the &mut ctx.
This would really help when the setups for testing become too heavy to be executed one time before each test execution.
What do you think? Would it make sense? Has it been explored before?

@CPerezz To answer your question, I have not explored this idea too much. My hope is that if someone had this need they would be able to implement it by using those types of tools directly (e.g., Once or a library like async_once) inside of their context's setup method. This keeps this library simple (which is good for me since I don't really have that much time to spend on it).


Clean Error Code Strings

It appears the naming of error code strings are not consistent and makes it a little confusing.  For example, below is a list of current distinct error strings within the api.go file.
ERR_ACTOR_DELETE_STATE
ERR_ACTOR_GET_REMINDER
ERR_ACTOR_GET_STATE
ERR_ACTOR_INSTANCE_MISSING
ERR_ACTOR_RUNTIME_NOT_FOUND
ERR_ACTOR_SAVE_STATE
ERR_ACTOR_STATE_TRANSACTION
ERR_CLOUD_EVENTS_SER
ERR_CREATE_REMINDER
ERR_CREATE_TIMER
ERR_DELETE_REMINDER
ERR_DELETE_STATE
ERR_DELETE_TIMER
ERR_DESERIALIZE_HTTP_BODY
ERR_DIRECT_INVOKE
ERR_GET_STATE
ERR_INVOKE_ACTOR
ERR_INVOKE_OUTPUT_BINDING
ERR_MALFORMED_REQUEST
ERR_PUB_SUB_NOT_FOUND
ERR_PUBLISH_MESSAGE
ERR_SAVE_REQUEST
ERR_STATE_NOT_FOUND
ERR_STATE_STORE_NOT_FOUND
There is a string "ERR_ACTOR_GET_REMINDER" where it includes the word "ACTOR".  However, "ERR_CREATE_REMINDER" and "ERR_DELETE_REMINDER" does not include the word "ACTOR".  It would be nice that all strings related to actors start with "ERR_ACTOR_" to help understand the respective error was for actors.  Another change would be to rename "ERR_INVOKE_ACTOR" to "ERR_ACTOR_INVOKE_METHOD" to follow the proposed format.
In addition, it would be nice to have something similar for state (store) related error strings.  For example, there currently is "ERR_STATE_NOT_FOUND" but also have "ERR_SAVE_REQUEST" used with store.  Could it be renamed to "ERR_STATE_SAVE_REQUEST"?
Last, it might be better to go even further and group by item (e.g. Timer, Reminder, state, etc.) and the function (e.g. create, save, delete, etc.).

Current Values
Proposed Values (*No Change Needed)

ERR_ACTOR_DELETE_STATE
ERR_ACTOR_STATE_DELETE

ERR_ACTOR_GET_REMINDER
ERR_ACTOR__REMINDER_GET

ERR_ACTOR_GET_STATE
ERR_ACTOR_STATE_GET

ERR_ACTOR_INSTANCE_MISSING
*

ERR_ACTOR_RUNTIME_NOT_FOUND
*

ERR_ACTOR_SAVE_STATE
ERR_ACTOR_STATE_SAVE

ERR_ACTOR_STATE_TRANSACTION
ERR_ACTOR_STATE_TRANSACTION_SAVE or use same as ERR_ACTOR_STATE_SAVE

ERR_CLOUD_EVENTS_SER
ERR_PUBSUB_CLOUD_EVENTS_SER

ERR_CREATE_REMINDER
ERR_ACTOR_REMINDER_CREATE

ERR_CREATE_TIMER
ERR_ACTOR_TIMER_CREATE

ERR_DELETE_REMINDER
ERR_ACTOR_REMINDER_DELETE

ERR_DELETE_STATE
ERR_STATE_DELETE

ERR_DELETE_TIMER
ERR_ACTOR_TIMER_DELETE

ERR_DESERIALIZE_HTTP_BODY
NOT SURE?

ERR_DIRECT_INVOKE
NOT SURE?

ERR_GET_STATE
ERR_STATE_GET

ERR_INVOKE_ACTOR
ERR_ACTOR_INVOKE_METHOD

ERR_INVOKE_OUTPUT_BINDING
NOT SURE?

ERR_MALFORMED_REQUEST
NOT SURE?

ERR_PUB_SUB_NOT_FOUND
ERR_PUBSUB_NOT_FOUND

ERR_PUBLISH_MESSAGE
ERR_PUBSUB_PUBLISH_MESSAGE

ERR_SAVE_REQUEST
ERR_STATE_REQUEST_SAVE

ERR_STATE_NOT_FOUND
*

ERR_STATE_STORE_NOT_FOUND
*

@amanbha @yaron2 Please look at his proposal

Thanks, this makes sense to keep consistency.
@amanbha please check and express your opinions on this, as the Dotnet SDK is probably dependent on some of these error codes, right?

Would change ERR_STATE_NOT_FOUND to ERR_STATE_KEY_NOT_FOUND

@amanbha please check and express your opinions on this, as the Dotnet SDK is probably dependent on some of these error codes, right?

@yaron2 Yes, I believe so related to the enum.  If needed I can do a PR for that as I was updating the comments/summaries.  I'll hold off until this proposal is determined.

Thanks, Looks good to me, Yes, the dotnet sdk will be updated to use these new error codes.


[linen.SelfAttention] Enable auto-regressive decoding for prompt length > 1

What does this PR do?

I think currently it is not possible to do auto-regressive decoding with flax.linen.SelfAttention if the input prompt is longer than 1. E.g., the following code works fine if the prompt_length is 1, but fails if prompt_length is 2, see this issue: https://github.com/google/flax/issues/1317.
This PR corrects this behavior by allowing the input length to be > 1 the very first time cache is used.
For decoder-only auto-regressive models, such as GPT1-3 it is very important to be able to pass input prompts > 1. Maybe, this is also already possible and I'm using it incorrectly?
If this PR looks like a good solution to you, then I'm more than happy to add a couple of tests to check the behavior @avital @marcvanzee
Checklist

[ ] This PR fixes a minor issue (e.g.: typo or small bug) or improves the docs (you can dismiss the other
checks if that's the case).
[ ] This change is discussed in a Github issue/
discussion (please add a
link).
[ ] The documentation and docstrings adhere to the
documentation guidelines.
[ ] This change includes necessary high-coverage tests.
(No quality testing = no merge!)

@levskaya do you have time to take a look at this PR improving cached decoding?


Change the display of focused buttons

Brief description
This will visually update the display of focused buttons so that users
using a keyboard will differenciate them from other buttons.
Developer Certificate of Origin

[x] I certify that these changes according to the Developer Certificate of Origin 1.1 as described at https://developercertificate.org/.

Sample pictures

Further details
You'll notice that I manually copied styles of .shadow-hover. I tried
&:focus{
    border: 2px solid @secondary;
    .shadow-hover;
}

without success.

Great idea!
But shouldn't it be merged to develop, instead of master?

Sorry. It seems like I've been submitting pull requests to master since then. Closing this in favor of #76 .


feature(docs): show sub component descriptions

Current coverage is 98.31% (diff: 100%)

Merging #462 into master will not change coverage

@@             master       #462   diff @@
==========================================
  Files            98         98
  Lines          1421       1421
  Methods           0          0
  Messages          0          0
  Branches          0          0
==========================================
  Hits           1397       1397
  Misses           24         24
  Partials          0          0

Powered by Codecov. Last update b246613...6a7877e


collapse/expand button vanish when "find & replace" affects code inside and outside code collapsed code block

VSCode Version: 1.25.1
OS Version: Windows 7 x64

Steps to Reproduce:

Collapse a code block / region
Use find & replace that affect lines INSIDE and OUTSIDE that code block
Boom it's gone (the collapse / expand buttons); time to restart vscode.

Context note:
I was replacing Boolean(member) with isEmpty(member) using Find & Replace (CTRL+H).
Screenshots
https://i.imgur.com/zei8Ioi.png (bug, before restart)
https://i.imgur.com/rmuVgYN.png (code block collapsed, after restart)
https://i.imgur.com/j6Y8xSW.png (code block expanded, after restart)
Note that at screenshot # 1, the code also appeared to be mangled - but when I restarted it ended up looking fine (shown in screenshots # 2 & # 3).
In screenshot # 3, you'll see that there is also isEmpty(member) shown, meaning there was a line affected by Find & Replace inside the collapsed code block shown at screenshot # 1 and # 2.
Does this issue occur when all extensions are disabled?: Yes

@aeschli What happens to folding ranges if the language server goes bad ?

Just an update.. I tried it again but it appears to only happen occasionally - sometimes it happens, sometimes it doesn't. The only extension I have is ESLint.
My gut tells me it has something to do with the red / green / blue git bars appearing on the left hand side, because earlier I can still hover those red / green / blue bars and be able click them to see the preview of the changes, but the expand/collapse button wasn't visible anymore.

@davalapar I'm not able to reproduce. Can you please attach a small code sample with the steps that cause the bug?

Haven't came to the exact steps or scenario to this issue. Closing for now.


How to use this addon

I don't know how to use this addon, can you please add some instructions please?

Thank you very much!
I was looking for some methods to draw waveform of an audio then I found your addon. It's very beautiful!


Access denied in UI when downloading the workflow run artefacts

In the workflow run details - step detail you can download the input/output artefacts.

The result is for download one and all:
Failed to get object in bucket mlpipeline at path artifacts/base-pipeline-67dg7/2022/02/08/base-pipeline-67dg7-1803391458/download-data-Data.tgz: S3Error: The Access Key Id you provided does not exist in our records.

Expected
The file is downloaded.
Suggestion
There is an additional secret not updated like in https://github.com/canonical/minio-operator/issues/32
The workaround for the above issue is already applied to my environment.

I have retried the scenario on the new installation and looks like this issue is not happening.
New CKF was deployed using the edge channel.
Feel free to close the issue.


Cascading changes Cycle detected

I have a case where I need to manage the lifecycle of domain objects (by calling destroy on them) but they are synchronized with another observable so I'm trying to cascade changes, but keep running into the Cycle detected error.
An example flow is:
update a setting with the list of projects -> create or destroy project domain models -> provide an array of current domain models
I originally implemented it like:
class Store
  @observable projects = [];

  constructor() {
   autorun(() => {
      let projects = this.settings.projects.map(path => _.find(this.projects, project => project.path === path) || new Project(path));

      _.difference(this.projects, projects).forEach(project => {project.destroy(); this.projects.remove(project)}); // destroy and remove old -> could have side effects
        this.projects.replace(projects); // `Cycle detected`!
      });
    }));
  }

// somewhere else
let store = new Store();

So I replaced it with:
   autorun(() => {
      let projects = this.settings.projects.map(path => _.find(this.projects, project => project.path === path) || new Project(path));

      untracked(() => {
        _.difference(this.projects, projects).forEach(project => {project.destroy(); this.projects.remove(project)}); // destroy and remove old -> could have side effects
          this.projects.replace(projects); // removed `Cycle detected`
      });
    }));

I spoke with someone about this and he suggested one solution could be to use a computed version of the projects (although he suggested simplifying by making the store an observable instead of a class and didn't add the outside variable):
let projects = [];

let store = observable({
  projects: () => {
     projects = this.settings.projects.map(path => _.find(_projects, project => project.path === path) || new Project(path));

      _.difference(this.projects, projects).forEach(project => {project.destroy(); this.projects.remove(project)}); // destroy and remove old -> could have side effects
      return projects;
  }
});

He suggested that because destroy itself could have side effects, that this wasn't a good solution since cycles could be created elsewhere.
I've been running into this a lot where something is observing another property and then needing to cascading update some other observables but when it gets triggered, it is in the middle of an update cycle so I get Cycle detected.
One solution is to try to make all dependent values computed, but with potential side effects, it seems like untracked is the best hammer for all nails?
When using KnockoutJS, I use kb.ignore and peek from time to time to stop auto-subscribing, but don't remember getting cycle warnings since it didn't really track them.
Question: how should cascading changes with and without potential side effects be set up in mobservable?

Some thoughts on this:
first of all, I think indeed your second solution is nice, after all, the projects is derived that and thus it shouldn't be state.
For the cleanup part, I would put the clean up in an autorun, because it is an action that needs to happen as side effect of changes in derived data. So that would look like this:
class Store {
    @observable get projects() {
       return this.settings.map // etc
    }

    _previousProjects = []; // not obsrevable!
    constructor() {
        autorun(() => {
              const newProjects = this.projects.slice();
              // diff & destroy
              this._previousProjects  = newProjects;
        });
}

What happens when destroy has side effects is a bit tricky. The times that I ran into such cases I usually discovered I didn't apply reactivity radically enough. Personally (professionally) I didn't need untracked yet. Usually I discover that destroying should be reactive in itself as well. autorunUntil is usually very useful here: "wait until a certain condition is met, then destroy". In your case that could be something ilke:
class Project {
    constructor(store) {
        autorunUntil(
            // if this yields true
            () => store.projects.indexOf(this) === -1
            // do that (and then stop the autorun)
            () => this.destroy();
        )
    }
}

With this approach you probably don't need the autorun in the store. In my flux-challenge solution I applied this pattern several times (see for example: https://github.com/staltz/flux-challenge/pull/50/files#diff-d3014615aa7d81c40ec426225337ccc5R164)

Btw I'm making serious progress on the reactive graph transformation thing, which can also call a cleanup method when an object is no longer used in the transformation.

These 'pro tips' are exactly what I was looking for...I thought there might be a reactive way to do this!
I'd be happy to beta-test the graph transformation thing whenever you are ready...


NIFI-6110: Updated StandardProcessSession such that if we fail to upd…

…ate the FlowFile Repository, we do not decrement claimant counts for any FlowFiles that were removed. Doing so can cause an issue where a FlowFile is removed, then the FlowFileRepo update fails, resulting in the flowfile being rolled back, but after its claimant count is decremented. It will then be processed again, which can result in the same thing, and we'll end up decrementing the claimant count repeatedly. Also updated LengthDelimitedJournal so that if the overflow directory already exists, it does not fail when trying to create the directory and instead just moves on. Updated unit tests to test both of these new fixes and updated DummyRecordSerde to be thread-safe because the TestLengthDelimitedJournal now needs it to be thread safe due to the new unit test that was added.
Thank you for submitting a contribution to Apache NiFi.
In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:
For all changes:

[ ] Is there a JIRA ticket associated with this PR? Is it referenced
in the commit message?

[ ] Does your PR title start with NIFI-XXXX where XXXX is the JIRA number you are trying to resolve? Pay particular attention to the hyphen "-" character.

[ ] Has your PR been rebased against the latest commit within the target branch (typically master)?

[ ] Is your initial contribution a single, squashed commit?

For code changes:

[ ] Have you ensured that the full suite of tests is executed via mvn -Pcontrib-check clean install at the root nifi folder?
[ ] Have you written or updated unit tests to verify your changes?
[ ] If adding new dependencies to the code, are these dependencies licensed in a way that is compatible for inclusion under ASF 2.0?
[ ] If applicable, have you updated the LICENSE file, including the main LICENSE file under nifi-assembly?
[ ] If applicable, have you updated the NOTICE file, including the main NOTICE file found under nifi-assembly?
[ ] If adding new Properties, have you added .displayName in addition to .name (programmatic access) for each of the new properties?

For documentation related changes:

[ ] Have you ensured that format looks appropriate for the output in which it is rendered?

Note:
Please ensure that once the PR is submitted, you check travis-ci for build issues and submit an update to your PR as soon as possible.

Reviewing...

Looks good, will merge


Poor fade-in performance since commit 4ef9fc2

I am experiencing very poor performance with --fade-in starting on commit 4ef9fc280f6d3f02557a3f3b9c67006b4d002150 and continuing up to the current tip of master (determined via git bisect). Its parent commit 89daa147638605b2026a401088bd316abdf61f75 is fine in this regard, though fades in from a black screen instead (which I suppose is what the broken commit is trying to solve).
This poor performance corresponds to the fade-in animation being very "discrete", at around 10 FPS (while previously I'd easily get the full 60 FPS of my monitor).

It seems like 7c5681ce96587ce3090c6698501faeccdfdc157d (#37) is supposed to mitigate this, but it has no noticeable effect on my system.

Reading through the code, it seems like the issue is that the image has to be rescaled on every frame.
Performance might improve if it is scaled only once at the start, and then the scaled version is reused for each frame. That is, render_background_image should be split into two parts: one that actually does the scaling and simply returns a new, scaled image; and another that renders any image and assumes it to already be the correct dimensions. It is of note that changing the filter used in this function to CAIRO_FILTER_FAST fixes the performance issue, showing that the filter is the bottleneck, and as far as I know, the filter is only used for the scaling operation.

While you’re at it, do you have any idea how to fix #25?


[ISSUE #4938, ISSUE #4939] fix the concurrency problems and limit the times of renew when some error occurred in ReceiptHandleProcessor

Make sure set the target branch to develop
What is the purpose of the change

fix the concurrency problems when renew and ack/changeInvisibleTime at the same time
retry renew for a limited times when some error occurred
code refactor for ReceiptHandleProcessor

Brief changelog
XX
Verifying this change
XXXX
Follow this checklist to help us incorporate your contribution quickly and easily. Notice, it would be helpful if you could finish the following 5 checklist(the last one is not necessary)before request the community to review your PR.

[x] Make sure there is a Github issue filed for the change (usually before you start working on it). Trivial changes like typos do not require a Github issue. Your pull request should address just this issue, without pulling in other changes - one PR resolves one issue.
[x] Format the pull request title like [ISSUE #123] Fix UnknownException when host config not exist. Each commit in the pull request should have a meaningful subject line and body.
[x] Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
[x] Write necessary unit-test(over 80% coverage) to verify your logic correction, more mock a little better when cross module dependency exist. If the new feature or significant change is committed, please remember to add integration-test in test module.
[x] Run mvn -B clean apache-rat:check findbugs:findbugs checkstyle:checkstyle to make sure basic checks pass. Run mvn clean install -DskipITs to make sure unit-test pass. Run mvn clean test-compile failsafe:integration-test  to make sure integration-test pass.
[ ] If this contribution is large, please file an Apache Individual Contributor License Agreement.

@xdkxlk thx for contributing, looks like another flaky test, could you create an issue for this?

Codecov Report

Merging #4940 (e25d0a2) into develop (64c18fb) will decrease coverage by 0.11%.
The diff coverage is 68.31%.

@@              Coverage Diff              @@
##             develop    #4940      +/-   ##
=============================================
- Coverage      43.29%   43.18%   -0.12%
- Complexity      7688     7708      +20
=============================================
  Files            991      995       +4
  Lines          68781    69094     +313
  Branches        9111     9149      +38
=============================================
+ Hits           29782    29836      +54
- Misses         35253    35513     +260
+ Partials        3746     3745       -1

Impacted Files
Coverage Δ

...proxy/grpc/v2/consumer/ReceiveMessageActivity.java
73.91% <0.00%> (ø)

.../org/apache/rocketmq/proxy/config/ProxyConfig.java
48.96% <50.00%> (+0.05%)
:arrow_up:

...ache/rocketmq/proxy/common/ReceiptHandleGroup.java
66.26% <60.00%> (+7.64%)
:arrow_up:

...cketmq/proxy/processor/ReceiptHandleProcessor.java
69.94% <71.64%> (+12.79%)
:arrow_up:

...he/rocketmq/proxy/common/MessageReceiptHandle.java
75.43% <100.00%> (+28.63%)
:arrow_up:

...or/validator/DefaultTopicMessageTypeValidator.java
40.00% <0.00%> (-10.00%)
:arrow_down:

...a/org/apache/rocketmq/store/StoreStatsService.java
39.77% <0.00%> (-9.95%)
:arrow_down:

...e/rocketmq/controller/impl/manager/BrokerInfo.java
78.94% <0.00%> (-9.29%)
:arrow_down:

...ocketmq/controller/impl/manager/SyncStateInfo.java
83.33% <0.00%> (-7.58%)
:arrow_down:

...apache/rocketmq/store/queue/ConsumeQueueStore.java
53.41% <0.00%> (-5.56%)
:arrow_down:

... and 78 more

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more


[Feature request] per world config and list

Hey,
would be very nice to have a per world config and list.
So we can give different rewards depending on the world or better depending on the head.
Also a way to delete heads per world would be nice.
So we can delete all farming world heads before the reset.
regards
sphings

Hi!
Thanks for the suggestion.
It requires quite a bit of modification but I think it's possible. I'll see if I can add it in the 2.0 which is under development


Update user isn't working

To reproduce the bug
Navigate to /user/edit.  Change fields, click the update button.  Info isn't updating.  Info on the page stays as the new field when you click update but it doesn't save, and when you refresh the page it's gone.
We need the new info to save, and we need tests to prove that this works and make sure it doesn't get broken in the future.

This is resolved but the PR didn't close the ticket so closing it now.


perf: use new built-in methods introduced before go 1.22

Changes:

chore: use built-in slices
perf: use built-in map clone
chore: use built-in map copy
perf: use slices.Sort instead of sort.Strings

Resolves: #713

LGTM although IANAM


Better error message if connection to rclone fails

What does this PR change? What problem does it solve?
When proxying the connection rclone using ssh (e.g. restic -o rclone.program='ssh<EMAIL_ADDRESS>forced-command' -r rclone: backup ... as in https://ruderich.org/simon/notes/append-only-backups-with-restic-and-rclone ) this initial connection setup can fail.
In this case rclone currently often just returns a context canceled error, which is not particularly helpful. Replace this error with the output from rclone.
Was the change previously discussed in an issue or on the forum?
No.

Checklist

[x] I have read the contribution guidelines.
[x] I have enabled maintainer edits.
[ ] I have added tests for all code changes.
[ ] I have added documentation for relevant changes (in the manual).
[ ] There's a new file in changelog/unreleased/ that describes the changes for our users (see template).
[x] I have run gofmt on the code in all commits.
[x] All commit messages are formatted in the same style as the other commits in the repo.
[x] I'm done! This pull request is ready for review.

The PR now replaces all initial communication errors with the exit code returned by rclone. More precisely the replaced errors are  context canceled, unexpected EOF or broken pipe error. Neither of these errors is useful for understanding what exactly went wrong and how to fix it.
In addition, I've discovered that according to the documentation of exec.Cmd the current usage of the StdErrPipe() was wrong. Wait() must not be called before everything was read from the former pipe.
The expand on the motivation for this PR: I've been seeing the following errors when using restic with the rclone backend proxied via ssh, however, for some reason the error returned by ssh is completely missing. This might be caused by the above StdErrPipe() problem but that is just a guess so far.
Fatal: unable to open repository at rclone:: error talking HTTP to rclone: context canceled
Fatal: unable to open repository at rclone:: error talking HTTP to rclone: Get http://localhost/file-5577006791947779410: unexpected EOF

LGTM.


Remove first unresolved question.

@Veykril, hello!
I can't find any problems or quirks here. Please see the amendments to the test here:
https://github.com/adetaylor/rust/commit/ceb5918ec65
The amended test now passes against our latest branch (which adds a Target trait to Receiver as proposed in the RFC), and seems to behave exactly as I'd want. If you still believe there are problems here please could you explain a bit more?

Actually - I've been poking at this and I can find some problems. I think it's the FIXME here - https://github.com/rust-lang/rust/blob/483ef5f4d8de1a8ef0d9a2771b7a4a45f9846721/compiler/rustc_hir_typeck/src/method/confirm.rs#L510
I'm going to close this PR and poke at it a bit more.

iirc, the question arises for assert_eq!(foo.a::<Foo>(), 2); in your tests which should fail to compile. (Note the lack of the reference), that is you cannot use by-value semantics in this scenario.


added puzzle section

@jtamiace
Added puzzle section (see below)

with button that scrolls to next element, fully responsive, tested on IE, chrome, firefox
**Disclaimer: Still working on above-the-fold section!
Deleted this section:

Prototype url for reference: http://g9qbzw.axshare.com/

awesome. merging


[Bug Report]

Describe the bug
A clear and concise description of what the bug is.
To Reproduce
Steps to reproduce the behavior:

Go to '...'
Click on '....'
Scroll down to '....'
See error

Expected behavior
A clear and concise description of what you expected to happen.
Environment (please complete the following information):

OS: [e.g. Ubuntu 18.04]
Browser [e.g. chrome, safari, if applicable]
Mango Version [e.g. v0.1.0]

Docker (if you are running Mango in a Docker container)

The docker-compose.yml file you are using, or your .env file.

Additional context
Add any other context about the problem here. Add screenshots if applicable.

Bot? Closing and reported...

hi


asset: set the advertise address based on pod ip

This flag was removed in https://github.com/kubernetes-incubator/bootkube/pull/151, but looks like we do still need this in some cases.
The bootkube-apiserver was setting the correct endpoint record for the default kubernetes service (kubectl get endpoint/kubernetes). However, after bootkube exits, the self-hosted api-server will eventually overwrite the endpoint again -- and it was using the host's default interface, which is not routable in some cases (e.g. virtualbox).
There may be some other options here (e.g. why does bootkube apiserver use correct interface, but hostNetwork api-server pod does not) -- but going to revert this part of the change so we avoid the regression until we have a better option.
/cc @dghubble @quentin-m @bassam

I'm still seeing the same behavior with this change. bootkube times out and the pods are in the following state:
> kubectl --kubeconfig=cluster/auth/kubeconfig get pods --all-namespaces
NAMESPACE     NAME                                       READY     STATUS              RESTARTS   AGE
kube-system   checkpoint-installer-rj673                 1/1       Running             0          8m
kube-system   kube-apiserver-153w3                       0/1       CrashLoopBackOff    6          8m
kube-system   kube-controller-manager-3438979800-sltl6   0/1       ContainerCreating   0          9m
kube-system   kube-controller-manager-3438979800-zrhg6   0/1       ContainerCreating   0          9m
kube-system   kube-dns-4101612645-j08jp                  0/4       ContainerCreating   0          9m
kube-system   kube-flannel-7m2fl                         2/2       Running             0          8m
kube-system   kube-flannel-t050l                         1/2       CrashLoopBackOff    6          8m
kube-system   kube-proxy-bwcpb                           1/1       Running             0          8m
kube-system   kube-proxy-gjc7x                           1/1       Running             0          8m
kube-system   kube-scheduler-694795526-0ktfv             0/1       ContainerCreating   0          9m
kube-system   kube-scheduler-694795526-g5z6f             0/1       ContainerCreating   0          9m
kube-system   pod-checkpointer-<IP_ADDRESS>              1/1       Running             0          7m

@aaronlevy things are a lot better if I revert #247:
> kubectl --kubeconfig=cluster/auth/kubeconfig get pods --all-namespaces
NAMESPACE     NAME                                       READY     STATUS    RESTARTS   AGE
kube-system   checkpoint-installer-tmf2c                 1/1       Running   0          3m
kube-system   kube-apiserver-9d5zg                       1/1       Running   3          3m
kube-system   kube-controller-manager-2751499733-0s565   1/1       Running   0          4m
kube-system   kube-controller-manager-2751499733-8z5h3   1/1       Running   0          4m
kube-system   kube-dns-4101612645-th3nx                  4/4       Running   0          4m
kube-system   kube-proxy-8vsc4                           1/1       Running   0          3m
kube-system   kube-proxy-q83rs                           1/1       Running   0          1m
kube-system   kube-scheduler-694795526-blt33             1/1       Running   0          4m
kube-system   kube-scheduler-694795526-l641q             1/1       Running   0          4m
kube-system   pod-checkpointer-<IP_ADDRESS>              1/1       Running   0          2m

This may mean coreos-baremetal needs to use a fork again :(

@dghubble there may be other options here - but it is a regression, so need to fix in the short term.


Peasy can't find p.exe on Windows

Peasy complains that P isn't installed so I have to use the VS Code terminal to run p compile. I looked at the Peasy code and located the problem.
The function checkPInstalled checks if the p binary exists but on Windows, it is an exe file and for some reason, the basename of the file is p.exe not p.
So a fix will need to make sure it can detect the p.exe on Windows.

Something like the following might do it:
var dirFiles = fs.readdirSync(dirPath);
    dirFiles.forEach(file => {
      if (path.parse(file).name == "p") {
        return true;
      }
    })

Thanks a lot Jack. We will fix this asap. thanks!

Fix included in peasy-1.0.2


The Difference

On the difference between
$$\gamma \circ \hat{\mathbb{P}}_n, \quad \hat{\gamma} \circ \hat{\mathbb{P}}_n$$

[ ] Do we need uniform convergence for the first one?

What is the convergence of the empirical measure?


fixed the return statetment as SampledProperty removeSample is return…

fixed the return statement as SampledProperty removeSample is returning
but this function is not even though the api docs states it should

Thank you so much for the pull request @vipulgusain! I noticed this is your first pull request and I wanted to say welcome to the Cesium community!
The Pull Request Guidelines is a handy reference for making sure your PR gets accepted quickly, so make sure to skim that.

:x: Missing CONTRIBUTORS.md entry.

Please add yourself to the contributors file!

:x: Missing CLA.

Please send in a Contributor License Agreement (CLA) and comment back here to let us know to check this!

:grey_question: CHANGES.md was not updated.

If this change updates the public API in any way, please add a bullet point to CHANGES.md.

:grey_question: Unit tests were not updated.

Make sure you've updated tests to reflect your changes, added tests for any new code, and ran the code coverage tool.

Reviewers, don't forget to make sure that:

[ ] Cesium Viewer works.
[ ] Works in 2D/CV.
[ ] Works (or fails gracefully) in IE11.

Contributor License Agreement (CLA) signed

"this is ready"

Thanks for the PR @vipulgusain!  At a glance this looks good, but I'll have time to do a thorough review and get this merged next week sometime

Thanks @vipulgusain!  I'll merge as soon as CI passes


Preconversion check error / No Red Hat signed kernel is installed

Hi,
I try to update one server from Centos 7.9 to Almalinux 8.
I use: https://support.plesk.com/hc/en-us/...f-a-Plesk-server-from-CentOS-7-to-AlmaLinux-8
I have this error during the pre check:
Required pre-conversion condition 'checking if the Red Hat kernel is installed' not met:
No Red Hat signed kernel is installed.
To proceed with the conversion, install a kernel by running:
- 'yum install kernel kernel-tools kernel-tools-libs'
After installing the kernel fix the grub configuration by calling:
- `grub2-set-default 'CentOS Linux (newly_installed_kernel_version) 7 (Core)'`
- `grub2-mkconfig -o /boot/grub2/grub.cfg`
- `reboot`

Is it safe to do this?
The server is working fine. It won't have any impact to modify the grub? There is currently no boot problem.
Actually i have:
# uname -r
4.9.185-xxxx-std-ipv6-64
# cat /etc/redhat-release
CentOS Linux release 7.9.2009 (Core)

If I have to do the installation, what version should I put in:
grub2-set-default 'CentOS Linux (newly_installed_kernel_version) 7 (Core)'
If I start as suggested
#yum install kernel kernel-tools kernel-tools-libs

I have:
Installation :
kernel x86_64 3.10.0-1160.119.1.el7.tuxcare.els12 centos7els-rollout-2 52 M
kernel-tools x86_64 3.10.0-1160.119.1.el7.tuxcare.els12 centos7els-rollout-2 8.2 M
kernel-tools-libs x86_64 3.10.0-1160.119.1.el7.tuxcare.els12 centos7els-rollout-2 8.1 M
Installation pour dépendances :
grubby x86_64 8.28-26.el7 base 71 k

Thank you for your help.
Erwan

Hello @Wanerys,

Is it safe to do this?

It is safe as long as you keep the currently installed kernel, so you can revert to it if needed
Unfortunately, we cannot carry out the conversion process with non-standard kernels. This is a requirement of the elevate utility we use for conversion

If I have to do the installation, what version should I put in:
The kernel version is 3.10.0-1160.119.1.el7.x86_64. I believe, you should be able to find the menuentry section for it in the /boot/grub2/grub.cfg file. On my test instance, it appears like this:

menuentry 'CentOS Linux (3.10.0-1160.119.1.el7.x86_64) 7 (Core)' --class centos --class gnu-linux --class gnu --class os --unrestricted $menuentry_id_option 'gnulinux-3.10.0-1160.45.1.el7.x86_64-advanced-44a6a613-4e21-478b-a909-ab653c9d39df' {
	load_video
	set gfxpayload=keep
	insmod gzio
	insmod part_msdos
	insmod xfs
	set root='hd0,msdos1'
	if [ x$feature_platform_search_hint = xy ]; then
	  search --no-floppy --fs-uuid --set=root --hint='hd0,msdos1'  44a6a613-4e21-478b-a909-ab653c9d39df
	else
	  search --no-floppy --fs-uuid --set=root 44a6a613-4e21-478b-a909-ab653c9d39df
	fi
	linux16 /boot/vmlinuz-3.10.0-1160.119.1.el7.x86_64 root=UUID=44a6a613-4e21-478b-a909-ab653c9d39df ro console=tty0 console=ttyS0,115200n8 crashkernel=auto net.ifnames=0 console=ttyS0 LANG=en_US.UTF-8
	initrd16 /boot/initramfs-3.10.0-1160.119.1.el7.x86_64.img
}

Hello @SandakovMM,
Thank you for your help.

It is safe as long as you keep the currently installed kernel, so you can revert to it if needed
Unfortunately, we cannot carry out the conversion process with non-standard kernels. This is a requirement of the elevate utility we use for conversion

So we can't use the conversion process... :(
menuentry 'CentOS Linux (4.9.185-xxxx-std-ipv6-64) 7 (Core)' --class centos --class gnu-linux --class gnu --class os --unrestricted $menuentry_id_option 'gnulinux-4.9.185-xxxx-std-ipv6-64-advanced-054226ad-e249-4af8-bc88-f01208349e05' {
Have you had any experience with Almalinux standard process? Is Plesk at risk of damage?
https://wiki.almalinux.org/elevate/ELevating-CentOS7-to-AlmaLinux-9.html#upgrade-centos-7-to-almalinux-8

Have you had any experience with Almalinux standard process? Is Plesk at risk of damage?

Actually, centos2alma is based on the same process. We only add a few extra steps to ensure Plesk functions properly after conversion.
The requirement for having a kernel signed by RHEL comes specifically from AlmaLinux Elevate (though I believe it's more related to the leapp framework it relies on). Therefore, I think leapp might prevent the conversion.
However, you can test this by executing leapp preupgrade (centos2alma likely already installed leapp).
If the preupgrade is successful, you can go ahead with the conversion. But I advise against proceeding with leapp upgrade as it doesn't provide any extra measures specifically for Plesk. I would appreciate it if you could send me a feedback archive instead (you can generate one using centos2alma -f), so I can confirm whether our pre-checker functions the same way as leapp’s.


chore(main): release siyuan-plugin-picgo 1.10.2

:robot: A new release will be created
1.10.2 (2024-04-23)
Bug Fixes

clipboard upload not work for external picgo (0fcd437)
deps: bump @iconify/json from 2.2.202 to 2.2.203 (2aba99d)
deps: bump vue from 3.4.23 to 3.4.24 (2d627d2)
github path error (e3e2b87)
other platforms path error (b80eb2b)

Miscellaneous

deps-dev: bump vue-tsc from 2.0.13 to 2.0.14 (0a63d3c)

This PR was generated with Release Please. See documentation.

:robot: Release is at https://github.com/terwer/siyuan-plugin-picgo/releases/tag/siyuan-plugin-picgo-v1.10.2 :sunflower:


threads: current worker thread index should be exposed to extensions

Title: Stats API should provide support for per-thread metrics
Context:

there are use cases where cross-thread aggregation of metrics is not desirable since it can make metrics more obscure
right now, Envoy already has a couple per-thread metrics, such as server.worker_N.watchdog_miss, but no general approach
having per-thread metrics could further improve Envoy observability story

Proposal:

provide general approach to maintain per-thread metrics
provide ready-to-use Stats API for that, e.g.

introduce Scope::createScopePerThread(name)
which will automatically include thread name into all metrics in that scope
e.g.auto scope   = parent.createScopePerThread("wasm.wm.<VM ID>")
auto counter = scope.counter("memory_size_bytes")

// as a result, `counter` will automatically get a full name
// `wasm.vm.<VM ID>.worker_N.memory_size_bytes`

Example use cases:

consider Wasm use case as an example

for every Wasm extension a separate Wasm VM will be created on each thread
for each Wasm VM it's important to have metrics like

memory_size_bytes
restarts_total
traps_total

having those metrics aggregated across all threads would make them more obscure

Would this just be helper functions around the existing stats subsystem that incorporates a thread name into the stats name? Or are you talking about having independent thread local stat stores?
cc @jmarantz

Yeah any particular reason not to just add a scope named for the current thread, and then use the existing API?
That would do exactly what you want functionally IIUC. It would also not be too far from optimal in its implementation in thread_local_store.cc: there would be one extra level of caching that would not be useful, but it's also probably not too expensive.

I was thinking about a helper function which abstracts the way current thread name is inferred.

In the context of WASM this should be pretty easy without any extra infrastructure; Wasm code controls the scope used for the lookup.
Do you want to have all the WASM stats be per-thread? Or do you want to aggregate some of them?

I'm mostly focused on metrics about Wasm VMs themselves.
Because in this particular case the advantages of per-thread metrics are clear to me - ability to spot a misbehaving VM.
I don't think that metrics of Wasm extensions need special treatment comparing to regular extensions. So, I would say that the same aggregated behaviour should stay the default for Wasm extensions as well.

From my perspective, this proposal is mostly about:

assigning a name to each thread (like worker_N)
providing API to access that name
providing a convenience method as part of Stats API

Sounds good. What's the reason this isn't addressed by using
  wasm_thread_scope_ = server().stats().createScope(absl::StrCat("worker_", worker_index));

or similar?

also there is not currently a thread name in Envoy, just a thread ID which in Linux is the pid.

Ideally, I'd like to see absl::StrCat("worker_", worker_index) a part of Envoy API.
Is there a way to get ahold of worker_index from the factory context of a filter  ?

I guess there is a worker index, and it lives only in source/server/listener_manager_impl.cc in the ListenerManagerImpl ctor
You just want that plumbed into some context visible from a Filter, is that right?

Wasm WM can be created from the context of any extension type. So far, it has been discussed for the Listener and Cluster contexts.
Will worker_index be available in the context of ClusterManager ?

IDK; I'll defer to @mattklein123 about the best place to expose a worker index to WASM, if there's not already a way to get to that.

I think, I can re-phrase.
Will worker_index be available in the context of a callback that is executed on individual threads as part of Slot::set() ?

@PiotrSikora @jplevyak @kyessenov

IDK; I'll defer to @mattklein123 about the best place to expose a worker index to WASM, if there's not already a way to get to that.

Yeah I think just formalizing the worker name or ID would be fine. We could make this available via the TLS interface potentially, or possible the dispatcher interface, or probably any number of other cases. Do you want to flesh out a concrete proposal?

Yes, I can prepare a proposal.
But I need to take a deeper look into TLS mechanics first.

@mattklein123
I think, the most simple (and also very natural) way to expose "worker name" is to assign it to an Event::Dispatcher.
In this case, it will be possible to access "worker name" from anywhere in the source code, at any moment, etc.
Regarding "worker name" vs "worker index", just index is not enough because it doesn't account for the main thread.
So, the proposal is to:

add std::string name() method to Event::Dispatcher
change allocateDispatcher(..) methods of Api::Api to take name as a mandatory parameter
update ProdWorkerFactory::createWorker(..) to allocate an Event::Dispatcher using "worker_N" as a name
update Server::InstanceImpl(..) to allocate an Event::Dispatcher using "main_thread" as a name

@yskopets this sounds reasonable to me. I assume you plan on cleaning up the existing worker_name being passed around?

yes

The proposed use of <thread name> inside Wasm metrics is described in #10734


Edit in Multi-Select

IFF the user selects a single process in the process list, the edit icon should show up as well.

#390


Issue with some websites

Am using the below API script for taking screenshots of webpage but something is happening wrong, can't figure out the issue.
var Pageres = require('pageres');

var pageres = new Pageres({delay: 2})
    .src('http://www.sullivanfence.com/', ['1280x1024']) //Image is having only white background & nothing else
    .dest(__dirname+'/static/images/');

pageres.run(function (err, i) {
    console.log('done', i);
});

Any help is appreciated. Thanks in advance.

Well, it would be a lot easier if you logged the errors for us.

@kevva
done [ { _readableState:
     { objectMode: false,
       highWaterMark: 16384,
       buffer: [],
       length: 0,
       pipes: null,
       pipesCount: 0,
       flowing: false,
       ended: true,
       endEmitted: true,
       reading: false,
       sync: false,
       needReadable: false,
       emittedReadable: false,
       readableListening: false,
       defaultEncoding: 'utf8',
       ranOut: false,
       awaitDrain: 0,
       readingMore: false,
       decoder: null,
       encoding: null,
       resumeScheduled: false },
    readable: false,
    domain: null,
    _events: { error: [Object], warn: [Function] },
    _maxListeners: undefined,
    _writableState:
     { objectMode: false,
       highWaterMark: 16384,
       needDrain: false,
       ending: true,
       ended: true,
       finished: true,
       decodeStrings: false,
       defaultEncoding: 'utf8',
       length: 0,
       writing: false,
       corked: 0,
       sync: false,
       bufferProcessing: false,
       onwrite: [Function],
       writecb: null,
       writelen: 0,
       bufferedRequest: null,
       lastBufferedRequest: null,
       pendingcb: 0,
       prefinished: true,
       errorEmitted: false },
    writable: true,
    allowHalfOpen: true,
    _transformState:
     { afterTransform: [Function],
       needTransform: false,
       transforming: false,
       writecb: null,
       writechunk: null,
       writeencoding: 'buffer' },
    extra: '',
    filename: 'sullivanfence.com-1280x1024.png' } ]
[Finished in 11.5s]

But the image is having only white background & nothing else.

That's not the error, that's the callback containing streams. Log err please.

I can reproduce white image. No idea why though. Might be the site running into a problem with the super old version of WebKit in PhantomJS.

var Pageres = require('pageres');

var pageres = new Pageres({delay: 2})
    .src('http://www.sullivanfence.com/', ['1280x1024']) //Image is having only white background & nothing else
    .dest(__dirname+'/static/images/');

pageres.run(function (err, i) {
	if (err){
		console.log(err);
	}
    console.log('done', i);
});

No error is generated.

Yep, I can reproduce it too. I think it's due to the site being JS only.

@kevva @sindresorhus Thanks a lot for your advice. Am waiting for PhantomJS 2.0.


updated '_waiting.py' file

added wait until element is not visible keyword will add acceptance test soon
added a highlight element keyword and test for it

Before we can do anything with a PR it needs to have working tests and be passing the Travis build.
Secondly, changes should be broken up into logical changes. These two keywords seem unrelated and it doesn't seem like they should be lumped into the same PR.

Hi @zephraph First of all build failure is not due to these changes and for the highlight element keyword I have added a test case. As recently 'Wait Until Element Not Visible' has been added. Just merge the 'Highlight Element' keyword. Please let me know if I need to do anything.

I think the failure is just because your PR is out of date. (For more information how you can update your fork, see this article).
As far as your highlight element keyword goes, I'm not sure that it adds enough substantial value to the library to be added. The reason I say that is that it's somewhat of a niche functionality that might not be useful in all cases. What about when there's a yellow background?
With that being said, I do want to help facilitate this functionality. It seems to me that to get this functionality we need two things: to be able to call Execute Javascript with arguments and to be able to get a WebElement just using a locator. Execute Javascript with args has been discussed in #323 but we haven't come up with a solution yet. I'll try to revive that conversation. As for getting webelements, that's coming soon! See #356.
As a temporary solution I would simple suggest using Execute Javascript and locating the element manually with javascript.

Hey @anilreddy, just as a follow up I am trying to make progress on the things I discussed yesterday.
I created a PR (#387) to address using arguments with Execute Javascript. If that PR and #356 gets merged in you'll be able to implement the same functionality in your PR like this....
*** Keywords ***
Highlight Element
    [Arguments]    ${locator}
    ${element}=    Get WebElement    ${locator}
    Execute Javascript   ${element}
    ...   element = arguments[0];
    ...   original_style = element.getAttribute('style');
    ...   element.setAttribute('style', original_style + "; background: yellow;");
    ...   setTimeout(function(){
    ...        element.setAttribute('style', original_style);
    ...   }, 300);


JSON5.0 - CVSS hard coded version numbers

See: https://github.com/Vulnogram/Vulnogram/issues/64
CVSS record forat is:
        {
          "format": "CVSS",
          "scenarios": [
            {
              "lang": "en",
              "value": "GENERAL"
            }
          ],
          "cvssV3_1": {
            "version": "3.1",
            "attackVector": "NETWORK",
            "attackComplexity": "LOW",
            "privilegesRequired": "LOW",
            "userInteraction": "NONE",
            "scope": "CHANGED",
            "confidentialityImpact": "LOW",
            "integrityImpact": "HIGH",
            "availabilityImpact": "NONE",
            "baseScore": 8.5,
            "baseSeverity": "HIGH",
            "vectorString": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:H/A:N"
          }
        },

This means that when the CVSS version changes to e.g. v3.2 the tag changes as well, meaning I have to update the code that renders CVEs records on https://csirt.divd.nl.
Having a version number as part of a tag is generally considered bad practice.

Proposal is to make this an array with multiple versions and format's allowed. E.g.:
       {
          "format": "CVSS",
          "scenarios": [
            {
              "lang": "en",
              "value": "GENERAL"
            }
          ],
          "score": [
          {
            "version": "3.1",
            "attackVector": "NETWORK",
            "attackComplexity": "LOW",
            "privilegesRequired": "LOW",
            "userInteraction": "NONE",
            "scope": "CHANGED",
            "confidentialityImpact": "LOW",
            "integrityImpact": "HIGH",
            "availabilityImpact": "NONE",
            "baseScore": 8.5,
            "baseSeverity": "HIGH",
            "vectorString": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:H/A:N"
          }
          ]
        },

Other scores such as SSVC #144 can also become part of a scores array when the CVE schema v6.0 or next major update is being considered.
Vijay

Changing the cvssV* properties would be a backwards compatibility breaking change. As a result, we will need to wait until v6.0 to make this change.

Does that imply that if a new version of CVSS is released it cannot be adopted unless a new version of CVE records is released too?

No. Adding a new optional field is not a breaking change. It will not break any of the existing tools to produce/consume records. It will be done in a schema minor release 5.x.

Removing a field on the other hand means existing tools will produce a JSON that no longer validates, which means CNAs will have to change their tooling.

While this request is perfectly valid and probably the better approach, changing this would break all previous content. We will not implement this currently. We may want to reconsider this and other CVSS changes in a major/model update.


Editor props/extends the actual width of the parent that is a flexbox item

monaco-editor version: 0.17.0 (latest)
Browser: Edge dev <IP_ADDRESS>
OS: Windows 10
When the editor is placed inside a flexbox item, it will prop the item horizontally and actually the flexbox item (and eventually the editor) cannot shrink back with editor.layout(), unless we explicitly specify a smaller width in layout method.
Steps or JS usage snippet reproducing the issue:
Go to https://microsoft.github.io/monaco-editor/playground.html , then enter the following code and click "run" button.
JS
var edt = monaco.editor.create(document.getElementById("container"), {
	value: "function hello() {\n\talert('Hello world!');\n}",
	language: "javascript",
    automaticLayout: true
});

CSS
/*
.monaco-editor {
    position: absolute;
}
*/

HTML

--- Test ---

Resize the window. When the window is shrinking in width, the editor cannot shrink accordingly. Actually the container has been propped by the editor horizontally.

Remove the comment marks in "CSS" tab, click "Run", and resize the window again. This time the editor can resize properly.

Hey, found this issue due to the same problem. Also found a (lucky solution) whilst I still had the tab open :) Below is my rough structure
#code_editor below is what monaco is set up to use. I put an overflow:hidden on the 'main' panel's div. and voila! Both method for resizing (manual via window resize listener, as well as Monaco's automaticLayout) worked perfectly; the latter being somewhat 'smoother'

      ...sidebar content...

.ide { display:flex; flex-direction:row; }
.ide-main { flex:3; display:flex; flex-direction:column; }

@redbullmarky overflow:hidden will also trim the auto-completion and syntax hint popups, which is not desirable. Actually, I closed this issue because later I found out it's not really a problem with the implementation of monaco-editor, but there is no rule to restrict div.container (as in my example above) from not being extended by the content. If you check out example code on the web, all the containers of monaco-editor have explicitly specified width.
Actually, if you replace the HTML field in my example above with

--- Test ---

You will find the editor resizing without any problem even though there is no position: absolute applied, and this should be the correct fix to solve the root cause of the problem.
And I don't think position: absolute is a correct "fix", either. If you replace the HTML field in my example above with, and enable position: absolute for .monaco-editor

drag the scroll bar and see what happens

--- Test ---

very long div

You will see the editor won't align with the container when you scroll the div.

Though you can still use position: relative container to fix this issue, but it is somewhat too far from "using monaco-editor natually" and IMO it is too much of hacking.