RAT-321: text based configuration

Overview
This is a larger change than I had hoped for.  However, the change has been minimized as much as possible.  The goal of this change is to switch to a text based configuration and in the process simplify the configuration architecture.
A secondary goal was to attempt to align the configuration options so that the same property name is used across all the user interfaces.
Changes from the user perspective.
For many users there are no changes as the original licenses are maintained in the change.   For users that define custom licenses there are changes.
For users that define special or custom licenses the easiest solution is to rewrite the custom licenses into a configuration file and include that when running RAT.
Configuration format
Configuration format is defined in XML only in this change.  However, future implementations of other formats are possible and anticipated in the code.  The default configuration file is located in /apache-rat-core/src/main/resources/org/apache/rat/default.xml
The configuration file starts with a <rat-config> tag and ends with a closing </rat-config>.  Within the configuration there are 3 sections:

<licenses> - Contains the definition of licenses.
<approved> - An optional list of approved licenses.  If not specified all licenses in the <licenses> element are assumed to  be approved.  The licenses in the list may include licenses defined but not approved in other configuration files.
<matchers> - Defines matcher builder implementations.  Implementations have names like TextBuilder.  The final Builder part of the name is removed and the first part lowercased, becomes the name of the matcher.  (i.e. CopyrightBuilder becomes the copyright matcher).

License definition
Each license is enclosed in a <license> tag.  The <license> tag has 3 properties:

id - The id of the license.  Must be unique across all definitions.  If more than 5 characters are specified only the first 5 are used, the rest are discarded.  This is equivalent to the old LicenseFamilyCategory property.
name - The name of the license.  Used in display.  This is equivalent to the oldd LicenseFamilyName property.
derived_from - (optional) Specifies the id of a license from which the current license is derived.  Currently this option is unprocessed but in future may be used to accept licenses from which an accepted license is derived.

Each license has up to two enclosed tags.  The possible enclosed tags are:

<note> - Notes about the license.  If multiple <note> tags are specified they are merged into a single note.
matcher - This is not a tag but one of several tags as defined in the <matchers> section of the configuration.  There may be only one matcher.  If more than one matcher is specified the last one is selected.

Matcher definition
There are eight (8) matchers defined in the default configuration file.  They have varying numbers of parameters and child nodes.    If the id property is not specified a default one is generated.  The id is used to reference the matcher.
Text matcher
The <text> matcher matches text just like the old text matching did.  The text to match can be specified either in a text property or simply by enclosing the text in <text> and </text> tags.
Regex matcher
The <regex> matcher uses a regular expression for matching.  This is much slower than the text matching above.  The expression is specified in a expr property on the tag.
Spdx matcher
The <spdx> matcher matches the SPDX tags of the form "SPDX-License-Identifier: ".  The name attribute of the <spdx> tag specifies the name in the license identifier string.
Copyright matcher
The Copyright matcher is a new matcher that matches the tokens "Copyright",  "(C)" , "(c)",  "©".  The token must be followed by a date, two dates separated by a dash, or a copyright holders name. or a combination.  The <copyright> tag has 3 properties, all of which are optional:

start - the start year for the copyright.  If only one year is provided this property should be set.
end - end end year for the copyright.  This should only be set if start has been set and the copyright is expected to have dates of the form "9999 - 9999".
owner - The owner of the copyright.

Copyright matches any either than name first of the date first.  if no date or owner is specified it will match the copyright tokens followed by 4 digits.  no dates are specified but the owner is then it will match the token followed by the owner name.  if date(s) and owner are specified then it will match the token followed by either the owner and then the date(s) or the date(s) and then the owner.
MatcherRef matcher
This is a matcher that references another defined matcher.  It has one property refId which matches the id property of another matcher.  The referenced matcher is used in place of the MatcherRef.
Not matcher
This matcher reverses the meaning of the match.   It has no properties and must enclose one and only one other matcher.
Any matcher
This matcher encloses a collection of matchers.  For this matcher to match one of the enclosed matchers must be matched.
All matcher
This matcher encloses a collection of matchers.  For this matcher to match all of the enclosed matchers must be matched.
Approved section
The <approved> section specifies which licenses are approved.  The <approved> encompasses one or more <family> tags that have a license_ref that contains the id of the approved license.  Licenses defined in other configuration files may be listed for approval.  If the approved section is not specified all licenses defined in the file are assumed to be approved.
Matchers section
The <matchers> section of the configuration file registers matcher builders for use in the system.   Implementations have names like TextBuilder.  The final Builder part of the name is removed and the first part lowercased, becomes the name of the matcher.  (i.e. CopyrightBuilder becomes the copyright matcher).   The <matchers>  comprises child elements that are of the form <matcher class="org.apache.rat.configuration.builders.AllBuilder" name='somename'/> where the class attribute specifies the class name of the implementation.  If the name attribute is specified it overrides the name of the matcher.
CLI interface
The command line interface adds new options to specify files of configurations to read.  Executing the --help option will list all the commands and their options.
ANT interface
The Ant interface has changed to utilize the various builders in the system.   An example of an ant build.xml can be found at /apache-rat-tasks/src/test/resources/antunit/report-junit.xml.
the <rat:report> tag has several properties to configure the system. In most cases there should be no changes for users.  For users that specify custom licenses the  <rat:license> tag is the same as the standard configuration file <license> tag.
Maven interface
the Maven interface has changed to utilize the various builders in the system.   An example of an maven pom.xml can be found at /apache-rat-plugin/src/it/it1/pom.xml.  The main difference  between the Maven implementation and the configuration file is that items that were properties in the configuration file are specified as enclosed text tags.
Changes from developer perspective
Separation of configuration from running report.
The ReportConfiguration class now contains all the information necessary to run the report.  The code to run the report has been moved from Report to Reporter.  Report is now limited to implementing the CLI interface and setting the properties in the ReportConfiguration properly.
All user interfaces (cli, ANT and Maven) have been modified to set the ReportConfiguration properties and call the Reporter to execute the report.
As part of this separation the MetaData object has been removed from the configuration and user facing code.  It remains in the reporting engine where it belongs.
Migration to builders
Multiple builders were created to assist in the creation of ILicense, and IHeaderMatcher implementations.  The Builders are utilized in the code that configures the ReportConfiguration and provide a standard mechanism to ensure that the objects are properly configured across all client interfaces.
ILicense and ILicenseFamily
The ILicense has been simplified to comprise and LicenseFamily, notes, derivedFrom, and a single matcher.  The ILicenseBuilder class implements the builder.   The licenseFamilyCategory must be unique across all licenses.  Licenses may be sorted by the LicenseFamily.  There is a Comparator<ILicense> available from the ILicense class.
The ILicenseFamily now implements Comparable<ILicenseFamily>.  Both the ILicense and the ILicenseFamily are ordered by the licenseFamilyCategory property.
IHeaderMatcher (matchers)
The system provided matchers are implemented by Builders.  New matcher types can be created by creating builders that extends org.apache.rat.configuration.builders.AbstractBuilder or otherwise implement IHeaderMatcher.Builder and produce an IHeaderMatcher that extends org.apache.rat.analysis.matchers.AbstractMatcher.
Any properly constructed org.apache.rat.configuration.builders.AbstractBuilder that is added to the <matchers> section of the configuration file (see above) is automatically registered and available for use in the license definition in the configuration file.  Additional steps must be taken to access the new matchers from ANT and Maven.
Changes to matching logic
With the addition of the <not> and <all> matchers it became necessary to provide deeper inspection of the state of the match.  Prior to this all matches were so a matcher could return true if a match was detected and false othewise.  However, the code tests the headers line by line so the matcher can not declare that it does not match until the last header line has been processed.  To handle this situation, the org.apache.rat.analysis.State enum has been added to the code base.   Matchers now return State when the IHeaderMatcher.matches(String) method is called and the reset() method now resets the current state to i (indeterminate).   IHeaderMatcher  also has two new methods:

currentState() - returns the current state of the matcher.
finalizeState() - sets the current state to either t (true) or f (false).

To simplify the construction of new IHeaderMatcher implementations there is a org.apache.rat.analysis.AbstractSimpleMatcher that handles the tracking of the State and assumes that finalizeState() will convert a i to f.  Classes implementing this simply need to implement boolean doMatch(String) to perform the check.
The change to matching logic necessitated a change to the matching engine to call the finalizeState() and switch from handling boolean matches(string) result to State handling.
Testing
Significant work has been done to improve testing for the various matchers and other classes that were touched by this change.
JavaDoc
Modified files have had their javadocs updated.  New files have javadocs as well.

I recognize that this is a massive change and will take some time to process.  If you have any questions or want to see extra tests please let me know and I will endeavour to complete them as quickly as possible.
It may make sense to create a new branch to put these changes on so that we can get an alpha release out to get some feedback before going all in on the changes.

@Claudenw  if I get it correctly there are no functional changes of existing functionality. Thus I'd prefer to merge your changes and prepare a release of RAT in order to collect feedback from existing users. WDYT?

There are differences in the UI for Maven and Ant when not using the
standard definitions.
Preparing a release and collecting feedback seems like a viable path.  I
think we need to update documentation, but I think a release candidate is a
good start.
Claude
On Mon, Oct 16, 2023 at 11:29 AM P. Ottlinger @.***>
wrote:

@Claudenw https://github.com/Claudenw if I get it correctly there are
no functional changes of existing functionality. Thus I'd prefer to merge
your changes and prepare a release of RAT in order to collect feedback from
existing users. WDYT?
—
Reply to this email directly, view it on GitHub
https://github.com/apache/creadur-rat/pull/157#issuecomment-1764081462,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AASTVHSEHJGAOTVR77ASA6TX7T5AXAVCNFSM6AAAAAA5W6RTVWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTONRUGA4DCNBWGI
.
You are receiving this because you were mentioned.Message ID:
@.***>

--
LinkedIn: http://www.linkedin.com/in/claudewarren

@ottlinger how do we proceed?  I do not have access to merge and I am unsure of the process to create a release so I think I need you to guide and/or execute this process.  If you need anything from me please let me know.

@Claudenw I'll start preparations for a new RC during the weekend (as the changelog and Jira needs some more attention before a new RC can be created). How would you summarize the feature RAT-321 introduces (feel free to add this to this branch's src/main/changes.xml))


Installing cgat-devel-lite 0.1-np19py27_1

Last time I pulled changes, installing gave me htslib errors. Reasoning this must be due to an pysam update, I updated by cgat-devel-lite with
conda update cgat-devel-lite

This updated cgat-devel-lite from 0.1-np19py27_0 to 0.1-np19py27_1 and pysam from 0.8.1 to 0.8.2.
Running python setup.py develop gave the following compilation errors:
running develop
/shared/conda-install/envs/cgat-devel-lite/lib/python2.7/site-packages/setuptools-14.0-py2.7.egg/pkg_resources/__init__.py:2512: PEP440Warning: 'binstar (dev)' is being parsed as a legacy, non PEP 440, version. You may find odd behavior and sort order. In particular it will be sorted as less than 0.0. It is recommend to migrate to PEP 440 compatible versions.
running egg_info
writing requirements to CGAT.egg-info/requires.txt
writing CGAT.egg-info/PKG-INFO
writing top-level names to CGAT.egg-info/top_level.txt
writing dependency_links to CGAT.egg-info/dependency_links.txt
writing entry points to CGAT.egg-info/entry_points.txt
reading manifest file 'CGAT.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'CGAT.egg-info/SOURCES.txt'
running build_ext
skipping 'CGAT/Components/Components.cpp' Cython extension (up-to-date)
skipping 'CGAT/NCL/cnestedlist.c' Cython extension (up-to-date)
cythoning scripts/_bam2bam.pyx to scripts/_bam2bam.c
building 'CGAT._bam2bam' extension
gcc -pthread -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -D_FILE_OFFSET_BITS=64 -D_USE_KNETFILE= -I/shared/conda-install/envs/cgat-devel-lite/lib/python2.7/site-packages/numpy/core/include -I/shared/conda-install/envs/cgat-devel-lite/lib/python2.7/site-packages/pysam-<IP_ADDRESS>-py2.7-linux-x86_64.egg/pysam -I/shared/conda-install/envs/cgat-devel-lite/lib/python2.7/site-packages/pysam-<IP_ADDRESS>-py2.7-linux-x86_64.egg/pysam/include/htslib -I/shared/conda-install/envs/cgat-devel-lite/lib/python2.7/site-packages/pysam-<IP_ADDRESS>-py2.7-linux-x86_64.egg/pysam/include/samtools -I/shared/conda-install/envs/cgat-devel-lite/include/python2.7 -c scripts/_bam2bam.c -o build/temp.linux-x86_64-2.7/scripts/_bam2bam.o
In file included from /usr/include/limits.h:27:0,
                 from /shared/conda-install/envs/cgat-devel-lite/lib/gcc/x86_64-unknown-linux-gnu/4.8.3/include-fixed/limits.h:168,
                 from /shared/conda-install/envs/cgat-devel-lite/lib/gcc/x86_64-unknown-linux-gnu/4.8.3/include-fixed/syslimits.h:7,
                 from /shared/conda-install/envs/cgat-devel-lite/lib/gcc/x86_64-unknown-linux-gnu/4.8.3/include-fixed/limits.h:34,
                 from /shared/conda-install/envs/cgat-devel-lite/include/python2.7/Python.h:19,
                 from scripts/_bam2bam.c:16:
/usr/include/features.h:324:26: fatal error: bits/predefs.h: No such file or directory
 #include <bits/predefs.h>
                          ^
compilation terminated.
error: command 'gcc' failed with exit status 1

Hi Ian,
Are you doing this on RHEL6-based operating system or Ubuntu?
Could you please try:
$ export C_INCLUDE_PATH=$C_INCLUDE_PATH:"/usr/include/x86_64-linux-gnu"
$ export LIBRARY_PATH=$LIBRARY_PATH:"/usr/lib/x86_64-linux-gnu"
and then:
$ python setup.py develop
again?
Best regards,
Sebastian.
2015-03-11 17:31 GMT+00:00 Ian Sudbery<EMAIL_ADDRESS>
Last time I pulled changes, installing gave me htslib errors. Reasoning
this must be due to an pysam update, I updated by cgat-devel-lite with
conda update cgat-devel-lite
This updated cgat-devel-lite from 0.1-np19py27_0 to 0.1-np19py27_1 and
pysam from 0.8.1 to 0.8.2.
Running python setup.py develop gave the following compilation errors:
running develop
/shared/conda-install/envs/cgat-devel-lite/lib/python2.7/site-packages/setuptools-14.0-py2.7.egg/pkg_resources/init.py:2512: PEP440Warning: 'binstar (dev)' is being parsed as a legacy, non PEP 440, version. You may find odd behavior and sort order. In particular it will be sorted as less than 0.0. It is recommend to migrate to PEP 440 compatible versions.
running egg_info
writing requirements to CGAT.egg-info/requires.txt
writing CGAT.egg-info/PKG-INFO
writing top-level names to CGAT.egg-info/top_level.txt
writing dependency_links to CGAT.egg-info/dependency_links.txt
writing entry points to CGAT.egg-info/entry_points.txt
reading manifest file 'CGAT.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'CGAT.egg-info/SOURCES.txt'
running build_ext
skipping 'CGAT/Components/Components.cpp' Cython extension (up-to-date)
skipping 'CGAT/NCL/cnestedlist.c' Cython extension (up-to-date)
cythoning scripts/_bam2bam.pyx to scripts/_bam2bam.c
building 'CGAT._bam2bam' extension
gcc -pthread -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -D_FILE_OFFSET_BITS=64 -D_USE_KNETFILE= -I/shared/conda-install/envs/cgat-devel-lite/lib/python2.7/site-packages/numpy/core/include -I/shared/conda-install/envs/cgat-devel-lite/lib/python2.7/site-packages/pysam-<IP_ADDRESS>-py2.7-linux-x86_64.egg/pysam -I/shared/conda-install/envs/cgat-devel-lite/lib/python2.7/site-packages/pysam-<IP_ADDRESS>-py2.7-linux-x86_64.egg/pysam/include/htslib -I/shared/conda-install/envs/cgat-devel-lite/lib/python2.7/site-packages/pysam-<IP_ADDRESS>-py2.7-linux-x86_64.egg/pysam/include/samtools -I/shared/conda-install/envs/cgat-devel-lite/include/python2.7 -c scripts/_bam2bam.c -o build/temp.linux-x86_64-2.7/scripts/_bam2bam.o
In file included from /usr/include/limits.h:27:0,
from /shared/conda-install/envs/cgat-devel-lite/lib/gcc/x86_64-unknown-linux-gnu/4.8.3/include-fixed/limits.h:168,
from /shared/conda-install/envs/cgat-devel-lite/lib/gcc/x86_64-unknown-linux-gnu/4.8.3/include-fixed/syslimits.h:7,
from /shared/conda-install/envs/cgat-devel-lite/lib/gcc/x86_64-unknown-linux-gnu/4.8.3/include-fixed/limits.h:34,
from /shared/conda-install/envs/cgat-devel-lite/include/python2.7/Python.h:19,
from scripts/_bam2bam.c:16:
/usr/include/features.h:324:26: fatal error: bits/predefs.h: No such file or directory
#include <bits/predefs.h>
^
compilation terminated.
error: command 'gcc' failed with exit status 1
—
Reply to this email directly or view it on GitHub
https://github.com/CGATOxford/cgat/issues/157.

Hi Sebastian,
That did it! Any chance you could explain it to me: shouldn't conda environments be self contained?
Its Ubuntu. I keep meaning to switch to CentOS, but not getting round to it because the default desktops won't run in my virtual machine (lack of 3D acceleration).
Cheers
Ian

Hi Ian,
cgat-devel-lite (or cgat-scripts-lite) try to minimise the number of dependencies, therefore I left gcc explicitly out of them. It should not happen with cgat-devel (and cgat-scripts) though, but further testing would be necessary to confirm this.
I hope it answers your questions.
Many thanks for your feedback!
Best regards,
Sebastian.


Update main.py

Added help command correctly this time

ping command*
I'm not too versed with the delete_after attribute, is there a need for the Try & Except statements after line 60?

its removable but its in case something happens to the message (HTTPException or Notfound)
I havent had any issues with delete_after but im fine with removing
🐍 snek

Please could you add those specific exceptions to the Except statement instead of a generalised Except statement?

david qt pls


Panic if permission denied opening skb keyring mobile

session.json is covered by libkb/json.go.

For leveldb, there is already some non-trivial error handling:
https://github.com/keybase/client/blob/master/go/libkb/leveldb.go#L163
I'd prefer not to mess with that until we see a similar error.


I added the models and the get route as documented here by Google  https://developers.google.com/android-publisher/api-ref/rest/v3/purchases.subscriptionsv2

Q
A

Branch?
1.x

Bug fix?
yes/no

New feature?
yes/no

Deprecations?
yes/no

Tickets
Fix #...

License
MIT

I was facing a issue trying to implement the subscriptions for a new Android app. I used this package in the past and I wanted to help upgrade it to make it compatible with this API also. I am currently using my fork in production. Thank you for this amazing package.

Hi @ManuConstantin
Glad to hear that this package helped you. Great job, but this PR has many breaking changes and the code is organized in a different way than what's planned for the future releases. Thank you so much for considering submitting this PR.


LICENSE File mising

Hi, could you please add a LICENSE file your repo. All repositories in the BCGOV ORG are required to have a LICENSE file. Reference: https://github.com/bcgov/BC-Policy-Framework-For-GitHub/tree/master/BC-Gov-Org-HowTo and https://github.com/bcgov/BC-Policy-Framework-For-GitHub/blob/master/BC-Gov-Org-HowTo/Cheatsheet.md. Thank you.

+1 a Creative Commons Attribution 4.0 would be ideal ;)

That would work for the context of this repo. Thanks

I have added a separate license file in commit ac1dca89f950a57392906659a09b1f0a8b4f58f4.
@camfindlay yup the existing license is CC BY 4.0.
@agehlers my read of the BC Gov policy framework is that the expected behaviour is to indicate the license with a footer in the readme, which @juhewitt had previously done (including a fancy badge) but I don't suppose there's any harm in also having a LICENSE.md as well.


Support for filtered real-time subscription

Pocketbase supports subscription for either a single record or an entire collection. However, if we want to subscribe to a subset of the collection, this feature is currently unavailable.
Use case: Let's say we have a collection of restaurants, and we want to subscribe to a particular user's restaurants. In this scenario, we are unable to achieve this.
Possible Solution 1: We would like to have the ability to subscribe to filtered records, allowing us to specify conditions for subscriptions. For example, using a syntax like this: collection("restaurant").subscribe(null, filter={"owner": "user123"}). In this case, even if we provide a null value for the first parameter, we should be able to use a filter to specify our subscription criteria.
Possible Solution 2: You can support more complex API rules for collections.

filter, expand, fields, custom query parameters and headers support for the realtime subscription APIs is already implemented in the develop branch and will be available with the next v0.20.0 release (there are no ETAs).
If you want to give it a try, you can test the v0.20.0-rc prerelease or build the develop branch on your own.
Also note that in order to work this requires JS SDK v0.20.0-rc or Dart SDK v0.17.0-rc.

That's awesome! Thank you, looking forward to it. 🚀

I, too, was looking for this feature.  If it is implemented, could the documentation be improved?  As of now, it doesn't list "filter" (it says: "expand, custom headers, etc."). It's also easy to misread the bolded You could subscribe to a single record or to an entire collection. as though you'd have to subscribe to the entire collection without having the option of filtering.
Perhaps an example could be added to make it clear that this is supported.

Hi @ganigeorgiev is this feature still in pre release?
I couldn't find autocompletion in the JS SDK.

@ShivamJoker It is available with v0.20.0+. Here is an example:
pb.collection("example").subscribe("*", (e) => {
   ...
}, { filter: "something > 10" })

Oh perfect. It works.
Thanks a lot.


Port existing PSF subtraction code from Roman Project

@mygouf is there actually a requirement that port the existing code?


page 43

https://hear-a-tale-awakening-pl895qe79-fattimo.vercel.app/page/43
chapter 9 page 7 does not exist

same with page 20, page 5 chapter 5

seems to only happen around chapter borders

Pretty sure this was a merge error. Rerunning script fixed it.


Use keccak SP1 patched crate

A significant number of cycles are probably due to keccak. We can use our patch of tiny-keccak: https://docs.succinct.xyz/writing-programs/patched-crates.html and we will probably notice a tremendous savings on the cycle count.

@puma314 All the code in Kona uses alloy_primitives::keccak256 for the hashes. Easy to sub that out in our zkvm_client, but we want it subbed across the whole codebase.
The only easy way I can see to do that without messing with all the Kona code would be to set up an alloy_primitives fork that uses the tiny-keccak patch, and then patch with that alloy_primitives fork.
Do you agree with that approach or have you all found a better way to do this?

@puma314 Oh obviously can just patch it. Did it in latest commits on the PR, massively improved benchmarks!
https://github.com/moongate-forks/kona/pull/7/files/19e5b3bc3ae25217286630a4c6b0087da78b2358..6c3217a11cdd574e6db6ef09eafeca06dc9b6d41
Lowered cycles on the derivation from 4bn to under 1bn.


Styling issue : Specialisations

There's an issue when you have in a row 1 line and 2 line names for the talents :

The progression lines do not adapt to the difference in height generated (or inversely the cells do not stay the same when the size of the title box gets bigger.
Personally I would like the progression lines to adapt to the required heights, if possible.

Fixed the issue in the dev branch


test: Cypress flaky fix - Specs failure due to for redirect login

Description

This PR adds validation to check the logout happened successfully before login can happen via api

Fixes #22261
Type of change

Script fix (non-breaking change which fixes CI failure issue)

How Has This Been Tested?

Cypress CI runs

Checklist:
QA activity:

[ ] Added Test Plan Approved label after reviewing all changes

/ok-to-test sha=838836b

/ci-merge-check

/ci-merge-check


Install Slim 3 with Composer issue

When I tried:
composer require slim/slim:"^3.0@RC"
the console showed:
Your requirements could not be resolved to an installable set of packages.

Problem 1
    - Installation request for slim/slim ^3.0@RC -> satisfiable by slim/slim[3.0.0-RC1].
    - Conclusion: remove pimple/pimple v1.1.1
    - Conclusion: don't install pimple/pimple v1.1.1
    - slim/slim 3.0.0-RC1 requires pimple/pimple ^3.0 -> satisfiable by pimple/pimple[v3.0.0, v3.0.1, v3.0.2].
    - Can only install one of: pimple/pimple[v3.0.0, v1.1.1].
    - Can only install one of: pimple/pimple[v3.0.1, v1.1.1].
    - Can only install one of: pimple/pimple[v3.0.2, v1.1.1].
    - Installation request for pimple/pimple == <IP_ADDRESS> -> satisfiable by pimple/pimple[v1.1.1].

I installed Slim 2 normally.

I did this just today using the following command composer require slim/slim ^3.0@RC

I tried your command but it still shows the same error.

I think you already pimple version 1 installed via composer. Slim requires version 3, so you need to update your pimple version to get it.

Thank you @SamNicholson you save my day.


feat: added dockerimage

For starters, I've added a basic Dockerfile to build the application. I also removed the triggers for current pipeline build so we don't waste minutes trying to build something that will fail


How to define the label dimension in multi-label task with LSTM?

Below is the code for model definition:
model = Sequential()
model.add(LSTM(200, return_sequences=True, input_shape=(timestep, n)))
model.add(LSTM(200))
model.add(Dense(output_dim=88, activation='sigmoid'))
sgd = SGD(lr=0.001, decay=1e-6, clipnorm=5., momentum=0.9)
model.compile(loss='binary_crossentropy', optimizer=sgd, metrics=['fmeasure'])
The model input x_train is a 3D matrix of shape (batch_number, timestep, n), where n is the dimension of the sequences. And I divided the ground truth label y_train into a 3D matrix of shape (batch_number, timestep, 88), where 88 is the dimension of the label. However it threw an execption:

Error when checking model target: expected dense_1 to have 2 dimensions, but got array with shape (batch_number, timestep, 88)

It's bit confusing because in my work, each sequence corresponds to a label vector, but in Keras, it seems no way to fit the label matrix into the LSTM layer.
Any help would be appreciated. Thank you.

Hello,
Currently you are using a many-to-one architecture.
Use :
model.add(LSTM(200,return_sequences=True))
model.add(TimeDistributed(Dense(output_dim=88, activation='sigmoid')))

For a many to many architecture which should work with the shape you currently try to pass.

It works well. Thank you @unrealwill


Missing image

Sismo.php requests an image which gives a 404 : http://localhost/sismo.php/images/shadow.png

fixed


how to stop  draggable div from moving out of parent  after dropping , how to add bound prop dynamically ?

Try StackOverflow.


SDK throws an error on seed mismatch to stored credentials

When trying to connect the SDK with a seed different to the encrypted credential, SDK throws an error:

Failed to decrypt credentials, seed doesn't match existing node

This can be handled by creating a different working directory for the SDK to use with the different seed, but that is not immediately obvious to a developer.

How about, if that happens, we delete the local sql files and re-populate them based on the new seed?
I find myself doing this a lot during tests, when switching between wallets.
It can be made configurable, or with a new flag added to connect.

Alternatively, we could store the DB files in a per-wallet subfolder, whose name is derived from the seed (HD wallet fingerprint).
Each new restore would then access the files from the matching DB, or create a new subfolder.

Alternatively, we could store the DB files in a per-wallet subfolder, whose name is derived from the seed (HD wallet fingerprint).
Each new restore would then access the files from the matching DB, or create a new subfolder.

This would better suit the multi-instance scenario, where different HWW determine the seed. I think Roy mentioned also having a method clear the state cache for a particular seed (or with an optional flag when calling disconnect)

This would better suit the multi-instance scenario, where different HWW determine the seed. I think Roy mentioned also having a method to clear the state cache for a particular seed (or with an optional flag when calling disconnect)

I like this approach.


Faulty Invocations Dashboard in APIM does not show the appropriate value

Description:
Faulty Invocations Dashboard in APIM does not show the appropriate value on popups
Suggested Labels:
BUG
Suggested Assignees:
Affected Product Version:
OS, DB, other environment details and versions:
Steps to reproduce:
Related Issues:


Even if I have set the seed, the result will change？

Even if I have set the seed, after each run the results will change. I am using MCMC mode.

Is this a pywFM specific problem? Or do you also observe it in srendle/libfm?

I'm closing this, feel free to open if you have any questions!


GetCiv3Path() returns null if Civ3 isn't in the Windows registry, and that causes issues

Stumbled upon this while reviewing Jim's PR.
Steps to reproduce:

Find a Windows box without Civ3 installed, or (more plausibly, since we all have Civ3 installed), rename the key HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Infogrames Interactive\Civilization III to something else temporarily, so C7 won't find it.
Run C7

Expected: You are able to select the Civ3 home.
Actual: C7 crashes.  Output:
Unhandled Exception:
System.ArgumentNullException: Value cannot be null.
Parameter name: path1
  at System.IO.Path.Combine (System.String path1, System.String path2) [0x00003] in <1400ea11d6fd49d4939be686a9549fb4>:0
  at Util.FileExistsIgnoringCase (System.String exactCaseRoot, System.String ignoredCaseExtension) [0x00001] in C:\Development\Civ Related Projects\Prototype\C7\Util.cs:60
  at Util.Civ3MediaPath (System.String relPath, System.String relModPath) [0x0008e] in C:\Development\Civ Related Projects\Prototype\C7\Util.cs:109
  at MainMenuMusicPlayer._Ready () [0x00002] in C:\Development\Civ Related Projects\Prototype\C7\MainMenuMusicPlayer.cs:14

The fact that it can't find the main menu music is a red herring, the real problem is that it's even trying to despite the registry not containing the expected key.  The relevant code in GetCiv3Path():
                // Look up in Windows registry if present
		path = Civ3PathFromRegistry("");
		if (path != "") return path;

It turns out that the method we use in Civ3PathFromRegistry to check the registry returns null if it doesn't find anything, but out code expects it to return the empty string.
Of note is that I've tested this on Windows 8.1 64-bit.  I know the Windows registry format has not been entirely the same for the past 30 years, so it's possible that it does return the empty string on another version of Windows.  I have separate registry-parsing code for pre-and-post-Vista in my editor, so it's not a wholly theoretical possibility.

Ah, I seem to have misunderstood the default value parameter: https://docs.microsoft.com/en-us/dotnet/api/microsoft.win32.registry.getvalue?view=net-6.0 . The registry is weird sometimes, but I get the problem now. I'll see if I can fix it real quick.

Created branch with fix: https://github.com/C7-Game/Prototype/tree/winregfix
I haven't tested it on Windows yet, but it doesn't crash Mac. Yay.

I just tried it on Windows. It works as expected with the registry right, when the install_path value missing, and with the key missing.
I originally thought there was a problem because the button didn't show up, but the button PR hasn't been merged yet, and that's why it's "missing".
Should I make a PR for winregfix or just merge it into PR #78? They're both dealing with the Civ3 home path.

I'd just as soon merge the existing approved PR, and open up a separate one for this.  TBH it wouldn't matter a ton in this case, but "I'll just toss one more thing on this PR" can lead to really large PRs.
Also going to assign it to you since it's now in progress.


[WFRP4e Core] Random Char Gen

So our weekly game is in two hours and we have a new player joining us. In past versions of WFRP on Foundry you could /char and build a char by the book that way. It is no longer possible. What gives?  Pretty much cripples a group that has to play online due to the pandemic.  It comes up with Species but when I hit Roll it says "Table Not Found". Help!From<EMAIL_ADDRESS>5.0.3wfrp4e-archives1: 2.3.0wfrp4e-core: 2.3.2wfrp4e-eis: 2.2.1wfrp4e-middenheim: 2.3.1wfrp4e-rnhd: 2.3.1wfrp4e-starter-set: 2.2.1wfrp4e-ua1: 2.2.1

I think that you have to import all tables from the Compendium first.


Reduced ability on Guest user.

The Guest user description says Can view, rate and favorite cocktails which sounds perfect. However, they can actually do more than I think a guest should do. Perhaps a new role "Guest Limited" or current "Guest" role should be renamed "User" and new actual "Guest" role created.
I found #81 which was dismissed to quickly.  The current "Guest" is really more of a "User" and not a "Guest".  Ideally a guest:

Cannot create collections (but perhaps can view shared ones)
Cannot manage a shelf (should not even see anything related to shelf)
Should not see how many cocktails they can make, a guest user is not making cocktails.
Should not have a shopping list or ability to add to them.

The Bar Assistant API docs description of guest role does not say a guest should be doing these things:

Hello,
Guest is just a user with permissions that don't really have effect on anything in the actual bar. So everything he does (like collections, personal shopping list, shelf) is "viewable" only to him.

I understand what you are saying.  I think my issue is that what is documented on what the "Guest" role is supposed to do and what the guest can actually do in Salt Rim do not line up.  A guest user can do a lot more than is documented.


Spacebar for Sendkeys

I dont know if I am missing it but SENDKEY {SPACE} doesnt seem to work.
Edit; SENDKEY {} Seems to work but its very unreliable.  I made a pretty lengthy script for programming, and all works fine except the spacebar.  Unfortunately the toggle options are spacebar only.
I was able to test it inside the option by SENDKEY {} and sometimes it worked and sometimes it didnt.

Ive read that maybe just adding SPACE and doing {" "} would work.  Ill give it a shot maybe later

SENDKEY {ENTER} also doesn't seem to work with MinTTY 2.2.2.


Append method of jqLite append only for the last target element

Hi,
With jQuery, it is specified that append function should append "cloned copies of the inserted element for each target except for the last one".
But with jqLite, the same node is appended for each target, it means that the node element will be inserted only for the last target element.
Here is a very simple jsFiddle to reproduce (it uses angularjs 1.2.1 but I reproduced with angular.js 1.3.14) : https://jsfiddle.net/5o5h5hzf/
I agree, this could be easily fixed using native dom api, so I wonder if it's a known bug or if it's the expected behavior. If it's a bug, I can submit a PR if you want, otherwise it should probably be documented ?

So jqlite does not clone the element that is inserted if there are multiple targets, but always appends the same element. However, only the last target should get the original.
I think we should document this. jqlite was never meant to mirror the implemented functions 1:1. Since angular does not allow querying for elements, a case where a jqLite object consists of multiple objects is basically non-existent in the code base. I haven't looked into it, but it's possible that the jqLite "constructor" only takes the last element, which would explain the behavior.

What do you mean by "since angular does not allow querying for elements" ?

BTW, JQLite keeps all elements (not just the last one). And indeed appending to a collection of elements, will call appendChild on each element in the collection (meaning the appended element(s) will end up in the last collection element only).
Besides documenting this, we could even optimize it :)

@gkalpak That's exactly the problem, your description is much more useful than mine :)
@Narretz I agree, Angular does not allow to query for element, but it allows anyone to wrap array of nodes into a jqLite object.
I understand that it does not need to be fixed, but what do you think of this code:
    angular.element(document.getElementsByTagName('li'))
      .addClass('foo')
      .attr('foo', 'bar')
      .append(document.createElement('span'))
      .children().text('foo');

Don't you find weird that everything works as expected except for 'append' method ?
I missed it in my first comment, but the problem is the same for other methods appending element (prepend, before, after and wrap).
Anyway, thank you for your feedback !

It fixing this doesn't bloat the code, I can see it getting changed. If you want to give it a try and send a PR, you're very welcome.

I am not really sure how we could properly handle that in Angular. How is it possible to adequately clone an compiled element (with directives, behaviours, parent awareness etc) ?

@gkalpak That's true, I didn't even think of that. The same problem exists with full jquery, too. Noone ever complained about this though, so I think we should just document how jqlite differs from jquery. A PR to bring the behavior in line with jquery might still be considered if it doesn't bloat the code.

Hi, I will have time to submit a PR soon (probably at the end of the week), I hope this will help you to take the best decision.

I submitted a docs PR for the current behavior: #16517.


Support locale based year-month view

Is your feature request related to a problem? Please describe.
No.
Describe the solution you'd like
Currently it only shows view: < month - year >.
But, if the locale set to ja, the view maybe like this: < year - month >, since ja is used to select year first, and then month.
Describe alternatives you've considered
Additional context

like this:

There is a slight change added to support it, instead of a prop, you can target the class and add flex-direction: row-reverse; Available under 3.6.0-alpha.1

@ms-mayya Sorry, I was switching some branches and somehow misplaced this, next version will be released soon.


PATCH /api/v1/repos/OWNER/REPO fails

Description
I'm trying to use the API to programmatically update the default_merge_style to 'rebase'.
The HTTP PATCH looks rather simple, I'm doing something like this from python:
When enabling the HTTPConnection.debuglevel of the python client, I get:
send: b'PATCH /api/v1/repos/laforge/3gpp-etsi-pdf-links HTTP/1.1\r\nHost: gitea.osmocom.org\r\nUser-Agent: python-requests/2.27.1\r\nAccept-Encoding: gzip, deflate, br\r\nAccept: */*\r\nConnection: keep-alive\r\nCookie: _csrf=rSUK77i1f32Y-foobar; i_like_gitea=foobar\r\nContent-Length: 33\r\nContent-Type: application/json\r\nAuthorization: token foobar\r\n\r\n'
send: b'{"default_merge_style": "rebase"}'
reply: 'HTTP/1.1 200 OK\r\n'

So what's odd here is

the PATCH body definitely contains the {"default_merge_style": "rebase"}
the HTTP status code is 200
the change is not visible afterwards, not via the web UI
the JSON returned in the response again states {"default_merge_style": "merge"} - which was the setting before issuing the patch.

The same problem is also observed when trying to change the allow_squash_merge in a similar PATCH
Gitea Version
1.16.8
Can you reproduce the bug on the Gitea demo site?
No
Log Gist
No response
Screenshots
No response
Git Version
No response
Operating System
Debian GNU/Linux 11
How are you running Gitea?
gitea docker container
Database
SQLite

This is a rather unfriendly 'feature' of the API — the request needs to contain "has_pull_requests": true for changes to PR settings to be accepted:
https://github.com/go-gitea/gitea/blob/c9c5bd88beb30b06cf52444e6515ef4c7d75993f/routers/api/v1/repo/repo.go#L834
...as is also noted in the docs:
https://github.com/go-gitea/gitea/blob/c9c5bd88beb30b06cf52444e6515ef4c7d75993f/modules/structs/repo.go#L182-L187

As this usage error comes up repeatedly (#13620 #15121 #18773 #19069), I take this opportunity to discuss if

this check is really helpful in any way
changing this behavior for better API UX is acceptable or a breaking change to avoid

Opinions? @6543

I would accept a patch if submited

This is a rather unfriendly 'feature' of the API — the request needs to contain "has_pull_requests": true for changes to PR settings to be accepted:

This is really odd.  I read the related documentation, but I understood it as "you can only set this setting if the existing repo already has "has_pull_requests": true.  That of course makes sense, why would you be able to configure details of merging pull requests, if you have no pull requests.
But having to send that "has_pull_requests": true via the API for a repo that already has this flag true before issuing the API request is really unexpected.  It would never have occurred to me that this needs to be done, even after reading the documentation.
Thanks for the clarification.

Parent issue #13622


AppNavItem without path is treated as root

If I create an AppNavItem without path it is highlighted as the selected item when navigation to the root.
This is wrong because AppNavItems without path are used as parents for sub navigation.
See screenshot:

That is done in my implementation of AppNavItem if you ended up using my quick fix. I wanted that functionality in my app. If you want to remove that go to the setPath method and remove the check for empty path being set to "/"
I hope that helps

There is a similar check for addPathAlias that you can remove as well if you use empty path as route alias anywhere

You mean a nav item without a path completely, right, not one with an empty string as its path (<vcf-nav-item> vs <vcf-nav-item path="">)?

Yes, without a path.


Segfault when calling hashmap_set

I'm using this library to make a 2D hashmap for a game I'm developing. For the "keys", I have 2 64 bit ints that represent the x and z coordinate. For the "values", I just have a huge array that represents the data in the x, z chunk. When I run hashmap_set, I get a segfault. I ran it with GDB and it says its coming from this line:
211         char edata[map->bucketsz]; // VLA;

If I'm doing something wrong, does anyone have any ideas why? If it's something wrong with the library (which it is most likely not), is there some feature that needs to be implemented? Thanks.

The error you are encountering may be due to the size of the map->bucketsz being too big to dynamically allocate a VAL on the stack.
How large is the elsize (element size) param that you are sending to the hashmap_new() function?
Generally you want to keep the element size as small as needed, where each element is an individual unit that is hashable and comparable. If you are intending on storing very large elements, then it may be best to use pointers as your elements, in which each is an individual allocation on the heap.
BTW, I recently replaced the VLA with an allocation in v0.3.1, which will generally avoid stack crashes for massive elements. If that is in fact your issue then it may be worthwhile to update.

When I initialize the world (that's the struct that contains the hashmap), the size is sizeof(chunk), which is the struct that contains the keys and values.

Just downloaded the new version and it's not segfaulting in the same place anymore. However, when I run hashmap_set, it still returns NULL. I'm sure this is a problem with my code, but I can't seem to figure out where. For the compare function, I'm just comparing a.x == b.x && a.y == b.y so I'm not sure why it isn't working.

the size is sizeof(chunk), which is the struct that contains the keys and values

How many keys and values is this? What is this as number of bytes?
This should be relatively small.
The elsize is meant to represent the size of a single element. Such as a one key/value pair. Each pair must be exactly the same elsize.

For the compare function, I'm just comparing a.x == b.x && a.y == b.y so I'm not sure why it isn't working.

The return value of the compare function should -1, 0, or 1, where -1 is a < b, 0 is a == b, and 1 is a > b.
A a.x == b.x && a.y == b.y probably won't work.
So if you are using multiple values you need to do something like:
int compare(a, b) {
    if (a.x < b.x) {
        return -1;
    } else if (a.x > b.x) {
        return 1;
    } else if (a.y < b.y) {
        return -1;
    } else if (a.y > b.y) {
        return 1;
    } else {
        return 0;
    }
}

Does it matter that it returns -1, 1 depending on whether it's more/less, or is it just "something else" than 0?

Sorry for wasting your time, turns out when I ran hashmap_get, I was just passing the key, not the chunk struct. I'm going to keep this open for a bit more because I might be doing something in an inefficient way with the compare function.

I usually make my compare function return the correct value because I often reuse compare with other collections, such as b-tree and qsort. But because it's a hashmap, I guess it probably doesn't matter as long as equals == zero, and not-equals == not zero.

Okay, thanks!


Android: Fix theme for android app start and logo

TL;DR
Updated app theme colors and splash screen timing for production release
What changed?

Removed unused gradient background resource
Changed foreground colors to pure black/white for better contrast
Updated app theme to use Material theme without action bar
Set splash screen delay to production value of 1200ms

How to test?

Launch the app and verify the splash screen displays for 1.2 seconds
Check both light and dark themes to ensure proper color contrast
Verify status bar is transparent
Confirm no visual artifacts from the removed gradient background

Why make this change?
These changes improve the visual consistency and user experience of the app by:

Using higher contrast colors for better readability
Implementing proper production timing for the splash screen
Removing unused resources to reduce app size
Maintaining a clean, modern appearance with transparent status bar

[!WARNING]
This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

#412
#411  👈 (View in Graphite)
#410
#409
#408
#407
main

This stack of pull requests is managed by Graphite. Learn more about stacking.

Merge activity

Dec 2, 1:04 AM EST: A user merged this pull request with Graphite.


Support prepared statements for query

As I feared, that change is unfortunately not enough:
     Reason: java.lang.IllegalStateException: Cannot find generators for database class liquibase.ext.neo4j.database.Neo4jDatabase, statement: liquibase.ext.neo4j.statement.ParameterizedCypherStatement@38fb50f8

This change has been tested end-to-end in https://github.com/liquibase/liquibase-neo4j/pull/195 and it works perfectly!
This would be a SUPER USEFUL addition for the Neo4j plugin.

Code Review and test results:
Things to be aware of

I worked with @fbiville on the changes. He tested that it works with his use case
Until I get the liquibase-sdk module split out, the change is in a module that I can't write an integration test for
It's not code that is used by anything in liquibase-core, but adds a capability usable by extensions (and future liquibase funtionality)

Things to worry about

Nothing


Fixes #1 Migrate specifications from old repo

We need to migrate the specifications for this BB from the old repo.
We ALSO need to move around some mock tests that ended up in the /spec folder

As per other INITIAL PRs into the per-bb spec, we cannot view the results of this PR until there is at least the beginnings of a structure defined to import into GitBook. So, testing this PR involves checking that

[ ] It contains a SUMMARY.md
[ ] It contains a README.md


Question: subtree filters with content match node

<get-config>
  <source>
    <running/>
  </source>
  <filter type="subtree">
    <if:interfaces xmlns:if="urn:ietf:params:xml:ns:yang:ietf-interfaces">
      <if:interface>
        <if:name>eth0</if:name>
      </if:interface>
    </if:interfaces>
  </filter>
</get-config>

send above xml to netopeer2-server,
in function op_get, it will create two filters like below:
/ietf-interfaces:interfaces/interface[name='eth0']/name
/ietf-interfaces:interfaces/interface[name='eth0']
is it correct behavior?

Hi,
I believe it is. The first filter is perhaps redundant but it is likely an optimization (in some similar cases it would not be redundant). If the result conforms to the RFC, it is correct.
Regards,
Michal

Thanks.
the get result is correct.


CommandBar implementation improvements

Platforms Impacted

[X] iOS
[ ] macOS

Description of changes
Make some additional improvements to the CommandBar implementation
--> The usages of CommandBar in CommandBarDemoController were not setting translatesAutoResizingMaskIntoConstraints to false
--> Move implementation from configureHierarchy() in CommandBarCommandGroupsView to be inline to reduce future confusion around use. The method should only be called once on init.
--> Update the CommandBar *ItemGroups properties to get and set the itemGroups property on the corresponding CommandBarCommandGroupsView. This will make it so that there is only 1 source of truth for each of the views.
--> Call setNeedsLayout after updating the value of leadingItemGroups and trailingItemGroups. In some cases, I found that the size of the containerMaskLayer was not updating as the leading and trailing views hide. Calling setNeedsLayout on the CommandBar marks the view as needing a layout and causes the containerMaskLayer frame to be updated.
Verification

Verified in devmain necessary devmain apps.
Verified in the CommandBarDemoController.
Some screenshots can be found in the original PR here.

Pull request checklist
This PR has considered:

[ ] Light and Dark appearances
[X] iOS supported versions (all major versions greater than or equal current target deployment version)
[ ] VoiceOver and Keyboard Accessibility
[X] Internationalization and Right to Left layouts
[ ] Different resolutions (1x, 2x, 3x)
[X] Size classes and window sizes (iPhone vs iPad, notched devices, multitasking, different window sizes, etc)
[ ] iPad Pointer interaction
[ ] SwiftUI consumption (validation or new demo scenarios needed)
[ ] Objective-C exposure (provide it only if needed)

Sorry if this is obvious, but would it be better to separate into multiple PRs? One which presumably will be undoing the revert (it sounds like additional changes on top are not needed and are instead needed in the consumer?) and then one for the other improvements which sound like they are unrelated?

The revert of the revert commit was put into a separate PR and merged. This PR is now on rebased on top of that commit (the tip on main).


Add repo for documentation site

Could you add the repo for the documentation site? This would open it up to contributors as well.
Great job on Caddy, btw! Looks awesome.

Thank you! That's a good idea. Will get around to that soon.

Here it is for now: https://github.com/mholt/caddyserver.com (/cc @coolaj86)
The repo will probably move soon, but at least it's up.


Document In Memory Grid Architectures in README

We can use this https://squidfunk.github.io/mkdocs-material/ to include markdown documentation and openapi/asyncapi specs using githubpages


[Web] How to use JS Charts In Flutter Web?

I want to use flutter develop my website.
But I don't know how to use the JS charts in Flutter Web.
I want to use the excellent and mature chart library such as Echarts/AntV.
Please help me, thanks!

The Github issue tracker is for bugs and features requests for the Flutter SDK. Help and support questions like these are better suited for Q&A sites like StackOverflow or on one of the flutter community sites at https://flutter.dev/community .

Have you found a solution?
I also want to use AntV in flutter


Wishlist: Make cache key elements explicit

Type: Feature
Task Name: CacheBeta@1
Environment
Azure Pipelines - but this is a feature wishlist item, not a bug,
Hosted agent
Issue Description
The current method of specifying a cache key has several issues.
First, it's very easy to generate invalid YAML with it, just by wanting to put literal strings first:
key: "v1" | some-file.txt

This is invalid because parsers see the double quote and assume that they value will be entirely quoted. There is a disgusting workaround, of course:
key: '"v1" | some-file.txt'

But this is a real eyesore!
The other issue is that we have to guess whether the task will interpret any given element as a path or not.
I propose a more explicit system for specifying the key where each key element is an array element:
key:
  - literal: v1
  - path: some-file.txt
  - literal: some-file-name

This is entirely unambiguous and doesn't require any odd double-quoting. As a bonus, this makes it trivial to introduce new types of key elements in the future if that is ever needed.

Great feedback @autarch !
Where it gets trick is with restore keys - which there are multiple of.  In some of our earlier iterations, we tried this, but we couldn't get a good array of arrays in YAML that we liked.  Do you have some ideas there?

Ah, that's a good point. YAML makes this so hideous, unfortunately. I think it might be acceptable to either accept a single array or a map of arrays, where the map keys are names (that are ignored):
restoreKeys:
  yarn-by-os:
    - literal: yarn
    - literal: $(Agent.OS)
  yarn-shared:
    - literal: yarn

This seems better than the truly heinous array of arrays in YAML:
restoreKeys:
- - literal: os
- - literal: yarn

Have I mentioned that I really don't like YAML?

Actually, no need for a single array, you already have that in key. You only need restoreKeys when you want multiple keys, so just a map of arrays seems fine.

Have I mentioned that I really don't like YAML?

Except Azure Pipelines YAML right? 😜  🤣
I like the maps.  I think we might be limited in what we can do with the task:'s inputs because they need to map to controls in the UI. 🤔  Well keep this in mind as we look at a cache: YAML alias.

Except Azure Pipelines YAML right?

Have you heard of CUE?

I have not - interesting. For now, the VS Code extension does do syntax correction/auto-complete for Pipelines YAMLs if you are looking for static checking/linting.

You will pry Emacs from my cold, dead hands, which will be curled into some unnatural Ctrl-Alt-Shift-$Letter shape.

Tracking this on the Azure Artifacts backlog now. :)

We do not have a good way to implement this in YAML without introducing further syntactic complexity.


Airplane Seat Assignment Probability

Problem Link
https://leetcode.com/problems/airplane-seat-assignment-probability/
Coding platform
Leetcode
Programming language

[ ] C
[ ] C++
[ ] Java
[ ] Python

Additional context (OPTIONAL)
I want to solve it in Java

I would like to code on this issue in C++.Kindly Assign me

I want to solve it in python,
Kindly assign me

Please merge this pull request
BFS: (Shortest Reach In A Graph) #449

Please merge pending pull request
BFS: (Shortest Reach In A Graph) #449

Mam Should i try this Issue in c++


accessing the cluster - access denied

when trying to access the mariadb cluster we get:
access denied for user<EMAIL_ADDRESS>
we are quite certain that we use the password from .secrets/mysql_root_password but wonder if the user created in the mariadb instance is for @localhost only?

It is created for both @localhost and @<IP_ADDRESS>, but not for @%. I thought this was common with how other MySQL-based images do it, is it not?

not sure about this, but I wonder how I am I supposed to access the cluster, if I can only access it from localhost? Or am I supposed to use an SQL-proxy and put it into the cluster network with an exposed port to the outside world?

There are several ways and I suppose the idea is to err on the side of security. You can easily add a less secure root account if you like either manually or via an init script, but there is nothing requiring it to even be named 'root' and not all users will want it to be '%', they may want it more restricted. But for starters:
docker exec -it <container_name> mysql

I just checked the latest Docker mariadb container and it looks like they added a $MYSQL_ROOT_HOST variable which can be used to specify a host other than localhost. Would need to port that change over to this image though as the docker-entrypoint.sh is replaced.

Added MYSQL_ROOT_HOST and MYSQL_ROOT_SOCKET_AUTH variables.


Return control to CMD console window by default after SQLOps application is closed

SQL Operations Studio Version:
Version 0.28.5-insider
Commit 3b90530717fa16ae289f6b4255b8f65cb089a893
Date 2018-04-24T03:24:41.772Z
Shell 1.7.11
Renderer 58.0.3029.110
Node 7.9.0
Architecture x64

Steps to Reproduce:
Any time if I launch the slops from command line on windows I notice that the command line doesn’t return me the prompt back once the application is closed.I have to manually hit enter or ctrl+c to get back to the prompt. This make the user believe that the process has not completely exited and its doing something in the backend. I was hoping once the process is shutdown the command line prompt should return back

Filing this issue based on Karl's inputs as follows
when SQL Ops is launched from a command window it appears to be capturing the consoles STDIO handles, and writing to them after returning control back to cmd.exe.  This behavior is present in the VS Code upstream code, so we’d likely prefer to have the fix applied there.
In the behavior you’re describing it doesn’t sound like the command terminal is frozen.  It’s more likely a STDERR message has been written to the console moving the focus from the input prompt.  Pressing ENTER returns focus back to the input prompt.
Please log a bug and we can work with upstream to understand this issue and where best to fix

Closing older "upstream" issues.  This should ideally be addressed in vscode code base.  Thanks for reporting!


This commit extends 'Bug' button's functionality

Due to huge amount of duplicate issues I decided to add a "Search" button so now campers can search issues in GitHub before opening an issue.
Also sometimes it's helpful to provide more info about what version of OS or browser camper is using so I added a checkbox and our campers now can provide such an information only setting a checkbox. By default this checkbox is unchecked.
Also I added a link to our Help I've Found a Bug Wiki article.
You can see visual changes in this video.

@benmcmahon100 Can you QA?


Multiple Icon Templates

This is a (multiple allowed):

[ ] bug
[x] enhancement
[x] question

Since Fontawesome 5 got released, I am faced with the distinction between icon shapes 'solid', 'regular', 'light', and 'brand'. These are selected through a supplemental class 'fas', 'far', 'fab' instead of simply 'fa' (which falls back to solid). While this is mostly a Fontawesome Pro feature, it also affects free users as some regular icons are free to replace the previous '-o' icons, and then there are the brand icons.
To be able to selectively use a specific shape we would need several icon templates, not only a default one. E.g.:
'icon' => [
    '_default' => '',
    's' => '',
    'b' => '',

Then we could enhance the magic icon syntax:
i:<iconname> // render icon['_default']
i:s:<iconname> // render icon['s']

Well the first problem with this idea is that templates reside in a flat array so my nesting would not work.
But just for the general idea.
What do you think about it and what design considerations would you have?
I would be happy to prepare a pull request for this feature.

That's an interesting idea, maybe a better idea for the templates would be to append something to 'icon', e.g.:
'icon' => '',
'icon-s' => '',
'icon-b' => ''

And when parsing the easy-icon, you get i:s:<iconame> and you render using icon-s. This way, users can easily add the icon templates they want and have them working with easy icons.
The following regex should work for parsing the icon:
(^|\s+)i:([a-zA-Z0-9\\-_]+:)?([a-zA-Z0-9\\-_]+)(\s+|$)

Something could be achieved by backing the icon template prior to the regex parsing, but maybe it is a better idea to add a custom option to the icon method in the HTML helper, like adding a 'template' option and defaulting it to 'icon'? Or maybe if you have some ideas on how the easy-icon trait can be detached from the HTML helper, I'll be glad to hear them, since it's something I am not really happy with...

I agree that the entry point to this functionality would be HtmlHelper's icon() method that could take a custom option for it. I will also have a closer look at the easy icon trait to see if I find a way to improve how it interfaces with the rest.

Options I considered:

Make icon() a functionality provided by EasyIconTrait and use the trait in HtmlHelper to expose to the user. All functionality is in one place. Drawback: Configuring the template does not work as expected (the template would need to be configured for all helpers exhibiting the trait individually).
Move the whole functionality of EasyIconTrait to HtmlHelper. All functionality, again, is in one place. Drawback: _makeIcon() and _easyIcon() need to be public methods and their hacky interface will be exposed.
Make an IconHelper for this. Drawbacks: Overkill, same drawback as option 2.

Have you thought about reversing how easyIcon works to make the interface less ugly? Consider replacing the call:
$this->_easyIcon('parent::link', 0, 2, [$title, $url, $options]);

with:
$this->Html->injectIcon($title, parent::link($title, $url, $options));

Now what insertIcon does is regex match $title within the already formatted HTML output of parent::link() and replace the icon at this point. No option mangling is needed.
Signature:
public function injectIcon($title, $text = null, $options = []);

Advantages:

No silent escape suppression. The text is still escaped as expected
Transparent in what it does, an interface that we can expose through the helper
Tag options can be supplied specifically for the icon (e.g., in my use case, where I wrote a custom button helper and add 'fa-fw' for menu buttons using _makeIcon())

What do you think about this idea?

This sounds interesting, I'd rather have this functionality in a IconHelper to separate it from HtmlHelper. HtmlHelper::icon could then falls back to IconHelper::icon (or something similar) for simplicity/compatibility.
You'd need to set templates for IconHelper instead of HtmlHelper but I think it's an improvement rather than anything else (HtmlHelper already contains two much templates... ).
I think we would need something to disable easy icon if needed, maybe:
$this->Icon->inject = false; // another name maybe

But it would be quite difficult to separate "automatic" injection from manual one... Maybe something else than a simple switch? I don't mind if this is not as simple as switching a variable to true/false since this is probably not used that often, I'd rather have something clean for this (if we make the icons clean, why not make everything clean ? 😃).
The regex for the pattern would need to be changed since it actually only matches beginning of string / pattern between spaces. At first glance this does not look too complex (would simply need to match > followed by spaces), but this would require more extensive testing than what is actually available.

Regarding the regex, my idea was to apply it on $title and then do a str_replace of $title within $text (if $title had matched and was actually altered). This is why it takes $title as a separate parameter, to make it safer against false replacements outside the title. We could harden it further by enforcing sth like '>{$title}<'.

I am not fan of this idea because:

You would need to str_replace against the possibly escaped $title, this means more work for the caller (need to pass $options) and the method (need to check), and it makes the interface not so user-friendly (people have to know that they should pass the escape if necessary).
...or you would need to escape $title before sending it to injectIcon, but this would require more work from the caller (in particular for all the automatically injected icon, this would add lots of boilerplate code... ).
Regarding the interface, this duplicates the place where you need to put the icon, e.g.:

$this->Icon->injectIcon('i:home', $this->SomeHelper->someMethod('i:home'));

I'd rather remove the $title option and parse the final $text, I don't think there would be much problem with this, especially if we provide something to disable it when needed, or maybe better, allow user to customize the matching pattern (and eventually disable it).

So the two issues you raise are argument duplication and how to deal with escaping.

For me the argument duplication is not a big deal as I only see calls for this method from other helpers or custom widget classes like one I wrote for myself. The usual developer will just call these or use icon() directly. So only few places in library/plugin code call injectIcon.

Escaping issue is a valid point, however I believe we would get away with simply trying to replace both escaped and unescaped title (try unescaped first, if it fails, escape it and try again). So it works transparently from the outside.

My counter argument for parsing the whole output is that people might have weird tag options where an 'i:something' slips in (e.g. data attributes). A test for '>i:something ' || ' i:something<' would certainly migitate this problem but would fail to work with a (stupid) button template like '<button>%nbsp;{{title}} </button>'.
I am just putting out my thoughts here, I am happy to implement either approach, just name it.
Regarding an easy way to disable it, obviously we can have enableInjection() / disableInjection() methods. I would like an easy way to do it case-by-case, e.g.
$this->Form->button('i:1 j:2', ['icon' => false]);

but this would lead to quite some extra work for the FormHelper (take icon option from option array, unset it in option array, pass it to injectIcon…), so it's probably not what we want after all.

Great idea of allowing matching pattern customization, I would add that I think for the user it is cleaner to have a setMatchingPattern() / enableMatching() / disableMatching() interface, as it is self-explanatory.

Just checked, it is enableMatching, disableMatching.

I think we could use named capture group in the regex so that user can customize how template are chosen depending on the pattern, e.g.:
// The <type> group is the special one used to select the actual icon.
$pattern = (^|[^\p{L}\p{N}]+)i:(?<type>[a-zA-Z0-9\\-_]+)([^\p{L}\p{N}]+|$);
$templatePattern = 'icon';

// New pattern, {{shape}} will be replaced by the matching:
$pattern = (^|[^\p{L}\p{N}]+)i:((?<shape>[srb]):)?(?<type>[a-zA-Z0-9\\-_]+)([^\p{L}\p{N}]+|$);
$templatePattern = 'icon-{{shape}}';

This way, this is extremely customizable, I could even use something like:
$pattern = (^|[^\p{L}\p{N}]+)i((?<toolkit>[srb]):)?:((?<shape>[srb]):)?(?<type>[a-zA-Z0-9\\-_]+)([^\p{L}\p{N}]+|$);
$templatePattern = 'icon-{{toolkit}}-{{shape}}';

To switch between FontAwesome and e.g. Glyphicon simply by doing i:fa:home or i:gl:home. Maybe we would need to find a way to find the template pattern when one of the matching group is not found, but that's something to consider I think.

I created a icon-helper branch, it'll be easier for me to accept PR to this branch and then merge it to master when everything is working as intended.

So this sounds like a version of preg_replace that supports named back references. Do a preg_replace_callback whereas the callback will fill-in all named captures as provided?
So in summary:

We have several templates and a default template selection as configurable by the user. we can provide common templates (for glyphicon and fontawesome) as defaults and glyphicon would be the default template selection
The user can configure the matching pattern, and the <template> capture group is used to determine the template from above, or if not present, default is used.
The user can also use/reference to other capture groups in both matching pattern and template strings at will which will be generically filled. The default pattern and templates would include a   (or ?) capture group for the icon name
There is a injectIcon option that is fished from '_original' or maybe '_parent' option array to disable functionality when false
We move over icon() from HtmlHelper and add a template option to it for convenience. Any other variables that the user defined in their templates they can provide with templateVars option.

Outside IconHelper:

formatAttribute() needs to strip/ignore injectIcon in custom template class
all helpers use IconHelper for injecting icons, passing $options as ['_parent' => $options]
HtmlHelper wraps icon() method by IconHelper

If you agree with this I will start working on the code.
Just as a remark I think the possibility of translating regex captures to template variables might be a bit of an obscure feature for this specific context.

So this sounds like a version of preg_replace that supports named back references. Do a preg_replace_callback whereas the callback will fill-in all named captures as provided?

I think preg_replace_callback handles named pattern since PHP 5.3, so it should be ok.

We have several templates and a default template selection as configurable by the user. we can provide common templates (for glyphicon and fontawesome) as defaults and glyphicon would be the default template selection

Yes, and templates would be in the IconHelper class.

The user can configure the matching pattern, and the <template> capture group is used to determine the template from above, or if not present, default is used.

You mean have <template> named groupe and use it like i:fa-icon-far:home?

The user can also use/reference to other capture groups in both matching pattern and template strings at will which will be generically filled. The default pattern and templates would include a   (or ?) capture group for the icon name

Yes, let's start with something matching shape and type (name to be confirmed) and replace it in a icon{{shape}} pattern for template.

There is a injectIcon option that is fished from '_original' or maybe '_parent' option array to disable functionality when false

Yes, I don't know if injectIcon or inject-icon would be the better, I think I have used the latter convention for some other options...

We move over icon() from HtmlHelper and add a template option to it for convenience. Any other variables that the user defined in their templates they can provide with templateVars option.

Yes, HtmlHelper::icon simply forwards everything to IconHelper::icon (or some other method).

formatAttribute() needs to strip/ignore injectIcon in custom template class

Yes, this can be easily done by calling parent::formatAttribute(..., ['injectIcon']);.

all helpers use IconHelper for injecting icons, passing $options as ['_parent' => $options]

Yes.

HtmlHelper wraps icon() method by IconHelper

Yes.

Just as a remark I think the possibility of translating regex captures to template variables might be a bit of an obscure feature for this specific context.

Maybe, but you'd be surprised by the number of obscure feature in this plugin 😀  I don't think that much people are even aware of the easy icon feature. As long as this does not disturb the basic usage of this feature, I'm fine with adding this.

Ok, so I will be working on this.

@ypnos-web After closing the above-mentioned PR, I was thinking about a nice feature that we could implement using __invoke and __call. Below is a (non-working) example:
class IconHelper {

    public function icon($type, $options = [], /* Extra? */) {
        $options += [
            'template' => $this->getConfig('defaultTemplate') // Something like this?
        ];
        // Whatever...
    }

    public function __invoke() {
        return call_user_func_array([$this, 'icon'], func_get_args());
    }

    public function __call($name, $arguments) {
        // Function name -> Template
        $result = $this->nameToTemplate($name);
        // Update arguments...
        $arguments[1]['template'] = $result;
        return call_user_func_array([$this, 'icon'], $arguments);
    }
};

Assuming $this->Icon is the icon helper, we could have stuff like this:
$this->Icon->icon('home'); // Default icon
$this->Icon('home'); // Same as above, less verbose.
$this->Icon->fa('home'); // Use icon-fa template?
$this->Icon->faS('home');; // Use icon-fa-s template?

At first, I thought about using faIcon as before, but since the helper is dedicated to icon, this seems redundant, and $this->Icon->fa('home') seems better for me.


Removed restangular from ProfileParameterService

What does this PR (Pull Request) do?
Removes a dependency on Restangular from the "ProfileParameterService"

[x] This PR partially addresses #3571

Which Traffic Control components are affected by this PR?

Traffic Portal

Traffic Portal dependencies are not individually documented, and so no documentation changes are necessary.
What is the best way to verify this PR?
No functionality should have changed (except that errors will now be logged instead of ignored in many cases), so the existing tests should all pass.
Jeremy: actually, the only way to truly verify that the functionality did not change is to:

run the UI tests (which is a very small subset of all TP functionality)
manually verify the functionality associated with ALL the services functions that changed just to be sure all is well.

The following criteria are ALL met by this PR

[x] This PR includes tests OR I have explained why tests are unnecessary
[x] I have explained why documentation is unnecessary
[x] This PR includes an update to CHANGELOG.md OR such an update is not necessary
[x] This PR includes any and all required license headers
[x] This PR does not include a database migration
[x] This PR DOES NOT FIX A SERIOUS SECURITY VULNERABILITY

Refer to this link for build results (access rights to CI server needed):
https://builds.apache.org/job/trafficcontrol-PR/3791/
Test PASSed.

Refer to this link for build results (access rights to CI server needed):
https://builds.apache.org/job/trafficcontrol-PR/4017/
Test PASSed.


High amount of log warnings from adapter after sonnenBatterie firmware update to 1.7.7

Describe the bug
After a firmware update of my sonnenBatterie eco 8.0 from version 1.6.x to 1.7.7 I now see a lot of warning messages from the sonnen adapter (version 1.11.0). It seems that the adapter tries to connect to not (anymore) existing endpoint on the sonnenBatterie.
Requesting API seems to work fine and data is there.
To Reproduce
Steps to reproduce the behavior:

Open iobroker logs
You can see 2 WARN log entires per request intervall (see log messages below)

Expected behavior
Stop querying non-existing sonnenBatterie endpoint and stop to flood iobroker logs.
Screenshots & Logfiles
These two log entries occur with every request interval:
sonnen.0 | 2022-09-01 16:58:26.693 | warn | [SETTINGS] Error receiving configuration: 404 - "{\"error\":\"404 Not Found\"}"
-- | -- | -- | --
sonnen.0 | 2022-09-01 16:58:26.675 | warn | [ADDITIONAL]  Error on requesting additional endpoints: Could not request ios  endpoint: 404 - "<!DOCTYPE html>\n\n\n<meta http-equiv=\"Content-Type\"  content=\"text/html; charset=utf-8\"  />\n<title>sonnenBatterie</title>\n<meta  charset=\"utf-8\">\n<meta content=\"IE=edge,chrome=1\"  http-equiv=\"X-UA-Compatible\">\n<meta  content=\"width=device-width,initial-scale=1\"  name=\"viewport\">\n<link rel=\"stylesheet\" type=\"text/css\"  href=\"/error.css\">\n\n\n
\n

\n
\n
Something went  wrong
\n
Page not found
\n
Try  again
\n
\n
\n\n\n"

Versions:

Adapter version: v1.11.0
JS-Controller version: 4.0.23
Node version: v16.17.0
Operating system: Debian GNU/Linux 11 (bullseye)
Battery model: sonnenBatterie eco 8.0 (firmware version <IP_ADDRESS>8395)

Additional context

Update:
My sonnenBatterie had now been downgraded to a firmware version <IP_ADDRESS>3111 (from 1.7.7) and the error messages are gone since then.

Please put loglevel to error for now. I have some information about the api a changes now and are currently thinking about best strategies to integrate it because api of Sonnen will be changed step by step.

Is it correct that with firmware 1.7.7 port 8080 is stopped?
I ask because many points are no longer provided by V2:
http://IP:8080/api/configuration
http://IP:8080/api/battery
http://IP:8080/api/setting

Yes, unfortunately some are stopped w/o replacement for now.

How can install v 1.12.0 / 1.13.0 ? In IoBroker there's only 1.11.0 available.
I have the same warning in the Logfile as pnuts

1.13.0 is stable now

Should 1.13.0 have fixed the warn messages? I still get loads of "Could not request ios endpoint" warnings
Thanks  - Michael

@skyx3 - Thanks!
But the "Could not request ios endpoint" messages in the log are still exists :/

Hello,
same problem here:
[ADDITIONAL] Error on requesting additional endpoints: Could not request ios endpoint: 404 - "\n\n\n<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />\nsonnenBatterie\n<meta charset="utf-8">\n<meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible">\n<meta content="width=device-width,initial-scale=1" name="viewport">\n<link rel="stylesheet" type="text/css" href="/error.css">\n\n\n
\n
\n
\nSomething went wrong\nPage not found\nTry again\n\n\n\n\n"
Software version of the Batterie:
<IP_ADDRESS>2029

Mit Software Version 1.8.7 kommen die Endpunkte zurück, der Inverter liefert nun allerdings andere Daten als vorher.

Hier benötige ich Feedback was interessant ist hiervon.


Allow syncing in the background

Until this is implemented, there will always exist a high possibility of bugs like this:

User makes significant edits to a post
A phone call comes in, app goes to background, edits are saved but not synced to the server
User does not open the app for several days
In that period, someone else (or this same user) makes some edits to the same post through the web interface -- at this point the user may notice their several days old edits have not appeared yet!
Now the user opens the app and a sync occurs -- this will end up overwriting the remote copy with edits in step 4 with the old edits!

This sample offline architecture may help (presented at the Android Dev Summit architecture talk): https://github.com/yigit/dev-summit-architecture-demo

Removed from 1.0 as this is a pretty big change.

GCM Network Manager looks like the best way to do this: it's convenient, flexible and conserves battery. Here's a great overview: https://www.bignerdranch.com/blog/optimize-battery-life-with-androids-gcm-network-manager/
It should be noted that with GCM moving over to Firebase, the GCM Network Manager will eventually be superseded by Firebase Job Dispatcher.


Slick within slick events

When you create a slick within slick, the parents events are fired instead of the selected event,
`

`
What is the expected behaviour?
To not fire the parents events, or just include the id of the slider where the event originated,

Legit issue. Definitely worth a fix. I think in the meantime you can get around it by controlling for event bubbling/capturing on your listener. Thanks!


No error message displayed in the Run Script qith the built-in Web UI

I can execute some YQL script with ydb. If a statement fails, ydb returns an error message:
[oleg@oleg2 ~]$ ydb yql -s "CREATE TABLE tab2 (id Uint64, value1 json, primary key(id));"
[oleg@oleg2 ~]$ ydb yql -s "CREATE TABLE tab2 (id Uint64, value2 json, primary key(id));"
Status: GENERIC_ERROR
Issues:
<main>: Error: Type annotation, code: 1030
    <main>:1:56: Error: At function: KiCreateTable!
        <main>:1:56: Error: Table name conflict: kikimr.[/Root/test/tab2] is used to reference multiple tables.

But if I try to execute the same YQL statement in the built-in Web UI, I receive the result Failed without any error message.
I'd like to see the same error message as I can see with ydb.

@Raubzeug @adameat Can you take a look?

KIKIMR-14997


Update README.md

I came here looking for this dictionary (https://marketplace.visualstudio.com/items?itemName=rbalet.code-spell-checker-fullstack) but did not find it, noticed these were missing from the README.md so I added them. Also, I was considering adding some terms to the EN dictionary is it possible? Are you looking for active maintainers? I do not mind to add things as I see them as I edit a lot of blog posts in markdown so I come across many missing en words.

Feel free to close this if not needed. :-)

Thank you.
Please feel free to add word to streetsidesoftware/cspell-dicts: Various cspell dictionaries


Update ASM to 7.2 to be JDK 13 compatible.

ASM must be updated to be JDK 13 compatible.
Moved the DependencyManagement block of ASM to the parent, as multiple sub-modules uses ASM. Otherwise, the sub-modules would use a different version of ASM (7.0 through transitive dependency of ByteBuddy).

Sorry for the lately reply, I just push #513 and will have a release as soon as possible.

ModelMapper v2.4.1 was just released including the fix.


import data from url

this webpack plugin front loads all data and blocks the app from running until its done,
not dynamic but the benefit here is that data does not have to be local to the machine and we can upload/replace data files on a server and have it magically update everything

Closing, as the data flow is now handled by a server/DB


bug: getting error while resolving a did:ethr on sepolia

Describe the bug
Issue Overview
When resolving a did did:ethr:sepolia using the masca resolveDID rpc method, the following error is returned:
"Error: call revert exception [ See: https://links.ethers.org/v5-errors-CALL_EXCEPTION ] (method="changed(address)", data="0x", errorArgs=null, errorName=null, errorSignature=null, reason=null, code=CALL_EXCEPTION, version=abi/5.7.0)"

Other Context
This error indicates that the did does not exist/has not been created. However, when instantiating the Veramo agent within a nodejs runtime, it resolves.
To Reproduce
Invoke masca rpc resolveDid
Expected behavior
The rpc call should resolve the provided did document.

Hi. Thank you for reporting the issue.
With which version of Veramo did you test this ?

Hey, thanks for your response. I am using the below veramo version:
"@veramo/did-comm": "5.5.4-next.32"

I have raised a PR with the fix (#545)

Hi. We are using the latest Veramo version 5.5.3.
I updated the all the Veramo package versions yesterday (to 5.5.4-next.32), but I still need to test if everything works correctly now.
If I don't encounter any new issues, I will create a new beta release of Masca today.

Appreciate it. Thanks @martines3000!

Hey @radleylewis. I created a new release (v1.2.0-beta.2) available here:
<EMAIL_ADDRESS>You will need MetaMask Flask for this version. You can test it on our beta dapp


Do you have a complete example about  spring-cloud-stream-binder-jms with ActiveMQ?

I am new to spring-cloud-stream-binder-jms.
I try to write a example about  spring-cloud-stream-binder-jms with ActiveMQ, but failed.
Anybody help?

Have you tried with ibm mq use the following configuration
add
implementation "com.ibm.mq:mq-jms-spring-boot-starter:$springMQJmsVersion"
IBM MQ ENV
IBMMQ_HOST: localhost
IBMMQ_PORT: 1414
IBMMQ_USER: admin
IBMMQ_PASSWORD: passw0rd
IBMMQ_QUEUE_MANAGER: QM1
IBMMQ_CHANNEL: DEV.ADMIN.SVRCONN
ibm:
mq:
user: ${IBMMQ_USER}
password: ${IBMMQ_PASSWORD}
conn-name: ${IBMMQ_HOST}(${IBMMQ_PORT})
queue-manager: ${IBMMQ_QUEUE_MANAGER}
channel: ${IBMMQ_CHANNEL}
ibmmq:
image: ibm-messaging/mq
container_name: ibm-mq
ports:
- "1414:1414"
- "9443:9443"
- "9157:9157"
environment:
LICENSE: "accept"
MQ_QMGR_NAME: "QM1"
#    volumes:
#      - ~/mqm-data:/var/mqm
restart: unless-stopped

@mohammedamineboutouil   thank you very much for your reply!
I  have wrote a example about spring-cloud-stream-binder-jms with ActiveMQ，it works fine.
https://github.com/waylau/spring-cloud-stream-tutorial/blob/main/docs/spring-initializr-cloud-stream-jms.md


Fixed fast color mapping

Here's what I mean:
Before

After

Code used in both cases
This is kinda production ready, but I only tested it on .net 4.7 and 4.5, your results may vary. I can test on the weekend if needed.

Thanks for the PR -- this looks great!  I really appreciate the contribution.


Active Soccer 2 DX [PCSB01008]

App summary
App name: Active Soccer 2 DX
App serial: PCSB01008
App version: 1.00
Vita3K summary
Version: v0.1.8
Build number: 3212
CPU backend: Dynarmic
Test environment summary
Tested by: space1
OS: Win11
CPU: AMD Ryzen 5 3600
GPU: Nvidia 3070
RAM: 32 GB
Issues
Players are invisible ingame.
Screenshots

Log
vita3k.log

Vita3K summary

Version: v0.2.0
Build number: 3685
Commit hash: https://github.com/vita3k/vita3k/commit/5857acd8
CPU backend: Dynarmic
GPU backend: Vulkan

Test environment summary

Tested by: Slade
OS: Microsoft Windows 10 Professional (build 19045)
CPU: Intel(R) Core(TM) i7-3770K CPU @ 3.50GHz
GPU: NVIDIA GeForce GTX 1060 6GB
RAM: 16 GB

Issues
Game plays well with full audio and no issues noted on graphics.
Vita3K threw an exception when quitting the game (via the Windows X button in the top right corner).
Frame rate is not stable, but that's likely to be my aging PC more than anything.
Screenshots

Log
vita3k.log
Recommended labels

Playable


Add Bootstrap C# API. Spec Bootstrap C# and get GenerationId (Flat-C/WinRT) APIs

Update spec for the Bootstrap C# API and Dynamic Dependency GenerationId property.
Spec @ Spec updates for GenerationId and Bootstrap C# API #1284
This PR also includes some internal maintenance (reorganizing some project layout).

Just some minor feedback. 👍

/azp run

/azp run

/azp run

/azp run

/azp run

Looking pretty good. Would be useful to have a test, and see the comment about not needing the _Nothrow variant.

We have IntegrationTests/gates in the internal repo. They currently use the 0.8-preview Samples' MddBootstrap.cs as a placeholder, to be updated once this is available. That will serve multiple ends:

tests exercising this API
IntegrationTests exercising E2E flow
gates to prevent regressions
simple starter projects for other devs to use as a starter on their unpackaged tests (@MikeHillberg was chomping at the bit ;-)
working reference for Sample updates

/azp run

/azp run

/azp run

/azp run

/azp run

/azp run

/azp run

/azp run

/azp run

/azp run

/azp run


Various updates to connection methods

Add a 'loop' state and loop_respond method; used in rdns_respond and connection_respond methods, so that if anything other than OK or CONT are returned, no other commands can be sent and the session does not progress (QUIT is allowed though).

Changed the default response codes in rdns_respond and connect_respond to be more RFC compliant

Changed the EHLO/HELO response not to output connection.remote_host if it isn't set or is NXDOMAIN or DNSERROR.

Check for command arguments to RSET, DATA and QUIT as per the RFC.

Just updated this to add DENYSOFTDISCONNECT as a valid return as I have a use case for this in a new plug-in that I'm writing (rate_limit).


It will only talk once?

Describe the bug
Calling textToSpeech.Speak("Hello World!"); only works the first time.
After that, if you want it to talk again, you have to stop and restart playmode in the unity editor.
To Reproduce
Steps to reproduce the behavior:

Call textToSpeech.Speak("Hello World!"); once per second.
Notice that it speak the first time, but not on any subsequent calls.

Expected behavior
It should speak every time you call the Speak function.
Desktop (please complete the following information):

OS: Windows 10

I used a workaround for this by turning each sentence into an object of its own that gets discarded afterwards. Your exact implementation might differ but the core concept might be the same. I create a pool of speakers so that they can instantiate in peace (as the mappings are read in the Start() method of TTSProcessor.cs and I was getting errors when trying to run it right away). It's probably a less-than-optimal solution but it works.

hey @maxg0 @BrainSlugs83 is this still an issue currently now that I have fixed this #2

@nixon-voxell Yes, the issue still persists. I'm getting no error messages either.

Ok, I'll take a look on this issue.

Heya, any potential fixx for this yet?

Looks like it could be an issue with tensorflow library? Tracing through callstack just leads to TfLiteInterpreterGetOutputTensor returning a bunch of 0s after the first call for some reason. Or maybe it could be the fastspeech model? I will try a different model (although I'm not sure where I can find it, I will try).

The issue was located here:
https://github.com/asus4/tf-lite-unity-sample/issues/260#issuecomment-1404928610
From my limited understanding of C#, UnityTTS is passing an Array that gets deallocated at the end of the function when the Interpreter GCHandle still contains a shallow copy of the array in the dictionary. When calling it a second time, the same tensor index is being used and assumes that the array is still active in that tensor index, when there is nothing to use.

This is my workaround for now until I have more time to make a more elegant fix. This is not ideal for performance but at least makes the voice trigger every call.

i see, thanks for the info!

This is my workaround for now until I have more time to make a more elegant fix. This is not ideal for performance but at least makes the voice trigger every call.

Seems like not just a performance issue, but a resource leak as well. -- You're calling GCHandle.Alloc(), but you're never calling Free() on that GCHandle.
Reference: https://learn.microsoft.com/en-us/dotnet/api/system.runtime.interopservices.gchandle.alloc?view=net-8.0


rsgx unit tests return output

Hi,
rsgx_unit_tests in awesome. it looks great and works great.
the only problem is that because it's unrelated to rust's test suite we need to somehow return -1 from the threads if there was any failure, so that CI's will fail this.
I see a couple of ways to do this.

That rsgx_unit_test_end() will return the length of failurecases.
that rsgx_unit_test_end() will return failurecases.is_empty().
maybe failurecases will panic at the end if failurecases isn't empty? I'm not sure what will be the behavior here.

then you could pass this output back via the edl and assert on the untrusted side (or in the trusted side but again, I have a feeling that assertion in the enclave in tests can crash the whole process)
what do you think? tell me what you decide and I can make a PR to change the functions,macro and the samplecode accordingly.
Thanks.

Hi Elichai,
I've been thinking about the same problem for a while -- in my current drone script I only "grep" the output for " 0 failed" for a hack (ugly!).
Personally, I like (1) -- it provides more information which might be useful in CI. What do you think? I'm very glad to merge PR :-)

yeah I also this 1 is the best solution for the function and macro.
I hoped we can make the thread return -1 from the enclave it self but I think that's not possible without UB for the other tests, right?
Maybe I'll try to play with it a bit.

what's the UB?  :joy:

That it would probably just crash all of the tests? lol

So it seems to me that 1 is the best option for knowing the result.
and the only option (if you can think of another please let me know) to fail the test visibly without crashing the other tests, is by returning some value and asserting on the outside.
If you agree I'll make a PR tomorrow to change both sgx_tunittest and the sample_code/unit-test

Yeah I like the idea of asserting the value of failed count on the outside! I'll merge your PR 😆


Fix Ping data-race

While testing some code under -race flag, the race detector flagged a data race on spdystream.Ping code path.
==================
WARNING: DATA RACE
Read at 0x00c012a966a8 by goroutine 483923:
  github.com/moby/spdystream.(*Connection).handlePingFrame()
      /go/pkg/mod/github.com/moby/spdystream@v0.2.0/connection.go:615 +0x3e
  github.com/moby/spdystream.(*Connection).frameHandler()
      /go/pkg/mod/github.com/moby/spdystream@v0.2.0/connection.go:432 +0x144
  github.com/moby/spdystream.(*Connection).Serve.func2()
      /go/pkg/mod/github.com/moby/spdystream@v0.2.0/connection.go:331 +0xa6
  github.com/moby/spdystream.(*Connection).Serve.func4()
      /go/pkg/mod/github.com/moby/spdystream@v0.2.0/connection.go:332 +0x47

Previous write at 0x00c012a966a8 by goroutine 483918:
  github.com/moby/spdystream.(*Connection).Ping()
      /go/pkg/mod/github.com/moby/spdystream@v0.2.0/connection.go:281 +0x117
  github.com/moby/spdystream.(*Connection).Ping-fm()
      <autogenerated>:1 +0x39
  k8s.io/apimachinery/pkg/util/httpstream/spdy.(*connection).sendPings()
      /go/pkg/mod/k8s.io/apimachinery@v0.26.3/pkg/util/httpstream/spdy/connection.go:197 +0x1b6
  k8s.io/apimachinery/pkg/util/httpstream/spdy.newConnection.func2()
      /go/pkg/mod/k8s.io/apimachinery@v0.26.3/pkg/util/httpstream/spdy/connection.go:96 +0x47

Goroutine 483923 (running) created at:
  github.com/moby/spdystream.(*Connection).Serve()
      /go/pkg/mod/github.com/moby/spdystream@v0.2.0/connection.go:327 +0x9e
  k8s.io/apimachinery/pkg/util/httpstream/spdy.newConnection.func1()
      /go/pkg/mod/k8s.io/apimachinery@v0.26.3/pkg/util/httpstream/spdy/connection.go:94 +0x47

Goroutine 483918 (running) created at:
  k8s.io/apimachinery/pkg/util/httpstream/spdy.newConnection()
      /go/pkg/mod/k8s.io/apimachinery@v0.26.3/pkg/util/httpstream/spdy/connection.go:96 +0x34d
  k8s.io/apimachinery/pkg/util/httpstream/spdy.NewClientConnectionWithPings()
      /go/pkg/mod/k8s.io/apimachinery@v0.26.3/pkg/util/httpstream/spdy/connection.go:57 +0x224
  k8s.io/apimachinery/pkg/util/httpstream/spdy.(*SpdyRoundTripper).NewConnection()
      /go/pkg/mod/k8s.io/apimachinery@v0.26.3/pkg/util/httpstream/spdy/roundtripper.go:357 +0x644
  k8s.io/client-go/transport/spdy.Negotiate()
      /go/pkg/mod/k8s.io/client-go@v0.26.3/transport/spdy/spdy.go:98 +0x42d
  k8s.io/client-go/tools/remotecommand.(*streamExecutor).newConnectionAndStream()
      /go/pkg/mod/k8s.io/client-go@v0.26.3/tools/remotecommand/remotecommand.go:125 +0x2d7
  k8s.io/client-go/tools/remotecommand.(*streamExecutor).StreamWithContext()
      /go/pkg/mod/k8s.io/client-go@v0.26.3/tools/remotecommand/remotecommand.go:157 +0xbc
==================

This PR aims to fix the present data race

@thaJeztah @dims PTAL

@thaJeztah @dims any update on this one?

Howdy @dmcgowan @tigrato @thaJeztah :wave: Is there any reason this PR has not been merged yet? It's been approved for over 6 months. The bug is impacting other systems (e.g. https://gitlab.com/gitlab-org/gitlab-runner/-/issues/31077). What's missing to get this merged? :bow:

Howdy @dmcgowan @tigrato @thaJeztah :wave: Is there any reason this PR has not been merged yet? It's been approved for over 6 months. The bug is impacting other systems (e.g. https://gitlab.com/gitlab-org/gitlab-runner/-/issues/31077). What's missing to get this merged? :bow:

I am waiting for someone with write access to merge the PR.
At gravitational, we keep a fork of this library https://github.com/gravitational/spdystream (branch is teleport) where we included this fix to avoid having crashes and several data races flagged during tests.

Thanks @tigrato :+1:

ran into this as well. Is this repo dead?

This project is open source, feel free to add reviews. Especially if you have a fork and verified the change, thats valuable for determining the change is good. This project is very inactive so its hard to be confident a change is ready to merge.  I prefer waiting until multiple reviews to hit the merge button.