Could this go upstream into PouchDB/CouchDB?

We're using this to shorten our initial replication times from remote CouchDB -> in-browser PouchDB (with pouchdb-load) from ~120s to 2s.  It's such a massive speedup that I can't help thinking that this component (which I see as server-side) could be in CouchDB/PouchDB trunk.
I guess the answer is philosophical, and the question might be naïve, but could this be pushed upstream?

@nickcmaynard I am also interested in a way to shorten our initial replication from CouchDB to in browser PouchDB. Can you please share the way you set it up? Thanks

@ngbinh You need an intermediary NodeJS server to run this package (we use exporess-pouchdb-replication-stream as a wrapper).  Then run pouchdb-load in your browser.  The documentation pretty much covers it.

This library is kind of a testing ground for a potential new CouchDB API. The code itself wouldn't be used (CouchDB is Erlang; this is JavaScript), but it could definitely influence the design. @janl has been particularly interested in this.

Theoretically, replicator may use such algorithm if it was asked to create target during replication or target docs count is zero. However, this also assumes that there will be no concurrent replication processes, so this feature as an option could be good.

Closing, currently no plans to integrate into CouchDB


A Wire.requestFrom() should not be followed by a Wire.endTransmission().

In the function "readI2CRegister16bitUnsigned()", there is a Wire.endTransmission() after the Wire.requestFrom(). You can remove that second Wire.endTransmission() in that function.
The Wire.endTransmission should only be used when writing data.

Do you have tested the functionality when you change this?
I do not have the sensors in use anymore, that's why I need you to test it (or someone else)

No, sorry. I was tired of explaining in forums how to use the Wire library. That's why I started to make many issues on Github, trying to tilt it into the right way.
The extra Wire.endTransmission() is not harmless: Common-mistakes#2


Issue with array filter method

I have an array of user answers, and i need to determin if one of their answers is still in the question list.  I've used both lodash and the vanilla javascript filter method.
_.filter(answers, async answer=>(await db.questions.where('key').equals(answer.key).first())!=undefined)
No matter what i do, it returns all 5 answers as if they are still in the database. But there is only 4 in the database.  Is there an issue with this?

_.fillter() and Array.filter takes a callback returning a boolean but your callback returns a Promise.

_.fillter() and Array.filter takes a callback returning a boolean but your callback returns a Promise.

No, it's not returning a promise. I'm using async await which should use the value and not the promise. I'm starting to feel this is a bug in not only this library but in browsers in general. Doesn't behave as expected.

async functions return promises

Every time i've used async await, the promise resolves and results in the value.  It doesn't return a promise after it's done.  It's not behaving as intended.

There are good resources on the net to read more about how async keyword works. For example this link. Please read it to understand that you can't use an async function as an argument to Array.filter(). The code wouldn't compile if it was typescript.
But I could also give you a hint on how to solve your actual problem:
const matchingQuestions = await Promise.all(
  answers.map(answer => db.questions.get({key: answer.key})
);
const result = matchingQuestions.filter(q => q !== undefined);

This doesn't change the fact that i've used async and await inside of callbacks before.  Oh well.

Hello @cpgb85 , sorry for stumbling in your conversation. Kindly remember that Dexie is Open Source Software. @dfahlander was very kind to point you in the right direction. You should at least thank him.
It is good to not know anything, is not good to be disrespectful.
Cheers.

Hello @cpgb85 , sorry for stumbling in your conversation. Kindly remember that Dexie is Open Source Software. @dfahlander was very kind to point you in the right direction. You should at least thank him.
It is good to not know anything, is not good to be disrespectful.
Cheers.

There was no disrespect.  Apologies if there was some taken.

@cpgb85 all right then. Have the solution presented by @dfahlander helped you?


Release patch version

Could you release patch version with latest changes, please?
Also, could you clarify the status of package, please?

I just released version 0.3.6 on Hex.

Also, could you clarify the status of package, please?

Can you elaborate on this? What kind of status are you referring to?


Improve comments for radio-group

Also fixup little errors here and there. @surma PTAL

Also, please rebase this branch against master so we get the auto-build and the linting :)

@surma I've rebased against master. Also I named the actual elements dash-*. And I factored _setChecked into smaller functions so I can call them during initialization without stealing focus.
Not sure why, but my first block comment is appearing next to the code, instead of at the top of the doc like it does in tab-panel.js

Same as with Monica’s PR, I rebased against master so the new linting rules are used and I fixed the linter errors (mostly whitespace) and I renamed the files to dash-*.
Preview is now available.
Are you going to add tests before we merge or do you want to do that separately?

I'll do it separate just because I figure it'll take a little while and I don't want to fall too far behind and get lost in rebase land :D

OFF WE GOOOOO 🚂

Merged in 115fdf015e37888bb5501dfb0200b2aecc260c0f


No module named 'btlewrap'

I get the following error:
/home/pi/miflora/demo.py --backend gatttool poll C4:7C:8D:61:57:A0
Traceback (most recent call last):
File "/home/pi/miflora/demo.py", line 9, in
from btlewrap import available_backends, BluepyBackend, GatttoolBackend, PygattBackend
ImportError: No module named 'btlewrap'

the latest version of miflora depends on the btlewrap library. If you install miflora via pip (which is the recommended way), pip will also install this dependency for you. I just added this to the documentation:
https://github.com/open-homeautomation/miflora/blob/master/README.md#dependencies

old issue --> closing it

I have the same error.
/home/pi/miflora/demo.py --backend gatttool poll C4:7C:8D:61:57:A0
Traceback (most recent call last):
File "/home/pi/miflora/demo.py", line 9, in
from btlewrap import available_backends, BluepyBackend, GatttoolBackend, PygattBackend
ImportError: No module named 'btlewrap'
please guide, for import btlewrap file

did you try the solution above?

yes, I try that... But still, I have a different error.
usage: demo.py poll [-h] mac
demo.py poll: error: the following arguments are required: mac


Override ASG Tag propagation

I have issues
Firstly thanks very much for maintaining this module, we've received a ton of value from this code.
Currently when passing a list of tags into the module they get applied to both The ASG and instances/workers due to propagate_at_launch defaulting to true.
I have a particular tag that I want applied to all resources including the ASG but except the worker nodes.
A similar PR/Issue has been raised here: https://github.com/terraform-aws-modules/terraform-aws-eks/pull/1076 but was rejected with a good suggestion on how to solve this, which I plan to raise a PR for.
I'm submitting a...

[ ] bug report
[x] feature request
[ ] support request - read the FAQ first!
[x] kudos, thank you, warm fuzzy

What is the current behavior?
Currently all tags passed in via var.tags are propagated to ASG and worker nodes.
If this is a bug, how to reproduce? Please include a code sample if relevant.
What's the expected behavior?
Based on the discussion in #1076 it seems there's a desire to solve this by allowing launch templates in the variable worker_groups_launch_template to override var.tags.  This would happen for ASGs by using local.asg_tags, so that during processing we use var.workers_group_defaults.tags, thus overriding the var.tag.
Are you able to fix this problem and submit a PR? Link here if you have already.
https://github.com/terraform-aws-modules/terraform-aws-eks/pull/1092
Environment details

Affected module version: latest/master
OS: N/A
Terraform version: N/A

Any other relevant info
It would really help although obviously not expected if this would be merged in and tagged fairly soon as this would allow us to ship some functionality we require and I know others are looking forward to this as well!

Closing this, since #1092 is now merged.

v13.2.0 is now released.


Remove duplicate primitive collections

Remove duplicate(check true is this) primitive collections. Now generated for each project that refers to the generator.

Now Primitive collections are generated only for the StackMemoryCollections library.


More options to change host and port of perseus serve

Right now, host and port can be changed through environment HOST and PORT.
It would be nice to have more options :

command line option
dotenv/perseus.toml

Moreover, HOST and PORT are too generic, PERSEUS_HOST and PERSEUS_PORT would be better.

The new -s/--serve flag on perseus export takes command-line arguments for these, and I agree that it would be far better to use the same system on perseus serve. I'll introduce the command-line arguments for development usage, and they'll take precedence over the environment variables, but the reason the system is the way it is now is because of the final binary.  I obviously don't want to bring something like clap into that, and I honestly want to avoid any argument parsing at all there, which is why I used environment variables. In development though, they are inconvenient.
As for the naming, I originally considered making them more specific in that way, though I decided to go with what other frameworks do (e.g. create-react-app uses HOST and PORT). However, I appreciate that these are inconvenient to specify in something like .bashrc because they'll likely impact other programs, so I'll make these less obnoxious in v0.4.0 (it's a breaking change).
With regards to perseus.toml, I think I'm going to say no to that, because it adds extra complexity that I don't think is necessary in terms of providing these arguments. If you want to set the host and port for all the Perseus apps you develop, you can set the environment variables somewhere like .bashrc (which will be easier with the name changes). If you just want to set them for a single project, you can use a command aliasing system like make or Bonnie.
How does that all sound to you @Mazwak?

About my original request, that is « enhance perseus serve ».
Command-line would be nice but not mandatory. Some users are more used to options than to environment variables. It would be a QoL for them. Also, most (all ?) frameworks have those options.
I think names for the environment variables should not be generic. It could be both though. First PERSEUS_HOST, then HOST.
I think reading a ".env" file would be nice. File can be committed.
You clone, you launch perseus serve, and it listen where you expect it to.
I do agree that it is MUCH more work than reading the environment.
It’s ok not to implement it.
Bonnie is an ok solution.
For perseus deploy or export
I do agree that less dependencies is better.
Using only HOST and PORT is ok, as you usually setup the env for your app.
I would even go as far as if --host/--port is used, host and port should be hardcoded, mainly for deploy.

As I said, I'll add the command line options and I'll change the environment variable names in v0.4.0. A .env file is not a standard thing outside the JS ecosystem to my knowledge, it's quite particular to NextJS, so I'm not that keen to implement that, it also makes the priorities system for conflicts overly complex in my opinion.
As for the deployed binary, I think hardcoding isn't an option because the binary should be as portable as possible, I'd prefer to stick to the environment variables there.

This is done, and will be released in v0.3.2. The HOST/PORT environment variables are now deprecated, and I'll remove them altogether in the next major release.


Lua 5.4

Lua 5.4.0 is nearing a final release. It is currently at rc3.
Our supported Lua versions according to our rockspec is lua >= 5.1. Does this imply that 5.4 is supported on release? If so, think we should should look at whether that is true. I'm not sure if there are any compatibility changes that will affect us.

Would definitely be nice to start testing 5.4 in CI.

Lua 5.4 has formally released since opening this issue. https://www.lua.org/manual/5.4/readme.html

Looks like #515 is merged. Are the build issues fixed? Should we make a 1.14.0 release?

Looks like #515 is merged. Are the build issues fixed? Should we make a 1.40.0 release?

YES

I'd like to finish up #487 and merge it before releasing 1.40.0. Will try to do that soon.

Anyone need to do before a new release

There are some open issues. #503 / #505 / #506. Not sure how easy those are to fix.


Update docker setup docs

As reported by @LyXman in #439, the docker setup docs needs to be updated with MIX_ENV=prod while running migration and seeding, as well as a BASE_URL.

@sirn That's definitely a more proper way than mine 👍

The installation from @sirn  is work. Please change it to official doc.


Added implementation of relative links #7

This takes the existing implementation of relative links, and rebases it on master (to fix the conflicts).
It also fixes the incorrect closing tag issue mentioned in 996655c3d8c0eecff622c8d82292ca2d2d133380.
Fixes #7.

Any timeline for this pull request ? This would be really nice to be able to link directly to specific lines :)


Code injection missing from the Subscribe page

Issue Summary
The code injection does not work on the "Subscribe" page.
Therefore tracking Goals/Conversions is impossible.
To Reproduce
Not applicable
Technical details:

Ghost Version: 2.1.0
Node Version: 8.11.1
Browser/OS: Chrome/Windows
Database: SQLite

Hey @RadoslavGatev   👋 Friendly reminder: help or support is not available on Github. Our default issue templates pointed you to our forum for this type of question 😄 We use GitHub solely for bug-tracking and on-going feature development so we try to keep it noise free.
Many questions can be answered by reviewing our docs for self-hosters, our theme API, or our public API. If you can't find an answer then our forum is a great place to get community support, plus it helps create a central location for searching problems/solutions.
FYI: Many projects have their own support guidelines and GitHub will highlight them for you, or the project owners will use issue templates to point you in the right direction. Reading the guidelines or issue templates before opening issues can save you and other project maintainers some valuable time.

Hey @kirrg001,
Friendly reminder: That's not a question and I can perfectly read and understand templates pointed to me😄
That's an issue with your system as it says the following about Code injection

Code here will be injected into the {{ghost_head}} tag on every page of your blog

Thank you so much!

@RadoslavGatev Yes the code will be injected into the {{ghost_head}} on any page, if the ghost_head is used. The subscriber app does not use the head by default.
If you want to use it, you can override the subscribe.hbs and put it in your theme.


Bring build scripts up to date with 13

Testing at https://ci.adoptopenjdk.net/view/build-tester/job/build-scripts-pr-tester/job/test-build-script-pull-request/236/

Have corrected 12 to 13 in the doc so approving - hope you don't mind me hijacking your PR to get this through @karianna

Not at all!


WebSocketApi Construct: Missing Cloudwatch Permission

It seems quite a few people on discord have run into this issue and I couldn't find an open issue regarding it so I thought I'd open one.
When attempting to run sst start or sst deploy with a web socket construct, the below occurs:
"CloudWatch Logs role ARN must be set in account settings to enable logging (Service: AmazonApiGatewayV2; Status Code: 400; Error Code: BadRequestException; Request ID ..."
It seems like a policy has been forgotten to be created and linked to the created websocket api.
Hopefully someone can address this soon :)
Hacky temporary work around until this is fixed (for those who are stuck):
If you do not care about the logging: pass in accessLog: false, as a prop the WebSocketApi construct and you are done.
If you care about the logs:
Once it is deployed (prop still needs to be passed in), you can follow this guide: https://sst.dev/chapters/api-gateway-and-lambda-logs.html
This will take you step by step how add the permission to the api gateway.
Note: you may still need to pass in the accessLog as false to get it to initially deploy and then remove it once you add the permission on the console
Note note: This is a hack to get around it, I am sure there is an official way to do but no one from SST has responded to this exact query that I posted the other day.
The issue explained (My interpretation of it):

You deploy the API
It's missing permissions
It fails to deploy
the role back deletes the API meaning you cannot add the permission manually

And then the cycle keeps repeating

@fwang can you take a look at this when you get a chance?

i think i've found a programmatic workaround, i no longer get the "CloudWatch Logs role ARN" error after doing the following:
import { aws_iam as iam, aws_apigateway as apigw } from "aws-cdk-lib";

// Do the following code *before* instantiating *any* API gateway (both regular and websocket)

const role = new iam.Role(stack, "cloudwatch-logs-role", {
  assumedBy: new iam.ServicePrincipal("apigateway.amazonaws.com"),
  managedPolicies: [
    iam.ManagedPolicy.fromAwsManagedPolicyName("service-role/AmazonAPIGatewayPushToCloudWatchLogs"),
  ],
});

new apigw.CfnAccount(stack, "cfn-account", {
  cloudWatchRoleArn: role.roleArn,
});

// Now you can instantiate your API gateways as usual
const api = new Api(stack, "api", { ... });
const wssApi = new WebSocketApi(stack, "wssApi", { ... });

Thanks! Ran into this when migrating from v1 to v2.

Fixed in 2.0.19.
^ added a custom resource that checks if the Role is present. If not, it will create one and attach to API Gateway.

Worked after a teardown and re-deploy. :-/


Token mismatch using iOS 18 Beta 1

Description
I'm getting the following error when running my app on iOS 18 and requesting phoneAuthentication:
Error Domain=FIRAuthErrorDomain Code=17048 "Token mismatch" UserInfo={NSLocalizedDescription=Token mismatch, FIRAuthErrorUserInfoNameKey=INVALID_APP_CREDENTIAL}.
Before the update to iOS 18 everything worked normally. I triple checked the configuration and everything should be okay on my side. Everything's untouched except the iOS version.
Strangely I could fix the issue by changing .prod -> .unknown in
Auth.auth().setAPNSToken(deviceToken, type: .unknown)
Messaging.messaging().setAPNSToken(deviceToken, type: .unknown)
Reproducing the issue
No response
Firebase SDK Version
10.28.0
Xcode Version
16.0 Beta (16A5171c)
Installation Method
Swift Package Manager
Firebase Product(s)
Authentication, Firestore, Messaging, Storage
Targeted Platforms
iOS
Relevant Log Output
Error Domain=FIRAuthErrorDomain Code=17048 "Token mismatch" UserInfo={NSLocalizedDescription=Token mismatch, FIRAuthErrorUserInfoNameKey=INVALID_APP_CREDENTIAL}

If using Swift Package Manager, the project's Package.resolved
No response
If using CocoaPods, the project's Podfile.lock
No response

Thanks for reporting, @Meyssam120. I tried to reproduce the issue on iOS 18 beta, but I can't get the same behavior. You mentioned that the issue was fixed by changing the APNs token type to .unknown, in which the actual token will be auto detected from your provisioning profile. The error you encountered usually happens when the APNs device token is either incorrect or doesn't match the certificate uploaded in the console.
With this, could you verify the following:

Check if the bundle ID in your app is the same as the bundle ID registered in the console (Check Project Settings -> Your App for the bundle ID registered)
Check that the uploaded APNS certificate is correct and up-to-date
Download an updated GoogleService-Info.plist and add it to your app
Verify if the APNs device token is not expired
Verify if your App ID and Team ID are setup correctly

Thanks for verifying, @Meyssam120. May I know if the issue occurred to all users or just in a specific region?

The app is not public yet, so I've only experienced myself in Germany.

@Meyssam120, is it possible for you to provide a sample app that reproduces the issue? Also, are you reproducing it using a simulator or a physical device?


Test Issue created at Fri, 11 Mar 2022 02:31:42 GMT

Test issue body  Fri, 11 Mar 2022 02:31:42 GMT

Comment on issue at Fri, 11 Mar 2022 02:31:44 GMT


Docs - store .net code snippets beside the converted markdown

The initial part of the docs conversion process is running a csproj executable which converts all of the javadocs html files based on their 4.8.0 release tag into consumable markdown files that are compatible with our api docs (which use DocFx). NOTE: These are not the same as the API docs output that are created from the /// comments in our code. These are extra java doc files that document things like namespaces and libraries
Each time this conversion process executes it overwrites all markdown files which means that we don't want to be manually changing the output markdown files because if we did that we'd have to go analyze all changes made by this process and revert parts of the changed files that we have knowingly changed which is not fun or sustainable (there's a lot of files!)
So instead of manually changing the output files we have written code for various tweaks of these files to ensure they are output correctly. Some of these tweaks are specific to certain namespaces and projects, etc... For embedded code snippets we should be able to do the same thing:

Store .net code snippets in separate files, we'll need to come up with a scheme for this to associate a code snippet for where it needs to be merged in
During the conversion process we can detect java code snippets and then lookup our own external files to see if there's a snippet for that section available and if so, replace the java snippet with the .net one

~15(+) hrs

@Shazwazza
With #396 in place, is there still a need to do this?

Nope, I'll close this one, Cheers!


Added file headers for better catting together

I added file headers like:
# ===== filename ===== #
content of file

to every file so that operations like,
cat /gitattributes/C.gitattributes >> ~/myproj/.gitattributes

give better looking and more maintainable output.
I suggest making this a standalone branch of the repo so that people can use whatever they want

I generally like this, but let's see what the .gitignore project thinks.

I am on the same boat as https://github.com/github/gitignore/pull/1869.
Similarly to gitignore.io there is: http://gitattributes.io


[Icon Request] NGRX Icons

[X] I'm sure this issue is not a duplicate?
[X] I want to create an icon request(if not, remove these lines below):
- Type: extension
- Icon Name: ngrx
- Sample original Icon: url
- Extensions: .state .*state, .actions, .reducer, .*reducer, .effects

could conflict with redux icons, if any. only applies to angular icons.

I'm afraid, but somewhat like .*state is not supported by vscode, so we cannot provide that, yet.

@robertohuertasm needs to have a look at this I suspect it's something similar to the smart-component thing.

.state.ts would handle the majority, as well as .reducer.ts but some people use rootReducer.ts and rootState.ts etc. and some even use the index.ts in a reducer folder as the root state. Obviously nothing to be done there.

This has been something that have crossed my mind several times but, honestly, I didn't find it so valuable as to bring it into the table.
Although these extensions are commonly used in ngrx most of them are also used in all redux-based implementations so, in case we thought of implementing this, we shouldn't approach it as an Angular iconset extension. Furthermore, it should be optional. Maybe we should add some detection functionality looking for ngrx, redux, vuex in the package.json.
But, as I said, I have many doubts about the benefit of implementing these icons:

These should be generic icons so it would suppose a huge difficulty finding and/or designing them.
Normally, people organize actions, reducers, state and effects in a specific folder. See ngrx example and redux example
I guess the extension itself along with the folder structure is enough to identify the purpose of the files so that's why I don't really see a strong point in favor of implementing this.

As a final reminder to @Kaffiend, I guess you already know that we provide the option to customize the file associations.
@JimiC, @jens1o, do you have an opinion on this matter?

I fail to comment that when #933 is delivered you will be able to add your custom icons into the same repo or even a shared location making it easy to share your custom icons with your team.

Technically ngrx detection can be done via PAD. It's the art part that's troubling me. And once we found them we will have to create also folder icons with them.

I think we can do that... But it's a huge job to get this done and this would introduce a lot of testing, while most of the users don't actually want this... We have 2.5 million downloads and only one request. Okay, when we get this done, and I'm really looking forward to see this working, I'm absolutely fine. I think this would be a big surprise and would add another value to this project. :)

this is the official ngrx image, with the angular shield and rx icon. different iterations of color could be used to differentiate?
@JimiC what folder patterns are you referring to? state, reducers, actions etc?

@Kaffiend Technically we can support ngrx and redux project's detection. It's the art part that will take time. Currently, the team is busy with RL staff and there is not much free time to dedicate to the project. We will iterate on this again by Fall.

@Kaffiend, obviously ngrx is not redux but it's clearly based upon it and thus they share some of the suffixes like reducers, actions... I don't see the point on why this should only be reduced to ngrx. If we're going to do this I will aim also for  redux, ng-redux and vuex (although the latest diverges in some of the terms like actions).
I use ngrx in a daily basis so it's not that I'm against this because of ignorance of the library. It's just that I'm not sure that this will add any value aside from more auto-detection prompts and additional restarts once you change between projects. As a user, this is a thing I'll try to avoid at all cost.  That being said, I'm fully aware that PAD is completely optional so changes can be done manually but the point would be that if I have several projects with different state management libraries like redux and ngrx which are based in the same pattern I wouldn't like to be even manually changing the icons.
Anyway, I agree with @JimiC in posposing this discussion after summer. We're all really busy aside from the project and this is not a priority issue.

Anything I can help on this issue?

Any news on this, since Material-Icons provided an example/solution for this (as per @KingDarBoja comment)?

Sorry @georgeat8 the project is in low maintenance mode and this would still required to code the PAD functionality. Not sure when we'll have bandwidth for this.


Pex disappearing when restarting server or date

Someone help me I put the pex on my server 1.8 ai when I close the server I open it disappears

Show me your console log.

as well?

Copying stuff to Pastebin is typically how things are shared in the Minecraft community.  Since you seemed extremely new to Minecraft servers, I figured I should mention Pastebin in my previous post.

Could you send me a tutorial on how I put the files there? Because I do not know

You don't know how to copy and paste text?

Yes I know

Copy the text from your server console and paste it into Pastebin.  After you click "Create a New Paste" at the bottom of the screen, you will see your paste with its own link at the very top of your browser, in the address bar.  Copy that address and paste it into this thread.

http://pastebin.com/D3UHwGKg

[21:03:24 WARN]: **** SERVER IS RUNNING IN OFFLINE/INSECURE MODE!
PermissionsEx does not support servers running in offline mode.  You will need to change the server.properties file setting to online-mode: true before PEX will function properly and then I can help you more.

But if I put online-mode I do not have original minecraft

Sorry.  I can't help you with that.  PEX doesn't support hacked/illegal copies of the Minecraft client or servers.


Remove attributes

The current benefits of using attributes are to tie statistics together and to have them grow in a non-linear fashion. The former can be better achieved manually, and the latter makes it very hard for players to predict how changes to an attribute will impact a character.
Thus, it would be better to remove the attributes and simply rely on the statistics.

Done.


Fixed backup_xcarchive destination path handling

Fixed #1247 issue.
The solution for the issue #1247 is to create zip file in some temporary folder and then move the file to the destination.

Really sorry for the delayed reply, this is a great pull request, thank you so much for your contribution :+1: This will be in the next release


Auto formatting error

Apparently the formatter doesn't account for conditional compilation, so when it sees a block of code like this...
#if !lime_webgl
public function bufferData(target:Int, srcData:ArrayBufferView, usage:Int, srcOffset:Int = 0, length:Int = 0):Void
{
#else
public inline function bufferData(target:Int, srcData:Dynamic, usage:Int, ?srcOffset:Int, ?length:Int):Void
{
#end

...it indents once per curly brace. So instead of duplicating these curly braces, we should put them after #end.

 Otherwise, Git would show that 1245 lines were removed and replaced by 1245 new lines, not recognizing that any of those lines match, and it would be much harder to verify.
I'm not saying the "files changed" tab shows a very good diff, but it's a lot better than if I'd submitted this PR as a single commit. At least the lines almost still line up, rather than appearing hundreds of lines down.
To see good-quality diffs, look at the individual commits.


add array REVERSE and APPEND VMOp codes

Implementing new VM Opcodes recently introduced to the C# VM in this issue:
https://github.com/neo-project/neo/issues/117
This goes along with neo-boa commit https://github.com/CityOfZion/neo-boa/commit/0bb91e754ed575c6a528ff0c469d3ac713eb4085, which provides compiler support for these OpCodes
So... now we can do this in a smart contract:
m = [1, 2, 4]
m.reverse()

m.append(8)

Notify(m) # this will output [4,2,1,8]

Coverage decreased (-0.09%) to 68.17% when pulling d15d6a5cd4f2963a62632fd6d134cb559641095b on feature-vm-additions into 4554cbb9f399d68db4b7dbadbbb0f2495c88857c on master.


Easily move databases

I used to use the local SQLite3 database (start command label studio start - p 8081) before, but now I want to switch to the local PGSQL database (start command label studio - db postgreSQL - p 8081), or switch from PGSQL to SQLite3.
But I found that the data is not interconnected. Is there a convenient command to synchronize user information and annotation data with each other.Thanks.

You can use this script:
https://github.com/HumanSignal/label-studio-sdk/tree/master/examples/migrate_ls_to_ls
It doesn't make the full migration, however the main entities will be copied.


Fix features of examples

Some errors because the corresponding features aren't enabled in Cargo.toml.

Great, thanks!


P5js examples not running

I'm trying to run the p5js examples with an 8x8 WS2812 neopixel matrix, but nothing is showing up.

Did you run the example in a web browser?

yeah yeah nothing shows up for some reason

The grid8x8_simple_noise.html runs in a web browser but when I run the javascript file in P5 nothing shows up, Why is this?

p5.js needs the sketch to be sketch.js or the html to be index.html. Also, p5 is very picky about how the file structure is setup.  I used p5.js to produce the sketches then transferred them out.  Can you open the browser console to see what the error is?  I'm not sure why it's not running from the browser.

Also make sure you have the libraries and images folders in the working folder.


NameError: name 'collect_results_cpu' is not defined

Thanks for your error report and we appreciate it a lot.
Checklist

I have searched related issues but cannot get the expected help.
The bug has not been fixed in the latest version.

Describe the bug

It works well if I run tools/test.py with single GPU.
But error happens when I run it with multiple GPUs.
The errors are as follow:

Reproduction

What command or script did you run?

CUDA_VISIBLE_DEVICES=0,1,2 bash ~/code/****/tools/dist_test.sh ~/code/****/configs/faster_rcnn_x101_32x4d_fpn_1x_hardhat.py ~/model/****/1228/epoch_9.pth 3 --out ~/model/****/1228/result9.pkl

Did you make any modifications on the code or config? Did you understand what you have modified?
Yes
What dataset did you use?
VOC (cusomized)

Environment

Please run python tools/collect_env.py to collect necessary environment infomation and paste it here.

sys.platform: linux
Python: 3.7.4 (default, Aug 13 2019, 20:35:49) [GCC 7.3.0]
CUDA available: True
CUDA_HOME: /usr/local/cuda
NVCC: Cuda compilation tools, release 10.0, V10.0.130
GPU 0,1,2,3: GeForce RTX 2080 Ti
GCC: gcc (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0
PyTorch: 1.2.0
PyTorch compiling details: PyTorch built with:
  - GCC 7.3
  - Intel(R) Math Kernel Library Version 2019.0.4 Product Build 20190411 for Intel(R) 64 architecture applications
  - Intel(R) MKL-DNN v0.18.1 (Git Hash 7de7e5d02bf687f971e7668963649728356e0c20)
  - OpenMP 201511 (a.k.a. OpenMP 4.5)
  - NNPACK is enabled
  - CUDA Runtime 10.0
  - NVCC architecture flags: -gencode;arch=compute_35,code=sm_35;-gencode;arch=compute_50,code=sm_50;-gencode;arch=compute_60,code=sm_60;-gencode;arch=compute_61,code=sm_61;-gencode;arch=compute_70,code=sm_70;-gencode;arch=compute_75,code=sm_75;-gencode;arch=compute_50,code=compute_50
  - CuDNN 7.6.4
    - Built with CuDNN 7.3.1
  - Magma 2.5.0
  - Build settings: BLAS=MKL, BUILD_NAMEDTENSOR=OFF, BUILD_TYPE=Release, CXX_FLAGS=-fvisibility-inlines-hidden -std=c++11 -fmessage-length=0 -march=nocona -mtune=haswell -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2 -ffunction-sections -pipe -I/opt/conda/conda-bld/pytorch_1566789512916/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_place/include -fdebug-prefix-map=/opt/conda/conda-bld/pytorch_1566789512916/work=/usr/local/src/conda/pytorch-1.2.0 -fdebug-prefix-map=/opt/conda/conda-bld/pytorch_1566789512916/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_place=/usr/local/src/conda-prefix -Wno-deprecated -fvisibility-inlines-hidden -fopenmp -DUSE_FBGEMM -DUSE_QNNPACK -O2 -fPIC -Wno-narrowing -Wall -Wextra -Wno-missing-field-initializers -Wno-type-limits -Wno-array-bounds -Wno-unknown-pragmas -Wno-sign-compare -Wno-unused-parameter -Wno-unused-variable -Wno-unused-function -Wno-unused-result -Wno-strict-overflow -Wno-strict-aliasing -Wno-error=deprecated-declarations -Wno-stringop-overflow -Wno-error=pedantic -Wno-error=redundant-decls -Wno-error=old-style-cast -fdiagnostics-color=always -faligned-new -Wno-unused-but-set-variable -Wno-maybe-uninitialized -fno-math-errno -fno-trapping-math -Wno-stringop-overflow, DISABLE_NUMA=1, PERF_WITH_AVX=1, PERF_WITH_AVX2=1, PERF_WITH_AVX512=1, USE_CUDA=True, USE_EXCEPTION_PTR=1, USE_GFLAGS=OFF, USE_GLOG=OFF, USE_MKL=ON, USE_MKLDNN=ON, USE_MPI=OFF, USE_NCCL=ON, USE_NNPACK=ON, USE_OPENMP=ON,

TorchVision: 0.4.0a0
OpenCV: 4.1.2
MMCV: 0.2.15
MMDetection: 1.0rc1+16a6f7d
MMDetection Compiler: GCC 7.4
MMDetection CUDA Compiler: 10.0

You may add addition that may be helpful for locating the problem, such as

How you installed PyTorch [e.g., pip, conda, source]
Other environment variables that may be related (such as $PATH, $LD_LIBRARY_PATH, $PYTHONPATH, etc.)

Error traceback
*****************************************
Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.
*****************************************
[>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>] 1701/1701, 21.6 task/s, elapsed: 79s, ETA:     0sTraceback (most recent call last):
  File "/home/****/code/****/tools/test.py", line 247, in <module>
    main()
  File "/home/****/code/****/tools/test.py", line 210, in main
    outputs = multi_gpu_test(model, data_loader, args.tmpdir)
  File "/home/****/code/****/tools/test.py", line 80, in multi_gpu_test
    results = collect_results_cpu(results, len(dataset), tmpdir)
NameError: name 'collect_results_cpu' is not defined
Traceback (most recent call last):
  File "/home/****/code/****/tools/test.py", line 247, in <module>
    main()
  File "/home/****/code/****/tools/test.py", line 210, in main
    outputs = multi_gpu_test(model, data_loader, args.tmpdir)
  File "/home/****/code/****/tools/test.py", line 80, in multi_gpu_test
    results = collect_results_cpu(results, len(dataset), tmpdir)
NameError: name 'collect_results_cpu' is not defined
Traceback (most recent call last):
  File "/home/****/code/****/tools/test.py", line 247, in <module>
    main()
  File "/home/****/code/****/tools/test.py", line 210, in main
    outputs = multi_gpu_test(model, data_loader, args.tmpdir)
  File "/home/****/code/****/tools/test.py", line 80, in multi_gpu_test
    results = collect_results_cpu(results, len(dataset), tmpdir)
NameError: name 'collect_results_cpu' is not defined
Traceback (most recent call last):
  File "/home/****/anaconda3/envs/open-mmlab/lib/python3.7/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/home/****/anaconda3/envs/open-mmlab/lib/python3.7/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/home/****/anaconda3/envs/open-mmlab/lib/python3.7/site-packages/torch/distributed/launch.py", line 246, in <module>
    main()
  File "/home/****/anaconda3/envs/open-mmlab/lib/python3.7/site-packages/torch/distributed/launch.py", line 242, in main
    cmd=cmd)
subprocess.CalledProcessError: Command '['/home/****/anaconda3/envs/open-mmlab/bin/python', '-u', '/home/****/code/****/tools/test.py', '--local_rank=2', '/home/****/code/****/configs/faster_rcnn_x101_32x4d_fpn_1x_hardhat.py', '/home/****/model/****/1228/epoch_9.pth',
'--launcher', 'pytorch', '--out', '/home/****/model/****/1228/result9.pkl']' returned non-zero exit status 1.

Bug fix
If you have already identified the reason, you can provide the information here. If you are willing to create a PR to fix it, please also leave a comment here and that would be much appreciated!

fixed! the issue is caused due to code merge error


Fix number lexer to support negative exponents

This pull request fixes the number lexer to support negative exponents like 1.23e-2.

Thanks!


refactor: expose auth field in Salesforce struct for enhanced integration

Addresses #43
This PR exposes the auth field in the Salesforce struct to allow direct access to the authentication token, essential for specific API calls such as retrieving ContentVersion data. This change improves the client's flexibility and integration capabilities. I have run the test suite, and all tests pass successfully. No changes in test coverage.

@iamber12 Hey Amber, thank you! I was hesitant to make this public, it opens the door for users to edit the field values of the Authentication struct, which doesn't feel right. What if instead we created a method on the Salesforce type GetAccessToken() that just returned the value of sf.auth.AccessToken? That way the values remains read-only.
Let me know your thoughts on that, I'm open to my mind being changed.

@k-capehart I hadn't thought of it that way, but it makes complete sense. I agree with your point, and I'll make the changes to create a GetAccessToken() method instead. I'll update the PR shortly.

@k-capehart I added it to the Salesforce struct for simplicity. Please let me know if this approach works for you.

@k-capehart I added it to the Salesforce struct for simplicity. Please let me know if this approach works for you.

@iamber12 I have once concern with this specific solution, but maybe you have a different perspective.
I'd be worried that there could be potential drift between the AccessToken in the Salesforce struct, and the AccessToken on the Authentication struct. Since one of them is public and therefore can be edited. So you could authenticate, then do something like sf.AccessToken = "1234". Your operations would still work, but then your public facing AccessToken differs from the private one, with no means of retrieving the private one.
Going back to what I said earlier, I think the best solution is still to have something like this.
func (sf *Salesforce) GetAccessToken() string {
    return sf.auth.AccessToken
}

@k-capehart while having it in the Salesforce struct would have been more convenient for certain operations, I understand the concern about maintaining consistency and avoiding potential issues.
I've made the necessary changes and updated the PR accordingly.

@iamber12 Awesome, thanks for spending the time, it's greatly appreciated! 🏆
I'll merge this in and create a new release shortly.
I also invited you to the repository. No pressure on more contributions or anything, but I think it'd be great to have you listed as a contributor.

@k-capehart Thank you for the invitation to the repository. I’m happy to accept and look forward to contributing more in the future.


fix: fix error when give Image propTypes eg. resizeMode (#20)

Coverage remained the same at 93.548% when pulling f292b65e5a2d64f4d627566db2023d54b16c740a on ShinyLeee:master into 20c438a62c5997e8e5bc673abeedf63f6fbb1321 on billmalarky:master.


[fjxld] group tiles by type, then decode using SIMD

Hi, Luca.
The question is related to jxl.
Previously I noticed that decoder is 10 times slower than encoder: https://github.com/libjxl/libjxl/pull/1975#issuecomment-1416775973
I guess, it is because of dependency between pixels at decoding. What if to group tiles with the same predictor type?
I said "guess" because I'm unable to locate the code for encoding and decoding -e 1, the structure of libjxl is a bit over-complicated. Can you provide the direct links at current master?
Or, maybe, you want to test this idea and write fjxld?

Moving the discussion to the jxl repo, which is more appropriate :)


knot: fix keymgr permissions

Disclaimer
Please note that I've discovered knot yesterday and thus don't know it well at all. I'm just hacking my way to make it work, and thus this PR may not be the right thing to do.
Motivation for this change
NixOS' services.knot module currently uses systemd's DynamicUser coupled with StateDirectory, but knotd is not the only executable which must be able to operate on the StateDirectory, keymgr must too be able to manage keys within it. keymgr could be run as root but then the permissions of the keys wouldn't be right for knotd. In some condition DynamicUser can run a recursive chown but it would be at the restart of service and AFAIU, only if the StateDirectory is owned by the wrong user, but here this is the sub directory keys/ which is would be owned by root and not knot.
Things done
This patch wraps keymgr with systemd-run --pipe --uid knot -p DynamicUser=yes -p StateDirectory=knot to run it with the proper mount namespace allowing it to reach /var/lib/private/knot, bypassing the /var/lib/private/ protection restricted to root by the DynamicUser machinery.
This workaround still has the (minor) inconvenient to require to run keymgr as root.
--working-directory="$PWD" is also use to be able to give relative paths to keymgr (eg. for import-bind) but this may fail if the current directory is not accessible to the knot dynamic user (even if it's just a keymgr $zone list).
Alternatives
Use a SETGID bit
I've not tested it but I thought that if StateDirectoryMode = "2770" instead of 0700 then the knot group will be inherited by sub dirs and files, and thus running keymgr as root shouldn't be a problem. However if kasp/data.mdb is rw by the group it is not the case of kasp/keys/ which is created with different rights for the user and the group, the later is not allowed to write in it, thus automatic key generation by knotd may not work as expected (it won't be able to write/delete the keys/*.pem files). Maybe this could be worked around by wrapping keymgr with a umask 007 or a chmod -R g+w afterward.
Remove DynamicUser
I'm proposing this patch which assumes that there is a good reason to use DynamicUser and thus keep it, but I don't understand the benefit of DynamicUser for knotd, why not using a fixed system user like other NixOS services do?
AFAICS this alternative would be better for me as this would also let me open the OUTPUT firewall chain only for this knot system user (so it can notify the DNS slave servers) :
DNS(ACCEPT) $FW net {user=${users.users.knot.name}}

Currently I must open the firewall for all users, and can only specify the IP address of the DNS slave servers:
DNS(ACCEPT) $FW net:<IP_ADDRESS> # for knot to notify ns6.gandi.net

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

[X] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[ ] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Ensured that relevant documentation is up to date
[X] Fits CONTRIBUTING.md.

Given all these problems I think it might be better not using DynamicUser at all for knot. cc @mweinelt @vcunat

It would also make https://github.com/NixOS/nixpkgs/pull/79266/files a lot simpler.

I dropped DynamicUser in https://github.com/NixOS/nixpkgs/pull/79266

I dropped DynamicUser in #79266

oh! good to see you're working on it :) well then let's drop my PR


What does the 1x1 average pooling layer do in VGG models?

In this line:
https://github.com/kuangliu/pytorch-cifar/blob/master/models/vgg.py#L37
There is a 1x1 average pooling layer with stride 1. According to my knowledge of pooling, this layer basically does nothing?

Why there is no answer?

BD


Adding isCleanUp to Transaction

thoughts on if you want to make this universal, including endpoints that only return a single transaction? I'm a little mixed on the consistency of all endpoints vs. the useless data fields

what specific endpoint you have in mind? I checked all other endpoints. they look clean to me so far. there is some validity with the consistency point that you are raising.
if it looks awkwardly inconsistent, we can apply the same change later as well. it's a minor change.

I was thinking all of them, for example
message PostOrderResponse {
  string transaction = 1;
  string openOrdersAddress = 2;
}

I'm leaning a bit more to consistency of fields vs. the unnecessary ones, but could be swayed either way. any thoughts @DimaCantemir @kdonthi @atulsriv @yobloxroute ?

thoughts on if you want to make this universal, including endpoints that only return a single transaction? I'm a little mixed on the consistency of all endpoints vs. the useless data fields

what specific endpoint you have in mind? I checked all other endpoints. they look clean to me so far. there is some validity with the consistency point that you are raising.
if it looks awkwardly inconsistent, we can apply the same change later as well. it's a minor change.

I was thinking all of them, for example
message PostOrderResponse {
  string transaction = 1;
  string openOrdersAddress = 2;
}

I'm leaning a bit more to consistency of fields vs. the unnecessary ones, but could be swayed either way. any thoughts @DimaCantemir @kdonthi @atulsriv @yobloxroute ?

I think consistency of fields looks a bit cleaner. Not sure how much it really matters vs. keeping the unnecessary fields, but it looks better imo.


grandpa: always store justification for the latest finalized block

Currently when GRANDPA finalizes a block the client does not always persist the justification. It currently only does it: on authority set change blocks, randomly every N blocks. Since the only justifications that are required to provably sync the chain correctly are for the authority set handoffs it would just contribute to database bloat if we kept justifications for everything that's finalized. Still having a justification at hand for a recent block is useful to prove finality to light clients who don't participate in the GRANDPA protocol.
This PR adds a GRANDPA auxiliary storage entry where we always store the justification for the latest finalized block and overwrite it once a new block gets finalized.
Additionally I updated the warp sync protocol to make sure that we send the latest justification once we have finished warp syncing to the latest authority set.

Still want to add some tests for this.

Awesome, nicely done!

Sorry but I forgot about this PR. Should be good to merge now.

I'm not qualified to review, but I enjoy the idea of merging this.

bot merge


Do not allow basket line price become negative after discounts.

Refs #2773

@pjstevns what do you think?

@sasha0 looks good to me

I added a PR against @sasha0 's PR which adds the tests

@pjstevns thanks for implementing test.
@solarissmoke shall I mention about this change in the release notes?

Added release note in https://github.com/django-oscar/django-oscar/commit/974eb2cde71b430ab82a03a62b656e99334734d8


Make queue information pages update their information liveish

http://blog.miguelgrinberg.com/post/easy-websockets-with-flask-and-gevent


Rewrite for testability, error handling,  separation of concerns

First off, thank you for writing this library. The API is exactly at the level it should be for 99% of the interactions that people have with S3, as opposed to the extremely detailed APIs of something like rusoto or aws_sdk_rust.
What I found when working with the library, though, is that many potential sources of errors were handled with panic!. This was unworkable for my needs since I would be running this from a server. I started by rewriting chunks of the code to use the Rust Result type, and started to notice more and more places where I could "rustify" code. In the end I reworked quite a bit, and ended up with something that I think will be easier to use, maintain, and extend.
I'm opening this PR mainly as an option for you - if you like the changes I've made, great! I'd love to have this code live on in rust-s3. If not, no problem! I'll keep this code local to my own branch, and will absolutely make sure that you continue to get credit and proper license handling under MIT. I may opt to change the name to avoid confusion as well.
Here's a hitlist of changes:

All authentication is split out to a separate module, and could potentially be replaced by another library like warheadhateus if desired
S3 functions are now calls on the Bucket type
Stringly type region has been converted to an enum with appropriate conversion functions.
Unit tests added across all authentication functions.
Operational example added - simply requires S3 credentials and a bucket name to perform a CRUD test.
All functions and methods properly handle or return errors - no more panics or unwraps
openssl is replaced with rust-crypto to eliminate system library dependency
Docs for all public functions added, and warn(missing_docs) added at module level
Credentials are their own type and accept a Token for use with temporary credentials.
Requests use the bucket name in the URL path, not as a subdomain. This eliminates TLS issues for non-matching domain names.
List command now supports delimiters

Hi @nastevens,
thank you for the very detailed PR, I'm glad this lib getting picked up :)
You are completely right about the panics, just one of many issues that needed addressing, I'll be sure to go through and merge this ASAP. I've been following your fork and saw some really nice code :)
In the meantime it would be great if you'd join us on gitter, we might actually have a community forming.


Display frame information in the titlebar

@davidplowman
I'm sure there are better ways to allow the user to select what to display on the titlebar, so we don't have to take the second patch if you think it's overkill.

Hi Naush, thanks for this feature, I really like it! I did want to have a few little meta-discussions about some bits of it...

I think we're measuring the framerate of the frames that actually get displayed, which is inherently limited by the display refresh rate. I wonder if we should put that measurement on the event loop side of things, rather than in the asynchronous preview thread, so that we could (in principle anyway) measure higher framerates? Just as an example, we could even measure the instantaneous framerate as part of the request completion callback, and put it in the message payload that we queue up, though I don't know if that's the best way.

GetFrameInfo seems to have sprouted quite a lot of arguments. Possibly I should have made a simple "FrameInfo" structure for it straight away, but I was evidently a bit lazy. Maybe now would be the time? A FrameInfo object might have a few simple methods, such as a constructor which makes it out of the ControlList metadata, perhaps a method to give its string representation? Though that depends a bit on how we handle other things...

If we're going to be passing around BufferMaps and their ControlList metadata together more of the time, should we pass them in a structure? I think there already is one - the RequestCompletePayload or something? - though it could have a less hideous name...

What do you think? Though I'm also aware this would start to make it all a more substantial change, which probably wasn't intended...

I think we're measuring the framerate of the frames that actually get displayed, which is inherently limited by the display refresh rate. I wonder if we should put that measurement on the event loop side of things, rather than in the asynchronous preview thread, so that we could (in principle anyway) measure higher framerates? Just as an example, we could even measure the instantaneous framerate as part of the request completion callback, and put it in the message payload that we queue up, though I don't know if that's the best way.

Yes, that does seem reasonable.  However, it is a bit awkward as this framerate measuring code must be duplicated for each app's event loop, or have I got that wrong?

GetFrameInfo seems to have sprouted quite a lot of arguments. Possibly I should have made a simple "FrameInfo" structure for it straight away, but I was evidently a bit lazy. Maybe now would be the time? A FrameInfo object might have a few simple methods, such as a constructor which makes it out of the ControlList metadata, perhaps a method to give its string representation? Though that depends a bit on how we handle other things...

I did intend to add exactly such a class, but opted for the lazy approach instead... :)

If we're going to be passing around BufferMaps and their ControlList metadata together more of the time, should we pass them in a structure? I think there already is one - the RequestCompletePayload or something? - though it could have a less hideous name...

I think I will add a FrameInfo class that populates from the ControlList.  This gets passed back though the RequestCompletePayload message.  Does it need to be an explicit struct holding the two?  Maybe a std::pair will suffice?

I think we're measuring the framerate of the frames that actually get displayed, which is inherently limited by the display refresh rate. I wonder if we should put that measurement on the event loop side of things, rather than in the asynchronous preview thread, so that we could (in principle anyway) measure higher framerates? Just as an example, we could even measure the instantaneous framerate as part of the request completion callback, and put it in the message payload that we queue up, though I don't know if that's the best way.

Yes, that does seem reasonable. However, it is a bit awkward as this framerate measuring code must be duplicated for each app's event loop, or have I got that wrong?

I was wondering about calculating the instantaneous framerate in the requestComplete method, and then putting the result in the RequestCompletePayload, that way everyone would get it, and we'd be calculating it a bit nearer the correct place. As a general thing, this is then a place to put any extra information that we decide we like, over and above what the ControlList allows.

GetFrameInfo seems to have sprouted quite a lot of arguments. Possibly I should have made a simple "FrameInfo" structure for it straight away, but I was evidently a bit lazy. Maybe now would be the time? A FrameInfo object might have a few simple methods, such as a constructor which makes it out of the ControlList metadata, perhaps a method to give its string representation? Though that depends a bit on how we handle other things...

I did intend to add exactly such a class, but opted for the lazy approach instead... :)

If we're going to be passing around BufferMaps and their ControlList metadata together more of the time, should we pass them in a structure? I think there already is one - the RequestCompletePayload or something? - though it could have a less hideous name...

I think I will add a FrameInfo class that populates from the ControlList. This gets passed back though the RequestCompletePayload message. Does it need to be an explicit struct holding the two? Maybe a std::pair will suffice?

I'm a bit in several minds about whether we pass back the metadata ControlList (as we do now), but with some extra values in the RequestCompletePayload (like the framerate). Or whether we turn that entire ControlList into a FrameInfo and return only that in the RequestCompletePayload. The latter is perhaps tidier, though it means we have plumbing to do whenever there's a new libcamera control that we decide we want to pass through. Maybe that's ok?
I wonder then about passing the RequestCompletePayload around (though with a better name) - I think I'd rather have meaningfully named fields. But I appreciate this is all becoming a bigger change. I do vaguely foresee a future (possibly this summer already if we get some interns) where we have "post-processors" that want to add their own metadata (such as neural network results), and such a structure would then be a place to put this... But as you can see, I'm a bit all over the place with this. Help is appreciated!!

Now rebased on top of tree.

@davidplowman, feel free to review when you can :)

@davidplowman, all fixed applied.  I've reworked some of the intermediate patches as well for clarity.


Vertices of selected way need updated when zooming in from non-editable

To reproduce:

select anything with multiple nodes
zoom lower than 16 to magic the feature away
zoom back in and the nodes are still displayed

For v2, fixed in v3.

I dug into this a bit last night and posted on Slack, just copying here for posterity:
I see what’s going on
In vertices.js we cache _currSelected.  this gets updated sometimes - whenever drawSelected gets called.
From map.js we call this whenever something might have happened that affects the selection..
This kind of helps performance by not calling it all the time, like on every render.
The mode enter.map handler in map.js is a time when we do it, but it skips that step when the map is not editable.. so when you zoom out, it switches to browse mode, it jumps into that code, but then doesn’t actually update the vertices.
I'm not sure if there is a way to fix this in v2.15 that can easily be merged into the v3 branch (code has diverged a bit), but I will think about it.  It's pretty low priority as it only affects which vertices are drawn after zooming out and back in again.

Closing as unable to replicate in v2.20.4.


Running offline ITs fails in assembly artifact tests

The POM at /liberty-maven-plugin/src/it/tests/assembly-artifact-it/pom.xml
                <assemblyArtifact>
                    <groupId>${runtimeGroupId}</groupId>
                    <artifactId>${runtimeArtifactId}</artifactId>
                    <version>${runtimeVersion}</version>
                    <type>zip</type>
                </assemblyArtifact>

needs to be parameterized with these properties from the invoking env, and this won't be established in the offline IT profile.
I didn't save the message but it's not too hard to connect to this issue.

I see at:  /liberty-maven-plugin/src/it/tests/pom.xml there's already a profile attempting to limit certain tests to WLP.   Let me spend some more time looking..cancelling the PR.

So in regards to EBAs, yes we have use profiles to run tests specific to each runtime. However I think this issue should remain open, since it is true that certain tests (such as the arquillian-tests) are not compatible with offline mode. I am looking into addressing this. Also I'm thinking if we might need to add offline tests to Travis...

I looked into this a bit more.
It seems we could support something like this:
mvn  install -Poffline-its -DlibertyInstallDir=/my/wlp -Druntime=wlp -DruntimeVersion=<IP_ADDRESS>

if we propagate properties like the runtimeArtifactId , runtimeGroupId, etc. on to the invoker plugin execution for the offline profile, like in this commit,.
This would enable a test like the assembly-artifact-it one to pass.   (Though even smarter would be to detect the runtime and runtimeVersion dynamically somehow.. if that'd be worth doing).
One problem that would raise, though, is that the tests activated by -Druntime=wlp
        <modules>
            <module>assembly-it</module>
            <module>basic-it</module>
            <module>test-assembly-with-code-it</module>
        </modules>

all fail against <IP_ADDRESS>, for various, separate reasons.
Maybe this isn't shocking, as since there is no invoker propagation of the runtime property, there is no way to run these from the top-level POM today.
If this seems like a good solution, though, I suppose we could merge a commit like mine, and open separate issue(s) for the failures of these three modules (commenting them out in the meantime).
@chyt please let me know what you think.  Thanks.

Opened the following issues for the three modules mentioned above:
#386, #387, #388


Open dialog with tail on hover and remain open for interactive elements

Enhancement Request
Desired behavior
Flow would like to use an element, like an info icon, and on hover show something that looks like a tooltip/popover to the end user, so an area with content and a tail pointed at the element (info icon). We want the behavior to be as follows:

Hover element (or on focus for accessibility)
Be able to move mouse to the popover without it closing
Interact within it and it wouldn't close
Have option to close popover on click outside, scroll outside, or on hover outside of (tooltip+initial target area)

Within the popover, we want to have interactive elements.

Some designs include links to help docs. https://www.figma.com/file/maQpQ6lYgFBUP15tgu7Zgx/Hover-Tooltips-and-Menus?node-id=1612%3A12606
Some designs include buttons that link to other pages within the app. https://www.figma.com/file/maQpQ6lYgFBUP15tgu7Zgx/Hover-Tooltips-and-Menus?node-id=1612%3A12607
Some designs include a mini-carousel to scroll through a few images. https://www.figma.com/file/FD1QQUZWLmMeeVo2ksIjPH/Coaching-1-1-Experiences?node-id=1531%3A23323

We want to make sure these are accessible if someone is using a screen reader to do this, so the element can be activated on hover and on focus. Edward had some good ideas on how to do this.
We want to use and reuse this across the site, plug and play, as much as possible since we want to start implementing these in multiple places.
Today's behavior
Problems/friction you encounter.
The Value Add
Why this should be added/changed in the Design System. Where we could use it.
The Tradeoffs
What we give up or de-optimize to get it. The costs.

Let me know if you need any flow specific dev input on this!

@alexzywiak So turns out dialog will not work for what you want because of how it was coded to use FocusManager. I'm out the rest of today and tomorrow. Here is a very basic solution using Tooltip. https://codesandbox.io/s/blissful-lumiere-isvlr?file=/src/example.tsx
However positioning is rough here. I'd honestly recommend combing the example here using the JS examples from Position docs: https://design-system.pluralsight.com/components/position/#javascript-example
For reason I haven't track down yet the JSX position component is iffy with this implementation.
I can come back to this on Thursday.

No longer adding features to this project. Closing.


Disable WebChat

I want to disable WebChat channel because my bot doesn't support it and I don't want this channel communication to be reviewed.
The phrase "Your bot is enabled on this channel. Edit the channel to change this setting." is appeared when I push "Enabled - Yes" link, but there are no buttons for disabling the channel in the channel configuration menu

Hi @akakoychenko, if the Web Chat configuration page is empty (see screenshot), the channel is disabled.
Web Chat is only active when you add a "site" to your bot.

hi @akakoychenko, were you able to figure this out?

yep


RangeWidget: new design changes

Description
These changes come after having the first iteration testing the RangeWidget
Type of change
(choose one and remove the others)

Feature

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

4 of 6 (66.67%)  changed or added relevant lines in 1 file are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-0.05%) to 72.277%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

packages/react-ui/src/widgets/RangeWidgetUI.js
4
6
66.67%

Totals

Change from base Build<PHONE_NUMBER>:
-0.05%

Covered Lines:
1653

Relevant Lines:
2142

💛  - Coveralls


ProductService.Test error

i have two errors when run app-run.sh:
[xUnit.net 00:00:05.22]     ProductService.Test.Controllers.ProductsControllerTest.GetByCode_ReturnsJsonResult_WithOneProductOfCorrectType [FAIL]                      [xUnit.net 00:00:05.22]       System.InvalidOperationException : Eureka URL http://localhost:8761/eureka/ is not valid in containerized or cloud environments. Please configure Eureka:Client:ServiceUrl with a non-localhost address or add a service binding.
[xUnit.net 00:00:05.34]     ProductService.Test.Controllers.ProductsControllerTest.GetAll_ReturnsJsonResult_WithListOfProducts [FAIL]                                   [xUnit.net 00:00:05.34]       System.InvalidOperationException : Eureka URL http://localhost:8761/eureka/ is not valid in containerized or cloud environments. Please c onfigure Eureka:Client:ServiceUrl with a non-localhost address or add a service binding.

@wesleimp @witek1902
I also faced the same error when I tried to run ~/app-run.sh  script for the deployment of microservices mentioned in the redme.md file then it's falling with the below two errors :
Failed ProductService.Test.Controllers.ProductsControllerTest.GetByCode_ReturnsJsonResult_WithOneProductOfCorrectType [1 s]
  Error Message:
   System.InvalidOperationException : Eureka URL http://localhost:8761/eureka/ is not valid in containerized or cloud environments. Please configure Eureka:Client:ServiceUrl with a non-localhost address or add a service binding.

Failed ProductService.Test.Controllers.ProductsControllerTest.GetAll_ReturnsJsonResult_WithListOfProducts [50 ms]
  Error Message:
   System.InvalidOperationException : Eureka URL http://localhost:8761/eureka/ is not valid in containerized or cloud environments. Please configure Eureka:Client:ServiceUrl with a non-localhost address or add a service binding.

Test_result:
Total tests: 14
     Passed: 12
     Failed: 2
Test Run Failed.
 Total time: 3.8143 Seconds
     1>Done Building Project "/opt/app/ProductService.Test/ProductService.Test.csproj" (VSTest target(s)) -- FAILED.

can you please provide me with some pointers on the above issue?

I am currently working on upgrade to .net 7, I'll try to have a look at it. In the meantime, I would suggest running services without docker or trying to change localhost to something like host.docker.internal
Something changed when steeltoe was upgraded and it was not tested against dockerized version
Note that you should be able to run all required dependencies (dbs, mqs and stuff) with infra-run, and the start services manually.

After upgrade to net 7 I fixed docker file and testes it on my ubuntu 20. It works fine with infra-run and app-run scripts. When all services are up, you can go to localhost:8080 to see the web client app. Let me know if it works for you


🚀 Feature: Auto click Share after dragging & dropping file(s)

🔖 Feature description
Once I drag and drop files I don't want to click the "Share" button. I think it would be a real time saver if I could just have that automatically clicked AFTER the files are uploaded. It would even more sweet if I could just pre-config and autofill the modal popup variables too so I can bypass that automatically.
🎤 Pitch

Save time
I'm rarely ever going to upload a file, just to delete the file
Trying to stay true to "for seamless and efficient file sharing" motto.

Released in v0.18.0.


Need to advertise Raku's '%' operator is the the same as Perl POSIX's fmod

From the Style guide:
### Don't reference Perl unless in a 5-to-6 document or related document

We are not expecting our users to have to know Perl to learn Raku,
so this should not be part of the bulk of the documentation.


stream sceneform cameraview

I am trying to stream the camera feed of the sceneform using RTMP as there is no support for such .What is the way for achieving that?

Streaming the camera feed is possible using the surface mirroring functionality exposed through SceneView.  At a high level, streaming the camera feed would require:

Get an input Surface from an Android MediaCodec that will allow the rendered frames to be encoded as a video stream.
Mirror the SceneView to this Surface using SceneView.startMirroringToSurface
Run the MediaCodec encoder pipeline to produce encoded video packets that can be used in a video streaming protocol.  You may find more relevant information on working with MediaCodec for streaming video on Stack Overflow


fix: column width calc when hide set to true

Related Issue
as discussed in the old repo:
https://github.com/mbrn/material-table/issues/2654
Description
Fix a bug on the columns width calculation if calc is not provided (props hide: true)
Impacted Areas in Application
List general components of the application that this PR will affect:
\utils\common-value
Additional Notes
We are currently using the material-table-core v0.2.x and this fix is not yet there. So i found the pr from the original repo and bring it there
https://github.com/mbrn/material-table/pull/2655

@oze4 Can we create a release of this one from next branch?

@Domino987

Is there a way i can install material-table with with this patch in?

Of course, use either the latest next version or version 6.x


RNAseq validation: sample not accessible

Hi again,
I tried re-running the RNAseq validation a few times and got the same result:
WARNING: sample not found SRR950084

Which is odd because I seem to be able to find it while browsing through the FTP site.
I relaunched the pipeline a few times and it had to restart from the beginning every time instead of getting the missing files.
But regardless, i did not manage to download the missing sample.

I think I found the problem:

rnaseq-seqc-getdata.sh contains the following commands:

cd input
for SAMPLE in SRR950078 SRR950079 SRR950080 SRR950081 SRR950082 SRR950083
do
   wget -O ${SAMPLE}_1.fastq.gz ftp://ftp.sra.ebi.ac.uk/vol1/fastq/SRR950/${SAMPLE}/${SAMPLE}_1.fastq.gz
   wget -O ${SAMPLE}_2.fastq.gz ftp://ftp.sra.ebi.ac.uk/vol1/fastq/SRR950/${SAMPLE}/${SAMPLE}_2.fastq.gz
done

wget --no-check-certificate https://raw.githubusercontent.com/chapmanb/bcbio-nextgen/master/config/examples/seqc.csv

The last sample downloaded is SRR950083 while the last entry in "seqc.csv" is "SRR950084".
That file is then copied to the input folder with the problematic entry.
In the meantime, I will download missing sample files manually.

I modified rnaseq-seqc-getdata.sh to include missing samples and download FWD and REV reads in parallel to the following:
cd input
for SAMPLE in SRR950078 SRR950079 SRR950080 SRR950081 SRR950082 SRR950083 SRR950084
do
   wget -O ${SAMPLE}_1.fastq.gz ftp://ftp.sra.ebi.ac.uk/vol1/fastq/SRR950/${SAMPLE}/${SAMPLE}_1.fastq.gz 1>${SAMPLE}_1.out 2>${SAMPLE}_1.err &
   s1=$!
   wget -O ${SAMPLE}_2.fastq.gz ftp://ftp.sra.ebi.ac.uk/vol1/fastq/SRR950/${SAMPLE}/${SAMPLE}_2.fastq.gz 1>${SAMPLE}_2.out 2>${SAMPLE}_2.err &
   wait %% ${s1}
done

I now avoided a slew of error messages until the next issue which I am about to post


CB-12962 set-endpoint-access-gateway fails on existing Medium duty environment

When populating the instance metadata for the stack, include the metadata for all gateway instances
instead of only the primary gateway metadata. This will allow the set-endpoint-access-gateway
functionality to be run on stack with multiple gateway isstance, e.g. medium duty data lakes.
Tested by calling the set-endpoint-access-gateway API on a medium duty environment.

which API is "set-endpoint-access-gateway API"?

which API is "set-endpoint-access-gateway API"?

This is the EnvironmentEndpoint.updateEnvironmentLoadBalancersByName API.

and have you tested it locally (i guess yes)? I just want to make sure that the test covers this change, since it seems we need to allows cert generation in config (gateway.cert.generation.enabled)

and have you tested it locally (i guess yes)? I just want to make sure that the test covers this change, since it seems we need to allow cert generation in config (gateway.cert.generation.enabled)

Yep. I created a medium duty data lake in my local CB services, and then invoked that API using a curl call. My local dev setup is configured to use the mow-dev PEM service for DNS registration and to generated certs, so I did have "gateway.cert.generation.enabled" set to true and the path to renew the certs was hit.

and have you tested it locally (i guess yes)? I just want to make sure that the test covers this change, since it seems we need to allow cert generation in config (gateway.cert.generation.enabled)

Yep. I created a medium duty data lake in my local CB services, and then invoked that API using a curl call. My local dev setup is configured to use the mow-dev PEM service for DNS registration and to generated certs, so I did have "gateway.cert.generation.enabled" set to true and the path to renew the certs was hit.

cool, that's what I wanted to ask, if you used mow-dev PEM. in this case that test should cover the change

@hreeve-cloudera pls do not forget to create a merge PR to master or ask @pkedvessy to do that since he has a recent change committed into 2.44 too


idris-modules/curses.nix: delete

Deletes the idris package curses.
Motivation for this change
While I appreciated the effort by @brainrape and @Infinisil to add my curses bindings, the repository is currently unmaintained and cannot be guaranteed to work with the current Idris version, and especially not with future Idris versions (the reason I know this is because it's my repository).
Things done

As I understand it, most of these do not apply here since I removed a package rather than adding one or editing an existing one.

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

[ ] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[x] Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
[ ] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Assured whether relevant documentation is up to date
[x] Fits CONTRIBUTING.md.

Thanks!


Pw updates fix compiling

Merging into pw-updates since pw-updates has the needed fixes that are failing in the current build.


test(apps/prod/tekton/configs/triggers): fix trigger name length issue

Why: length must be no more than 63 characters for metadata.name
Signed-off-by: wuhuizuo<EMAIL_ADDRESS>

/approve


pull request for e2e test at 12/24/2016 12:56:11

:white_check_mark: Validation status: passed
For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.


How to unwrap pieces

Sorry, I am still a new Rust user. I realize it's a wrapper, but I can't seem to convert pieces to an Vec!!!
pieces: b"J\u{a0}\u{c3}\u{fb}\u{ce}q&\u{8c}N\u{fb}V\u{fe}L\u{b1}\u{f4}\"&\u{bc}YY&\u{c5}\u{f5}\u{90}\u{f8}\u{8d}\u{c5}`\u{90}]-,\u{1d}J\u{82}\u{db}9O\u{ae}\u{98}\u{c4}Sa\u{a1}\u{85}\u{8c}7\u{cf}\u{df}w\u{bb}qlH\u{fa}6\u{8f}6\u{5}\u{af}MB\u{89}\u{c7}i\u{94}\u{ee}\u{95}\u{b0}0+v\u{ca}\r\u{f2}\u{a3}Q\u{a1}\n\u{fc}\u{84}\u{ea}\u{c8}-?8>l\u{1b}\u{b9}\u{d5}\u{a0}\u{c1}\u{8b}\\\u{db}\u{c1}\u{b7})\u{af}\u{db}&_\u{87}\u{a7}\u{f6}\u{4}y\u{16}\u{c3}\u{2}\u{98}G\u{9c}\u{ae}\u{3}\u{c9}\u{dc}\u{ec}\u{cb}\u{fa}(W\u{f4}\u{fb}\u{eb}M>\u{9d}}\u{84}~K\u{94}\u{c6}\u{b4}\u{18}\u{f4}\u{fa}\u{83}"

This is my current self.info.pieces

let v: Vec<u8> = self.info.pieces.into();

I filed #3 to make this more discoverable.

OOOOHHH! I saw that function name, but i didn't realize that is what it did. Thank you so much!


Suffices terminst advice

#42

Passing all tests, and I added two more where advice should / shouldn't be given. It might be worth taking some time to brainstorm more situations when this could arise, though as arguments of calls is certainly the most common.

Wait to merge this, there might be a problem with the operator fix :
suffices to prove:
        a + sum(d) = + a

Also the lalr parser doesn't like this :)
theorem foldr_eq_sum : all ls : List. sum(ls) = foldr(ls, 0, operator +)

It's the paren after operator+

Closing since https://github.com/jsiek/deduce/commit/0e88ca917e471eadf085805b71f9de83a0d760d7 appears to fix

Interesting. You're solution is a more specific that what I just pushed, which could make it less verbose, which is good, but the question is whether Call is the only problematic context...

I suspect that there are more contexts that could be problematic... any place in synthesis mode.

So the really good solution would be to augment the substitute method to know about check/synthesis and only set inferred = False when substituting in a synthesis context. But that's a bunch more work. I'll make an issue for that.

Hmm, actually, it's not as simple as recognizing synthesis mode because of generic functions.

I think perhaps the fix I just pushed is good because it is conservative and not that complicated. To do better seems to require a much more complex solution.


stdenv/generic: introduce shellDryRun

Add shellDryRun to the generic stdenv and substitute it for uses of ${stdenv.shell} -n. The point of this layer of abstraction is to add the flag -O extglob, which resolves #126344 in a more direct way.

Things done

Built on platform(s)

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

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[x] Tested, as applicable:

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

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

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module
[ ] (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes

[x] Fits CONTRIBUTING.md.

@ofborg build tests.trivial-builders.overriding

I really like the naming changes.
I've tried to look for reasons to not have extglob enabled but couldn't find any. I think the only downside is that people might not know about it. Perhaps we should just add something in the release notes ? (no worries if you think it's not worth it).
One other thing that jumped to mind is that probably failglob should be enabled as well. I understand that this would be breaking behavior so not for this PR, just a thought that came to mind.
So all in all, looks good to me.
Thank you for this!

I've tried to look for reasons to not have extglob enabled but couldn't find any. I think the only downside is that people might not know about it. Perhaps we should just add something in the release notes ? (no worries if you think it's not worth it).

The reason you might want extglob disabled in general is if you plan to run arbitrary sh scripts that might use extglob syntax without expecting it to glob. This is not the case at all for writeShellScript, where the scripts are statically known and can just be written as bash.
I don't think it's worth mentioning, but I won't stop people from writing release notes.

One other thing that jumped to mind is that probably failglob should be enabled as well. I understand that this would be breaking behavior so not for this PR, just a thought that came to mind.

Do you mean enabled at runtime (since it wouldn't make a difference at check time)? If so, definitely not in writeShellScript (I think we want to keep these functions as agnostic as possible to the kind of shell script they accept), but maybe in the default builder or something?
I don't know if failglob is that useful in practice, given that most globs are passed to commands and most commands fail on non-existent files.

So all in all, looks good to me.
Thank you for this!

Thanks for the review!

I didn't think about the checktime vs runtime difference for failglob, it might not be that useful.
Regarding failglob discussion. I'm trying to enable failglob for stdenv, and there are 22 failures spotted so far, and possibly quite a bit left https://github.com/NixOS/nixpkgs/pull/142860 . Hopefully this is in by default sometimes in the future.

I don't think it's worth delaying this anymore, let me know if you had intended to add something else.

This is ready. The darwin failures are unrelated, let's try restarting the build
@ofborg build tests.trivial-builders.overriding

Oh well.

It looks like a time-out. I think it's fine to merge. Let's just keep an eye on the staging-next branch

Thanks!


Custom modules and Yield/Wait support, for embedding in Tasmota ESP32

First let me say that Berry is fantastic. I'm considering using Berry as a scripting language for Tasmota (https://github.com/arendst/Tasmota) running on ESP32. It's compact enough, powerful and easy to embed in existing code.
ESP8266 is too short in memory, but ESP32 makes a perfect target for the Berry language. I did a quick & dirty embeddeding Berry in Tasmota with no issue and it compiles fine. The documentation is very clear and easy to follow. Calling Berry functions from Tasmota, and the reverse works fine.
Now here are my questions:

Native modules: I tried to register native module used by import at runtime but I have the feeling that it's currently not supported except for the pre-included libraries. Do you plan to allow custom libs?

Yield/Wait: it would be fantastic to be able to yield() from within Berry code to give back control to the host code, and resume execution later. I understand that it's probably not straightforward, but this would make a great way to do async-style code that would not block the host code.

Thinking deeper into yield/wait, I believe it could be implemented using closures and sending back an array with first element being the number of ms to wait for, and the second the continuation function.
Ideally the code would look like:
def test()
  print('before')
  print('before2')

  yield            # of wait(0)

  print('after')
  print('after2')

end

And it would be actually compiled as:
def test()
  print('before')
  print('before2')

  return [0, def()  # added

  print('after')
  print('after2')

  end ]             # added

end

Example using REPL:
> cont = test()
before
before2
> cont
[0, <function: 0x7ffb90605350>]
> cont[1]()
after
after2
>

Scratch that. This is over-simplistic and wouldn't work for recursion and loops.
Looking at vm_exec(), maybe it would imply adding a new opcode in the bytecode, to exit vm_exec() and freeze the vm state so that it can be continued later.

For native modules, you can refer to be_timelib.c and be_modtab.c. You need to provide be_modtab.c in your project.
Berry supports native module instances generated during compilation (special comments are processed by the coc tool to generate code). E.g:
/* @const_object_info_begin
module time (scope: global, depend: BE_USE_TIME_MODULE) {
    time, func(m_time)
    dump, func(m_dump)
    clock, func(m_clock)
}
@const_object_info_end */

You can check the operation of coc in the Makefile.

Thanks for you response. I think I found a way to implement yield/wait outside of Berry using setjmp/longjmp.
More concretely, I allocate a separate stack for the berry vm when calling be_pcall(), then I used crossed setjmp/longjmp to switch between the host code and the berry code. I did a quick and dirty proof of concept and it works fine on ESP8266.

It's a little tricky from the caller side, but tweaking jmp_buf structure allows me to change the stack pointer without requiring assembly code (although the location of the stack is processor dependent). From Berry side, I simply need to add yield and wait native function, and it works with the vm as-is.

I have heard of coroutines implemented using setjmp/longjmp. For this, you have to be very careful to ensure the validity of setjmp/longjmp.

Agreed. But it looks like it's working fine. Setting the new stack is CPU dependent since it requires to change the jmp_buf opaque structure, and the change of stack requires the communication between both threads to go through global variables. That's not pretty, but I didn't find any easy way around this (yet).

FYI I will finally not go that route. I have added a timer system and it's simpler to just set a timer to trigger a closure in the future.


[SPARK-26266][BUILD] Update to Scala 2.12.8 (branch-2.4)

What changes were proposed in this pull request?
Back-port of https://github.com/apache/spark/pull/23218 ; updates Scala 2.12 build to 2.12.8
How was this patch tested?
Existing tests.

Test build #99871 has started for PR 23264 at commit 4427e9f.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/testing-k8s-prb-make-spark-distribution-unified/5888/
Test PASSed.

Test build #99871 has finished for PR 23264 at commit 4427e9f.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/99871/
Test PASSed.

Merged to branch-2.4.

This is merged now. Please close the PR, @srowen . :)


Async validations

Closes #1.

Have a look at this, @prochazkafilip. Me and @dknvmlhok are experimenting with async validation in FormStateKit. I think it might interest you since you pointed up this issue.

Have a look at this, @prochazkafilip. Me and @dknvmlhok are experimenting with async validation in FormStateKit. I think it might interest you since you pointed up this issue.

Good job, it looks cool 👌. The only one think I'm thinking about is a way of async validations execution. You execute it sequentially, but I'm not sure if parallel way wouldn't be better in some cases 🤔.

Have a look at this, @prochazkafilip. Me and @dknvmlhok are experimenting with async validation in FormStateKit. I think it might interest you since you pointed up this issue.

Good job, it looks cool 👌. The only one think I'm thinking about is a way of async validations execution. You execute it sequentially, but I'm not sure if parallel way wouldn't be better in some cases 🤔.

That's why I'm gonna make an example app where we can try some of these edgecases 😉

Closing this due to inactivity.


Rework C++ examples

Hello!
It would be interesting hear your opinion about this PR.

What are you think about this PR now?

Hi!
I fixed bugs and add new library.


Issue when reading svo file Jetson Nano

Hello !
I have an issue when I try to playback a SVO file recorded on Jetson Nano. In fact my code run well on my Desktop but on my jetson nano with JetPack 4.4, the while loop reading each frame of the svo is infinite because the error ERROR_CODE.END_OF_SVOFILE_REACHED is never returned by zed.grab() with the same svo file of 10 frames.
When I print the read frame position with get_svo_position(), results are very strange like : 1 then 2 then 0 then 1 then 3 then... that doesn't happen on my Linux Desktop.
        input_type = sl.InputType()
        input_type.set_from_svo_file(input_path)

        init_params = sl.InitParameters(input_t=input_type)

        init_params.camera_resolution = self.init_params.camera_resolution
        init_params.camera_fps = self.init_params.camera_fps
        init_params.depth_mode = self.init_params.depth_mode
        init_params.coordinate_units = self.init_params.coordinate_units

        err = self.zed.open(init_params)
        if err != sl.ERROR_CODE.SUCCESS:
            raise Exception(err)

        print(self.zed.get_svo_number_of_frames()) # return 10
        while err != sl.ERROR_CODE.END_OF_SVOFILE_REACHED:
            err = self.zed.grab()
            print(err)
            if err == sl.ERROR_CODE.SUCCESS:
                self.zed.retrieve_image(image, sl.VIEW.LEFT)

I've already reinstalled the ZED SDK 3.3.3 and updated the zed python api.
Thanks for you help !

Is there any solution for this problem?


Trust editor: both options are color coded with red

Refs: https://github.com/microsoft/vscode/issues/122228
Open trust editor:
Both trusted and untrusted are color coded red.
I suggest to use the same color coding as in the dialog:
Blue for Trusted and gray for Untrusted (disabled).
Both the outline and the icon on top
fyi @misolori

At the moment the workspace trust editor is using the accent colour to highlight the selected option.
I suspect that you are using the "GitHub Sharp" light theme which uses #d64926 as the accent colour.

Yes I am using the GitHub Sharp, you are correct. However I still think these two should be different colors, and the icon on top should be different colors based on that.

hmm, the button color suggestion seems reasonable except I am worried that this will be difficult to tell which is selected in the disabled case as the unselected border is already grey

@sbatten maybe we could increase the border width for selected and use a stronger grey
fyi @misolori

I tried using the grey for untrusted (the standard secondary color), but it was too muted even with some thicker border, instead I have used the 2 colors suggested but the selected option gets the primary color while the unselected option gets the secondary grey.
https://github.com/microsoft/vscode/commit/6673ba9c46481a933fa730d40e2b77455af20714


fixes to MARINe rocky intertidal data plots

From Jenn Brown:
I spoke to Pete Raimondi and he agrees that we should:

create a mussel time series that first filters by target_assemblage = mytilus and then uses lumping_code = MYTCAL. This can be a different tab in the Mussel modal window
create barnacle time series that filters by target_assemblage = balanus and then uses lumping_code = CHTBAL. This can be a different tab in the barnacle modal window

We have received feedback on the graph layout in the interactive graphs, here are the suggested improvements:

X-axis needs to have more years labeled and the axis title 'Year' should be located under the axis labels instead  of under the slider graph
it is unclear to people what the slider graph under the x-axis is showing. We should either remove it or it needs some sort of label
when you zoom in on the x-axis, the label goes to yearly but says 'Jan 2014' for example. Can we remove the 'Jan' so it only gives the 4 digit year?
color of trend lines - I would prefer a thicker black or red line for the overall sanctuary mean and thinner brightly colored lines for the site//island/region means.
OCNMS map and graph legend: currently the legend has the site names listed in alphabetical order. I would prefer if they were listed from north to south. Is that possible?
legend blocks some of the data points on the barnacle graph.

Here's a visual of the fixes:
OLD plot

NEW plot:

Let's review what did and did not get fixed:

[X] 1) create a mussel time series that first filters by target_assemblage = mytilus and then uses lumping_code = MYTCAL. This can be a different tab in the Mussel modal window
[X] 2) create barnacle time series that filters by target_assemblage = balanus and then uses lumping_code = CHTBAL. This can be a different tab in the barnacle modal window

Note that we're using target_assemblage inclusive of both chthamalus_balanus (CINMS) and balanus (OCNMS), both of which are present in MBNMS

We have received feedback on the graph layout in the interactive graphs, here are the suggested improvements:

[X] 1) X-axis needs to have more years labeled and the axis title 'Year' should be located under the axis labels instead  of under the slider graph
[ ] 2) it is unclear to people what the slider graph under the x-axis is showing. We should either remove it or it needs some sort of label

Relabeled x axis label from Date to Year. The handles on either end allow you to zoom into a narrow date window. Should I relabel to "Year (slide to zoom)" ?

[X] 3) when you zoom in on the x-axis, the label goes to yearly but says 'Jan 2014' for example. Can we remove the 'Jan' so it only gives the 4 digit year?
[X] 4) color of trend lines - I would prefer a thicker black or red line for the overall sanctuary mean and thinner brightly colored lines for the site//island/region means.
[ ] 5) OCNMS map and graph legend: currently the legend has the site names listed in alphabetical order. I would prefer if they were listed from north to south. Is that possible?

Possible, but do you propose doing that for CINMS which goes more East to West ?

[X] 6) legend blocks some of the data points on the barnacle graph.

Seems improved in the updated version.

I also fixed the "NA: Island" to just "Island".

Applies to CINMS:

Algal groups
Barnacles
Mussels

Here's the breakdown of Acorn Barnacle target_assemblage (ie sp_target) by sanctuary:

sp
sp_name
sp_target
cinms
mbnms
ocnms

CHTBAL
Chthamalus spp/Balanus glandula
balanus

488
345

CHTBAL
Chthamalus spp/Balanus glandula
chthamalus_balanus
2423
1715

For OCNMS, ANY includes all spp_targets:

sp
sp_name
sp_target
ocnms

CHTBAL
Chthamalus spp/Balanus glandula
balanus
345

CHTBAL
Chthamalus spp/Balanus glandula
mytilus
344

CHTBAL
Chthamalus spp/Balanus glandula
pelvetiopsis
60