fix: Delete forks after proving job has finished

Adds a delete method to the db, which is called in a cleanup handler of the proving job once it finishes. This is needed so we don't pile up forks of the db as we keep proving blocks.

Benchmark results
Metrics with a significant change:

protocol_circuit_simulation_time_in_ms (private-kernel-tail-to-public): 779 (-48%)
avm_simulation_time_ms (Token:mint_public): 42.1 (-33%)
avm_simulation_time_ms (Token:assert_minter_and_mint): 67.6 (+68%)

Detailed results
All benchmarks are run on txs on the Benchmarking contract on the repository. Each tx consists of a batch call  to create_note and increment_balance, which guarantees that each tx has a private call, a nested private call, a public call, and a nested public call, as well as an emitted private note, an unencrypted log, and public storage read and write.
This benchmark source data is available in JSON format on S3 here.
Proof generation
Each column represents the number of threads used in proof generation.

Metric
1 threads
4 threads
16 threads
32 threads
64 threads

proof_construction_time_sha256_ms
5,775
1,579 (+2%)
709 (+1%)
754 (+1%)
769 (+1%)

proof_construction_time_sha256_30_ms
11,908
3,185
1,418
1,467 (+2%)
1,478

proof_construction_time_sha256_100_ms
45,323
12,053
5,568 (+3%)
5,495 (+1%)
5,449 (+1%)

proof_construction_time_poseidon_hash_ms
78.0
34.0
34.0
59.0 (+2%)
89.0

proof_construction_time_poseidon_hash_30_ms
1,528
421
204 (+1%)
234 (+1%)
268 (-1%)

proof_construction_time_poseidon_hash_100_ms
5,650
1,515
677 (-1%)
726
746 (+1%)

L2 block published to L1
Each column represents the number of txs on an L2 block published to L1.

Metric
4 txs
8 txs
16 txs

l1_rollup_calldata_size_in_bytes
4,324
7,844
14,852

l1_rollup_calldata_gas
49,732
92,508
177,500

l1_rollup_execution_gas
1,294,395
2,042,139
3,869,170

l2_block_processing_time_in_ms
247 (-7%)
444
813

l2_block_building_time_in_ms
9,276
18,162
36,172

l2_block_rollup_simulation_time_in_ms
9,275
18,162
36,171

l2_block_public_tx_process_time_in_ms
7,828
16,613
34,569

L2 chain processing
Each column represents the number of blocks on the L2 chain where each block has 8 txs.

Metric
3 blocks
5 blocks

node_history_sync_time_in_ms
2,963
3,821

node_database_size_in_bytes
12,709,968
16,781,392 (-1%)

pxe_database_size_in_bytes
16,254
26,813

Circuits stats
Stats on running time and I/O sizes collected for every kernel circuit run across all benchmarks.

Circuit
simulation_time_in_ms
witness_generation_time_in_ms
input_size_in_bytes
output_size_in_bytes
proving_time_in_ms

private-kernel-init
101
393 (-1%)
21,846
44,858
N/A

private-kernel-inner
176 (+4%)
701 (-1%)
72,545
45,005
N/A

private-kernel-reset-tiny
509
1,194
69,614
44,844
N/A

private-kernel-tail
272 (+1%)
194 (-1%)
50,760
52,256
N/A

base-parity
5.59 (+2%)
N/A
160
96.0
N/A

root-parity
33.3 (+1%)
N/A
69,084
96.0
N/A

base-rollup
2,875 (+1%)
N/A
187,817
664
N/A

root-rollup
38.6
N/A
54,525
716
N/A

public-kernel-setup
99.7
N/A
103,760
71,222
N/A

public-kernel-app-logic
106
N/A
103,599
71,222
N/A

public-kernel-tail
568
N/A
409,190
16,414
N/A

private-kernel-reset-small
485
N/A
66,533
45,629
N/A

private-kernel-tail-to-public
:warning: 779 (-48%)
712
507,554
1,697
N/A

public-kernel-teardown
94.3 (+1%)
N/A
104,005
71,222
N/A

merge-rollup
19.1
N/A
35,742
664
N/A

undefined
N/A
N/A
N/A
N/A
67,549

Stats on running time collected for app circuits

Function
input_size_in_bytes
output_size_in_bytes
witness_generation_time_in_ms

ContractClassRegisterer:register
1,344
11,731
343 (-1%)

ContractInstanceDeployer:deploy
1,408
11,731
18.1

MultiCallEntrypoint:entrypoint
1,920
11,731
458

FeeJuice:deploy
1,376
11,731
387

SchnorrAccount:constructor
1,312
11,731
169 (-1%)

SchnorrAccount:entrypoint
2,304
11,731
505

Token:privately_mint_private_note
1,280
11,731
222 (+3%)

FPC:fee_entrypoint_public
1,344
11,731
21.1 (-14%)

Token:transfer
1,312
11,731
408

Benchmarking:create_note
1,344
11,731
164 (-1%)

SchnorrAccount:verify_private_authwit
1,280
11,731
27.7

Token:unshield
1,376
11,731
637 (+1%)

FPC:fee_entrypoint_private
1,376
11,731
853

AVM Simulation
Time to simulate various public functions in the AVM.

Function
time_ms
bytecode_size_in_bytes

FeeJuice:_increase_public_balance
54.5 (+2%)
8,139

FeeJuice:set_portal
9.40 (-7%)
2,362

Token:constructor
86.0 (+1%)
31,107

FPC:constructor
52.2 (-4%)
22,380

FeeJuice:mint_public
38.8 (+1%)
6,150

Token:mint_public
:warning: 42.1 (-33%)
11,720

Token:assert_minter_and_mint
:warning: 67.6 (+68%)
8,028

AuthRegistry:set_authorized
46.6 (+23%)
4,537

FPC:prepare_fee
228 (-4%)
8,812

Token:transfer_public
22.1 (+6%)
47,374

FPC:pay_refund
59.3 (+5%)
12,114

Benchmarking:increment_balance
970
7,450

Token:_increase_public_balance
41.8 (-2%)
8,960

FPC:pay_refund_with_shielded_rebate
70.8
12,663

Public DB Access
Time to access various public DBs.

Function
time_ms

get-nullifier-index
0.164

Tree insertion stats
The duration to insert a fixed batch of leaves into each tree type.

Metric
1 leaves
16 leaves
64 leaves
128 leaves
256 leaves
512 leaves
1024 leaves

batch_insert_into_append_only_tree_16_depth_ms
2.15 (-1%)
3.85 (-4%)
N/A
N/A
N/A
N/A
N/A

batch_insert_into_append_only_tree_16_depth_hash_count
16.8
31.7
N/A
N/A
N/A
N/A
N/A

batch_insert_into_append_only_tree_16_depth_hash_ms
0.111 (-1%)
0.108 (-4%)
N/A
N/A
N/A
N/A
N/A

batch_insert_into_append_only_tree_32_depth_ms
N/A
N/A
11.4 (-1%)
17.5
31.6 (+3%)
57.9 (-2%)
113 (+1%)

batch_insert_into_append_only_tree_32_depth_hash_count
N/A
N/A
95.9
159
287
543
1,055

batch_insert_into_append_only_tree_32_depth_hash_ms
N/A
N/A
0.109 (-1%)
0.101
0.102 (+2%)
0.0996 (-2%)
0.101

batch_insert_into_indexed_tree_20_depth_ms
N/A
N/A
14.2 (-3%)
25.3 (-1%)
44.2 (+2%)
81.4 (-2%)
160 (+1%)

batch_insert_into_indexed_tree_20_depth_hash_count
N/A
N/A
109
207
355
691
1,363

batch_insert_into_indexed_tree_20_depth_hash_ms
N/A
N/A
0.108 (-3%)
0.102 (-1%)
0.107 (+2%)
0.100 (-2%)
0.101

batch_insert_into_indexed_tree_40_depth_ms
N/A
N/A
16.1 (-1%)
N/A
N/A
N/A
N/A

batch_insert_into_indexed_tree_40_depth_hash_count
N/A
N/A
132
N/A
N/A
N/A
N/A

batch_insert_into_indexed_tree_40_depth_hash_ms
N/A
N/A
0.103 (-2%)
N/A
N/A
N/A
N/A

Miscellaneous
Transaction sizes based on how many contract classes are registered in the tx.

Metric
0 registered classes
1 registered classes

tx_size_in_bytes
64,779
668,997

Transaction size based on fee payment method
| Metric |  |
| - |  |


#37 Added callback adapter for the  React TextAnnotator

Issue
This PR resolves the #37 issue and makes it possible to provide the W3CFormat adapter into the TextAnnotator component
Changes Made
I implemented the 2nd approach suggested in the #37. It allowed having a simple component's API on the consumer side and not dealing with the undefined container element manually.

Thanks, I'll merge this!
I've been thinking about this myself. Although I hadn't thought as far as the React wrapper yet (so - thanks for this!) I was wondering whether we could somehow reorganize things, simply to make the API look nicer. I.e. get from the current...
var r = createTextAnnotator(contentContainer, {
  adapter: W3CTextFormat('https://www.gutenberg.org', contentContainer)
});

...to something like this again:
var r = createTextAnnotator(contentContainer, {
  adapter: W3CTextFormat('https://www.gutenberg.org')
});

I guess, with your current PR, we're almost there. W3CTextFormat('...')  could itself return a function(container). In this case, we'd get the same behavior in React and a leaner API in vanilla JS. (Not sure how that would play with callback and re-rendering in React tho?)

W3CTextFormat('...') could itself return a function(container). In this case, we'd get the same behavior in React and a leaner API in vanilla JS.

That's an interesting suggestion 👍🏻
I may get back on this in some time when I'll finish with project-specific work


add test cases for collateral rebalancing pool

closes #183

Overall the flow makes sense and I can work on adding error cases and fee charging.
You can also try testing by using 2 entities (eg. deployer and wallet_1), at the beginning deployer can send certain amount of balance to wallet_1 then conduct on test cases.
I also think it might be better if we can breakdown the testcase, but still this must be good if you have already checked the values manually.


Changed the documentation to reflect that work should be on master.

The dev branch is not as up to date as the master branch, so
I made the change to remove the dev branch identifier in the
instructions on how to clone the repo. Now, the contributor
will know to download and work off of the master branch.

I signed it!

I signed it!

LGTM, What do you think @tedsta @hildrum ?

LGTM


Google+ shutdown will break OAuth provider

The Authentication.Google package implements OAuth2 with Google services. However, it uses Google+ to fetch additional user information.
https://github.com/aspnet/AspNetCore/blob/5ab3c89be3e6342f2a39c666fd0aca708fc7ec8b/src/Security/Authentication/Google/src/GoogleDefaults.cs#L21
https://github.com/aspnet/AspNetCore/blob/5ab3c89be3e6342f2a39c666fd0aca708fc7ec8b/src/Security/Authentication/Google/src/GoogleOptions.cs#L29-L34
"The Google+ Sign-in feature is fully deprecated and is being shut down on March 7, 2019. This will be a progressive shutdown, with intermittent failures starting as early as January 28, 2019. Developers should migrate to the more comprehensive Google Sign-in authentication system." ~https://developers.google.com/+/web/signin/
This is a patch candidate all the way down to 1.0 and Katana. @muratg @blowdart
Proposals:

Find a new API that will give us basic information like name, e-mail, etc.. It's unlikely the transition would be seamless.
Deprecate the provider and show people how to use OpenIdConnect. This has the benefit of being a docs only change. It may not work for Katana though, we'll have to see if it supported enough ODIC features.

Pardon my ignorance on the subject.... but where do I find this call in an asp.net web api project? I'm only using token validation.
I know I'm using it somewhere, according to google I'm sending calls to plus.people.get
I do have reference to Microsoft.Owin.Security.Google

If you're using ASP.Net Core 2.2, you might have the following code in your Startup.cs file which makes use of the OAuth provider (taken from https://docs.microsoft.com/en-us/aspnet/core/security/authentication/social/google-logins?view=aspnetcore-2.2):
services.AddAuthentication().AddGoogle(googleOptions =>             {                 googleOptions.ClientId = Configuration["Authentication:Google:ClientId"];                 googleOptions.ClientSecret = Configuration["Authentication:Google:ClientSecret"];             });
I'm currently using this and am affected by this issue.

Definitely a breaking change on my site... I hope it's as simple as just updating Microsoft.Owin.Security.Google NuGet pkg when they are able to update it.

Yup this will break our stuff.
Google has really screwed us up by pushing the date to end of march.
I tried changing the endpoints to the endpoints given back by the well-known configuration:
https://accounts.google.com/.well-known/openid-configuration
The current code works until it tries to retrieve the userinfo.
The response is not the same format as the response given by google+ apis.
For users like us, we do not really need to poke the userinfo endpoint, the id_token already contains information about the user. I guess in some cases it may be easier to poke the user endpoint than to actually verify the id_token.
I hope there is an answer soon from the owners of the project, Google has threaten to start failing requests as early as January 28,2019.

cc @DamianEdwards @Eilon @davidfowl FYI.

I confirmed that manually disabling the Google+ API in their developer console does indeed break the process. I tried enabling their People API hoping they may do some magic on their side to redirect the request but no luck there. According to their documentation, the People API allows for the profile, email, and some other related profile scopes:  https://developers.google.com/people/v1/how-tos/authorizing#OAuth2Authorizing

Workaround, all the user info has changed format so you need to remap everything:
    .AddGoogle(o =>
            {
                o.ClientId = Configuration["google:clientid"];
                o.ClientSecret = Configuration["google:clientsecret"];
                o.UserInformationEndpoint = "https://openidconnect.googleapis.com/v1/userinfo";
                o.ClaimActions.Clear();
                o.ClaimActions.MapJsonKey(ClaimTypes.Name, "name");
                o.ClaimActions.MapJsonKey(ClaimTypes.GivenName, "given_Name");
                o.ClaimActions.MapJsonKey(ClaimTypes.Surname, "family_Name");
                o.ClaimActions.MapJsonKey("urn:google:profile", "profile");
                o.ClaimActions.MapJsonKey(ClaimTypes.Email, "email");
                o.ClaimActions.MapJsonKey("urn:google:image", "picture");
            })

This should work with ASP.NET Core 2.0 and later.
Does anybody here have interest in 1.0 or 1.1?
I'll follow up on the the Microsoft.Owin components.

Workaround, all the user info has changed format so you need to remap everything:

This does not work.
"Error loading external login information. "

Can confirm: I get the same error on my end. Using ASP.NET Core 2.1.

@HaoK is Identity looking for the NameIdentifier claim? I wonder if sub is the same as the old Id claim.
What if you add:
o.ClaimActions.MapJsonKey(ClaimTypes.NameIdentifier, "sub");

@HaoK is Identity looking for the NameIdentifier claim? I wonder if sub is the same as the old Id claim.
What if you add:
o.ClaimActions.MapJsonKey(ClaimTypes.NameIdentifier, "sub");
Ah, yes, there it is. https://github.com/aspnet/Identity/blob/fcc02103aa10dcdd8759e0463cac2717114f3c1e/src/Identity/SignInManager.cs#L611

Adding o.ClaimActions.MapJsonKey(ClaimTypes.NameIdentifier, "sub"); did the trick! Login is working now.

Did it recognize you as the same user, or as a new user?

Same user. I used two different accounts and both logged in correctly.

Yeah we use the Name identifier to use as the key to associate logins in identity, and the email which we use as the user name

Updates for Microsoft.Owin.Security.Google are being tracked at https://github.com/aspnet/AspNetKatana/issues/251. I've posted a temporary workaround there.

@dwdickens the Microsoft.Owin example I posted here should easily adapt for Asp.Net Core 1.1. Let me know if it gives you any trouble.

the Microsoft.Owin example I posted here should easily adapt for Asp.Net Core 1.0 and 1.1. Let me know if it gives you any trouble.

I can confirm it works in .Net 4.5.2 if you update Microsoft.Owin.Security.Google to version 4.0.0

Workaround, all the user info has changed format so you need to remap everything:
    .AddGoogle(o =>
            {
                o.ClientId = Configuration["google:clientid"];
                o.ClientSecret = Configuration["google:clientsecret"];
                o.UserInformationEndpoint = "https://openidconnect.googleapis.com/v1/userinfo";
                o.ClaimActions.Clear();
                o.ClaimActions.MapJsonKey(ClaimTypes.NameIdentifier, "sub");
                o.ClaimActions.MapJsonKey(ClaimTypes.Name, "name");
                o.ClaimActions.MapJsonKey(ClaimTypes.GivenName, "given_Name");
                o.ClaimActions.MapJsonKey(ClaimTypes.Surname, "family_Name");
                o.ClaimActions.MapJsonKey("urn:google:profile", "profile");
                o.ClaimActions.MapJsonKey(ClaimTypes.Email, "email");
                o.ClaimActions.MapJsonKey("urn:google:image", "picture");
            })

This should work with ASP.NET Core 2.0 and later.
Does anybody here have interest in 1.0 or 1.1?
I'll follow up on the the Microsoft.Owin components.

This worked great. Just an FYI that given_name and family_name should be all lowercase otherwise it won't pull that information correctly. Thanks.

@earllocker I updated the sample, thanks.

That error doesn't seem directly related. It may be a secondary error. Turn on you application logs to see if there's anything else. Also capture a fiddler trace file.

I modified my code to use the endpoints provided by https://accounts.google.com/.well-known/openid-configuration but hit a problem where the response from the user information endpoint wasn't deserialising. I modified my user information endpoint to https://www.googleapis.com/oauth2/v2/userinfo which seems to be compatible with the old mappings. I have also taken out the profile scope for my implementation.
Shouldn't this library get it's configuration from https://accounts.google.com/.well-known/openid-configuration in the future?
authenticationBuilder.AddGoogle(options =>
{
options.ClientId = Configuration["auth:google:clientid"];
options.ClientSecret = Configuration["auth:google:clientsecret"];
options.AuthorizationEndpoint = "https://accounts.google.com/o/oauth2/v2/auth";
options.TokenEndpoint = "https://oauth2.googleapis.com/token";
options.UserInformationEndpoint = "https://www.googleapis.com/oauth2/v2/userinfo";

options.Scope.Clear();
options.Scope.Add("openid");
options.Scope.Add("email");

options.ClaimActions.Clear();
options.ClaimActions.MapJsonKey(ClaimTypes.NameIdentifier, "id");
options.ClaimActions.MapCustomJson(ClaimTypes.Email, GoogleHelper.GetEmail);

});

I modified my code to use the endpoints provided by https://accounts.google.com/.well-known/openid-configuration but hit a problem where the response from the user information endpoint wasn't deserialising. I modified my user information endpoint to https://www.googleapis.com/oauth2/v2/userinfo which seems to be compatible with the old mappings. I have also taken out the profile scope for my implementation.
Shouldn't this library get it's configuration from https://accounts.google.com/.well-known/openid-configuration in the future?
authenticationBuilder.AddGoogle(options =>
{
options.ClientId = Configuration["auth:google:clientid"];
options.ClientSecret = Configuration["auth:google:clientsecret"];
options.AuthorizationEndpoint = "https://accounts.google.com/o/oauth2/v2/auth";
options.TokenEndpoint = "https://oauth2.googleapis.com/token";
options.UserInformationEndpoint = "https://www.googleapis.com/oauth2/v2/userinfo";

options.Scope.Clear();
options.Scope.Add("openid");
options.Scope.Add("email");

options.ClaimActions.Clear();
options.ClaimActions.MapJsonKey(ClaimTypes.NameIdentifier, "id");
options.ClaimActions.MapCustomJson(ClaimTypes.Email, GoogleHelper.GetEmail);

});

That error doesn't seem directly related. It may be a secondary error. Turn on you application logs to see if there's anything else. Also capture a fiddler trace file.

There is no secondary error. Also, don't have Fiddler in the pipeline so can't really make logs with that.
Generally speaking though, I find that External Login errors seem very hard to debug since the errors are very generic. "Correlation failed" and "The oauth state was missing or invalid." aren't really actionable. A more detailed logging setup built into the pipeline would make things much easier...

@kanadaj agreed, though the trouble with those situations is that the error usually occurs on the client or IDP, the server doesn't know why it happened.

@alanleouk the .well-known endpoint is for OpenIdConnect, not OAuth2 (though the two are related). There is a proposal to replace this library with the existing OpenIdConnect implementation in a future release.

Using OpenID Connect is a good alternative anyway. It's just as easy to setup, you don't need a client secret, and you can get all the information from the id_token without requiring an extra API call (just add email to the requested scopes to get the email address)

@Tratcher The problem is that even if Sentry picks up the request details, it's usually still just encrypted tokens and such. I imagine it'd be the same with Fiddler.

@thomaslevesque you don't need a client secret? Last I checked Google only supported the code response type so the client secrete was required to exchange the code for an idtoken. I double checked and they do support token flows, but only for the client.
https://developers.google.com/identity/protocols/OpenIDConnect#authenticationuriparameters
response_type | (Required) | If the value is code, launches a Basic flow, requiring a POST to the token endpoint to obtain the tokens. If the value is token id_token or id_token token, launches an Implicit flow, requiring the use of Javascript at the redirect URI to retrieve tokens from the URI #fragment.

@kanadaj let's take that discussion to another thread.

@thomaslevesque you don't need a client secret? Last I checked Google only supported the code response type so the client secrete was required to exchange the code for an idtoken. I double checked and they do support token flows, but only for the client.

You can get an id_token directly, without needing an authorization code. Just use id_token as the response_type (this is the default when you use AddOpenIdConnect). In this case you don't need the client secret.

@Tratcher I see the Google documentation is misleading. It says:

If the value is token id_token or id_token token, launches an Implicit flow, requiring the use of Javascript at the redirect URI to retrieve tokens from the URI #fragment.

But I just tried it in my app, and it works just fine. Probably because it's using form_post as the response_mode, not fragment.

@thomaslevesque Ah, it does work. Well there's an undocumented feature for us.

See https://github.com/aspnet/AspNetCore/pull/6338 for the proposed patch. Note this uses a different endpoint than proposed earlier. I've updated the mitigation above to match.

See #6338 for the proposed patch. Note this uses a different endpoint than proposed earlier. I've updated the mitigation above to match.

Is there any specific reason you changed the new endpoint?

@AnthonyMascia this one seemed more appropriate for an OAuth2 component, and it's also a later version of the API. The prior one was an OpenIdConnect specific endpoint and an older API version.

@Tratcher Hi, so if my app still calls the URL https://www.googleapis.com/auth/plus.me, what should I replace it with? I saw the migration article you posted but I'm still not sure what the actual replacement should be. Also, I'm not sure why you told @Tr4pSt3R that using the https://www.googleapis.com/auth/plus.me was fine, since this is the one being deprecated, isn't it?


The constant "LL_RCC_USB_CLKSOURCE_PLL2Q" is missing from file "stm32h5xx_ll_rcc.h"

File: Inc/stm32h5xx_ll_rcc.h (sorry, I'm new to the "issue" section of github and not sure how to find or embed the commit number.)
Lines starting at: 918
The constant: LL_RCC_USB_CLKSOURCE_PLL2Q is missing from the file.
When compiling for the NUCLEO-H503RB board, and using the IDE to set the USB clock source to PLL2Q, you will get an undeclared error. The work around is to add:

#ifndef LL_RCC_USB_CLKSOURCE_PLL2Q
#define LL_RCC_USB_CLKSOURCE_PLL2Q   RCC_CCIPR4_USBSEL_1       /*!< PLL2 Q clock used as USB clock source */
#endif

to the "main.h" file.
My best guess as to what is needed to fix the issue, is the lines:

918 #define LL_RCC_USB_CLKSOURCE_NONE        0x00000000U               /*!< No clock used as USB clock source */
919 #define LL_RCC_USB_CLKSOURCE_PLL1Q       RCC_CCIPR4_USBSEL_0       /*!< PLL1 Q clock used as USB clock source */
920 #if defined(RCC_CR_PLL3ON)
921 #define LL_RCC_USB_CLKSOURCE_PLL3Q       RCC_CCIPR4_USBSEL_1       /*!< PLL3 Q clock used as USB clock source */
922 #endif /* PLL3 */
923 #define LL_RCC_USB_CLKSOURCE_HSI48       RCC_CCIPR4_USBSEL         /*!< HSI48 clock used as USB clock source */

should be something like:

918 #define LL_RCC_USB_CLKSOURCE_NONE        0x00000000U               /*!< No clock used as USB clock source */
919 #define LL_RCC_USB_CLKSOURCE_PLL1Q       RCC_CCIPR4_USBSEL_0       /*!< PLL1 Q clock used as USB clock source */
920 #if defined(RCC_CR_PLL3ON)
921 #define LL_RCC_USB_CLKSOURCE_PLL3Q       RCC_CCIPR4_USBSEL_1       /*!< PLL3 Q clock used as USB clock source */
922 #else
923 #define LL_RCC_USB_CLKSOURCE_PLL2Q       RCC_CCIPR4_USBSEL_1       /*!< PLL2 Q clock used as USB clock source */
924 #endif /* PLL3 */
925 #define LL_RCC_USB_CLKSOURCE_HSI48       RCC_CCIPR4_USBSEL         /*!< HSI48 clock used as USB clock source */

Hi @iizonn,
Issue reproduced using a STM32CubeMX generated example. Thank you for the fix proposal. Looks quite relevant. This will be forwarded to our development team to have it fixed. I will keep you informed.
With regards,

ST Internal Reference: 183323


Dependency bug from chroma 0.5.23 at SentenceTransformerEmbeddingFunction

Transformer library updated to use "tokenizers>=0.21,<0.22" (released 4 days ago)
Where in chroma we are still point to 'tokenizers >= 0.13.2, <= 0.20.3',
Which creating dependency conflict, can you please update tokenizers to latest package.
Here is the I am trying to run
sentence_transformer_ef = embedding_functions.SentenceTransformerEmbeddingFunction(
    model_name="all-MiniLM-L6-v2"
)

Links:
https://github.com/huggingface/transformers/blob/34f4080ff59b1668d919a1ba9f8bc4a3a2a3f478/setup.py#L183C5-L183C30
https://github.com/chroma-core/chroma/blob/1110d07f17c75e44c372361fd2684f5b08edec0d/pyproject.toml#L31C3-L31C37
I tried to use lower version, which started creating more issues, related to torch 2.5.1 compatible not found.
Platform:
MacOS
Python 3.12.4

is it safe to use tokenizers version 0.21.0 with chromadb?


fix(types): Calculate Context type for each handler

closes #3587
This PR makes all Context<Env> in handlers respect type changes made by previous handlers.
The author should do the following, if applicable

[ ] Add tests (In progress)
[ ] Run tests
[x] bun run format:fix && bun run lint:fix to format the code
[ ] Add TSDoc/JSDoc to document the code

I tested the type computation performance after the change using the following code.
(Testing method: same as ci / perf-measures-type-check)
import { Hono } from '../../../src'
import { createMiddleware } from '../../../src/helper/factory'

const mw1 = createMiddleware<{ Variables: { foo: string } }>(async (c, next) => {
  c.set('foo', 'bar')
  await next()
})

const mw2 = createMiddleware<{ Variables: { bar: string } }>(async (c, next) => {
  c.set('bar', 'baz')
  await next()
})

const mw3 = createMiddleware<{ Variables: { baz: string } }>(async (c, next) => {
  c.set('baz', 'qux')
  await next()
})

const mw4 = createMiddleware<{ Variables: { qux: string } }>(async (c, next) => {
  c.set('qux', 'quux')
  await next()
})

const mw5 = createMiddleware<{ Variables: { quux: string } }>(async (c, next) => {
  c.set('quux', 'corge')
  await next()
})

const mw6 = createMiddleware<{ Variables: { corge: string } }>(async (c, next) => {
  c.set('corge', 'grault')
  await next()
})

const mw7 = createMiddleware<{ Variables: { grault: string } }>(async (c, next) => {
  c.set('grault', 'garply')
  await next()
})

const mw8 = createMiddleware<{ Variables: { garply: string } }>(async (c, next) => {
  c.set('garply', 'waldo')
  await next()
})

const mw9 = createMiddleware<{ Variables: { waldo: string } }>(async (c, next) => {
  c.set('waldo', 'fred')
  await next()
})

export const app = new Hono().get('/route1', mw1, mw2, mw3, mw4, mw5, mw6, mw7, mw8, mw9, (c) => {
  const foo = c.get('foo')
  return c.json({ foo })
})

The result looks like this.
I think this is an acceptable increase in type calculation cost.
				  Before     After
Files:              257        257
Lines:           114397     114397
Identifiers:     112274     113322
Symbols:         206750     274808
Types:           125133     135385
Instantiations:  492354     548176
Memory used:    281358K    315432K
I/O read:         0.02s      0.02s
I/O write:        0.00s      0.00s
Parse time:       0.45s      0.52s
Bind time:        0.17s      0.18s
Check time:       2.40s      2.50s
Emit time:        0.00s      0.00s
Total time:       3.03s      3.20s

I know what kind of test is needed,
but not sure whether to write it within an existing case or as a new case.

I used the following code to investigate how much type computation costs vary.
( The testing method is the same as ci / perf-measures-type-check )
import { Hono } from '../../../src'
import { createMiddleware } from '../../../src/helper/factory'

const mw1 = createMiddleware<{ Variables: { foo: string } }>(async (c, next) => {
  c.set('foo', 'bar')
  await next()
})

const mw2 = createMiddleware<{ Variables: { bar: string } }>(async (c, next) => {
  c.set('bar', 'baz')
  await next()
})

const mw3 = createMiddleware<{ Variables: { baz: string } }>(async (c, next) => {
  c.set('baz', 'qux')
  await next()
})

const mw4 = createMiddleware<{ Variables: { qux: string } }>(async (c, next) => {
  c.set('qux', 'quux')
  await next()
})

const mw5 = createMiddleware<{ Variables: { quux: string } }>(async (c, next) => {
  c.set('quux', 'corge')
  await next()
})

const mw6 = createMiddleware<{ Variables: { corge: string } }>(async (c, next) => {
  c.set('corge', 'grault')
  await next()
})

const mw7 = createMiddleware<{ Variables: { grault: string } }>(async (c, next) => {
  c.set('grault', 'garply')
  await next()
})

const mw8 = createMiddleware<{ Variables: { garply: string } }>(async (c, next) => {
  c.set('garply', 'waldo')
  await next()
})

const mw9 = createMiddleware<{ Variables: { waldo: string } }>(async (c, next) => {
  c.set('waldo', 'fred')
  await next()
})

export const app = new Hono().get('/route1', mw1, mw2, mw3, mw4, mw5, mw6, mw7, mw8, mw9, (c) => {
  const foo = c.get('foo')
  return c.json({ foo })
})

The result is as follows.
I think this is an acceptable increase in type calculation cost.
				  Before     After
Files:              257        257
Lines:           114397     114397
Identifiers:     112274     113322
Symbols:         206750     274808
Types:           125133     135385
Instantiations:  492354     548176
Memory used:    281358K    315432K
I/O read:         0.02s      0.02s
I/O write:        0.00s      0.00s
Parse time:       0.45s      0.52s
Bind time:        0.17s      0.18s
Check time:       2.40s      2.50s
Emit time:        0.00s      0.00s
Total time:       3.03s      3.20s

@sushichan044 Thank you for handling it.
Exactly. I also thought the decrease in performance would possibly be a pain point.

I think this is an acceptable increase in type calculation cost.

@m-shaka What do you think of it?

@sushichan044
I haven't merged yet because I'm concerned about performance. TypeScript performance is critical to DX, so I am considering whether or not to allow performance degradation due to this change.

@yusukebe
Yes, the experience gained, and performance diminished by this PR should be discussed in depth.


$filter is not working as expected

Hi,
I am trying to use $filter function but it's failing each time and always return all data. Filtering is not filtering out the data from JSON.
Jsonata Expression:
results.(
$y := "test";

$bta := function($x) {(
	$count($x.billToAccounts) > 1
		? ($contains($join($x.billToAccounts, ','), "super") ? "Super" : "Standard")
		: ($contains($x.billToAccounts[0], "super") ? "Super" : "Standard")
)};

{
  "users": $filter($, function($v, $i, $a) {
        $v.status =  "PROVISIONED"   }) {
    "firstName": $.profile.firstName,
    "lastName": $.profile.lastName,
    "email": $.profile.login,
    "lastLogin": $.lastLogin,
    "id" : $.id,
    "userType": $bta($.profile)
  }
}

)
JSON Data:
{
	"results": [
		{
			"id": "00uj8pe5xarGA3VYy0h7",
			"status": "STAGED",
			"profile": {
				"firstName": "Test",
				"lastName": "334",
				"mobilePhone": null,
				"secondEmail": null,
				"login": "xxxxxxxxxxxxxx",
				"email": "xxxxxxxxxxxxxx"
			}
		},
		{
			"id": "00uj8pe5xc0HBaczt0h7",
			"status": "STAGED",
			"profile": {
				"firstName": "Test",
				"lastName": "445",
				"mobilePhone": null,
				"secondEmail": null,
				"userType": "super",
				"login": "xxxxxxxxxxxxxx",
				"email": "xxxxxxxxxxxxxx"
			}
		},
		{
			"id": "00uj8pe5xeqI98wwp0h7",
			"status": "PROVISIONED",
			"profile": {
				"firstName": "Test",
				"lastName": "556",
				"mobilePhone": null,
        "billToAccounts": [
					"624780:standard"
				],
				"secondEmail": null,
				"login": "xxxxxxxxxxxxxx",
				"email": "xxxxxxxxxxxxxx"
			}
		},
		{
			"id": "00unxk5tzcKcwJU2s0h7",
			"status": "PROVISIONED",
			"profile": {
				"firstName": "BRENDA",
				"lastName": "SMART",
				"mobilePhone": "0408770744",
				"billToAccounts": [
					"624780:super",
          "624780:super"
				],
				"secondEmail": null,
				"userType": "User",
				"CustomerRoleType": "Director",
				"login": "xxxxxxxxxxxxxx",
				"email": "xxxxxxxxxxxxxx"
			}
		}
	]
}

Expected Output:
[
  {
    "users": {}
  },
  {
    "users": {}
  },
  {
    "users": {
      "firstName": "Test",
      "lastName": "556",
      "email": "xxxxxxxxxxxxxx",
      "id": "00uj8pe5xeqI98wwp0h7",
      "userType": "Standard"
    }
  },
  {
    "users": {
      "firstName": "BRENDA",
      "lastName": "SMART",
      "email": "xxxxxxxxxxxxxx",
      "id": "00unxk5tzcKcwJU2s0h7",
      "userType": "Super"
    }
  }
]

Actual Output:
I am getting full JSON, no filtering of data is happening.

Thank you for the report. I am currently trying to work through all the unit tests for jsonata.js and finding there are several problems to be addressed. When I attempted to set up your example at the try.jsonata.org website, something was wrong because it reported ** no match **. It may be an email issue (e.g., perhaps characters were transformed). If possible, could you please set up your test example above at the try.jsonata.org website, and then select the share icon which will provide you a URL you can paste here with everything set up and working as expected there.
Because I have everything all over the floor right now, it will take me some time to get a jar built with a fix for you, but I'm willing to do this as soon as I have a working test case.

hmm, pasting from here worked in try.jsonata.org with this example: https://try.jsonata.org/Eh4qvuddB
You need not do anything. I'll work from here.

I'm having difficulty getting the parser to recognize the entire expression and have asked for help on StackOverflow here: https://stackoverflow.com/questions/61197185/antlr4-finding-tokens-but-returns-truncated-parse-tree
The reason the filter isn't working is because all that is returned when parsing the expression is "result" so it is merely returning the result's array from the input data.

FYI,
This issue is happening for all Higher-Order Function from JSONATA.
None of the function is working with the Library.
https://docs.jsonata.org/higher-order-functions

I've been working to clean up by comparing JSONata4Java against the unit tests for jsonata.js -- it has been a difficult few weeks. I still have a lot of work to go. I've opened new issues > 40 for unimplemented features. I'll update the README once I get through all the problems I expect to work.
The issue with the example you've posted is the system doesn't recognize the effect of merging the output of the filter function with another objects fields. I worked a few days trying to get that working but had to back out my fixes pending trying to address the unit tests.
{
"users": $filter($, function($v, $i, $a) {
$v.status =  "PROVISIONED"   }) {  <-- this is not recognized by the parser
"firstName": $.profile.firstName,
"lastName": $.profile.lastName,
"email": $.profile.login,
"lastLogin": $.lastLogin,
"id" : $.id,
"userType": $bta($.profile)
}
}
I saved the MappingExpression.g4.new file in the src/main/antlr4/com/api/jsonata4java/expressions/generated
directory so I can go back to that approach.
I haven't forgotten about this issue.


Looks like the program stalled

Hi all,
I haven't had any activity for the last 4 hours. What can I do to restart or check on the program status without cancelling the job at task?

Please disregard. It started up again.

program is working


Let's add some types of MySQL in The Migration component

Could somebody tell me why we don't have in The Migration component some types of MySQL?
For example, we don't have MEDIUMTEXT.

All the types that present in migrations must be supported by all database engines we have. Current set is a bare minimum. If you do not plan to develop a portable solution, there's no point in having universal types, you can use strings.

All the types that present in migrations must be supported by all database engines we have. Current set is a bare minimum. If you do not plan to develop a portable solution, there's no point in having universal types, you can use strings.

Ok. It's clear. Thank you.


[Blame] Why can librime affect UI settings?

Recently I found an article: https://zhuanlan.zhihu.com/p/187195412
In the comment section of this column, I saw a "interesting" thing:

And this related commit: https://github.com/rime/librime/commit/dbb35c61295a5b089a588c94886ce720f834f2f4
What the ......!? Why can librime, a back-end, directly (and even decisively) affect the UI settings? Why?
This obviously should be left to front-end management, why finally left to the back-end?
Can't understand! (理解不能！） And there are many confusing mechanisms
Not only I but also many users ask for a explanation.

I have to admit that I wrote this issue with a little anger, but, many users and I DO think that it would be better to left to front-end to handle things like UI settings.

I think so too.

And this related commit: dbb35c6

This code is for arrow keys. The vertical/horizontal layout is controlled by UI.
Likes weasel

And this related commit: dbb35c6

This code is for arrow keys. The vertical/horizontal layout is still controlled by UI.
Like weasel

You are right. But still: why a back-end need to process the key pressing?

And this related commit: dbb35c6

This code is for arrow keys. The vertical/horizontal layout is still controlled by UI.
Like weasel

You are right. But still: why a back-end need to process the key pressing?

Arrow keys will change the state of librime, the dbb35c6 need know XP_Right represented. It is next candidate in _horizontal settings, or previous candidate in _vertical settings.
It seems _horizontal and _vertical are private settings controlled by squirrel.
./SquirrelInputController.m:  Bool is_horizontal_mode = NSApp.squirrelAppDelegate.panel.horizontal;
./SquirrelInputController.m:  if (is_horizontal_mode != rime_get_api()->get_option(_session, "_horizontal")) {
./SquirrelInputController.m:    rime_get_api()->set_option(_session, "_horizontal", is_horizontal_mode);

In my understanding, librime is only responsible for returning candidates and waiting for the front-end to tell which one has been selected. Why does it involve the front-end UI and the placement of candidate words?

In my understanding, librime is only responsible for returning candidates and waiting for the front-end to tell which one has been selected. Why does it involve the front-end UI and the placement of candidate words?

This is what I want to say, too. @sih4sing5hong5

In my understanding, librime is only responsible for returning candidates and waiting for the front-end to tell which one has been selected. Why does it involve the front-end UI and the placement of candidate words?

This architecture is OK. In this architecture, every frontends need:

Keep the state of the candidates.
Reset the state, when pressing esc, commit candidate, cursor moving ... actions.
Manipulate the eaten value returned to OS. This value tells OS, whether the input method detail with the key event. If not, OS must capture the key event, like caps lock, number lock, print screen, ...etc.

If the frontend knows all candidate, it can scroll candidates like macOS system input method.
If you want this feature, just write a new selector in librime, you can archieve your goal and keep back compatibility with librime.
I think the architecture of librime selector is referencing fcitx or ibus framework.

I think the architecture of librime selector is referencing fcitx or ibus framework.

Maybe you are right, but that is your "think", subjectively I don't quite believe that ......After all, as far as I know, the core library of fcitx (or fcitx5) doesn't affect the UI performance.

I think the architecture of librime selector is referencing fcitx or ibus framework.

Maybe you are right, but that is your "think", subjectively I don't quite believe that ......After all, as far as I know, the core library of fcitx (or fcitx5) doesn't affect the UI performance.

Oh! There are two different things in the selector.

The architecture, the candidate state controlled by the selector, maybe for fcitx.
The _vertical and _horizontal config  in the selector are private setting for squirrel only(only squirrel uses this string). It seems an UI API for squirrel. Maybe there are some clues in SquirrelInputController.m.

./SquirrelInputController.m:  Bool is_horizontal_mode = NSApp.squirrelAppDelegate.panel.horizontal;
./SquirrelInputController.m:  if (is_horizontal_mode != rime_get_api()->get_option(_session, "_horizontal")) {
./SquirrelInputController.m:    rime_get_api()->set_option(_session, "_horizontal", is_horizontal_mode);

I think you are concerned about second one. You can trace why squirrel need this is_horizontal_mode valuable.

OP is angry because they cannot understand my code? I guarantee you, if they know code, it'll be super easy.
The code change https://github.com/rime/librime/commit/dbb35c61295a5b089a588c94886ce720f834f2f4 is not related to the disucussion on Zhihu, at all.
By the way, the feature Zhihu User was asking for has been implemented in Squirrel ~7 years ago: https://github.com/rime/squirrel/commit/316b34b8f7944fe1bc9829e4b8504d082731b43e
and recorded in the release notes.
OP doesn't even understand what the dialog was about, and hurried to GitHub to "blame" what they thought was going on... Confusing. They simply have to learn one thing, as the Elder said, and stop being naïve.

The code change dbb35c6 is not related to the disucussion on Zhihu, at all.

In fact, I don't know this zhihu post until I found this issue.
But I can't understand why these code about UI or the placement of candidate appear in back-end when I found this commit yesterday.
I think it important to make front-end and back-end do what they should do.
As I said above, in my opinion, the code about UI or the placement of candidate should not be in the back-end code.

Since you have time to make this change, why not optimize memory cost of dict-compile or add some code to make librime load plugins?

Of couse librime cannot directly affect UI or any front-end behaviour. The library is always passively called by the front-end, giving the results for the query in return. Which part in the commit are you not clear that it's all doing back-end work?
Again, I advice that OP learn the very basics - the minimal CS knowledge and coding skills - until they are ready to know what to blame.

The code change dbb35c6 is not related to the disucussion on Zhihu, at all.

In fact, I don't know this zhihu post until I found this issue.
This is no issue.

But I can't understand why these code about UI or the placement of candidate appear in back-end when I found this commit yesterday.
Because the back-end needs to know the necessary information from the front-end to answer the front-end's queries, which in this case, is "What will be the candidates when the User pressses Left or Right in this input method". To answer that, the engine has to know how User saw the previous candidates in order to understand the User's intention.

I think it important to make front-end and back-end do what they should do.
That's what is in the code.

As I said above, in my opinion, the code about UI or the placement of candidate should not be in the back-end code.
Those are not in the backend code. The code is not about manipulating UI. The code is purely building a model in the backend with information coming from the frontend - keyboard input is also such information - and with that, the model is able to answer the frontend's queries. You cannot have a backend that has zero knowledge of the frontend yet is able to answer questions about the frontend.

Look, I've boiled it down to the very basics. Yet most skills cannot be told. I know how to design an input method library so well, because I've seen too much.

Since you have time to make this change, why not optimize memory cost of dict-compile or add some code to make librime load plugins?

No, thanks. I have my own priorities.

Of couse librime cannot directly affect UI or any front-end behaviour. The library is always passively called by the front-end, giving the results for the query in return. Which part in the commit are you not clear that it's all doing back-end work?
Again, I advice that OP learn the very basics - the minimal CS knowledge and coding skills - until they are ready to know what to blame.

我还是用中文说出来吧，以我的水平可能英语表达不出来。
也许是我的无知和幼稚，这条 issue 让大家见笑了。这里面的一些东西，肯定避免不了误会误解。如果说是我理解有误会，那么我感到很抱歉，非常对不起。但是我想说我开始的想法里有借这条 issue 去引出一些讨论的意味。
就我个人感觉，开发者和我们用户交流似乎很少。作为普通（初级或中级）用户，我们能知道也（可能）仅能知道 experience，我们有可能没法去理解 design，理解您的想法（至少源码层面上会是这样）。从体验上来说，我们确实感到了很多不满意。我们希望能了解您是怎么想、怎么去实现的。也许这样我们才能更好地提出更针对性和更具体的意见和建议。
无论如何，都先非常感谢您本人能回答我的疑惑。: )

上午我提出这条 issue 时，我的确是带着一些怒气的。但是想到我的水平，可能会造成一些误会（就像现在这样，最终可能显得我自己既无能又跳脚得很）。所以冷静下来，我的想法就和上一条 comment 一样。其实可能是一种广泛的非技术问题，我跑来 GitHub 来抱怨确实让人觉得有些 无事找事，不切重点，不符合氛围 。但我（们）依旧想借一个空间来表达想法，毕竟我认为这种方式您有更多机会来看到。我想让您知道，大家的不满是有些长久的（具体提过不短时间但依旧未实现的）、普遍的，甚至是挺迫切的。
引用 TG 用户交流群里几位小伙伴的话（他们看了这条 issue 里的 comments）：

Although we may not know the design of the input method very well,
at least we know one thing, the user experience is not good,
and this time it is just a fuse.

Users maybe don't know design, but know experience.

我衹看到氣話

使用 Rime 推荐发行版： AOSC OS
你永远不知道一个发行版帮上游填了多少坑……

......
这条 issue 本身的问题或许不再值得讨论下去。但，希望佛振先生能够更切实感受到我们的声音。
Best wishes.

 I learn Elder's words so well and faithfully follow His instructions on taking constant effort in foreign language study, as well as His practice in sharing knowledge with younger people.
「怒氣」……
技術牛不牛不清楚，你們有一個好，脾氣可真不小，聲音不絕於耳。只是問來問去的問題，太業餘了，有時荒謬。
還想弄個大新聞，就把我批判一番？
你們要知道，寫OpenCC的大神BYVoid，比你們不知高到哪裏去了，我跟他談笑風生。
某曾遭遇過路怒，遭遇過佛棍誣我「謗佛」，還從未見過搬磚寫碼也致人狂怒的。
我寫碼爲樂，跟你關係大嗎。何以動氣？玩不轉，都怨別人不給你做？
某主張，哪裏不滿，就做到滿意。帶上有說服力的設計和代碼實現來討論。切實感受，莫過於此。讓你們的聲音有助於完成真正有用的工作。

我上午提出 issue 没多久就已经冷静下来过了，不过我当时觉得收不住这说出的话了...... 遭遇您的批评无可避免，我也不怕因此「丢假」。请您不要误会，可能是我的锅，但是我个人角度没有任何要「制造大新闻」、「诽谤」、「无理横加指责」的初衷和目的。还请您原谅。

我寫碼爲樂，跟你關係大嗎。何以動氣？玩不轉，都怨別人不給你做？

这一点我能理解，在我的学习生活中也有深刻体会。说白了今天，可以说是场由我开头，由我承担后果的「闹剧」。但是有时候现实是，我（非具体指代）觉得应该这样，但是大家觉得要怎样，然后就吵起来了，这种矛盾很普遍。
再次，如果我的鲁莽行为造成了您的不解甚至愤怒，我非常抱歉。「大新闻」真非我本意。我在那时只是想用自己的一种方式去解决 —— 即使不能解决，但也或许能有个回音 —— 问题罢了。

技術牛不牛不清楚，你們有一個好，脾氣可真不小，聲音不絕於耳。只是問來問去的問題，太業餘了，有時荒謬。

还想就这条补充一点话。我个人而言，至少目前我确实是个水平上的「年轻人」，但是其实不是大家真的都没能力却都又喜欢嚷嚷。比如其实 trime 同文输入法有个 fork 在 QQ 群，是群友做的（不过不知为何不愿公开；另外考虑到 trime 和 rime 本体「负责人」不同，就没多提）。
「只是人总是习惯找一个带头的作为责任人而已……」，有的人认为某某事情应该去交给「上面那个人」去做，依赖上游一方（这可能是个非技术问题）。我不相信大家都没实力，但是哪怕是在开源社区，这种「责任感」（姑且这么形容）问题也并不总是扁平化的。  说话永远比实际付出更容易，即使自己有能力，在当下快节奏的环境下也无形驱使着人说的比做的快。这是我的看法
但真的真的，这条 issue 是有点代大家说话的意思在里面。以我的感受，这可能只是一个导火索，或许 this is no issue。未来可能会有更激烈的声音。

无论如何，这场讨论还是告一段落吧。

我上午提出 issue 没多久就已经冷静下来过了，不过我当时觉得收不住这说出的话了...... 遭遇您的批评无可避免，我也不怕因此「丢假」。请您不要误会，可能是我的锅，但是我个人角度没有任何要「不讲理」、「诽谤」的初衷（开始时是有一点点，但绝没有要一直贯彻下去的意思）和「制造大新闻」 的最终目的。还请您原谅。

There are a guideline for community communication in  How to write the perfect pull request . Using positive language is helpful for the community.

「只是人总是习惯找一个带头的作为责任人而已……」，有的人认为某某事情应该去交给「上面那个人」去做，
但真的真的，这条 issue 是有点代大家说话的意思在里面。

Everyone need take responsibility for himself/herself. We can choose speaking out or suffering in silence. So I think more discussion with positive language is better.

大家的不满是有些长久的（具体提过不短时间但依旧未实现的）、普遍的，甚至是挺迫切的。

The librime is an open source library. If there are some valuable features for you, you try to raise funds to hire full-time/part-time engineers to achieve what you want. It's more efficiency than just blame.

It's more efficiency than just blame.

Sometimes blaming is not the purpose, but expressing our attitude is.

使用 Rime 推荐发行版： AOSC OS
你永远不知道一个发行版帮上游填了多少坑……

Sounds sweet, but we have never heard of anything from AOSC OS developers.
ibus-rime has been relatively inactive for years. When any user of a certain Linux distribution comes up with patches, it is always helpful to start an issue at ibus-rime repository to let us know about their great ideas.
RIME developers mostly work on macOS. It is unreasonable to check communities of every possible Linux distribution to collect patches regularly.

I have to admit that I wrote this issue with a little anger, but, many users and I DO think that it would be better to left to front-end to handle things like UI settings.

You can do it if you are  both capable and willing to, nothing is preventing you to contribute if you are not satisfied with my work.

Sounds sweet, but we have never heard of anything from AOSC OS developers.

Hmm, some users have heard more than what I know. For that, I just a listener rather than a insider.

nothing is preventing you to contribute

Some people (not me) have deep doubts about it.

I have know this already. In fact, my own problem (i.e. the problem of UI settings) has been solved, and I will ask such a problem because I didn't understand it well (whether it is my lack of knowledge).
The reason why the code is said to be "relevant" is only because we only found that one in the recent commit history. In the subsequent discussion and explanation, we already knew that it was not really relevant.
It now appears that everyone's conflicts and concerns are obviously not this problem itself.

使用 Rime 推荐发行版： AOSC OS
你永远不知道一个发行版帮上游填了多少坑……

Sounds sweet, but we have never heard of anything from AOSC OS developers.
ibus-rime has been relatively inactive for years. When any user of a certain Linux distribution comes up with patches, it is always helpful to start an issue at ibus-rime repository to let us know about their great ideas.
RIME developers mostly work on macOS. It is unreasonable to check communities of every possible Linux distribution to collect patches regularly.

Ironically, I just did some "anyone can do" work to improve the out-of-the-box experience of RIME.
like this: https://github.com/AOSC-Dev/rime-schema-manager


v2 api: RL, Client SSL, and other filters

Signed-off-by: Shriram Rajagopalan<EMAIL_ADDRESS>title: Moving rate limit (http/tcp), client ssl auth, echo filters to v2
Description: Filter conversion, some test case cleanup, code cleanup to have uniform variable naming, etc. Also removed deprecated_v1 from integration tests..
Risk Level: Medium
Testing: Unit tests and integration tests

@rshriram please fix format


Update stack.py

Python doesn't require predefined list size. It can resize on it's own.
Describe your change:
Python doesn't require sizing. It can extend or shorten on its own.

[ ] Add an algorithm?
[ ] Fix a bug or typo in an existing algorithm?
[ ] Documentation change?

Checklist:

[ ] I have read CONTRIBUTING.md.
[ ] This pull request is all my own work -- I have not plagiarized.
[ ] I know that pull requests will not be merged if they fail the automated tests.
[ ] This PR only changes one algorithm file.  To ease review, please open separate PRs for separate algorithms.
[ ] All new Python files are placed inside an existing directory.
[ ] All filenames are in all lowercase characters with no spaces or dashes.
[ ] All functions and variable names follow Python naming conventions.
[ ] All function parameters and return values are annotated with Python type hints.
[ ] All functions have doctests that pass the automated testing.
[ ] All new algorithms have a URL in its comments that points to Wikipedia or other similar explanation.
[ ] If this pull request resolves one or more open issues then the commit message contains Fixes: #{$ISSUE_NO}.

By removing the limit, the client can add more items to the stack if needed, Python can handle the resizing automatically. It becomes cumbersome if the client have to add more items to the stack if the stack is already full. And the client have to resize manually a bigger list and then copying previous list elements to the newer bigger list.


Polybar missing parameter

I get:
error: Disabling module "cpu" (reason: Missing parameter "module/cpu.type")
error: Disabling module "memory" (reason: Missing parameter "module/memory.type"))

Hey @samerickson, inside the .config/polybar/config CPU and Memory modules are not used.
You should take a look at the Polybar repo to make sure you properly updated config.

CPU and Memory modules are not used.

Your polybar config enables the cpu and memory modules on the right side of polybar, but since they aren't enabled they display that error.
https://github.com/ibrahimbutt/direwolf-arch-rice/blob/f2c51cdb2a4b85855b58947e769b5a0f1d7a7d3f/.config/polybar/config#L31

So, how do we enable them? My file has that in it, and I would like to see both of them.  Is there something I need to install?


Fix go sdk gbk load test

Changes to fix Go SDK GBK Load test case.

Skip GBK 7 test for now because it runs out of memory
Fix typings in num_records for GBK_2, GBK_5, GBK_6

Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

[ ] Choose reviewer(s) and mention them in a comment (R: @username).
[ ] Format the pull request title like [BEAM-XXX] Fixes bug in ApproximateQuantiles, where you replace BEAM-XXX with the appropriate JIRA issue, if applicable. This will automatically link the pull request to the issue.
[ ] Update CHANGES.md with noteworthy changes.
[ ] If this contribution is large, please file an Apache Individual Contributor License Agreement.

See the Contributor Guide for more tips on how to make review process smoother.

GitHub Actions Tests Status (on master branch)

See CI.md for more information about GitHub Actions CI.

R: @kamilwu


fix: fix values example config

:tada: This PR is included in version 0.11.0-next.1 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


How to set minimum and maximum panel sizes in DockView?

Hi,
I'm currently working on a project using the DockView library, and I'm trying to implement size constraints for my panels. Specifically, I want to set minimum and maximum sizes for each panel to ensure they don't become too small or too large when users resize them.
I've looked through the documentation but couldn't find a clear way to achieve this. Is there a built-in method or property in DockView to set minimum and maximum sizes for panels?
My use case requires that panels:

Don't shrink below a certain width and height
Don't expand beyond a certain width and height

Could you please provide guidance on the proper way to set these size constraints for panels in DockView? If this feature isn't currently available, are there any workarounds or plans to implement it in the future?
Thank you for your time and assistance.

Tracking in https://github.com/mathuo/dockview/issues/640

Released in 1.17.0
See http://localhost:3000/docs/core/panels/add#minimum-and-maximum
See https://github.com/mathuo/dockview/issues/708 for continued work on group size preservation


Work out application profile for publications and projects

When working on projects and having publications, I think all of our researchers should add this to their own website, and walder should be able to scrape this. We should work out an application profile for scholarly communications

Do you mean a SHACL shape then?

We could start from a documentation snippet and end up with a SHACL shape finally.
@pietercolpaert I would suggest to move this issue to the knows-site repo (it's about the data, not about the coder, right?)


Go To not working in route if group method uses as

Go to not working by clt+b or clt+ click only in route file.
//admin manage orders menu
Route::get('orders', [
'uses' => 'OrderController@orderListsContent',
'as'   => 'admin.shop_orders_list'
])->middleware('verifyLoginPage', 'admin', 'sufficientPermission');
Note: in controller and view work perfectly.

Works for me, can click on ::get and ->middleware
Do you still have this issue?


Can not save any changes in my html and CSS files

I am new to Brackets. Whenever I save my files it gives an error that the permissions do not allow. What should I do? Thankyou

Hi @thealiraza
You should move your own projects to an other folder such as under Documents (C:\Users\username\Documents) where you are guaranteed to have write access.
You can do this by opening the folder C:/Program Files (x86)/Brackets/samples/root/Getting Started on Windows Explorer and cutting / pasting them to C:\Users\username\Documents. Then you can open the folder by clicking the button that on the screenshot says Getting Started ➡ Open Folder or from File -> Open Folder

IT is now working. same problem. ANd, if I create a new html file directly in Brackets, it also do not save that file and gives this error.


rename eisvogel.tex to eisvogel.latex

This step in the "Installation" section of the readme irritated me:

Move the template eisvogel.tex to your pandoc templates folder and rename the file to eisvogel.latex

Wouldn't it be useful to eliminate that renaming step, by renaming the file directly in the release?
Am I missing something here (backwards compatibility or so) making this infeasable?

my thoughts exactly :)

Exactly. This is extremely confusing.

Then let's change it or what's stopping us?

Then let's change it or what's stopping us?

Well, I first thought of directly submitting a PR, but this seemed so simple that I thought this might have some deeper meaning that isn't visible on first sight. As nobody has had any problem with this in the last half year and the overall mood for renaming this is fairly positive, there shouldn't be a problem with renaming it.

Well, I first thought of directly submitting a PR, but this seemed so simple that I thought this might have some deeper meaning that isn't visible on first sight. As nobody has had any problem with this in the last half year and the overall mood for renaming this is fairly positive, there shouldn't be a problem with renaming it.

The renaming in the released artifacts seems like a reasonable step. I hesitated because the file in the repository was intentionally named eisvogel.tex to get syntax highlighting and filetype recognition. If the file has a different name when released it's going to confuse people who install directly from the repository master branch.
However, one should only install a stable release from the releases page, so this is not a major issue.

The renaming in the released artifacts seems like a reasonable step. I hesitated because the file in the repository was intentionally named eisvogel.tex to get syntax highlighting and filetype recognition. If the file has a different name when released it's going to confuse people who install directly from the repository master branch.
However, one should only install a stable release from the releases page, so this is not a major issue.


fixed unused arg compiler warning

This throws a warning, in QGC warnings are errors so QGC master currently does not compile.

Thanks!


[🔥] Remove spelling mistake guideline

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


Asset Editor is empty when navigating from assets.json in the file explorer

To Reproduce
Steps to reproduce the behavior:

Go to the JavaScript editor
Click on 'Explorer' and then 'assets.json'
See Asset Editor with none of the assets showing

This also happens when in JavaScript or Python and then clicking Assets.

Closing this issue as a duplicate. The new issue has a bit more context: https://github.com/microsoft/pxt-arcade/issues/5649


(BOLT-936) Docs for bolt release (Bolt 1.1.0)

Superseded by https://github.com/puppetlabs/bolt/pull/718.


Moar promises

Lets dogfood on that promises stuff...
I found a really odd bug... createAnswers gets a third constraints argument which doesn't make sense.
@alvestrand is that worth bailing out on in adapter?

@jiayliu worked around the issue -- ugly but shrug
I've also seen getStats failures since apprtc is using the legacy syntax without a browser switch but that's a different story

Does it mean we have a regression in infobox on firefox?

I doubt it's a regression. Firefox getStats has never worked without a track selector as its called in https://github.com/webrtc/apprtc/blob/master/src/web_app/js/peerconnectionclient.js#L172

lgtm.
ok to merge?

yeah. The Firefox issue should soon be fixed but I guess it will take time to go to the stable channel there.


server fails to start: relative URL without a base

atuin 0.8.0

atuin server start --host <IP_ADDRESS> --port 8888

Error: error with configuration: relative URL without a base

Caused by:
    relative URL without a base

Location:
    /rustc/f1edd0429582dd29cccacaf50fd134b05593bd9c/library/core/src/result.rs:1914:27

Sorry for the long delay, the issue here is that the server is expecting the db_uri configuration, but it was allowing it to go through with a default value (a default that would never work).
There's 2 new fixes, I've introduced. The first provides a better error message for an invalid db_uri:
$ ATUIN_DB_URI="garbage" atuin server start
Error: failed to connect to db: garbage

Caused by:
   0: error with configuration: relative URL without a base
   1: relative URL without a base

Location:
    /Users/conrad.ludgate/Documents/code/atuin/atuin-server/src/lib.rs:29:10

The second removes the default value for the db_uri in the first place, so it gives you a better error message:
$ atuin server start
Error: could not load server settings

Caused by:
    failed to deserialize: missing field `db_uri`

Location:
    atuin-server/src/settings.rs:63:26


boards: arm: add ubx_bmd340eval_nrf52840

Add support for BMD-340-EVAL board from u-blox AG
Signed-off-by: Bob Recny<EMAIL_ADDRESS>

I just returned from holiday and thought I'd check progress. It looks like the automated checks passed.


add purple team to OWNERS

This looks fine to me, but I'll let TLs 👍 or 👎 .

/lgtm
/approve
(for Matt)


Vulkan: CanvasItem.draw_texture_rect() tiling does not work as expected

Godot version:
current master
3.x unaffected
OS/device including version:
Debian 10
Vulkan, Mesa DRI Intel(R) UHD Graphics 630
Issue description:
calling CanvasItem::draw_texture_rect with tile = true does not work or only in an unintuitive way. It definitive does not work as in 3.x
In 3.x this argument, well, tiled the texture.
In 4.0 it only prevents texture scaling but instead of tiling the edges just get stretched out.
Behavior in 3.2

left: TextureRect Stretch Mode tile, just a hidden call to draw_texture_rect really
right: manual call to draw_texture_rect from _draw()
The same setup in 4.0.dev

To achieve the same results in 4.0 one has to

call draw_texture_rect with tile = true to prevent scaling instead of tiling
and specify a tiling mode (calling set_texture_repeat or specifying the texture_repeat argument)

Related Issues

reason for #40011
background checkerboard does not correctly tile in ColorPicker related Nodes with alpha < 1: (example with alpha=0)
3.2:
4.0:
possible that I missed some

Possible Solutions

setting texture repeat as described above. some places in the engine already do this.
changing the api to be less confusing. Maybe rename tile to keep_src_size as this currently describes the behavior, however compat breakage might be hard to spot as the same calls work but they don't do their job properly.

Steps to reproduce:
any call to draw_texture_rect with tile=true
Minimal reproduction project:
draw_texture_rect-tile.zip - setup as above

background checkerboard does not correctly tile in ColorPicker related Nodes with alpha < 1: (example with alpha=0)

See also https://github.com/godotengine/godot/issues/41561.

This is most likely a result of the tiling property now being a property of the material instead of the texture. Tiling works with sprites, so someone just needs to update draw_texture_rect to use the proper tiling mode.

This bug is still relevant in the current master, and it's immediately noticeable when porting some of the demo projects.


Ignore database columns not specified in the struct

I am working with some large legacy tables and only need a subset of the columns in my model.
It would be very useful to have gorp ignore columns that aren't mapped to a field in the struct.
Two ways of approaching this:
Change the default behaviour and just ignore unmapped columns.
Create a config option on DbMap that enables allows incomplete models.
Thoughts?

As is, it's unsafe to use "select *" if you ever plan on rolling out changes to the DB schema without downtime.

:-1:
Personally, I prefer to use strict mapping, and prevent unpredictable behavior, like what you can see in language such as PHP.

I agree. Required columns should be specified explicitly. What could be added though is a method to automatically query all required columns based on the struct.

In case it helps, I've got a project (which I've named gorq), which imports and extends gorp's functionality with a query DSL.  It was built to handle some of these sorts of issues (the whole project stems from a function I wrote to generate column names for use in queries).  It's new, kind of complicated, doesn't have the most useful error messages, needs some cleanup, and the test coverage isn't very solid yet; but it's being used actively on at least four projects (all of which are using postgresql).
The basic syntax of queries becomes (as an example):
type Foo struct {
  ID int
  Bar Bar `db:"bar_id"` // Bar.ID populated with bar_id using sql.Scanner or a TypeConverter
  Baz string
}

foos := []Foo{}
ref := Foo{}
err := dbMap.Query(&ref).
  Where().
  Equal(&ref.Baz, "public").
  SelectToTarget(&foos)

It uses references quite a bit for figuring out column names (for input values, it will usually use the column name of a field if the value is equal to a field's address), which isn't exactly ideal... but I couldn't think of anything better at the time.  Still, it's a start.
More complicated queries (e.g. needing OR in the where clause, or using joins) are supported, but the syntax isn't always as clean as the above.  For example:
foos = []Foo{}
err = dbMap.Query(&ref).
  Join(&ref.Bar).On().
  Equal(&ref.Bar, &ref.Bar.ID).
  Where().
  Greater(&ref.Bar.Rank, 3).
  SelectToTarget(&foos)

foos = []Foo{}
filter := filters.Or(filters.Equal(&ref.Bar, someAdminBarID), filters.Equal(&ref.Baz, "public"))
err = dbMap.Query(&ref).
  Where(filter).
  SelectToTarget(&foos)

I really wanted to have better test coverage before mentioning it to anyone else ... but I thought it might help anyone who's running in to this issue, and I can't hide forever.
By the way, my two cents, for what they're worth: select * is code smell, and discarding data (even via an option that defaults to off) is dangerous.  But my opinion's probably obvious from the fact that I wrote a pretty massive extension to gorp, in part to avoid using select *.

I agree. Required columns should be specified explicitly. What could be added though is a method
to automatically query all required columns based on the struct.

Great, I want this and am willing to code it up.
It needs to support the single/multiple row fetched and it should memoize the results of reflecting structs for keys. What's the API you'd like to see?

Related to #133

There is a very specific case where it would be nice if it was possible to ignore columns: when fetching database metadata where you don't have control of the output columns. For example, show slave status in mysql outputs a fairly long list of columns, and you can't limit the columns. You also don't quite know if a newer mysql version will add more columns to the output.

@recht fetching metadata is done through select statements in postgres.  There are shortcuts in the psql CLI, but they all run select statements under the covers.
That said, if/when I find time to actually work on a new version of gorp in the future, I wouldn't mind adding this as a specific flag you can pass to queries.  Something along the lines of the following might make sense:
res, err := dbmap.Statement("show slave status")
if err != nil {
    // you know the drill
}
res.IgnoreMissing().Unmarshal(&slaveMeta)

Would that cover the edge case well enough for you?

I know that postgresql uses regular selects for metadata. That's why I singled out mysql, which has custom statements for much of the metadata where you cannot control the output.
Anyway, your suggestion would definitely work for me.

Hm, any updates for issue?


Change py.test to pytest.

This came up in #131, but it appears that PR was abandoned.  This should
bring us inline with upstream recommendations.

Hi @maltzj, thanks for the pull request. Before we can merge it, we need you to sign our Contributor License Agreement. You can do so electronically here: http://opensource.box.com/cla
Once you have signed, just add a comment to this pull request saying, "CLA signed". Thanks!

CLA signed

Verified that @maltzj has just signed the CLA. Thanks, and we look forward to your contribution.


Adding table of contents to main readme

Purpose

This PR adds a table of contents to the top level readme allowing the user to better navigate the documentation.
Will happily move it if you think it fits in a better spot in the readme! :)
Does this introduce a breaking change?

[ ] Yes
[x] No

Pull Request Type
What kind of change does this Pull Request introduce?

[ ] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[x] Documentation content changes
[ ] Other... Please describe:

thanks, this makes it a lot easier to read. It also points out that the second main heading is wrong (Azure Deployment Costs) it should just be Azure Deployment then Costs as a subheading. We'll fix that separately.

@tonybaloney I fixed that heading and did a bit more rearranging to get things in a logicalish order. Merging!


Add dependencies for ripping and labeling MP3s

Currently the automatic-ripping-machine Docker image cannot rip CDs to MP3 files.
[ERROR] abcde: lame is not in your path.
[INFO] Define the full path to the executable if it exists on your system.
[INFO] Hint: sudo apt-get install lame
[03-19-2023 15:53:31] ERROR ARM: Call to abcde failed with code: 1 (b'')
[03-19-2023 15:53:31] INFO ARM: Music rip failed.  See previous errors.  Exiting.

This commit installs dependencies for ripping MP3s and writing their ID3 and ID3v2 tags.

eyed3 was re-added so it appears once (eyeD3 was removed).  mp3gain doesn't exist in focal and was removed.

Merged! Thanks


Set the xhr.withCredentials flag after xhr.open()

Setting xhr.withCredentials = true before the xhr.open() call throws an InvalidStateError in IE10 (and possibly other browsers too). This behaviour is actually according to spec: http://www.w3.org/TR/XMLHttpRequest2/#the-withcredentials-attribute.
I can't see any reason for the try catch around it either (other than making it harder to spot errors), so I removed it too. I'm happy to bring it back if there are good reasons for it.

Can we get this merged? Won't work on IE10 otherwise.


assertion failed: !self.is_end() in Range::add_base_address

gcc 8.1.1 produces the following debuginfo in a file compiled with -gdwarf-5 -O2:
                ranges: 4 at .debug_rnglists offset 149 (0x00000095)
                        [ 0] <new base address 0x000017a7>
                        [ 1] <offset pair low-off: 0x00000000 addr 0x000017a7 high-off: 0x00000000 addr 0x000017a7>
                        [ 2] <offset pair low-off: 0x00000000 addr 0x000017a7 high-off: 0x00000003 addr 0x000017aa>
                        [ 3] <offset pair low-off: 0x00000005 addr 0x000017ac high-off: 0x00000008 addr 0x000017af>

Note that the first offset pair entry in the range list has a low and high of 0. This causes Range::is_end() to return true for that Range, which causes Range::add_base_address to fail the assertion in a debug build.
Such an entry seems pointless, but gcc releases are producing it and I need to handle it somehow.

I believe that 0,0 meaning "end" is only true for DWARF4 .debug_ranges. In DWARF5 the end-of-list entry has a dedicated representation DW_RLE_end_of_list.

I don't need to see them.


VelocyPackHelper::patchDouble issues SIGBUS on armv7h compilation.

Hi,
my environment running ArangoDB
I'm using the latest ArangoDB of the respective release series:

[x] 3.1
[ ] self-compiled devel branch

On this operating system:

[x] Linux
[x] other: Archlinux - armv7h

VelocyPackHelper::patchDouble issues SIGBUS on armv7h compilation:
leading to the arangod crash at startup on ArchLinux ARM.
Using gdb the problem can be pinpointed to the VelocyPackHelper::patchDouble method.
Thread 1 "arangod" received signal SIGBUS, Bus error.
0x00813c48 in arangodb::basics::VelocyPackHelper::patchDouble(arangodb::velocypack::Slice, double) ()
(gdb) bt
*#*0  0x00813c48 in arangodb::basics::VelocyPackHelper::patchDouble(arangodb::velocypack::Slice, double) ()
#1  0x003d0d8c in arangodb::aql::Query::executeV8(v8::Isolate, arangodb::aql::QueryRegistry) ()
*#*2  0x006b13a0 in ?? ()
*#*3  0x00cd1a00 in ?? ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
This is a custom compilation with the following flags:
CFLAGS=-march=armv7-a -mfloat-abi=hard -mfpu=vfpv3-d16 -O2 -pipe -fsigned-char -fstack-protector --param=ssp-buffer-size=4
CXXFLAGS=-march=armv7-a -mfloat-abi=hard -mfpu=vfpv3-d16 -O2 -pipe -fsigned-char -fstack-protector --param=ssp-buffer-size=4
I think the reinterpret_cast causes an alignment problem on the arm issuing the SIGBUS signal.
Txs

Confirmed. ARM does not support unaligned writes.

Fixed in the 3.1 and devel branches. Fix will be part of the next 3.1 release (3.1.1).

3.0.12 is available for download via the regular upgrade channels - closing.


Bug with using feat "War Caster" when triggered by subclass "Marshal"

SolastaUnfinishedBusiness Version : <IP_ADDRESS>
UserCampaign: https://steamcommunity.com/sharedfiles/filedetails/?id=2687348727
Description:

The game bug when using ranged reaction from the feat "War Caster" when it trigger by the subclass "Marshal" with "Coordinated Attack".

A step-by-step procedure to reproduce it:

Attack with "Za Roth"
Select a ranged reaction with "Pimelith" (Eldritch Blast)

yendor11.zip
Player.log
And there is climb issue on character "Pimelith"

@EnderWiggin, it's indeed not getting a rulesetSpellEffect.
changed title as climb issue isn't caused by mod but by custom location.

Hello @ThyWoof,
I don't know if it work as intented, but the spell use the current weapon as base.
If use a spell (Eldritch Blast) with a dagger equip i get a disaventage for long range attack.
No disaventage if i switch to a crossbow.

And by the way thank for the quick fix !


Pin to versions that work with v22.

Checklist

[x] Used a personal fork of the feedstock to propose changes
[x] Bumped the build number (if the version is unchanged)
[ ] Reset the build number to 0 (if the version changed)
[x] Re-rendered with the latest conda-smithy (Use the phrase @conda-forge-admin, please rerender in a comment in this PR for automated rerendering)
[x] Ensured the license file is being packaged.

Hi! This is the friendly automated conda-forge-linting service.
I just wanted to let you know that I linted all conda-recipes in your PR (recipe) and found it was in an excellent condition.

@conda-forge-admin, please rerender

The unpinned versions caused failures that were fixed in the source, but those fixes occurred after the releases for which this (historical) rubin-env version is to be used.


Added masters to the enrollment modes

This will be required for future analytics work.

Coverage remained the same at 100.0% when pulling 59b3a3475304eb50b8538339c2e5b0db83771542 on dcs/add-masters into d776bc34744c752f45db9723bc85fb2ee74f7d68 on master.


socket_can_bridge.launch.xml is not working if group tag is added

Normally, socket_can_bridge.launch.xml works correctly.
$ ros2 launch ros2_socketcan socket_can_bridge.launch.xml interface:=vcan0
[INFO] [launch]: All log files can be found below /home/kenji/.ros/log/2021-03-28-15-45-41-152424-desktop-1257792
[INFO] [launch]: Default logging verbosity is set to INFO
1616913941.225444 [19]       ros2: using network interface enp8s0 (udp/<IP_ADDRESS>) selected arbitrarily from: enp8s0, br-51dac8a7becc, docker0
[INFO] [socket_can_receiver_node_exe-1]: process started with pid [1257803]
[INFO] [socket_can_sender_node_exe-2]: process started with pid [1257805]
[socket_can_receiver_node_exe-1]<PHONE_NUMBER>.245093 [19] socket_can: using network interface enp8s0 (udp/<IP_ADDRESS>) selected arbitrarily from: enp8s0, br-51dac8a7becc, docker0
[socket_can_sender_node_exe-2]<PHONE_NUMBER>.245764 [19] socket_can: using network interface enp8s0 (udp/<IP_ADDRESS>) selected arbitrarily from: enp8s0, br-51dac8a7becc, docker0
[socket_can_receiver_node_exe-1] [INFO<PHONE_NUMBER>.249226146] [socket_can_receiver]: interface: vcan0
[socket_can_receiver_node_exe-1] [INFO<PHONE_NUMBER>.249265876] [socket_can_receiver]: interval(s): 0.010000
[socket_can_sender_node_exe-2] [INFO<PHONE_NUMBER>.249974288] [socket_can_sender]: interface: vcan0
[socket_can_sender_node_exe-2] [INFO<PHONE_NUMBER>.250025899] [socket_can_sender]: timeout(s): 0.010000

Or this is okay.
// test.launch.xml
<launch>
  <include file="$(find-pkg-share ros2_socketcan)/launch/socket_can_bridge.launch.xml">
    <arg name="interface" value="vcan0" />
  </include>
</launch>

$ ros2 launch ./test.launch.xml
(Same result)

However, if group tag is added, it doesn't work. auto_configure and auto_activate couldn't be resolved.
// test.launch.xml
<launch>
  <group>
    <include file="$(find-pkg-share ros2_socketcan)/launch/socket_can_bridge.launch.xml">
      <arg name="interface" value="vcan0" />
    </include>
  </group>
</launch>

$ ros2 launch ./test.launch.xml
[INFO] [launch]: All log files can be found below /home/kenji/.ros/log/2021-03-28-15-46-32-602952-desktop-1257993
[INFO] [launch]: Default logging verbosity is set to INFO
1616913992.678658 [19]       ros2: using network interface enp8s0 (udp/<IP_ADDRESS>) selected arbitrarily from: enp8s0, br-51dac8a7becc, docker0
[INFO] [socket_can_receiver_node_exe-1]: process started with pid [1258004]
[INFO] [socket_can_sender_node_exe-2]: process started with pid [1258006]
Task exception was never retrieved
future: <Task finished name='Task-7' coro=<LaunchService._process_one_event() done, defined at /opt/ros/foxy/lib/python3.8/site-packages/launch/launch_service.py:271> exception=SubstitutionFailure("launch configuration 'auto_configure' does not exist")>
Traceback (most recent call last):
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/launch_service.py", line 273, in _process_one_event
    await self.__process_event(next_event)
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/launch_service.py", line 293, in __process_event
    visit_all_entities_and_collect_futures(entity, self.__context))
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/utilities/visit_all_entities_and_collect_futures_impl.py", line 38, in visit_all_entities_and_collect_futures
    sub_entities = entity.visit(context)
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/action.py", line 106, in visit
    if self.__condition is None or self.__condition.evaluate(context):
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/condition.py", line 44, in evaluate
    return self._predicate(context)
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/conditions/if_condition.py", line 43, in _predicate_func
    return evaluate_condition_expression(context, self.__predicate_expression)
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/conditions/evaluate_condition_expression_impl.py", line 41, in evaluate_condition_expression
    expanded_expression = perform_substitutions(context, expression)
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/utilities/perform_substitutions_impl.py", line 26, in perform_substitutions
    return ''.join([context.perform_substitution(sub) for sub in subs])
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/utilities/perform_substitutions_impl.py", line 26, in <listcomp>
    return ''.join([context.perform_substitution(sub) for sub in subs])
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/launch_context.py", line 184, in perform_substitution
    return substitution.perform(self)
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/substitutions/launch_configuration.py", line 98, in perform
    raise SubstitutionFailure(
launch.substitutions.substitution_failure.SubstitutionFailure: launch configuration 'auto_configure' does not exist
Task exception was never retrieved
future: <Task finished name='Task-8' coro=<LaunchService._process_one_event() done, defined at /opt/ros/foxy/lib/python3.8/site-packages/launch/launch_service.py:271> exception=SubstitutionFailure("launch configuration 'auto_configure' does not exist")>
Traceback (most recent call last):
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/launch_service.py", line 273, in _process_one_event
    await self.__process_event(next_event)
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/launch_service.py", line 293, in __process_event
    visit_all_entities_and_collect_futures(entity, self.__context))
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/utilities/visit_all_entities_and_collect_futures_impl.py", line 38, in visit_all_entities_and_collect_futures
    sub_entities = entity.visit(context)
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/action.py", line 106, in visit
    if self.__condition is None or self.__condition.evaluate(context):
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/condition.py", line 44, in evaluate
    return self._predicate(context)
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/conditions/if_condition.py", line 43, in _predicate_func
    return evaluate_condition_expression(context, self.__predicate_expression)
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/conditions/evaluate_condition_expression_impl.py", line 41, in evaluate_condition_expression
    expanded_expression = perform_substitutions(context, expression)
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/utilities/perform_substitutions_impl.py", line 26, in perform_substitutions
    return ''.join([context.perform_substitution(sub) for sub in subs])
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/utilities/perform_substitutions_impl.py", line 26, in <listcomp>
    return ''.join([context.perform_substitution(sub) for sub in subs])
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/launch_context.py", line 184, in perform_substitution
    return substitution.perform(self)
  File "/opt/ros/foxy/lib/python3.8/site-packages/launch/substitutions/launch_configuration.py", line 98, in perform
    raise SubstitutionFailure(
launch.substitutions.substitution_failure.SubstitutionFailure: launch configuration 'auto_configure' does not exist
[socket_can_receiver_node_exe-1]<PHONE_NUMBER>.698730 [19] socket_can: using network interface enp8s0 (udp/<IP_ADDRESS>) selected arbitrarily from: enp8s0, br-51dac8a7becc, docker0
[socket_can_sender_node_exe-2]<PHONE_NUMBER>.699225 [19] socket_can: using network interface enp8s0 (udp/<IP_ADDRESS>) selected arbitrarily from: enp8s0, br-51dac8a7becc, docker0
[socket_can_receiver_node_exe-1] [INFO<PHONE_NUMBER>.701642017] [socket_can_receiver]: interface: vcan0
[socket_can_receiver_node_exe-1] [INFO<PHONE_NUMBER>.701682377] [socket_can_receiver]: interval(s): 0.010000
[socket_can_sender_node_exe-2] [INFO<PHONE_NUMBER>.704002656] [socket_can_sender]: interface: vcan0
[socket_can_sender_node_exe-2] [INFO<PHONE_NUMBER>.704059466] [socket_can_sender]: timeout(s): 0.010000

Just removing auto_configure and auto_activate can fix this problem, but I'll try to investigate in a bit more detail.

Probably related? https://github.com/ros2/launch_ros/issues/114


Add compile error for generic Main

This PR adds a compile error for a Main actor with type parameters.
closes #1936

What do you think about moving this check to the syntax_entity check in pass/syntax.c? There are some closely related checks there, such as enforcing that Main must be an actor, and enforcing that C API actors do not have type parameters.

@jemc seems reasonable, I'll try

@jemc the check has been moved to the syntax pass.

Thanks!
The appveyor CI failure was unrelated, so I'm merging.


Apple Silicon : macOS 14 - error: ANEProgramProcessRequestDirect()

Im running latest macOS 14 beta
Apple M1 Mini
16GB
Getting this error and crash if I try to generate something
/AppleInternal/Library/BuildRoots/1a7a4148-f669-11ed-9d56-f6357a1003e8/Library/Caches/com.apple.xbs/Sources/MetalPerformanceShadersGraph/mpsgraph/MetalPerformanceShadersGraph/Runtimes/MPSRuntime/Operations/GPUANERegionOps.mm:332: failed assertion `ANE Evaluation Error = Error Domain=com.apple.appleneuralengine Code=3 "processRequest:model:qos:qIndex:modelStringID:options:error:: ANEProgramProcessRequestDirect() Failed with status=0xf : statusType=0x9: Program Inference timeout: timed out" UserInfo={NSLocalizedDescription=processRequest:model:qos:qIndex:modelStringID:options:error:: ANEProgramProcessRequestDirect() Failed with status=0xf : statusType=0x9: Program Inference timeout: timed out}'
[2]    24037 abort      ./webui.sh
/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/multiprocessing/resource_tracker.py:224: UserWarning: resource_tracker: There appear to be 1 leaked semaphore objects to clean up at shutdown
warnings.warn('resource_tracker: There appear to be %d '
(--no-half) seems to work for now but im getting worse speeds with this enabled

The "leaked semaphore" seems to be a generic warning when python crashes because of memory issues.  The smaller print that you copied above that is the real error, but I'm in the dark as to what it means.

Hi @criskb, couple of notes:

I am unsure what you are referring to by --no-half, could you please clarify?
Looks like you are using a webui which is not a part of this repository. Are you able to reproduce using our Swift or Python CLIs?
Python 3.10 is not tested for this repo. I recommend 3.8 or 3.9 but I don't yet think this is related to your issue
"leaked semaphore" is also highly unlikely to be root cause of your issue

@atiorh Just edited the (webui-macos-env.sh) to contain --no-half under commandline_args

im using https://github.com/brkirch/stable-diffusion-webui fork but I was able to make this work on the main fork too

Automatic1111 does not use any of the CoreML python packages, so this is really the wrong place to be discussing this, but I have been using these command arguments for a while, with both the brkirch build and the main branch:
export COMMANDLINE_ARGS="--skip-torch-cuda-test --upcast-sampling --use-cpu interrogate --opt-sub-quad-attention --precision full --no-half-vae --disable-nan-check"
On my laptop, the generation speed running the current main branch is almost the same as using an efficient Swift app that does use CoreML.  Recently, the brkirch build has been running noticeably slower for me than the main branch.  It needs a new build, or perhaps all his newest optimizations are already merged into main and his experiments are finished.


convertFromRaw returns an Array of ContentBlocks not a ContentState

Hi there,
As documented here the function convertFromRaw should return a ContentState object.
However it returns an array of ContentBlock objects.
This works:
var data = '{"entityMap":{},"blocks":[{"key":"4oah6","text":"Dieser Test","type":"unstyled","depth":0,"inlineStyleRanges":[{"offset":7,"length":4,"style":"BOLD"},{"offset":0,"length":11,"style":"CODE"},{"offset":0,"length":6,"style":"ITALIC"}],"entityRanges":[]}]}'

var json = JSON.parse(data)

var blockArray = convertFromRaw(json);

var contentState = ContentState.createFromBlockArray(blockArray);

var editorState = EditorState.createWithContent(contentState);

However this throws an error:
var contentState = convertFromRaw(json);

var editorState = EditorState.createWithContent(contentState);

Error:

Is this a mistake in the docs or a bug?

Great catch. It's a mistake in the docs.

Ok, thanks... PR is in progress ;)

Hi there,
There is still mistake in the docs: https://facebook.github.io/draft-js/docs/api-reference-data-conversion.html#content
convertFromRaw(rawState: RawDraftContentState): ContentState

Where? Can't find it.

Here is a screenshot of this page: https://facebook.github.io/draft-js/docs/api-reference-data-conversion.html#content
I marked the mistake with the red rectangle

What do you think should be there?

From conversation above instead of ContentState there should be array of ContentBlocks

Ah, now I see. I had fixed this in PR.
However, it was changed it back by @hellendag here
This was because the return type has changed here.
In PR #333 it was discussed a bit.
So docs are correct.

Oh, thanks. I used a 0.5.0 version and it was returning an array of ContentBlocks, so I thought that there is a mistake in docs. Now, after I've updated to 0.6.0 it works fine.


Make types closer to semantics

Review of the types that are deserialized from JSON. Adjusted to be closer to Ink runtime's actual semantics.

Some fields of structs were Option but they weren't optional (an artefact of the port from C# nullable types?). This change required changing some constructors.
There wasn't any 'parent' enum variant for path fragments. Change allows cleanly matching on the fragment type, rather than comparing a string for equality to "^". (An explicit todo!() has been added to resolve_path, previously ^ would break anyway, because I think resolving parent not implemented anyway.)
Since original port was made, directional Glue has been removed from Ink, no longer G< and G>, just <>.

I also deleted unnecessary refs and borrows from the functions I was already changing — they aren't idiomatic Rust anymore.

There's a few compiler and test errors with the updated external args, but otherwise everything looks good and we can merge after they're fixed

That's embarrassing on my part. I've corrected the test cases that don't compile. One test case fails, which is the same one from #10.


Building and Signing a m-of-n transaction

I'm in the process of trying to create a transaction, and have multiple parties sign it. I'm fairly sure I'm just not doing something correct; But I have the following code; which generates a transaction; and I'm able to sign it; but it ends up not being a valid transaction.
I did remove the other private key signing, but it follows the same as the first.
/*
 * First Request
 */
//Build Wallet
$keys = array(
    HierarchicalKeyFactory::fromExtended("xpub661MyMwAqRbcGL2QoVnUfWuSrF9VM2MTvvCr6RrV8NWJRqYbxkmNULpGf1aHcjV7z7ownfg4hv5cr49FPd5TEUZeYRkbjPtsNniRHV34ufS"),
    HierarchicalKeyFactory::fromExtended("xpub661MyMwAqRbcEv4MBs7yVyrQWFxuqLgcAn8K6an8pyrLbqCWNfwDySDuEqWcEnUYU5ZPkRBHm4idyZw6fBt1xscEkbNNBMwK7pEmg3Ttv4k"),
    HierarchicalKeyFactory::fromExtended("xpub661MyMwAqRbcGL92A9hhGZc17vrf4UXdvg3syTCtxDnGP1jop8k3NS4nxKXmonVn1KFP5zfoqpJ4uSJDoyzbBYpYMpcCc7ZKwR3KH5ZWsJH")
);
$ecAdapter = Bitcoin::getEcAdapter();
$sequences = new HierarchicalKeySequence();
$masterWallet = new MultisigHD(2,'m',$keys,$sequences,true);
$transactionWallet = $masterWallet->derivePath("0/0");
echo "1) Funds Were Sent To: ".$transactionWallet->getAddress()->getAddress();
echo PHP_EOL;

//Build Transaction
$utx = array(
    'tx_hash' => 'db98592de692c251ef3c4c3336741e3236f791a9deb62851467d3fbd6191f52c',
    'tx_hash_le' => '2cf59161bd3f7d465128b6dea991f736321e7436334c3cef51c292e62d5998db',
    'tx_index' => 220648228,
    'tx_output_n' => 0,
    'script' => 'a9146e360babf021eb1886dc7478078a5aabbf403b6187',
    'value' => 0.00110000,
    'value_hex' => '01adb0',
    'confirmations' => 382
);
$txAddress = AddressFactory::fromString("1hMQLE6PokBcnfbS9f4FUia9DH4jKUtXQ");

$outPoint = new OutPoint(Buffer::hex($utx['tx_hash'],32),$utx['tx_output_n']);
$tx = (new TxBuilder())
    ->spendOutPoint($outPoint)
    ->PayToAddress(intval($utx['value']*100000000), $txAddress)
    ->get();

echo "2) Unsigned Transaction Hex: ".$tx->getHex();
echo PHP_EOL;

/*
 * Second Request
 */
// Sign Transaction 1
$keys2 = array(
    HierarchicalKeyFactory::fromExtended("xprv9s21ZrQH143K3qwwhUFUJNxiJDJzwZdcZhHFJ3Ssa2yKZ3DTRDT7vYVnohBS6yVBLjXAH4pncos2RWQAFWZCgL5itT23RX2CT4nyFFet5QH"),
    HierarchicalKeyFactory::fromExtended("xpub661MyMwAqRbcEv4MBs7yVyrQWFxuqLgcAn8K6an8pyrLbqCWNfwDySDuEqWcEnUYU5ZPkRBHm4idyZw6fBt1xscEkbNNBMwK7pEmg3Ttv4k"),
    HierarchicalKeyFactory::fromExtended("xpub661MyMwAqRbcGL92A9hhGZc17vrf4UXdvg3syTCtxDnGP1jop8k3NS4nxKXmonVn1KFP5zfoqpJ4uSJDoyzbBYpYMpcCc7ZKwR3KH5ZWsJH")
);
$tx2 = signTx($keys2, $tx, $utx);
echo "3) One Sig Transaction Hex: ".$tx2->getHex();
echo PHP_EOL;
echo "    Raw Script Hex: ".$tx2->getInputs()[0]->getScript()->getHex();
echo PHP_EOL;
echo "    Decoded Script: ".$tx2->getInputs()[0]->getScript()->getScriptParser()->getHumanReadable();
echo PHP_EOL;

$keys3 = array(
    HierarchicalKeyFactory::fromExtended("xpub661MyMwAqRbcGL2QoVnUfWuSrF9VM2MTvvCr6RrV8NWJRqYbxkmNULpGf1aHcjV7z7ownfg4hv5cr49FPd5TEUZeYRkbjPtsNniRHV34ufS"),
    HierarchicalKeyFactory::fromExtended("xprv......"),
    HierarchicalKeyFactory::fromExtended("xpub661MyMwAqRbcGL92A9hhGZc17vrf4UXdvg3syTCtxDnGP1jop8k3NS4nxKXmonVn1KFP5zfoqpJ4uSJDoyzbBYpYMpcCc7ZKwR3KH5ZWsJH")
);
$tx3 = signTx($keys3, $tx2, $utx);
echo "4) Two Sig Transaction Hex: ".$tx2->getHex();
echo PHP_EOL;
echo "    Raw Script Hex: ".$tx3->getInputs()[0]->getScript()->getHex();
echo PHP_EOL;
echo "    Decoded Script: ".$tx3->getInputs()[0]->getScript()->getScriptParser()->getHumanReadable();
echo PHP_EOL;

function signTx($keys, $tx, $utx){
    $ecAdapter = Bitcoin::getEcAdapter();
    $sequences = new HierarchicalKeySequence();

    $masterWallet = new MultisigHD(2,'m',$keys,$sequences,true);
    $transactionWallet = $masterWallet->derivePath("0/0");
    foreach($transactionWallet->getKeys() as $key){
        if(strpos(substr($key->toExtendedKey(),0,4),"xprv") !== false){
            $signingKey = $key->getPrivateKey();
        }
    }

    $txOut = new TransactionOutput($utx['value']*100000000, $transactionWallet->getRedeemScript());

    $signed = (new Signer($tx, $ecAdapter))
        ->sign(0,$signingKey,$txOut);
    $tx = $signed->get();
    return $tx;
}

Again, Please forgive my lack of knowledge on the subject, but hopefully you will be able to assist in resolving this and maybe it can become an example?

I think the problem is it's not setting the right script in $txOut in signTx, that's the redeemScript but you need to make a P2SH output script, and set it as the output script.
Your code should become:
$p2shScript = ScriptFactory::scriptPubKey()->p2sh($transactionWallet->getRedeemScript()->getScriptHash());
    $txOut = new TransactionOutput($utx['value']*100000000, $p2shScript);
    $signData = (new SignData())->p2sh($transactionWallet->getRedeemScript());
    $signed = (new Signer($tx, $ecAdapter))->sign(0,$signingKey,$txOut, $signData);

Submitting a PR now to expose a method on MultisigHD::getScriptPubKey(), and calling getRedeemScript() will return P2shScript - basically just a Script but decorated so the hash/address is cached, and you can call P2shScript::getOutputScript() there too (output script == scriptPubKey, sorry for inconsistency)

#472 should make this case easier going forward

Let me know if that got it working, happy to make this into an example

Worked prefect! Just had to change it from static code to dynamic and test. Thanks again!


:memo: add slack owner to all docs, updated review date

This PR adds owner_slack property to all our documentation pages.  This will allow us to receive review notifications in slack later.
This is a pre-requisite for #32  using "Daniel the Manual Spaniel🐶" to manage our documentation reviews!

🦴


Constant structs

Apache Thrift supports struct literals in the Thrift file.
For example,
struct Date {
    1: byte day
    2: byte month
    3: i16 year
}

const Date foo = {'day': 1, 'month': 1, 'year': 1234}

Generated Python code includes,
foo = Date(**{
  "day" : 1,
  "month" : 1,
  "year" : 1234,
})

Related uber/thriftrw#77