UI rs 2

Purpose

https://issues.folio.org/browse/UIRS-2
Approach

TODOS and Open Questions

Learning

Pre-Merge Checklist
Before merging this PR, please go through the following list and take appropriate actions.

[ ] I've added appropriate record to the CHANGELOG.md
Does this PR meet or exceed the expected quality standards?

[ ] Code coverage on new code is 80% or greater
[ ] Duplications on new code is 3% or less
[ ] There are no major code smells or security issues

Does this introduce breaking changes?

[ ] If any API-related changes - okapi interfaces and permissions are reviewed/changed correspondingly
[ ] There are no breaking changes in this PR.

If there are breaking changes, please STOP and consider the following:

What other modules will these changes impact?
Do JIRAs exist to update the impacted modules?

[ ] If not, please create them
[ ] Do they contain the appropriate level of detail?  Which endpoints/schemas changed, etc.
[ ] Do they have all they appropriate links to blocked/related issues?

Are the JIRAs under active development?

[ ] If not, contact the project's PO and make sure they're aware of the urgency.

Do PRs exist for these changes?

[ ] If so, have they been approved?

Ideally all of the PRs involved in breaking changes would be merged in the same day to avoid breaking the folio-testing environment.  Communication is paramount if that is to be achieved, especially as the number of intermodule and inter-team dependencies increase.
While it's helpful for reviewers to help identify potential problems, ensuring that it's safe to merge is ultimately the responsibility of the PR assignee.

yarn run v1.22.4
$ eslint .
/home/jenkins/workspace/olio-org_ui-remote-storage_PR-11/project/index copy.js
1:1   error  Filename 'index copy' must match the exported name 'Organization'  filenames/match-exported
6:23  error  Unable to resolve path to module './Addresses'                     import/no-unresolved
7:20  error  Unable to resolve path to module './Locale'                        import/no-unresolved
8:21  error  Unable to resolve path to module './Plugins'                       import/no-unresolved
9:22  error  Unable to resolve path to module './Bindings'                      import/no-unresolved
10:25  error  Unable to resolve path to module './SSOSettings'                   import/no-unresolved
11:30  error  Unable to resolve path to module './LocationCampuses'              import/no-unresolved
12:34  error  Unable to resolve path to module './LocationInstitutions'          import/no-unresolved
13:31  error  Unable to resolve path to module './LocationLibraries'             import/no-unresolved
14:31  error  Unable to resolve path to module './LocationLocations'             import/no-unresolved
15:27  error  Unable to resolve path to module './ServicePoints'                 import/no-unresolved
95:8   error  Missing trailing comma                                             comma-dangle
✖ 12 problems (12 errors, 0 warnings)
1 error and 0 warnings potentially fixable with the --fix option.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

yarn run v1.22.4
$ eslint .
/home/jenkins/workspace/olio-org_ui-remote-storage_PR-11/project/index copy.js
1:1   error  Filename 'index copy' must match the exported name 'Organization'  filenames/match-exported
6:23  error  Unable to resolve path to module './Addresses'                     import/no-unresolved
7:20  error  Unable to resolve path to module './Locale'                        import/no-unresolved
8:21  error  Unable to resolve path to module './Plugins'                       import/no-unresolved
9:22  error  Unable to resolve path to module './Bindings'                      import/no-unresolved
10:25  error  Unable to resolve path to module './SSOSettings'                   import/no-unresolved
11:30  error  Unable to resolve path to module './LocationCampuses'              import/no-unresolved
12:34  error  Unable to resolve path to module './LocationInstitutions'          import/no-unresolved
13:31  error  Unable to resolve path to module './LocationLibraries'             import/no-unresolved
14:31  error  Unable to resolve path to module './LocationLocations'             import/no-unresolved
15:27  error  Unable to resolve path to module './ServicePoints'                 import/no-unresolved
95:8   error  Missing trailing comma                                             comma-dangle
✖ 12 problems (12 errors, 0 warnings)
1 error and 0 warnings potentially fixable with the --fix option.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.


Wallet.Emulator.Folds.walletFees incorrectly computes fees for transactions that failed with missing UTxO error in Phase 2

Summary
The emulator fold Wallet.Emulator.Folds.walletFees incorrectly computes the fees from a faulty assumption that all transactions that fail in phase 2 will result in fees being charged. This is not the case for all transactions as seen below.
Steps to reproduce the behavior
Produce two transactions that race for the same UTxO. Using QuickCheck we found the following trace that results in walletFees telling us 20 lovelace was used in fees when the actual number is only 10 lovelace:
Prelude Test.QuickCheck Spec.Escrow Main> quickCheck . withMaxSuccess 100 $ prop_Escrow
/nix/store/hy3lz2vfv9qq2v5jz9nzlx6mmiaq79rj-binutils-2.35.1/bin/ld: warning: type and size of dynamic symbol `plutuszmledgerzm0zi1zi0zi0zminplace_LedgerziIndex_minAdaTxOut_closure' are not defined
*** Failed! Assertion failed (after 24 tests and 5 shrinks):
Actions
 [AnyRefund (Wallet d3eddd0d37989746b029a0e050386bc425363901) (Wallet 7ce812d7a4770bbf58004067665c3a48f28ddd58),
  Pay (Wallet d3eddd0d37989746b029a0e050386bc425363901) 29]
Expected funds of Wd3eddd0 to change by
  Value (Map [(,Map [("",-29000000)])])
but they changed by
  Value (Map [(,Map [("",-28999990)])])
Test failed.
Emulator log:
[INFO] Slot 0: TxnValidate ee3a44b98e0325e19bc6be1e6f25cdb269301666a3473758296e96cd7ea9a851
[INFO] Slot 1: 00000000-0000-4000-8000-000000000000 {Wallet W872c}:
                 Contract instance started
[INFO] Slot 1: 00000000-0000-4000-8000-000000000001 {Wallet W7ce8}:
                 Contract instance started
[INFO] Slot 1: 00000000-0000-4000-8000-000000000002 {Wallet Wc30e}:
                 Contract instance started
[INFO] Slot 1: 00000000-0000-4000-8000-000000000003 {Wallet W5f5a}:
                 Contract instance started
[INFO] Slot 1: 00000000-0000-4000-8000-000000000004 {Wallet Wd3ed}:
                 Contract instance started
[INFO] Slot 1: 00000000-0000-4000-8000-000000000004 {Wallet Wd3ed}:
                 Receive endpoint call on 'anyrefund-escrow' for Object (fromList [("contents",Array [Object (fromList [("getEndpointDescription",String "anyrefund-escrow")]),Object (fromList [("unEndpointValue",Object (fromList [("unPaymentPubKeyHash",Object (fromList [("getPubKeyHash",String "80a4f45b56b88d1139da23bc4c3c75ec6d32943c087f250b86193ca7")]))]))])]),("tag",String "ExposeEndpointResp")])
[INFO] Slot 1: Wd3eddd0: Balancing an unbalanced transaction:
                           Tx:
                             Tx 10011e49ebb9f8435aba2a6d53a82adce83afb896e6d9eabbcb353eda04f31e7:
                               {inputs:
                               collateral inputs:
                               outputs:
                               mint: Value (Map [])
                               fee: Value (Map [])
                               mps:
                               signatures:
                               validity range: Interval {ivFrom = LowerBound NegInf True, ivTo = UpperBound PosInf True}
                               data:}
                           Requires signatures:
                           Utxo index:
                           Validity range:
                             [ POSIXTime<PHONE_NUMBER>998 , +∞)
[INFO] Slot 1: Wd3eddd0: Finished balancing:
                           Tx f8b175e639e27f517052c8a1c2915174e26ee27145504fdb31451f2d2887857a:
                             {inputs:
                                - ee3a44b98e0325e19bc6be1e6f25cdb269301666a3473758296e96cd7ea9a851!7
                             collateral inputs:
                               - ee3a44b98e0325e19bc6be1e6f25cdb269301666a3473758296e96cd7ea9a851!7
                             outputs:
                               - Value (Map [(,Map [("",99999999999999990)])]) addressed to
                                 PubKeyCredential: bf342ddd3b1a6191d4ce936c92d29834d6879edf2849eaea84c827f8 (no staking credential)
                             mint: Value (Map [])
                             fee: Value (Map [(,Map [("",10)])])
                             mps:
                             signatures:
                               993684ab55aa4f999edb02c9cd1e730e91d785eccc0922db5d2aa805fde40f68
                             validity range: Interval {ivFrom = LowerBound (Finite (Slot {getSlot = 1})) False, ivTo = UpperBound PosInf True}
                             data:}
[INFO] Slot 1: Wd3eddd0: Submitting tx: f8b175e639e27f517052c8a1c2915174e26ee27145504fdb31451f2d2887857a
[INFO] Slot 1: Wd3eddd0: TxSubmit: f8b175e639e27f517052c8a1c2915174e26ee27145504fdb31451f2d2887857a
[INFO] Slot 2: 00000000-0000-4000-8000-000000000004 {Wallet Wd3ed}:
                 Receive endpoint call on 'pay-escrow' for Object (fromList [("contents",Array [Object (fromList [("getEndpointDescription",String "pay-escrow")]),Object (fromList [("unEndpointValue",Object (fromList [("getValue",Array [Array [Object (fromList [("unCurrencySymbol",String "")]),Array [Array [Object (fromList [("unTokenName",String "")]),Number 2.9e7]]]])]))])]),("tag",String "ExposeEndpointResp")])
[INFO] Slot 2: Wd3eddd0: Balancing an unbalanced transaction:
                           Tx:
                             Tx dab9bed6bface777ee4be812de7ec292e82241ae58f0fbc583994a806676e111:
                               {inputs:
                               collateral inputs:
                               outputs:
                                 - Value (Map [(,Map [("",29000000)])]) addressed to
                                   ScriptCredential: 5f0ea0cb1f3efccb057c221aac4e5670d965cb8cee44b678e5fee8be (no staking credential)
                               mint: Value (Map [])
                               fee: Value (Map [])
                               mps:
                               signatures:
                               validity range: Interval {ivFrom = LowerBound NegInf True, ivTo = UpperBound PosInf True}
                               data:
                                 "\191\&4-\221;\SUBa\145\212\206\147l\146\210\152\&4\214\135\158\223(I\234\234\132\200'\248"}
                           Requires signatures:
                           Utxo index:
                           Validity range:
                             [ POSIXTime 1 , POSIXTime<PHONE_NUMBER>000 ]
[INFO] Slot 2: Wd3eddd0: Finished balancing:
                           Tx d5d5c4862fc57ad9b91f8ae4962d5d64c2aabd7f1f44a66213595691b4dcb9bb:
                             {inputs:
                                - ee3a44b98e0325e19bc6be1e6f25cdb269301666a3473758296e96cd7ea9a851!7
                             collateral inputs:
                               - ee3a44b98e0325e19bc6be1e6f25cdb269301666a3473758296e96cd7ea9a851!7
                             outputs:
                               - Value (Map [(,Map [("",99999999970999990)])]) addressed to
                                 PubKeyCredential: bf342ddd3b1a6191d4ce936c92d29834d6879edf2849eaea84c827f8 (no staking credential)
                               - Value (Map [(,Map [("",29000000)])]) addressed to
                                 ScriptCredential: 5f0ea0cb1f3efccb057c221aac4e5670d965cb8cee44b678e5fee8be (no staking credential)
                             mint: Value (Map [])
                             fee: Value (Map [(,Map [("",10)])])
                             mps:
                             signatures:
                               993684ab55aa4f999edb02c9cd1e730e91d785eccc0922db5d2aa805fde40f68
                             validity range: Interval {ivFrom = LowerBound (Finite (Slot {getSlot = -1596059091})) False, ivTo = UpperBound (Finite (Slot {getSlot = 40})) False}
                             data:
                               "\191\&4-\221;\SUBa\145\212\206\147l\146\210\152\&4\214\135\158\223(I\234\234\132\200'\248"}
[INFO] Slot 2: Wd3eddd0: Submitting tx: d5d5c4862fc57ad9b91f8ae4962d5d64c2aabd7f1f44a66213595691b4dcb9bb
[INFO] Slot 2: Wd3eddd0: TxSubmit: d5d5c4862fc57ad9b91f8ae4962d5d64c2aabd7f1f44a66213595691b4dcb9bb
[INFO] Slot 2: TxnValidate d5d5c4862fc57ad9b91f8ae4962d5d64c2aabd7f1f44a66213595691b4dcb9bb
[WARNING] Slot 2: TxnValidationFail Phase2 f8b175e639e27f517052c8a1c2915174e26ee27145504fdb31451f2d2887857a: TxOutRefNotFound (TxOutRef {txOutRefId = ee3a44b98e0325e19bc6be1e6f25cdb269301666a3473758296e96cd7ea9a851, txOutRefIdx = 7})
[INFO] Slot 3: 00000000-0000-4000-8000-000000000005 {supercalifragilisticexpialidocious}:
                 Contract instance started
[INFO] Slot 3: 00000000-0000-4000-8000-000000000005 {supercalifragilisticexpialidocious}:
                 Receive endpoint call on 'register-token-env' for Object (fromList [("contents",Array [Object (fromList [("getEndpointDescription",String "register-token-env")]),Object (fromList [("unEndpointValue",Object (fromList [("0",Object (fromList [])),("1",Object (fromList []))]))])]),("tag",String "ExposeEndpointResp")])
[INFO] Slot 3: 00000000-0000-4000-8000-000000000005 {supercalifragilisticexpialidocious}:
                 Contract instance stopped (no errors)

Actual Result
We get 20 lovelace spent on fees.
Expected Result
10 lovelace spent on fees.
Describe the approach you would take to fix this
I think it's a case of adjusting walletFees, which currently computes its fees by summing up the fees of all good txs and all txs that fail in phase 2, to only pick "the right" transactions to accumulate fees from. I would do it myself but I don't know the exact rules the ledger uses to determine what Phase 2 failed transactions compute fees.
System info
Plutus: main at the time of writing - this code hasn't been touched in a while anyway so I suspect it's not sensitive to specific commits.

Closing as quickCheck . withMaxSuccess 100 $ prop_Escrow doesn't produce an error anymore. There were some changes in that function in commit https://github.com/input-output-hk/plutus-apps/commit/2bfeae00f8c1c5eec537088d6951568175956b4e


NoClassDefFoundError: jakarta/ws/rs/core/GenericType upgrading past 2.0.0

2.0.0 works fine, but upgrading to 2.1.0 or 2.2.0 throws ClassNotFoundException looking for jakarta.ws.rs.core.GenericType
new LogsApi(ApiClient
        .getDefaultApiClient()
        .setApiKey(x);

Hi,
Can you detail your environment a bit? What's your java version? Do you use maven? Which jars do you install? Thanks.

We're on Java 17, Maven 3.8.5. We are only explicitly installing datadog-api-client.

It's most likely an issue with the upgrade, as that dependency should have been upgraded when going from 2.0 to 2.1. Can you try bumping jakarta.ws.rs-api from jakarta.ws.rs?

Bumping jakarta.ws.rs-api to 3.1.0 leads to NoClassDefFoundError: javax/ws/rs/core/Configurable
2.3.0 has the same issue, fwiw.
For me, datadog-api-client is pulling in jersey 2.3.5, which pulls in jakarta.ws 2.1.6. This seems odd since 2.1.0 says it upgrades to jersey 3.x?

Right we do depend on jersey 3: https://github.com/DataDog/datadog-api-client-java/blob/ea8b6a39487d97336a5abffe25f60955c53c19f8/pom.xml#L625. It's weird that it's getting 2 in your environment.

encountered the same problem: in our spring-boot 2.7.4 app the property jersey.version gets set to 2.35 via spring-boot-dependencies. So i assume this is caused by an override for the maven property. When manually setting the jersey.version to 3.0.4 everything works fine, but is only a workaround because then the jersey version is pinned to that version.
@internetstaff are you also using spring-boot?

Same problem here.

same issue here

Can you try putting this in the pom:
<properties>
    <jersey-version>3.0.4</jersey-version>
</properties>

adding that gets me
Caused by: java.lang.NoClassDefFoundError: jakarta/ws/rs/core/Configuration

Oh okay: setting jersey-version does not fix it, but setting jersey.version works. So it it's not the property getting overriden, which would have been strange. It's the jersey-bom in dependencyManagment from spring-boot-dependencies:
  <dependencyManagement>
    ...
      <dependency>
        <groupId>org.glassfish.jersey</groupId>
        <artifactId>jersey-bom</artifactId>
        <version>${jersey.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
    ...
    </dependencyManagement>

and so by setting jersey.version the version is defined (defaults to 2.35 in spring-boot-deps).
output of mvn dependency:tree -Dverbose shows
...
[INFO] +- com.datadoghq:datadog-api-client:jar:2.3.0:compile
[INFO] |  +- jakarta.annotation:jakarta.annotation-api:jar:1.3.5:compile (version managed from 2.1.0; scope not updated to compile)
[INFO] |  +- org.glassfish.jersey.core:jersey-client:jar:2.35:compile (version managed from 3.0.4)
...

But I couldn't figure out a smart way of overriding the dependencyManagment version in datadog-api, even when setting it there (in dependencyManagment section) the transitive dependency from the parent is still preferred.

Does that mean that spring-boot depends on jersey-client 2? Can you try maybe using the shaded jar distribution of the client, as it should contain the correct version of the library?

Hello,
I have the same problem with datadog-api-client 2.5.0 and Spring Boot 2.7.6. It worked when I had version 2.0.0 and now I have this error:
Caused by: java.lang.ClassNotFoundException: com.datadog.api.client.ApiClient
	at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:641) ~[na:na]
	at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:188) ~[na:na]
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:520) ~[na:na]
	... 66 common frames omitted

And this is the code I'm using:
var apiClient = ApiClient.getDefaultApiClient()
                .setServerVariables(Map.of("site", "datadoghq.eu"))
                .setApiKey(datadogApiKey);
var metricsApi = new MetricsApi(apiClient);

Do you have any news about this?

Hi All,
I am facing couple of issues implementing Datadog custom metrics api
With datadog-api-client 2.4 version:
NoClassDefFoundError: javax/ws/rs/core/Configurable is thrown.
As per earlier comments when i tried to revert the datadog-api-client version 2.0, getting below error:
java.lang.NoSuchMethodError: 'void javax.ws.rs.core.MultivaluedMap.addAll(java.lang.Object, java.lang.Object[])'
at org.glassfish.jersey.client.ClientRequest.accept(ClientRequest.java:280)
at org.glassfish.jersey.client.JerseyInvocation$Builder.accept(JerseyInvocation.java:242)
at org.glassfish.jersey.client.JerseyInvocation$Builder.accept(JerseyInvocation.java:165)
Is there a workaround to fix it?
I am using Java 11 and it's a spring boot application.

Hello,
I have the same issue with datadog-api-client 2.6 and 2.7.
Java 11 + SpringBoot 2.5.8
Nicolas

Hi, I see new version of the Api was released, but this issue persist. Can someone look into that, or at least specify here which versions of Jakarta are required?

Same problem here even trying 2.10.0 but it throws the error since 2.1.0 onwards
Exception in thread "main" java.lang.NoClassDefFoundError: jakarta/ws/rs/client/InvocationCallback
	at com.dersuzala.movieme.MonitorCreatetExample.main(MonitorCreatetExample.java:15)
Caused by: java.lang.ClassNotFoundException: jakarta.ws.rs.client.InvocationCallback
	at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:641)
	at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:188)
	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
	... 1 more

Java19, SpringBoot 2.7.4
Any help?

Hi, have you tried the shaded jar artifact?

In looking at this issue, what would the shaded jar artifact configuration look like in Maven?

Getting the following error when trying to use DD-Agent v2.10. Tried adding Jakarta deps and using Java 19 and Spring Boot 2.7.4. ANy ideas?
Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.datadog.api.client.ApiClient]: Factory method 'datadogApiClient' threw exception; nested exception is java.lang.NoClassDefFoundError: javax/ws/rs/core/Configurable 11:43:07  	at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:185) ~[spring-beans-5.3.24.jar:5.3.24] 11:43:07  	at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:653) ~[spring-beans-5.3.24.jar:5.3.24] 11:43:07  	... 90 common frames omitted 11:43:07  Caused by: java.lang.NoClassDefFoundError: javax/ws/rs/core/Configurable 11:43:07  	at com.datadog.api.client.ApiClient.getDefaultClientConfig(ApiClient.java:1760) ~[datadog-api-client-2.10.0.jar:na] 11:43:07  	at com.datadog.api.client.ApiClient.buildHttpClient(ApiClient.java:1739) ~[datadog-api-client-2.10.0.jar:na] 11:43:07  	at com.datadog.api.client.ApiClient.<init>(ApiClient.java:521) ~[datadog-api-client-2.10.0.jar:na] 11:43:07  	at com.datadog.api.client.ApiClient.<init>(ApiClient.java:511) ~[datadog-api-client-2.10.0.jar:na] 11:43:07  	at com.datadog.api.client.ApiClient.getDefaultApiClient(ApiClient.java:475) ~[datadog-api-client-2.10.0.jar:na]

For anyone who finds this error, here is the solution:
    <dependency>       <groupId>com.datadoghq</groupId>       <artifactId>datadog-api-client</artifactId>       <version>2.10.0</version>       <classifier>shaded-jar</classifier>       <scope>compile</scope>     </dependency>


[MODUSERS-421] - Disable username uniqueness validation for system users

Purpose
Describe the purpose of the pull request.
Approach
How does this change fulfill the purpose?
TODOS and Open Questions

[ ] Use GitHub checklists. When solved, check the box and explain the answer.

Learning
Describe the research stage. Add links to blog posts, patterns, libraries or addons used to solve this problem.

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.


Add a license to the repository

I recently came across your project Qiskit and I noticed that the repository github.com/alejomonbar/Qiskit currently does not have a license specified.
Why Adding a License is Important?
As GitHub documents

Public repositories on GitHub are often used to share open source software. For your repository to truly be open source, you'll need to license it so that others are free to use, change, and distribute the software.

Would be possible to add a valid license to this repository? Probably something really OpenSource such as the Apache 2.0 license would fit really well.
Thanks!

Thanks


add setter to attribute radius to make it modifiable

In hillshade.py we can encounter an error at self.radius = optimal_radius.
In object-oriented programming language as python, setting a new value to a private class attribute (decorator @property) is possible if the attribute has a setter defined (decorator @attr.setter). As self.radius is the only attribute which is modified in peculiar cases, we never encountered this error before.
After testing this solution I encounter no more error

Indeed it is a lot more simple !


Revert "[CherryPick r2.4]Disable test for macos."

Reverts tensorflow/tensorflow#44398
Testing if this causes the memory issue (very unliekly)

Not the culprit, closing,


Enable RescueModifier cop

For discussion.
Followup to https://github.com/capistrano/capistrano/pull/1594

Good catch, fixed.

I think this is a case in point that inline rescue is a bad idea. :+1:


[WasmPlugin Integration Test] RegistryRedirector: Relax the authentication for blob retrieval

Not requires the authentication for the blob retrieval to re-use this in Remote Wasm Loading via HTTP.
Because the OCI registry is using HTTP for retrieval of each blobs, we can share the uploaded Wasm Image for testing HTTP as well.
For the details, please refer to the discussion starting with https://github.com/istio/istio/pull/39225#issuecomment-1144207752

@ingwonsong: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name
Commit
Details
Required
Rerun command

integ-security-multicluster_istio
eba0b0cf8b5825db2a40f2c7b56f457c5f3b35e8
link
true
/test integ-security-multicluster_istio

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

/retest

/test integ-security-multicluster_istio


No Flip V10 PF2E

Hi,
I find that I am unable to flip my tokens in V10.
More specifically, I am on Pathfinder 2E v4.0.6 and Foundry v10.285 with Fast Flip 3.0.0
I have tried using both the keybinds and the buttons when you have a token selected. Neither of these work.
The AFK button works though.
I have tried this module in my current game and a new game I created to test if there was some weird conflict with my other modules and in both games I am unable to flip my tokens.

Hi,
I was able to confirm that this is indeed broken in PF2e, but the problem doesn't seem to be on Fast Flip's side.  While testing this I was unable to reproduce any errors and I also tried using the Mirror Token check boxes in the token's settings under Appearance, and it also had no effect.

This is likely an issue with the PF2e system itself.

Alright, thank you very much for the update. I honestly didn't think to check the mirror image buttons as I had gotten so used to Fast Flip. I guess I'll just have to wait and hope the issue to resolve itself or leave a message with their team asking about the mirror feature.

Hi again, within the last 24 hours, Pathfinder 2nd Edition updated to V4.1.0. which fixed the mirror image function.
I re-enabled Fast-Flip which now works - sorta. Fast-Flip now allows me to mirror my tokens both horizontally and vertically but clicking the Flip button a second time does not return the token to its original position.
(I can flip the token once each way but I cannot flip it back to its original position.)

Thanks for the update! Since I'm in process of converting my own campaigns
over to PF2e I'll take a deeper look at this and see what I can do.
On Wed, Sep 21, 2022 at 12:00 PM InstantZzz @.***>
wrote:

Hi again, within the last 24 hours, Pathfinder 2nd Edition updated to
V4.1.0. which fixed the mirror image function.
I re-enabled Fast-Flip which now works - sorta. Fast-Flip now allows me to
mirror my tokens both horizontally and vertically but clicking the Flip
button a second time does not return the token to its original position.
(I can flip the token once each way but I cannot flip it back to its
original position.)
—
Reply to this email directly, view it on GitHub
https://github.com/Mr-Byte/fast-flip/issues/7#issuecomment-1254107474,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AARWWOVV7CZ7ZQUXD5P34Q3V7NLN5ANCNFSM6AAAAAAQNZ4NQY
.
You are receiving this because you commented.Message ID:
@.***>

Hi there, I've released v3.1.0 which should fix this for you.  I've tested this multiple times using the latest PF2e and I'm unable to reproduce this at this time.


Use viewset.layout  in the detail view

https://gitter.im/viewflow/django-material

Jose Juan Tapia @jjtapia 02:47
Another question. I noticed that the default view contains a simple enumeration of the model fields from a given entry
like so: http://forms.viewflow.io/integration/sea/11/detail/
while the change option contained the layout defined in views.py: http://forms.viewflow.io/integration/sea/11/change/
is there a way of making this change layout the default that is shown in .../detail?

I'm working on this but my approach needs that you have to pass form_class to DetailView and then rewrite all the templates in material/fields in order to only print the label and the value. What do you think? Could be useful for you?
cheers!

Yeah, that's the hard question.
To have reasonable looking good detail view by default is the nice feature, but anyway it's supposed to be overridden in real projects. So it won't be good if the solution for this optional feature would overcomplicate the other part of the codebase.
Currently the layout primitives Row/Column/Fieldset are too bound to the form rendering. From another side, getting a text representation for a model value is hard without a widget. So, there is no simple way to reuse a layout without form instance. But I don't think that the detail view should look exactly like a form but with all widgets disabled. That's is too crudy.
Your approach looks reasonable, as implementing a template pack that renders a form in a read-only state, without actually do the tricks on a python side.
{% form template='material/readonly/form.html' %}

This would be the really useful feature, in many scenarios beyond the frontend.detail view.
It looks that only a few templates could be overridden. django-material lookup for the template according to a class inheritance mro. So the material/readonly/fields/django_widget.html is the catch-all template.
django-material have some code to get a field value for the list view. You can take a look what django have  in django.contrib.admin.utils.display_for_field and django.contrib.admin.utils.display_for_value and what placed in the  material.frontend.views.list.DataTableMixin.display_for_field
We can move display_for_field code to the utility module and expose it as a template tag to use it in a widget generic template. If it isn't enough, few templates for a Select/FK could also be added.

Hi,

But I don't think that the detail view should look exactly like a form but with all widgets disabled.

Absolutely agree, thats why I want to replace every field template with non-form elements (inputs, radios, etc).
Take a look at the PoC:
https://github.com/APSL/django-material/commit/789fd1b1225cbf2c2f356ab093375e00c0865f70
This is that's look like:
form:

detail:

{% form template='' %} sets the base path for the whole template_pack.  So basicly, there is possibility to write {% form template='bootstrap/form.html' %} to render a boostrap styled form with django-material _
Check the template selection code, it chooses most specific template for the widget. If the template pack would contain a single fields/django_widget.html file, it would be selected for all form fields.

{% form template='' %} sets the base path for the whole template_pack. So, there is possibility to write {% form template='bootstrap/form.html' %} to render a boostrap styled form with django-material =)

cool!

Check the template selection code; it chooses the most specific template for the widget. If the template pack contains a single fields/django_widget.html file, the template would be selected for all form fields.

Are you sure about that? For an input field, it drops me the following:
template_names
Out[2]:
['material/frontend/detail/fields/django_textinput.html',
 'material/frontend/detail/fields/django_input.html',
 'material/frontend/detail/fields/django_charfield/django_textinput.html',
 'material/frontend/detail/fields/django_charfield/django_input.html']

ups, that's b/c we have  -2 here
It could be simply adjusted to -1

Yeah, it worked. Thanks

Several material-design samples of the detail view


#1110 removed unused dependencies

Signed-off-by: initard<EMAIL_ADDRESS>Proposed changes
removed unused dependencies.
cargo +nightly udeps --all-targets now says:
All deps seem to have been used.

Types of changes

[x] Improvement (general improvements like code refactoring that doesn't explicitly fix a bug or add any new functionality)

Paste Link to the issue

Closes #1110

Checklist

[x] I have read the CONTRIBUTING doc
[x] I have signed the CLA (in all commits with git commit -s)

Further comments

Nice addition. Something worth adding to our CI pipeline along with cargo fmt and clippy runs, to prevent unused dependencies getting added in future. But, need not be in this PR.

This commit caused the integration test compilation failure due to lacking crates. See this. https://github.com/thin-edge/thin-edge.io/runs/6323052371?check_suite_focus=true
I will revert.


Fix examples for docsite

Alaska Airlines Pull Request
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.
Fixes: #154
Summary:
Please summarize the scope of the changes you have submitted, what the intent of the work is and anything that describes the before/after state of the project.

Implement changes to the example js code in order for them to be able to work properly on the docsite
Fix removal of invisible screenreader label

Type of change:
Please delete options that are not relevant.

[ ] New capability
[x] Revision of an existing capability
[ ] Infrastructure change (automation, etc.)
[ ] Other (please elaborate)

Checklist:

[x] My update follows the CONTRIBUTING guidelines of this project
[x] I have performed a self-review of my own update

By submitting this Pull Request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
Pull Requests will be evaluated by their quality of update and whether it is consistent with the goals and values of this project. Any submission is to be considered a conversation between the submitter and the maintainers of this project and may require changes to your submission.
Thank you for your submission!
-- Auro Design System Team

:tada: This PR is included in version 2.8.3 :tada:
The release is available on:

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


[BUG] Networking between longhorn-csi-plugin and longhorn-manager is broken after upgrading Longhorn to 1.7.0-rc3

Describe the bug
This issue came out the troubleshooting with @bk201, @Vicente-Cheng, @starbops, and myself at the thread https://suse.slack.com/archives/C02DR3N5T24/p1723085198729569
With network policy enabled, networking between longhorn-csi-plugin and longhorn-manager is broken after upgrading Longhorn to 1.7.0-rc3
To Reproduce

Install Longhorn 1.6.2 with network policy enabled (A.K.A set this field to true)
Upgrade Longhorn to 1.7.0-rc3 (still with networking policy enable)
See that many CSI pod stuck in crash loop. Noticeably, longhorn-csi-plugin pods crashes repeatedly because it cannot reach out to longhorn-backend service:time="2024-08-08T02:46:10Z" level=info msg="CSI Driver: driver.longhorn.io version: v1.7.0-rc3, manager URL http://longhorn-backend:9500/v1" func="csi.(*Manager).Run" file="manager.go:23"
time="2024-08-08T02:46:20Z" level=fatal msg="Error starting CSI manager: Failed to initialize Longhorn API client: Get \"http://longhorn-backend:9500/v1\": context deadline exceeded (Client
.Timeout exceeded while awaiting headers)" func=app.CSICommand.func1 file="csi.go:37"

Further notice that longhorn-csi-plugin pod cannot ping longhorn-manager pod on different node but can ping the longhorn-manager pod on the same node

Expected behavior
Networking between longhorn-csi-plugin and longhorn-manager is not broken
Environment

Kubernetes distro (e.g. RKE/K3s/EKS/OpenShift) and version: v1.28.11+rke2r1

Number of control plane nodes in the cluster: 1
Number of worker nodes in the cluster: 3

Update:
Narrowed it down to the problematic network policy:
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
  annotations:
    meta.helm.sh/release-name: longhorn
    meta.helm.sh/release-namespace: longhorn-system
  labels:
    app.kubernetes.io/managed-by: Helm
  name: longhorn-manager
  namespace: longhorn-system
spec:
  ingress:
    - from:
        - podSelector:
            matchLabels:
              app: longhorn-manager
        - podSelector:
            matchLabels:
              app: longhorn-ui
        - podSelector:
            matchLabels:
              app: longhorn-csi-plugin
        - podSelector:
            matchExpressions:
              - key: recurring-job.longhorn.io
                operator: Exists
            matchLabels:
              longhorn.io/managed-by: longhorn-manager
        - podSelector:
            matchExpressions:
              - key: longhorn.io/job-task
                operator: Exists
        - podSelector:
            matchLabels:
              app: longhorn-driver-deployer
  podSelector:
    matchLabels:
      app: longhorn-manager
  policyTypes:
    - Ingress

If we remove all network policies. Then deploy this one, then longhorn-csi-plugin cannot reach longhorn-manager on other nodes. This is very weird because this longhorn-manager network policy specifically allow network between longhorn-csi-plugin and longhorn-manager. Not sure why network is being blocked like this

Simpler reproducing:

Install longhorn 1.7.0-rc3
Deploy the network policy:apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
  name: longhorn-manager
  namespace: longhorn-system
spec:
  ingress:
    - from:
        - podSelector:
            matchLabels:
              app: longhorn-manager
        - podSelector:
            matchLabels:
              app: longhorn-ui
        - podSelector:
            matchLabels:
              app: longhorn-csi-plugin
        - podSelector:
            matchExpressions:
              - key: recurring-job.longhorn.io
                operator: Exists
            matchLabels:
              longhorn.io/managed-by: longhorn-manager
        - podSelector:
            matchExpressions:
              - key: longhorn.io/job-task
                operator: Exists
        - podSelector:
            matchLabels:
              app: longhorn-driver-deployer
  podSelector:
    matchLabels:
      app: longhorn-manager
  policyTypes:
    - Ingress

See the longhorn-csi-plugin cannot ping longhorn-manager on different node.
This not happening in longhorn v1.6.2

Update:
It looks like the issue is related to the CSI plugin pods in 1.7.0-rc3 using host network and they have the same IP with the host. This might cause the network policy to be broken

Referencing this commit https://github.com/longhorn/longhorn-manager/commit/1cca4ca83d0d375f1fc925d46aa7d133bb3f6101#diff-d4f309d528674353f3e6e803a8b0653e5e8c19913fa5de4af1414795bb3a53d4R281-R282 which change the CSI plugin to use host network and DNSClusterFirstWithHostNet
cc @c3y1huang

Investigating the possible fix
The HostNetwork: true change in CSI plugin daemonset seems to be a refactor so that we can mount the NFS mount within host network namespace without having to specify HostPID: true and mounting the host proc for CSI plugin pod: ref https://github.com/c3y1huang/longhorn/blob/b431f9a64783b99049fbc185163be17a089399cc/enhancements/20240522-storage-network-for-rwx-volumes.md#:~:text=Currently%2C the CSI,storage network configured.
However, that refactor does have negative effect as shown in this ticket, so I am thinking if we should revert back to the previous implementation of specifying HostPID: true and mounting the host proc for CSI plugin pod. cc @c3y1huang @ejweber

Reverting to the original implementation using nsenter with HostPID breaks storage network support for RWX volumes. This is because the CSI plugin pod need to be aware of the Multus network, which also means the NFS client mount must recognize the Multus network.

@c3y1huang What do you think about When RWX storage network is enabled, we mount NFS in the container namespace. When it is not we mount the NFS in host name space by nsenter the host namespace ref code https://github.com/longhorn/longhorn-manager/pull/3064/files#diff-e3208de2b41b1544cc85ea18e65fb55e847951129cdeee7db877af639c08e584 ?

Test Plane
Deploy longhorn with networkPolicies enabled
Case 1: Networking

Exec into each longhorn-csi-plugin pod, e.g., kubectl exec -it longhorn-csi-plugin-tkkj5 -c longhorn-csi-plugin -n longhorn-system -- bin/bash
Make sure that you can ping every longhorn-manager pod

Case 2: Regular RWX volume without RWX storage network

Deploy this RWX deployment
Exec into one of the workload pod and verify that you can read/write to the Longhorn PVC
Delete all longhorn-csi-plugin pod and wait for them to be terminated/recreated
Make sure that none of the RWX workload pod is restarted
Exec into one of the workload pod and verify that you can read/write to the Longhorn PVC

Case 3: Regular RWX volume with RWX storage network enabled

Repeat this test https://github.com/longhorn/longhorn-tests/pull/1931
Repeat this test https://github.com/longhorn/longhorn-tests/pull/1914
Repeat this test https://github.com/longhorn/longhorn-tests/pull/1921

Case 4: RWO volume

Deploy a workload using Longhorn RWO PVC
Exec into the workload pod and verify that you can read/write to the Longhorn PVC
Delete all longhorn-csi-plugin pod and wait for them to be terminated/recreated
Make sure that the workload pod is not restarted
Exec into one of the workload pod and verify that you can read/write to the Longhorn PVC

Verified on master-head 20240815

longhorn master-head https://github.com/longhorn/longhorn/commit/721c076647471205a7820569458e68ef471aa51a
longhorn-manager master-head https://github.com/longhorn/longhorn-manager/commit/470213508633a57934d0b6fa8fb75b16ca91b088

Verified on v1.7.x-head 20240815

longhorn v1.7.x-head https://github.com/longhorn/longhorn/commit/61908a1b5afb845b2c5c3e2c4376f02c4dcf5d29
longhorn-manager v1.7.x-head https://github.com/longhorn/longhorn-manager/commit/553e3b9f2dc5c5b610404ea0669c26817933a2e0

The test steps
https://github.com/longhorn/longhorn/issues/9223#issuecomment-2287014612
Result Passed

[x] Case 1: Networking
[x] Case 2: Regular RWX volume without RWX storage network
[x] Case 3: Regular RWX volume with RWX storage network enabled

[x] 1. Repeat this test https://github.com/longhorn/longhorn-tests/pull/1931
[x] 2. Repeat this test https://github.com/longhorn/longhorn-tests/pull/1914
[x] 3. Repeat this test https://github.com/longhorn/longhorn-tests/pull/1921

[x] Case 4: RWO volume
[x] Case 5: Block volume
[x] Case 6: Encrypted volume
[x] Case 7: Mitigrable volume


Implement ::allocate and nil methods

Skipped NilClass#to_c, #to_r, and #rationalize because they require Complex and Rational
Ported mspec's SpecVersion

This is great work. The PR itself is kinda all over the place... in the future, it would help with PR review if you could keep it to a single logical change...
The change of default encoding on StringObject has me really scratching my head, so I'm hoping we can put that back to UTF8.

 That was a bit of work, so I'll let you do that next time @FnControlOption. :stuck_out_tongue:

I rebased this against master and merged each 'SQUASHME' commit with the commit it accompanied. That was a bit of work, so I'll let you do that next time @FnControlOption. :stuck_out_tongue:


Update hello_world.R

Pull Request Type
What kind of change does this PR introduce?
[x] Solved an issue/task
New behavior - I just added Hello World! program in R
Other information

Please review and merged it.

Merged

This is an automated message from Fork, Commit, Merge [BOT].

Thank you for your contribution! Your pull request has been merged. The files have been reset for the next contributor.
What's next?
If you're looking for more ways to contribute, I invite you to check out my other projects. Just click here to find more. These projects contain real issues that you can help resolve. You can also check out the Influences section in the README to find more projects similar to this one.
Also please leave a star to this project if you feel it helped you, i would really appreciate it.
I look forward to seeing your contributions!


DDS DataWriter write

Change write method to follow the standard
Add unit test for the preconditions check

This branch is over PR #1155, so it need to be merged after

Build status:

Linux
Mac
Windows

Build status:

Linux
Mac
Windows

Build status:

Linux
Mac
Windows

Build status:

Linux
Mac
Windows


Background trigger for web

We can use the page visibility API to trigger background persistence on web when the tab is minimized 🎉

Yep! Considered that, but I excluded it because it encourages data loss.
On React Native, in nearly all scenarios, an app will transition to the
background before it terminates, and usually remains in the background
state for several seconds before termination, giving it opportunity to
persist. (This is even true if the user manually terminates the app via the
app switcher, because the app transitions to the 'inactive' state and
persists as soon as the app switcher is activated. As long as the user
isn't super fast — or the phone, super slow — persistence generally
completes before the app is swiped and closed.) The only case where
background persistence is likely to lose data in RN is if the app crashes,
but if your app is crashing, you have other reasons to fix it.
The web is a different beast. On the web, it is typical for users to close
a tab without first transitioning that tab to the background. I thought to
handle this edge case by hooking onbeforeunload, however the async nature
of the persistence means that it is likely not to complete before the tab's
VM is halted.
I don't view this as a huge loss for the web, because performance was my
motivation for background persistence on RN. In an ideal world, we'd
persist instantly after every write, but persisting blocks the UI thread on
RN and can do so for several hundred milliseconds. The web is generally
much faster here (it can JIT, and marshalling the serialized store doesn't
block the UI), so I think it's safe and reasonable to only offer the write
trigger with a configurable debounce interval.
On Dec 4, 2017 9:12 AM, "Peggy Rayzis"<EMAIL_ADDRESS>wrote:
We can use the page visibility API
https://developer.mozilla.org/en-US/docs/Web/API/Page_Visibility_API to
trigger background persistence on web when the tab is minimized 🎉
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/jamesreggio/apollo-cache-persist/issues/1, or mute the
thread
https://github.com/notifications/unsubscribe-auth/AAyLvWUf5JvS1pgJOH_E2oigPu_l124gks5s8_3SgaJpZM4Q0tjP
.

Your reasoning makes sense to me! I'm down to hold off on this unless enough people request it, but it seems like it won't be needed.


Some questions from the paper

Hi Xingang, could I ask some questions about the SCNN?

What is spatial cross entropy loss in training mentioned in paper?
Are labels pixel level segmentation of the same size as input image?
Currently I am doing lane segmentation using a network with some conv layers and then some deconv layers. Should I insert SCNN right after conv layers and before deconv layers?

Thanks!

Check this https://pytorch.org/docs/stable/nn.html#crossentropyloss
Yes.
I haven't try this, and its hard to say. I would recommend inserting SCNN right after conv layers, since this would save computations.

@XingangPan Thank you. I think the link you provided in question 1 is explanation for a normal cross entropy loss, but what is the difference between "spatial cross entropy loss" and "cross entropy loss"? Those two terms are in Fig. 5 in your paper.

@XingangPan One more question please... Have you tested the inference time of SCNN with VGG or Resnet? Is time you reported in Table 6 "SCNN_DULR: 42ms" is only for the SCNN part, or the full segmentation task?

@xiaoshuliu spatial cross entropy loss is to apply cross entropy loss for each spatial location.
The time reported is only for the SCNN part.

Hi, I would like to ask you some questions about model structure and implementation code. I have read the implementation of LargeFOV here: https://github.com/DrSleep/tensorflow-deeplab-lfov/blob/master/deeplab_lfov/model.py

In their implementation, they added 2 more CONV layers (and dropout also) after the original VGG model. However, I could not find these extra layers in your implementation, but they are available in the tensorflow implementation of this author: https://github.com/cardwing/Codes-for-Lane-Detection/blob/master/SCNN-Tensorflow/lane-detection-model/encoder_decoder_model/vgg_encoder.py
So could you explain to me about the difference between these implementations? If I misunderstand your paper at some points, please help me to get it right.
Thank you for considering my question here.

My implementation and  https://github.com/cardwing/Codes-for-Lane-Detection/blob/master/SCNN-Tensorflow/lane-detection-model/encoder_decoder_model/vgg_encoder.py are the same.
If you print the provided vgg.t7 model, you would get:

In (43)(4) we use 128 channels in order to save memory.
(44) is another branch to classify the existence of lane markings, as discussed in the paper.
From (1) to (43), there are 16 layers as in the original VGG16.

@XingangPan thank you for your clear explanation.  Due to I am not familiar with torch/lua (I mostly work with tensorflow), I could not find out the part where you put the layer (43) at the first read. Then I will try to read it again.
Thank you again for a brilliant work.


Added fix for version bug that disabled iTunes validation

This cause an app to not be validated when sent to AppStore. Don't really know if this is the case but the target framework was 7.0 and after changing it to 8.0 as the error suggested it worked.

I believe this is obsolete


Error message on complete

E5108: Error executing lua ...vim/site/pack/packer/opt/nvim-compe/lua/compe/source.lua:63: attempt to index local 'state' (a nil value)

@yech1990 require"compe"._complete is private function. Why do you using that?
And I can't reproduce it.
You should provide more detailed information if you hope to solve it.

Thank you @hrsh7th, this message appear when there is not complete choice.
I post my configuration on github, could me help me to check it out at link: https://github.com/yech1990/myneovim.lua

@yech1990 Thank you for your information. But this problem already solved, I think.
Could you test with latest master?

Your configuration seems good.

Thank you for your help. I will test the lastest release now and let you
know if I have any questions.
On Tue, Feb 23, 2021, 12:32 PM hrsh7th<EMAIL_ADDRESS>wrote:

@yech1990 https://github.com/yech1990 Thank you for your information.
But this problem already solved, I think.
Could you test with latest master?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/hrsh7th/nvim-compe/issues/201#issuecomment-783869836,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABJKEVU3NS7R2SLUYILHACTTAMVWRANCNFSM4YBFW5HQ
.

Hi @hrsh7th,
I'm sorry to have disturbed you. I still have a small problem in using nvim-compe. source.spell has been set to be true in my configuration, but I still can not get the [Spell] complete from nvim-compe plugin.

@yech1990 You should set set spell in your vimrc to enable spell source.

Hi hrsh7th, I wonder is there a way to enable Spell source without enabling spell check in vim?

https://user-images.githubusercontent.com/5415510/108808505-bb930d00-75e1-11eb-9ab3-ff1e9bff5980.mp4

I don't know. the spell source uses spellsuggest function that vim's builtin-function.


MSID: 95371 Version: 2 DOI: 10.1101/2<IP_ADDRESS>4432

MSID: 95371
Version: 2
Preprint DOI: https://doi.org/10.1101/2<IP_ADDRESS>4432
Step 1. Awaiting reviews
Editorial to post reviews via hypothesis
Useful links:

DocMap: https://data-hub-api.elifesciences.org/enhanced-preprints/docmaps/v2/by-publisher/elife/get-by-manuscript-id?manuscript_id=95371
New model tracking: https://docs.google.com/spreadsheets/d/1_fHaoOy7hjyocptKtVJRijeNpUY4hBS7Ck_aVmx6ZJk/
Reviews on sciety: https://sciety.org/articles/activity/10.1101/2<IP_ADDRESS>4432

For trouble shooting (e.g. no Docmaps available):

DocMap issue addressing: https://miro.com/app/board/uXjVNCwK6EI=/
Explore DataHub DocMaps API: https://lookerstudio.google.com/reporting/4c2f0368-babb-4beb-b5b3-497e7e7b0f08/page/ejphD
Unmatched submissions and preprints: https://lookerstudio.google.com/u/0/reporting/9f86204f-3bf7-477c-9b18-5c5ef141bf69/page/p_gxi57ha93c
Unmatched manuscripts spreadsheet: https://docs.google.com/spreadsheets/d/15QcK8w-ssB7109RQEDtFpJPZ0J5HTGxoHa_2TtpMBbg/edit#gid=1336081641

Step 2. Preview reviewed preprint
Production QC content ahead of publication
Instructions:

QC preview: https://prod--epp.elifesciences.org/previews/95371v2
Update ticket with any problems (add blocked label)
When QC OK, add QC OK label to ticket and add publication date and time to https://docs.google.com/spreadsheets/d/1amAlKvdLcaDp5W8Z8g77NmkwbMF5n_u89ArSqPMO8jg
Move card to next column
(At end of the day post link in #enhanced-preprint and ask for PDF to be generated)

Useful links:

Preprint DOI :  https://doi.org/10.1101/2<IP_ADDRESS>4432
Confirm reviews returned by EPP: https://prod--epp.elifesciences.org/api/reviewed-preprints/95371/v2/reviews
To update the MECA path in the docmap: https://docs.google.com/spreadsheets/d/1mctCQuNFBjSn97Lihy7_vBO6z7-N-oqyLv4clyi6zHg

Step 3: Awaiting search reindex
This step adds the reviewed preprint to the homepage: https://elifesciences.org
The search reindex is triggered once an hour. We need the reviewed preprint to be indexed as the search application serves the journal homepage.
Useful links:

Jenkins pipeline to reindex search can be triggered sooner or monitored here: https://alfred.elifesciences.org/job/process/job/process-reindex-reviewed-preprints/

Step 4: Published! PDF requested
Waiting for PDF to be generated
Useful links:

PDF tracking: https://docs.google.com/spreadsheets/d/106_XeDjmuBae7gexOTNzg60lapeqjl2aRn9DzupGyS8/

Step 5: Introduce PDF to data folder and git repo
Upload PDF to relevent folder in git repo https://github.com/elifesciences/enhanced-preprints-data/
Step 6: Done!

[ ] Kettle is on!

Hi @acollings, By any chance is this also wrong in eJP? I think these details are taken directly from there, so if we updated in eJP it might (eventually) update here too:

Going to proceed in the meantime with this one

Hi @fred-atherden yep, I've corrected eJP!

Thanks!


Added source_url and thumbnail fields to Metadata and Requester ID can be optionally stored in Trackhandle

Some useful changes to Metadata and Trackhandle.

Metadata: Added source_url and thumbnail fields and additional changes to from_ytdl_output fn.
Trackhandle: Added requester field to optionally store requester UserId and additional changes to few function to allow optional entry of the UserId while playing or enqueuing source.

Hi Saanu, thanks for the pull request.
The metadata changes are fine, sensible, and useful. Those look good to me.
I disagree with the requester IDs change, though. This seems to be very queue-specific functionality, and has a large API surface impact (i.e., users who don't care about queues now have an extra field added to all their method calls). I think that it's reasonable to expect that devs keep track of this themselves until something like #17 is cleanly implemented/solved. The reason why it should wait for something like this is that the requester ID is metadata, in a sense -- but it shouldn't affect anyone who isn't using the demo queue. The library is more general-purpose than that.
In future, please try to keep separate feature additions as separate PRs where possible! :)

That makes sense. I have reverted Requester ID changes in Tracks.
Until #17 this can be implemented what if the requester field is added to metadata, which can be easily mutated if wanted?

I think the requester field steps over the line from "intrinsic metadata" (i.e., data about the input itself) to something more use-specific, so I would say not for now.


Binary Literals and Beautiful Literate Programming

Support for binary literals (where, say, 0b100 is like 0x04, as is the case in Ruby, Python, and in a different way Erlang).
Implements issue jashkenas/coffee-script#1780 non-invasively (which I believe @jashkenas will like) with a single test case, which basically just checks that binary literals are understood as would be integers. And it passes.
It also implements issue jashkenas/coffee-script#1786 which is to consider all .literatecoffee files as literate code. Very literate; and beautiful.

You need to split these commits onto separate branches so they can be reviewed individually. Closing.


Chinese words will overlap together

English words perform normally under the same configuration.

Here is my code, most of them come from example code.
// use random data for now
var frequencies = new Dictionary<string, int>
{
    { "游戏剪辑", 10 },
    { "宗教仪式", 5 },
    { "鬼畜", 8 },
    { "IKUN", 3 },
    { "Vtuber", 6 },
    { "原神", 7 },
    { "米哈游", 4 },
    { "B站", 9 },
    { "哔哩哔哩", 2 },
    { "UP主", 1 }
};

var wordEntries = frequencies.Select(p => new WordCloudEntry(p.Key, p.Value));
var wordCloudInput = new WordCloudInput(wordEntries)
{
    Width = 256,
    Height = 64,
    MinFontSize = 2,
    MaxFontSize = 8
};
var sizer = new LogSizer(wordCloudInput);
using var engine = new SkGraphicEngine(sizer, wordCloudInput);
var layout = new SpiralLayout(wordCloudInput);
var colorizer = new RandomColorizer();
wordCloudGenerator = new WordCloudGenerator<SKBitmap>(wordCloudInput, engine, layout, colorizer);
wordCloudItems = wordCloudGenerator.Arrange();

Hi, thanks for reporting this issue.
I've just tried on Linux, installed fonts-arphic-ukai so I have a font capable of displaying Chinese characters, ran the example with font AR PL UKai CN specified, and I'm getting a nice result like:

Can you clarify which font you are using?
My full code:
var freqs = new Dictionary<string, int>() {
    { "游戏剪辑", 10 },
    { "宗教仪式", 5 },
    { "鬼畜", 8 },
    { "IKUN", 3 },
    { "Vtuber", 6 },
    { "原神", 7 },
    { "米哈游", 4 },
    { "B站", 9 },
    { "哔哩哔哩", 2 },
    { "UP主", 1 },
};

// Generate topic cloud.
const int k = 4; // scale
var wordCloud = new WordCloudInput(
freqs.Select(p => new WordCloudEntry(p.Key, p.Value)))
{
    Width = 1024 * k,
    Height = 256 * k,
    MinFontSize = 8 * k,
    MaxFontSize = 32 * k
};
var sizer = new LogSizer(wordCloud);
var typeFace = SKTypeface.FromFamilyName("AR PL UKai CN", SKFontStyle.Normal);
using var engine = new SkGraphicEngine(sizer, wordCloud, typeFace);
var layout = new SpiralLayout(wordCloud);
var colorizer = new RandomColorizer();
var wcg = new WordCloudGenerator<SKBitmap>(wordCloud, engine, layout, colorizer);

// Draw the bitmap on white background.
using var final = new SKBitmap(wordCloud.Width, wordCloud.Height);
using var canvas = new SKCanvas(final);
canvas.Clear(SKColors.White);
using var bitmap = wcg.Draw();
canvas.DrawBitmap(bitmap, 0, 0);

// Save to PNG.
using var data = final.Encode(SKEncodedImageFormat.Png, 100);
using var writer = new FileInfo("output.png").Create();
data.SaveTo(writer);

Thanks for reply! I'm using blazor wasm on dotnet 8. Runnning on Edge browser, Windows 11. I didn't set the font family, but I guess it may be "YaHei" by default.
I find it strange that this bug may occur when measuring the size of the font, but the font can actually be displayed normally.

Try specifying the font family explicitly (like I did in the code posted above). I'm not sure how you are rendering the result, via SVG? If so, you might need to specify the font family there as well. During the arrange phase the font needs to be the same as during rendering for everything to match.

Specifying a TypeFace solved my problem. Thanks.


[Bloc] Already consumed events should stay consumed

Consider the following element with two click handlers that are added independently by tools:
BlElement new
   when: BlClickEvent do: [ :anEvent | anEvent consumed: true ];
   when: BlClickEvent do: [ :anEvent | anEvent consumed: false ]

One would expect the click event to be consumed and to not be propagated to the parent element. However, as it turned out, it is sometimes consumed, sometimes not, depending on the random order of announcements, basically with ~50% chance.
This is an inconsistency.

BlEvent>>#consumed: keeps consumed events marked as consumed.


[backport] document arithmetic special functions

Backport of #4495

@kmaehashi thanks for pointing that out. I'll create a new PR since changing the base from GitHub wasn't very successful.


Missing Windows ARM64 support

I was setting up my new Glasgow, and as I went to build the demo, I discovered that this package doesn't have a Windows AARCH64 build.
Looking deeper, I found a few upstream issues that are blocking forward motion. Unfortunately, I'm not familiar with unwinding in Rust to be able to help. Once wasmtime has Windows on ARM64 support, it'd be swell to get wasmtime-py support for the platform.

Thanks for the report! Support upstream is indeed required first, so this'll be blocked on the issues you linked.


-iu flag slows down closest command significantly

I'm trying to identify the closest regions in my target file which are downstream, on the same strand, and do not overlap those in my query file. In addition, I want to report the distance. I'm using the following command:
bedtools closest -a reads.bed -b regions.bed -s -io -iu -D a > reads.closest.regions.bed

Both the reads.bed and regions.bed files have ~20 million records. When I run this command it runs without error, but has still not finished ~ 2 hours later. When I run variations of this command, they only take ~5-10 minutes:
time bedtools closest -a reads.bed -b regions.bed -s > /dev/null
real	9m5.165s
user	8m57.597s
sys	0m6.920s

time bedtools closest -a reads.bed -b regions.bed -s -io > /dev/null
real	5m25.619s
user	5m21.876s
sys	0m3.191s

time bedtools closest -a reads.bed -b regions.bed -s -io -D a > /dev/null
real	5m40.379s
user	5m36.784s
sys	0m3.019s

I've tried to make sure my BED file is correct by using bedops error checking:
bedops --ec --everything reads.bed 1> /dev/null
bedops --ec --everything regions.bed 1> /dev/null

Does ignoring records upstream of the query record via the -iu flag introduce this much slow down or is this a possible bug? I'm using bedtools v2.24.0.

Hi James,
The good news is that, since you definitely want the downstream hits, you can use the -fd option ("Force Downstream"), which will consider the downstream hits first. I'm fairly sure that should get you better performance.
 The bad news is that I'm no longer with the lab, and Aaron's dealing with a lot of other stuff right now, so I don't know when this can be properly debugged and fixed. But below are some suggestions to whoever looks at it (me, him, or someone else):

In src/utile/NewChromsweep/CloseSweep.cpp:
Change line 404 from:
if (totalHitsUsed < _kClosest && !overlaps->empty()) {
to
if (!_context->ignoreOverlaps() && totalHitsUsed < _kClosest && !overlaps->empty()) {
Similarly, change line 430 from:
if (upDist < downDist || (tie && tieMode != ContextClosest::LAST_TIE)) {
to
if (!_context->ignoreUpstream() && (upDist < downDist || (tie && tieMode != ContextClosest::LAST_TIE))) {
and likewise line 435 from:
if (downDist < upDist || (tie && tieMode != ContextClosest::FIRST_TIE)) {
to
if (!_context->ignoreDownstream() && (downDist < upDist || (tie && tieMode != ContextClosest::FIRST_TIE))) {

Hi James,
Once we get a breather from the current onslaught (likely mid August), we will dig into this to find the source of the slowdown.  Thanks very much for reporting this.

Looking at this now. I'm able to reproduce the error in the latest repository with 2 files each of 100K reads only on chr1 (generated by the bedtools random tool). I suspect even smaller files will show it as well.
$ ~/bedtools/bugs/bug268$ time ~/bedtools/workspace/bt2-release/bin/bedtools closest -a a100K.txt -b b100K.txt -s -io -D a > /dev/null
real	0m0.192s
user	0m0.176s
sys	0m0.016s
$ ~/bedtools/bugs/bug268$ time ~/bedtools/workspace/bt2-release/bin/bedtools closest -a a100K.txt -b b100K.txt -s -io -D a -iu > /dev/null
(doesn't finish after several minutes.)

This is "mostly fixed" in pull request #294. What I mean is that I established that -iu was running very slow only when used with -s and -S. This is now fixed.
But there was a similar undiscovered problem that -id would also run slow if used with -s or -S. I fixed that also, but only with -D ref. If using -D a or -D b with -id and -s or -S, it will still be slow. Aaron, I'll shoot you a mail with more details.

Ok, pull request #294 now fixes all the slowdowns I know of / can think of, meaning all combinations of:
-D (ref, a , or b) / -s or -S / -iu or -id.
We're good to go.

Terrific, thanks for working on this issue.


fix bug: deserialization of chinese encoding characters in xml is incorrect

Describe what this PR does / why we need it

nacos config center 中配置xml，包含中文字符。
app启动参数配置了-Dfile.encoding=gb18030时，启动报错。
当-Dfile.encoding=utf-8时，启动正常。

Does this pull request fix one issue?

NONE
Describe how you did it
在 NacosDataParserHandler 中引入 encode 字段
Describe how to verify it
复现

在配置中心新建一个config.xml，内容为

中文

项目启动参数配置：-Dfile.encoding=gb18030
增加配置项：spring.cloud.nacos.config.encode=gb18030
注意：这里配置utf-8也会报错

Special notes for reviews
目前我没想到有更好的方法修复它，你们可以自己探索其它的方法。这个问题值得关注一下。

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.


Add vscode workspace files to .gitignore

(by default these are stored in .vs/ or .vscode/, which I recommend as otherwise you'll end up with other random files in your root dir like launch.json/etc)

Oh... OK.

Sorry, hadn't seen you had still approved.  OK, i'll merge that then.

Yeah still fine to exclude, just heads up that you may have an easier time without it in the root :)


Training

Can you share the trainning code please ?

+1

Can you share the trainning code please ?


Proposal: how many machines are attacking at the same time

not implementable without centralizing the software
We can add analytics, but we will never do that, because security of users is also important

How about some indications of how mant URL are being attacted pr minut/hour/day from local mashine?

not implementable without centralizing the software We can add analytics, but we will never do that, because security of users is also important

"without centralizing the software" - to the top. Decentralized software is a key for many aspects.

The local statistic was successfully implemented. Global statistic is very hard to implement. We are connected to IT Army and they tried to do this but were instantly DDoSed. https://itarmy.com.ua/check/


Official Docker Builds

What behavior of the library made you think about the improvement?
Users, including me, have their own bespoke Docker containers and build workflows. There are a few unofficial images on the hub https://hub.docker.com/search?q=outlines&sort=updated_at&order=desc&type=image
How would you like it to behave?
Users should use a trusted official image. This will allow quick integration of Outlines into their project.
A new image should be built with every merge via CI.

Do you have examples of libraries providing a Docker image?

Yes, this is specifically for vLLM serving.
example with vLLM:

https://github.com/vllm-project/vllm/blob/main/Dockerfile
https://hub.docker.com/r/vllm/vllm-openai

I think it would be great if users could get up and running immediately with outlines + vLLM through an official Docker image.

I think we should hold off for now, and see what happens on the vLLM side. It's fine if users create their own Docker image, but adding one in the repo adds maintenance overhead.

Re-opening this, I am open to adding an official Docker build. We can start with adding a Dockerfile and take it from there.


ImportError with home-assistant v. >= 0.88.0

Error loading custom_components.media_player.alexa. Make sure all dependencies are installed
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/homeassistant/loader.py", line 147, in _load_file
    module = importlib.import_module(path)
  File "/usr/local/lib/python3.7/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1006, in _gcd_import
  File "<frozen importlib._bootstrap>", line 983, in _find_and_load
  File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 677, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 728, in exec_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "/config/custom_components/media_player/alexa.py", line 16, in <module>
    from homeassistant.components.media_player import (
ImportError: cannot import name 'MEDIA_TYPE_MUSIC' from 'homeassistant.components.media_player' (/usr/local/lib/python3.7/site-packages/homeassistant/components/media_player/__init__.py)

Report
Caused by change in package bundling:
Note for custom component developers: We are moving to a new file structure. Platforms now live embedded in components. Custom platforms will have to be updated to follow this pattern. This is a breaking change in case your custom platform overrides a built-in platform. Rename your custom platform from, ie light/hue.py to hue/light.py.

This was also addressed by #75, but I didn't realize it was submitted and will use #77 to close since it has the version increment. Thanks to @akinomeroglu for his effort.

Is there a outlook when a fixed version for 0.88.0 will be available? Release date for HA 0.88.0 is today
https://rc--home-assistant-docs.netlify.com/

@Obicom When it's actually live.

Ok, that sound good ... I understand you are prepared ... (y)

Is there anything to do with the new alexa.py for HA 0.88.0 or only exchange the file?

Just replace the file for 0.88.0.  For later version of HA, they may require you rename the file and move it from media_player/alexa.py to alexa/media_player.py.  This is not a long term solution though as a later version of HA will break. The problem is HA plans to prevent partial modifications of existing components and would require a complete override.  When that happens, 1.x.y should be the main code.

Thank you for explanation ...

Just replace the file for 0.88.0. For later versions of HA, they may require you rename the file and move it from media_player/alexa.py to alexa/media_player.py. This is not a long term solution though as a later version of HA will break. The problem is HA plans to prevent partial modifications of existing components and would require a complete override. When that happens, 1.x.y should be the main code.

hi, can i alreddy change the folder to "alexa/media_player.py" or will that not work now?
//Regards

@chali272 It will work for now, but will break in some point in the future.

@chali272 It will work for now, but will break in some point in the future.

ok thank you. Does this support multiple account yet?  (like to ad my kids accounts)  //Regards


Unlimited line length

Is there a way to set the max_line_length to be unlimited?
Currently, even if the max_line_length is undefined. The code will get reformated to 120 chars long. I can obsviously just set this value super high, but I would rather not have a limit at all.

set max_line_length=unset but it mean length = 998

Would there be any way for it to actually just not check for the line length at all?

Currently no, and the line width is intended to have no performance impact, my algorithm is very fast, and the current style check does not check the line width


Do not change atext on failure of task importDatatToStage

[oereb_einzelschutz_denkmal] Do not change atext on failure of task importDatatToStage

Resolves #141


HDDS-8317. [Snapshot] DirectoryDeletingService should clean up Snapshot's deletedDirTable.

What changes were proposed in this pull request?
Clean up deletedDirTable of the snapshot in SnapshotDeletingService

Move common functions between SnapshotDeletingService and DirectoryDeletingService to AbstractKeyDeletingService
Add support for snapshots in OMDirectoriesPurgeResponseWithFSO and OMDirectoriesPurgeRequestWithFSO.
Added support to move directories from the current snapshot to the next snapshot in OMSnapshotMoveDeletedKeysRequest and OMSnapshotMoveDeletedKeysResponse

What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-8317
How was this patch tested?
Existing unit tests and CI

Thanks for the review @smengcl. We can use this JIRA for SDS test. I will add some tests to this PR for DirectoryDeletingService to ensure it doesn't break anything on its code path if snapshot is present.


Refactoring OC Mirror deployment to Helm Chart

What this PR does
Jira:
Link to demo recording:
Special notes for your reviewer

i was just having a look at the github action job flow. i think the  build_push_imagesync and build_push_ocmirror steps need to run before deploy_to_service_cluster step. can you add them to the needs list of deploy_to_service_cluster


Cannot compile device_calendar on Android with last version 0.10.2 of flutter

Hi,
I cannot run my program with Flutter v0.10.2. I get :
D:\dev\tools\flutter\.pub-cache\hosted\pub.dartlang.org\device_calendar-0.0.6\android\src\main\kotlin\com\builttoroam\devicecalendar\DeviceCalendarPlugin.kt: (82, 50): Type mismatch: inferred type is String? but String was expected
e: D:\dev\tools\flutter\.pub-cache\hosted\pub.dartlang.org\device_calendar-0.0.6\android\src\main\kotlin\com\builttoroam\devicecalendar\DeviceCalendarPlugin.kt: (92, 35): Type mismatch: inferred type is String? but String was expected
e: D:\dev\tools\flutter\.pub-cache\hosted\pub.dartlang.org\device_calendar-0.0.6\android\src\main\kotlin\com\builttoroam\devicecalendar\DeviceCalendarPlugin.kt: (96, 31): Type mismatch: inferred type is Long? but Long was expected
e: D:\dev\tools\flutter\.pub-cache\hosted\pub.dartlang.org\device_calendar-0.0.6\android\src\main\kotlin\com\builttoroam\devicecalendar\DeviceCalendarPlugin.kt: (97, 29): Type mismatch: inferred type is Long? but Long was expected
e: D:\dev\tools\flutter\.pub-cache\hosted\pub.dartlang.org\device_calendar-0.0.6\android\src\main\kotlin\com\builttoroam\devicecalendar\DeviceCalendarPlugin.kt: (99, 55): Type mismatch: inferred type is String? but String was expected
e: D:\dev\tools\flutter\.pub-cache\hosted\pub.dartlang.org\device_calendar-0.0.6\android\src\main\kotlin\com\builttoroam\devicecalendar\DeviceCalendarPlugin.kt: (105, 47): Type mismatch: inferred type is String? but String was expected
e: D:\dev\tools\flutter\.pub-cache\hosted\pub.dartlang.org\device_calendar-0.0.6\android\src\main\kotlin\com\builttoroam\devicecalendar\DeviceCalendarPlugin.kt: (105, 59): Type mismatch: inferred type is String? but String was expected

> flutter doctor -v
[√] Flutter (Channel beta, v0.10.2, on Microsoft Windows [version 10.0.16299.726], locale fr-FR)
    • Flutter version 0.10.2 at D:\dev\tools\flutter
    • Framework revision d8cbb80206 (12 days ago), 2018-10-26 01:30:21 -0400
    • Engine revision 6c2ade9fa2
    • Dart version 2.1.0-dev.8.0.flutter-bf26f760b1

[√] Android toolchain - develop for Android devices (Android SDK 28.0.2)
    • Android SDK at C:\Users\...\AppData\Local\Android\sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-28, build-tools 28.0.2
    • Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1024-b02)
    • All Android licenses accepted.

[√] Android Studio (version 3.1)
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin version 28.0.1
    • Dart plugin version 173.4700
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1024-b02)

[√] VS Code, 64-bit edition (version 1.28.2)
    • VS Code at C:\Program Files\Microsoft VS Code
    • Flutter extension version 2.20.0

[√] Connected device (1 available)
    • Android SDK built for x86 • emulator-5554 • android-x86 • Android 9 (API 28) (emulator)

Thanks for your help

Exactly same issue here :(

Figured it out. Following fixes the issue.
Replacing things in the said files in following way solves the issue:
for cases where error is:
Type mismatch: inferred type is String? but String was expected
Changing String references to ?:"", which just means if variable is null then return "" (blank)
From:
_calendarDelegate.retrieveEvents(calendarId, startDate, endDate, eventIds, result)   //line (82,50)
To:
_calendarDelegate.retrieveEvents(calendarId?:"", startDate, endDate, eventIds, result)   //line (82,50)
And for cases where error is:
Type mismatch: inferred type is Long? but Long was expected
Changing Long references to ?:0L, which just means if variable is null then return 0L (Zero of type Long)
from
event.start = eventStart   //Line (96,31)
to
event.start = eventStart?:0L   //Line (96,31)

PR #69 by @huzhiren should fix this issue. Closing this issue. Feel free to re-open if this is still an issue


support ligatures

Please support ligatures.

Seems that the support has been added. Check here: https://github.com/sunflowerdeath/webfonts-generator/issues/13
However we are still missing a new release of this package. Latest npm release was 5 months ago.

@sunflowerdeath or @moimael can we please get this published?

I made it a bit configurable with my pull-request: #59 We are using my fork in our project more than one year.


[std.experimental.logger] please add LogLevel.debug

singingbush reported this on 2018-05-13T12:37:23Z
Transfered from https://issues.dlang.org/show_bug.cgi?id=18856
CC List

atila.neves (@atilaneves)

Description
it would be helpful if the standard logger supported LogLevel.debug, it would make it easier to hook in to vibe.core.log

https://github.com/mysql-d/mysql-native/issues/113
https://github.com/vibe-d/vibe.d/issues/1530

atila.neves (@atilaneves) commented on 2022-07-18T14:13:01Z
I think here vibe.d should cater to the standard library, and not the other way around.

dfj1esp02 commented on 2018-05-16T12:53:51Z
`debug` is a keyword and can't be used for an identifier, I suppose LogLevel.trace serves the purpose of debug log level.


ERROR: ThreadSanitizer: SEGV on unknown address

Description
cd ~/Downloads/json-develop/build/tests/Debug
for x in ./test-* ; do ./$x 1> /dev/null  || echo $x ; done
./test-cbor_cpp11
==36891==ERROR: ThreadSanitizer: requested allocation size 0xffffffffffffffff exceeds maximum supported size of 0x10000000000
#0 operator new(unsigned long)  (libclang_rt.tsan_osx_dynamic.dylib:x86_64h+0x7596b)
#1 void* std::__1::__libcpp_operator_new(unsigned long) new:235 (test-cbor_cpp11:x86_64+0x10004abc4)
==36891==HINT: if you don't care about these errors you may set allocator_may_return_null=1
SUMMARY: ThreadSanitizer: allocation-size-too-big (libclang_rt.tsan_osx_dynamic.dylib:x86_64h+0x7596b) in operator new(unsigned long)
Abort trap: 6
./test-cbor_cpp11
./test-testsuites_cpp11
ThreadSanitizer:DEADLYSIGNAL
==36941==ERROR: ThreadSanitizer: SEGV on unknown address 0x60000005d000 (pc 0x7ff80f562adb bp 0x7ff7b5762f10 sp 0x7ff7b5762f00 T6880876)
==36941==The signal is caused by a READ memory access.
#0 flockfile :197228464 (libsystem_c.dylib:x86_64+0x12ada)
#1 fgetc :197228464 (libsystem_c.dylib:x86_64+0x3382e)
#2 nlohmann::detail::file_input_adapter::get_character() input_adapters.hpp:56 (test-testsuites_cpp11:x86_64+0x100044ca7)
#3 nlohmann::detail::lexer<nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >, nlohmann::detail::file_input_adapter>::get() lexer.hpp:1341 (test-testsuites_cpp11:x86_64+0x100044b0b)
#4 nlohmann::detail::lexer<nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >, nlohmann::detail::file_input_adapter>::skip_bom() lexer.hpp:1480 (test-testsuites_cpp11:x86_64+0x100042db8)
#5 nlohmann::detail::lexer<nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >, nlohmann::detail::file_input_adapter>::scan() lexer.hpp:1504 (test-testsuites_cpp11:x86_64+0x100042997)
#6 nlohmann::detail::parser<nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >, nlohmann::detail::file_input_adapter>::get_token() parser.hpp:456 (test-testsuites_cpp11:x86_64+0x1000427cc)
#7 nlohmann::detail::parser<nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >, nlohmann::detail::file_input_adapter>::parser(nlohmann::detail::file_input_adapter&&, std::__1::function<bool (int, nlohmann::detail::parse_event_t, nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >&)>, bool, bool) parser.hpp:73 (test-testsuites_cpp11:x86_64+0x100042738)
#8 nlohmann::detail::parser<nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >, nlohmann::detail::file_input_adapter>::parser(nlohmann::detail::file_input_adapter&&, std::__1::function<bool (int, nlohmann::detail::parse_event_t, nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >&)>, bool, bool) parser.hpp:71 (test-testsuites_cpp11:x86_64+0x1000426ac)
#9 nlohmann::detail::parser<nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >, nlohmann::detail::file_input_adapter> nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >::parsernlohmann::detail::file_input_adapter(nlohmann::detail::file_input_adapter, std::__1::function<bool (int, nlohmann::detail::parse_event_t, nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >&)>, bool, bool) json.hpp:169 (test-testsuites_cpp11:x86_64+0x100041e9d)
#10 nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > > nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >::parse<__sFILE*>(__sFILE*&&, std::__1::function<bool (int, nlohmann::detail::parse_event_t, nlohmann::basic_json<std::__1::map, std::__1::vector, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, bool, long long, unsigned long long, double, std::__1::allocator, nlohmann::adl_serializer, std::__1::vector<unsigned char, std::__1::allocator > >&)>, bool, bool) json.hpp:3992 (test-testsuites_cpp11:x86_64+0x100041b38)
#11 _DOCTEST_ANON_FUNC_42() unit-testsuites.cpp:389 (test-testsuites_cpp11:x86_64+0x100006be3)
#12 doctest::Context::run() doctest.h:6486 (test-testsuites_cpp11:x86_64+0x100064469)
#13 main doctest.h:6571 (test-testsuites_cpp11:x86_64+0x1000663b2)
#14 start :197228464 (dyld:x86_64+0x551d)
==36941==Register values:
rax = 0x000000010bd096ac  rbx = 0x0000000000000000  rcx = 0x000000010bd096ac  rdx = 0x0000000000000103
rdi = 0x0000000000000000  rsi = 0x00007ff80f556154  rbp = 0x00007ff7b5762f10  rsp = 0x00007ff7b5762f00
r8 = 0x0000000000000001   r9 = 0x000000010b925160  r10 = 0x0000000000000000  r11 = 0x0000000000000000
r12 = 0x000000010bd093a0  r13 = 0x00007ff7b5765278  r14 = 0x0000000000000002  r15 = 0x000000010bcf5010
ThreadSanitizer can not provide additional info.
SUMMARY: ThreadSanitizer: SEGV (libsystem_c.dylib:x86_64+0x12ada) in flockfile
==36941==ABORTING
Abort trap: 6
./test-testsuites_cpp11
Reproduction steps
mkdir build
cd build
cmake -G 'Xcode' ..
xcodebuild -verbose
cd tests/Debug
for x in ./test-* ; do ./$x 1> /dev/null  || echo $x ; done
Expected vs. actual results
SUCCESS! for all tests
Minimal code example
No response
Error messages
No response
Compiler and operating system
Xcode 13.4.1 Build version 13F100, Clang 13.1.6 (clang-13<IP_ADDRESS>.5),   macOS-12.4-x86_64-i386-64bit
Library version
json-develop-master
Validation

[X] The bug also occurs if the latest version from the develop branch is used.
[ ] I can successfully compile and run the unit tests.

Looks like you're missing the test data.
Please run the tests through ctest at least once, as that will download the test data automatically. Alternatively, download the test data from here and point JSON_TestDataDirectory to that folder.

even though the program should not expose a SEGV;-)

Maybe. Care (enough) to submit a PR? ;-)

Trying to reproduce - where did you enable TSAN?

@nlohmann This isn't really a TSan issue. Look at the trace. json_test_data is missing and I run into this myself quite frequently.
The unit tests need something like std::ifstream ifs(...); REQUIRE_MESSAGE(ifs.good(), "Could not open file. Did you forget to download json_test_data?"); if anyone else wants to do the work.

Thanks, I can do so - I just missed why TSAN was enabled in the first place.

@nlohmann
TSAN is a default setting for latest MacOS Development.
For Linux or other OS, you can download latest release LLVM, including clang++, llvm, ....

@nlohmann
here the SEGV caused by missing  "test data",
for final customers, This SEGV may triggered by missing configuration file, data file or any other possible file types, since our Json library is broadly used in anywhere that is possible, and the SEGV sort of severity will lead to the services/products fully unavailabe!
And we don't assume final customers can get it done at first time like you professional experts, when they facing a SIGSEGV and tons error text.
further more, we actually have encountered and resolving such SEGV issue.

The issue is accessing a FILE* after fopen failed. I think it's the job of client code to check that this does not happen. We could add an assertion though.

Why you nlohmann innovated this Json library beside other famous existing Json libraries?
We users and contributors believe you can make it better than any other choices.

@nlohmann here the SEGV caused by missing "test data", for final customers, This SEGV may triggered by missing configuration file, data file or any other possible file types, since our Json library is broadly used in anywhere that is possible, and the SEGV sort of severity will lead to the services/products fully unavailable!

Simple. Fix your code! The library is not responsible for mistakes by the user. We can try and make your life easier, but we can't magically solve a file being unavailable. :man_shrugging:

And we don't assume final customers can get it done at first time like you professional experts, when they facing a SIGSEGV and tons error text.

You are supposed to be the expert. Don't hand your customers a broken product.

further more, we actually have encountered and resolving such SEGV issue.

Then you should know how to prevent it in the future, right? ;-)

Maybe you're unaware that you can use std::ifstream instead of FILE *?
The former would result in an exception (of type json::parse_error) that you can catch instead of a segfault.

https://github.com/nlohmann/json/blob/develop/include/nlohmann/detail/input/input_adapters.hpp#L43
Would it make sense to have the file_input_adapter constructor throw if f is null?

Then, while we're at it, stream_input_adapter should throw as well. If possible, an empty input should produce a distinct parse error instead of 101.

Then, while we're at it, stream_input_adapter should throw as well. If possible, an empty input should produce a distinct parse error instead of 101.

This would be a breaking change though...

There isn't really an equivalent to a null in the input_stream_adapter constructor as it takes the stream by reference. About the only thing I can think of to check there is eof(), and that's already cleanly handled.

I was thinking of good(). This is really what the user should be doing to determine if a file was correctly opened. I dislike that there isn't a clear error in case this is missed, though.

If possible, an empty input should produce a distinct parse error instead of 101.

That can be done once at the very beginning of the parse, rather than in the adapters, as you'd want that for a valid stream or file or string that just doesn't have any text in it.

Yes. It's a separate issue, but nonetheless, something that's been bothering me lately. It's also kind of a breaking change.

Then, while we're at it, stream_input_adapter should throw as well. If possible, an empty input should produce a distinct parse error instead of 101.

This would be a breaking change though...

Yes. 4.0 …

I'd favor option 2 with an ID that can be re-used in other adapters. Otherwise, option 1.

Please have a look at https://github.com/nlohmann/json/pull/3593 where an exception is thrown if a passed file pointer is null.

Please have a look at #3593 where an exception is thrown if a passed file pointer is null.

you made it ;-)