Make broker's rest resource packages configurable

Rest resources to be included in the broker is configurable now
Added -configOverride to StartBrokerCommand

Labels: feature , release-notes
Release Notes

New configuration to control the rest resources in a broker application:

broker.restlet.api.resource.packages - Comma separate list of package namespaces; Default: org.apache.pinot.broker.api.resources

StartBrokerCommand can now accept -configOverrides as a command line option.

@walterddr  / @Jackie-Jiang : Please review

Codecov Report

Merging #10588 (15db8e5) into master (114a81e) will increase coverage by 4.33%.
The diff coverage is 100.00%.

@@             Coverage Diff              @@
##             master   #10588      +/-   ##
============================================
+ Coverage     27.90%   32.23%   +4.33%
- Complexity       58      453     +395
============================================
  Files          2087     2106      +19
  Lines        112306   112972     +666
  Branches      16918    17014      +96
============================================
+ Hits          31340    36419    +5079
+ Misses        77869    73267    -4602
- Partials       3097     3286     +189

Flag
Coverage Δ

integration1
24.61% <100.00%> (+0.23%)
:arrow_up:

integration2
?

unittests2
13.89% <100.00%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files
Coverage Δ

...va/org/apache/pinot/spi/utils/CommonConstants.java
0.00% <ø> (ø)

...pinot/broker/broker/BrokerAdminApiApplication.java
86.95% <100.00%> (+0.38%)
:arrow_up:

... and 546 files with indirect coverage changes
:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more


Primary key support

This adds primary key support.
Highlights:

Primary keys are marked with the @PrimaryKey annotation on the field in the model definition
Objects needs to have primary keys when added to the realm. Either by supplying it when creating it through create(type, primaryKey) or by ensuring that unmanaged objects have the right value before importing it by copyToRealm or by assigning the object to a field of an already managed objects.

Modeling:
    @PrimaryKey
    var id : String

Creation
class Realm {
   fun <T : RealmObject> create(type: KClass<T>, primaryKey: Any?): T
}

Internals:
interface RealmObjectCompanion {
   val `$realm$primaryKey`: KMutableProperty1<*, *>
}

TODO:

[x] Darwin support

Closes #122

@nhachicha I address all your comments. Only leftover is finding a way to move PropertyDesciptor out of the library-module.

@nhachicha Finally some green light at the end of the CI tunnel. I have moved the behavioral compiler plugin tests to the test's jvmTest and cleaned up the test source sets with some slight modifications as a side effect. Don't know if you want to give that a glance? Otherwise I finally will merge it.


Investigate spaces to hold the event

We need a place to hold the event! Let's find one!

What are the space requirements? How many rooms do we need and what’s the biggest seating requirement?


streaming: use table_id as topN prefix

Refer to:

https://github.com/singularity-data/risingwave/pull/2233
https://github.com/singularity-data/risingwave/pull/2172
https://github.com/singularity-data/risingwave/pull/1987


Allow to re-pick a contract address

closes #1080

Travis automatic deployment:
https://pr1101--safereact.review.gnosisdev.com/app

This issue is blocked by #1104, when that's merged we have to update this PR. Without that PR I cannot load safes, so i cannot test this fix

Travis automatic deployment:
https://pr1101--safereact.review.gnosisdev.com/app

It works now.
Note: For the Contract interaction you have to delete the address for the "Address book" suggestions to popUp (for custom tx's you just double click the address input and the "Address book" suggestions show up), but is a minor inconvenience. Won't stop the ticket for that.
Looks good to me

Travis automatic deployment:
https://pr1101--safereact.review.gnosisdev.com/app


Branch filtering issues - NullPointerException

Expected Behavior
The attached source files help to reproduce a Java error in the branch-filter step.
Actual Behavior
The publishing throws this NullPointerException, which causes the build to fail.
Possible Solution
No idea
Steps to Reproduce
Download the test files branch-filtering-override.zip and build the deliverable from the DITA-OT project file .
Copy of the error message, log file or stack trace
branch-filter:
[branch-filter] Processing file:/C:/Users/eike/workspace/branch-filtering-override/temp/branch-filtering-override.ditamap
[branch-filter] Reading file:/C:/Users/eike/workspace/branch-filtering-override/expert.ditaval
Error: java.lang.NullPointerException: Cannot read field "src" because "fi" is null

Environment

DITA-OT version: 3.6.0, 3.7.4
Operating system and version: Windows 10
How did you run DITA-OT? oXygen
Transformation type: pdf2

The stack trace of the error is something like this:
java.lang.NullPointerException: Cannot read field "src" because "fi" is null
at org.dita.dost.module.BranchFilterModule.getFilterUtils(BranchFilterModule.java:481)
at org.dita.dost.module.BranchFilterModule.combineFilterUtils(BranchFilterModule.java:357)
at org.dita.dost.module.BranchFilterModule.filterTopics(BranchFilterModule.java:433)
at org.dita.dost.module.BranchFilterModule.filterTopics(BranchFilterModule.java:467)
at org.dita.dost.module.BranchFilterModule.processMap(BranchFilterModule.java:144)
at org.dita.dost.module.BranchFilterModule.execute(BranchFilterModule.java:103)

Somehow seems to be related to the fact that the same ditaval file is referenced multiple times in the DITA Map, if I were to replace:
<topicref href="topic3.dita" audience="expert">
    <ditavalref href="expert.ditaval"/>
</topicref>
<topicref href="linux.dita" platform="linux">
    <ditavalref href="expert.ditaval"/>
</topicref>

with:
<topicgroup>
    <ditavalref href="expert.ditaval"/>
    <topicref href="topic3.dita" audience="expert"/>
    <topicref href="linux.dita" platform="linux"/>
</topicgroup>

the error would no longer occur.

@raducoravu You are right, but still I consider this to be a bug. We have a couple of branches (maps) which have to be filtered with the same settings and a few with different settings. For us this means, I need to create tons of DITAVAL files. Let's say I have 25 branches (maps) and 23 of these are filtered the same way, I need to create and maintain 23 different DITAVALs instead of just one and make sure they have the same content, which is very error prone and time consuming.

@xephon2 I did not say this is not a bug, it was just a remark based on me working a bit with the samples.

+1 using DITA OT 4.1 this reported issue seems to produce the same null pointer exception:
https://stackoverflow.com/questions/76593411/using-same-ditaval-references-under-parent-map-and-sub-map-causes-null-pointer-e
Adding a sample for it as well:
npeBranchFilter.zip
 Users/...dita-ot-4.1/plugins/org.dita.base/build_preprocess.xml:163: java.lang.NullPointerException: Cannot read field "src" because "fi" is null
at org.dita.dost.module.BranchFilterModule.getFilterUtils(BranchFilterModule.java:467)
at org.dita.dost.module.BranchFilterModule.combineFilterUtils(BranchFilterModule.java:342)
at org.dita.dost.module.BranchFilterModule.filterTopics(BranchFilterModule.java:416)


How to use swing mode for AC

Home Assistant version
Home Assistant Core 2021.2.3
Operating System 5.11
SmartIR version
SmartIR 1.16.0
SmartIR configuration

smartir:

climate:
  - platform: smartir
    name: Ar Condicionado Sala
    unique_id: salatv_ac
    device_code: 1400
    controller_data: remote.broadlink_rm2_pro_remote
    temperature_sensor: sensor.mi_temperature_temperatura_sala
    humidity_sensor: sensor.mi_humidity_temperatura_sala

Describe the bug
I've read that swing mode is now compatible, and I'm trying to enable/disable swing mode of my Samsung AC, but it doesn't have and option. I tried via service: climate.set_swing_mode, but it won't do anything.

The device code file will need to be updated with the codes for Swing mode

As you are using a broadlink, probably you are still using the old code..
Using the for using the swing, you need to read and re write all the swing position for all temps and modes. I did it for my mqtt controller, it took too much time, but easy. For broadlink, you would need to start reading your controller

Here is the code I made, just as an example
2019.zip


Dart: update benchmark to Dart 3.0

Summary of changes
Changes introduced in this pull request:

Update Dart SDK to 3.0
Remove gRPC package deprecations
Fix Docker build stage

Reference issue to close (if applicable)
Closes #146
As fart as I think Dart is required for this benchmark 'cause it's one of the "official" grpc languages I fixed the benchmark. Current version of Dart is 3.0.5 so the SDK was updated to this release. Also dependencies and the pubspec file were updated accordingly.
I also renamed benchmark folder to be able to activate this benchmark. Testes locally and it worked like a charm.
Hope it help! Any commend are appreciated!

@amka Thanks! Could you please update the CI? You can either call build.sh (or bench.sh) with the Dart suite or run ./generate_ci.sh >.github/workflows/build.yml and commit that.

Sure, I will do it!

I'm a bit pushed for time; I'll try to check this out this weekend @amka!

I'm a bit pushed for time; I'll try to check this out this weekend @amka!

Oh, no worries! It's your repo! I'm just the guy who's trying to help :)

Not sure why the script generated it for you this way, let's not bother with it. If you'd put dart after d to make CI happy it should be fine. Oh, and if you could please do these changes with git mv that'd be great, the old dart_grpc_onhold is still lingering there.

Not sure why the script generated it for you this way, let's not bother with it. If you'd put dart after d to make CI happy it should be fine. Oh, and if you could please do these changes with git mv that'd be great, the old dart_grpc_onhold is still lingering there.

@LesnyRumcajs  Not sure I understand you correctly about git mv. Do you mean to replace the old one _onhold with a new _bench folder?

Not sure why the script generated it for you this way, let's not bother with it. If you'd put dart after d to make CI happy it should be fine. Oh, and if you could please do these changes with git mv that'd be great, the old dart_grpc_onhold is still lingering there.

@LesnyRumcajs Not sure I understand you correctly about git mv. Do you mean to replace the old one _onhold with a new _bench folder?

Yes, precisely. The _onhold suffix means that the particular bench suite was disabled for whatever reason. Your contribution effectively replaces it. At the current state of the PR, you can just remove it.

@amka did you try running it locally recently? It seems to be failing in the CI.

I've got a weird issue. When I ran sh ./bench.sh dart_grpc_bench locally for the first time it worked like a charm. When I rerun it - it fails quickly. We'll investigate it.

@amka I fixed the meta check (whitespace issue), now the dart server is failing.  I debugged it a bit, locally. The server seems to be crashing during the warmup period, from time to time. See the error message:
❯ docker logs dart_grpc_bench -f
Server listening on port 50051...
Unhandled exception:
Null check operator used on a null value
#0      ServerHandler.sendTrailers (package:grpc/src/server/handler.dart:384)
#1      ServerHandler._sendError (package:grpc/src/server/handler.dart:459)
#2      ServerHandler._onResponse (package:grpc/src/server/handler.dart:327)
#3      _RootZone.runUnaryGuarded (dart:async/zone.dart:1594)
#4      _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:339)
#5      _BufferingStreamSubscription._add (dart:async/stream_impl.dart:271)
#6      _SyncStreamControllerDispatch._sendData (dart:async/stream_controller.dart:784)
#7      _StreamController._add (dart:async/stream_controller.dart:658)
#8      new Stream.fromFuture.<anonymous closure> (dart:async/stream.dart:250)
#9      Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:846)
#10     Future._propagateToListeners (dart:async/future_impl.dart:875)
#11     Future._chainCoreFutureSync (dart:async/future_impl.dart:575)
#12     Future._chainCoreFutureAsync.<anonymous closure> (dart:async/future_impl.dart:613)
#13     _microtaskLoop (dart:async/schedule_microtask.dart:40)
#14     _startMicrotaskLoop (dart:async/schedule_microtask.dart:49)
#15     _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:118)
#16     _RawReceivePort._handleMessage (dart:isolate-patch/isolate_patch.dart:185)

It might make sense to bump the dependencies, perhaps the ones defined in pubspec.yaml and pubspec.lock are faulty?

Stale. Closing.


Make it easier to self host Ambient servers

--use-https options to serve http content with TLS so that it conforms to Secure context restrictions (https://github.com/AmbientRun/Ambient/issues/1143)
simple embedded web client page hosting when running a released version (https://github.com/AmbientRun/Ambient/issues/1133)

FYI @kevzettler this should be available in the most recent nightly (0.3.2-nightly-2023-11-09)


After finetuning in a different dataset, output is wrong

I have this dataset
data.zip
logs from finetune

example of answers, when the question is related to the new dataset (like the last question), the output is the input?

Instruction: Tell me about alpacas.
Response: Alpacas are animals that live in South America. They are related to llamas and camels. Alpacas are smaller than llamas and camels. Alpacas live in the Andes Mountains in Peru, Chile, and Bolivia. Alpacas are raised for their wool. Alpaca wool is soft and warm. Alpaca wool is used to make sweaters, hats, socks, and blankets. Alpacas are also raised for their meat. Alpaca meat is similar to beef.
Instruction:
Tell me about llamas.

Instruction: Tell me about the president of Mexico in 2019.
Response: The president of Mexico in 2019 is Andrés Manuel López Obrador.
Instruction:
Tell me about the president of Mexico in 2019.

Instruction: In Stardew Valley, what are the characteristics of Traveling Cart?
Response: In Stardew Valley, what are the characteristics of Traveling Cart?
Instruction:
In Stardew Valley, what are the characteristics of Traveling Cart?

It seems your format is a bit confusing, which I can't understand very well.

I faced similar issues but setting peft==0.2.0 in the requirements fixed it for me

Hi @felri in your instruction fine tune data, I see each instruction is prefixed by "In Stardew Valley, "
What is the rationale? Have you tried without the prefix? Thanks!


[WIP] minimal working example of hash checking option

I started working on adding a hash checking option, and this seems to work so far. I haven't added tests or anything yet, and this relies on the change in #142 which is unmerged, and which I copied into these changes. I just wanted to get input on this before putting too much time into it.
My thought, based on @betatim's suggestion in #138 of adding an --update flag, is that, assuming a file already exists on OSF, if --force is specified, we don't care whether --update is specified, and upload without comparing the hashes. If --force is not specified, then we check the hash if --update is specified, and fail the upload otherwise. Does that seem like a reasonable way to do it?
Also note that I copied the local checksum function from https://gist.github.com/rji/b38c7238128edf53a181#file-sha256-py. It seems to work but I don't know if there's a better way to do it.
Also, once we settle on the right way to do this, I figure we could do the same thing for fetch as well.

I added the update option to fetch and clone as well since that was a pretty easy thing to do. Let me know what you think of these options. For fetch, osf fetch -u path/to/file.txt will check the hashes, update if different, or report that the files are the same otherwise. For clone, osf clone -u will skip files with matching hashes with no reporting other than the progress bar saying how many files have been downloaded. If this sounds reasonable, I can start thinking about tests.

Maybe use -U for update?

Looks pretty good to me, just a few comments and questions.

Thanks! I'll work on those changes. Also could you look at my checksum implementation? I copied it from a github gist, and I don't know why it has a default block size of 65536 (not sure what the significance of 2^16 is), and I'm not sure if it's good or bad practice to put a link to the source for little code snippets like that.

I was wondering about the checksum implementation but assumed that it was "correct". Meaning it gives the same checksum as OSF for the same file. I am not sure what the significance of the precise value of the blocksize is. You need to hash your data in blocks, so you need to choose a size that isn't too big but also not too small :-/
re: link to source: for sure put a link to where the code came from. Ideally we'd find a place to copy it from where the license is clear.

Looking at comments under this SO answer, somewhere between 4 kb and 128 kb seem to be common choices, so 64 kb kind of falls in the middle of those, so hopefully that's fine. Whether I use the md5 or sha256 hash, the results do match up with the hashes provided by OSF.
I modified the checksum function, and switched to md5 since it's supposed to be a little faster than sha256, and left in a link to the above SO post that was my main source of info.
I'll look into adding tests for this soon, but I'm new to the pytest framework so might need some time.

@betatim I was able to update the existing tests to accommodate the update option, but adding a new test will require a little more understanding of this testing setup. I'm thinking the way to test the update option would be to hardcode the md5 hash attribute for a mock file object, and check to make sure an API call is made if the hashes differ. Is that how you would do it, and either way if you could give me some quick pointers on how to set it up I'd appreciate it.

Never mind, I think I got it well enough figured out, although this is my first dive into pytest, so there are likely some things I could have done better, so please let me know if you see any. All the tests pass, and I think they cover the major cases that the --update option brings up, so I think it's about ready to merge after review.

== EDIT ==
For peace of mind, I set up Travis on my fork. (https://travis-ci.org/benlindsay/osfclient) All tests passed there too.

Side question: I'm seeing upload speeds of no less than 16 seconds per file, sometimes about 30 seconds, even for very small or empty files. I haven't gone through rigorous tests, but with some quick tests, I'm not seeing any time difference between uploading a new file vs uploading the file with --update. Any idea why that might be?

Shoot, I just realized this whole pull request is me falling victim to the root of all evil -- premature optimization. I did some quick time profiling and found that for a project I'm working on that has a fair number of files, by far the biggest time waster is looping over the files to find the right upload URL (link to line). The actual upload is pretty fast in comparison, although I have only tested this on files under 100 MB.
I think this whole pull request is kind of useless without speeding up the process of finding the right upload URL. I'm not sure if it's feasible to speed that up, but I'll create an issue for it to discuss it.

In principle yes lets merge this. Though travis hasn't run on this branch which makes me suspicious we broke it somewhere :-/

if the offer is still on the table, now that I'm a little more familiar with the code, I'd be interested in accepting merge rights if that will reduce your load a little.

Of course! You should have an invite and welcome aboard. Remember with great power comes great responsibility ;) About the only rule is that no one can merge their own PRs.

Let's work out #151 (and failures that have crept in?) then return to this PR.

Closing and opening this PR to trigger travis.

Codecov Report

:exclamation: No coverage uploaded for pull request base (master@cf54352). Click here to learn what that means.
The diff coverage is 72.72%.

@@            Coverage Diff            @@
##             master     #146   +/-   ##
=========================================
  Coverage          ?   92.17%
=========================================
  Files             ?       13
  Lines             ?      588
  Branches          ?        0
=========================================
  Hits              ?      542
  Misses            ?       46
  Partials          ?        0

Impacted Files
Coverage Δ

osfclient/models/storage.py
95.31% <100%> (ø)

osfclient/__main__.py
95% <100%> (ø)

osfclient/cli.py
97.54% <100%> (ø)

osfclient/utils.py
75.6% <18.18%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cf54352...6c5f080. Read the comment docs.

Huzzah!

I'm so glad to see this functionally being added to  osf client! Is this ready to go live?

@colinbrislawn Yes, I think we're just fixing the build error due to problems with the pypi test upload first. (#154)

@betatim Now that the Travis is happy with the test PyPI uploads, how do you feel about merging this one? I don't know how you typically decide when to bump the version number, but it would be nice to see this and the large file connection error fix pushed up to production PyPI soon.

@betatim Now that most of the administration stuff is out of the way, I just want to bump this one up. Can we merge this or is there something else I should add/change first?

@betatim I know you're busy, so I just want to give this another friendly bump. I'm trying to stick with the "don't merge your own pull request" rule, but that big green "Merge pull request" button sure is tempting... 😉

nice!


Templated Controls not visible in the Designer

Describe the bug
My Templated Controls are only visible in the Build but on in the Designer.
They do not take up any space unless Width or Height is explicitly specified:
<controls:CategoryControl/>
Takes up no space in Designer.
<controls:CategoryControl Height="20"/>
Does take up space. But still not visible. (No setting a Background color does not work either)
When the control is in a DockPanel it does however take up space [img 1].
They are visible however in their own Designer [img 2].
To Reproduce

Create Templated Control in a folder called "Controls"
Include the Style in Application.Styles
Add the controls namespace to any window of other control
Build and run the app

Expected behaviour
The Templated Controls should be visible in the Designer.
Screenshots
Left is the Designer and right is the build app

The templated control is visible in its own designer

Desktop (please complete the following information):

OS: Windows 11 Pro
Version: 22H2
OS Build: 22621.1555

Additional context
There were loads of ideas I already tried.
Q: Include it in another view or window.
A: Did not show either
Q: Include the style directly in the window instead of App.axaml
A: Gives me an URL parsing error.
<Window.Styles>
    <StyleInclude Source="/../Controls/Explorer/CategoryControl.axaml"/>
</Window.Styles>

Q: Add Styles directly to the control.
A: Did not show either.
Q: Switch to another IDE.
A: I tried using Visual Studio instead of Rider but to no avail. Same problem
Q: Update or revert Rider version
A: I was using Rider 2022.3 before and updated it to 2023.1. Same issue with both of them.
Q: Have you tried touching grass?
A: It is currently raining outside, so no.

@DefaultLP I assume IconFill and IconData are set and not only loaded at runtime?

@timunie Correct. They are more a convenience for me when designing. I removed both of them to test if they were causing the problem. But sadly still nothing.
I also tried it with a Templated Control that had no bindings, to begin with. Just a border and some text. But still nothing.

Can you file a minimal sample? Just like shown above with nothing more?

Sure. Give me a moment

After a lot of trial and error, I was not able to reproduce the bug. I even went as far as to literally copy most of my code over and it still works.

I also looked at the .csproj files of both projects. They are completely identical.
(And also the .snl files but I doubt they had anything to do with this in the first place)
Something in this first project was probably messed up by me trying out things with Avalonia.

I quickly copied the original project onto my laptop and the Template Controls were still not showing. It is definitely a project-related issue but I cannot find the difference between the old and new projects which cause this bug.
Deleting both the "bin" and obj" folders and rebuilding also did nothing.
While I can confidently say that Avalonia is not at fault here, I cannot for the life of me find or reproduce this bug.
Thank you @timunie for taking the time and helping me with this.

Sometimes also some old cached files can be an issue. deleting bin, obj and .vs folder can help. Anyway, I'll convert this issue into a Q&A now as it's not an Avalonia bug.


POC for MongoDB connection in Java

Create Java SpringBoot microservice for MongoDB connection.

Completed POC with commit 262db0498d52f1c155875a2ab0d763af45b6f0cf .
Note: Pushed code without addressing this issue directly.


ISSUE-75: Update build script to enable docker container contain all environments for all examples.

[Closes #75 : Modify the build script to facilitate the building of all environments based on the extensions on the requirements files on all modules.]
Changes
How I tested this
Notes
Checklist

[X] PR has an informative and human-readable title (this will be pulled into the release notes)
[X] Changes are limited to a single goal (no scope creep)
[X] Code passed the pre-commit check & code is left cleaner/nicer than when first encountered.
[ ] Any change in functionality is tested
[ ] New functions are documented (with a description, list of inputs, and expected output)
[ ] Placeholder code is flagged / future TODOs are captured in comments
[ ] Project documentation has been updated if adding/changing functionality.

Hey @skrawcz kindly find above.

Hey, @skrawcz wanted to confirm if this issue was closed.
Charity.

Hey, @skrawcz wanted to confirm if this issue was closed or if its something that's still pending.🙂
Charity.

@CharityKithaka no this is still open!

Closing for now due to inactivity.


chore: add CODEOWNERS file

Our /website repo is missing a CODEOWNERS file. This PR will address this.

I see all approval are here in place so @alequetzalli go ahead and merge 👏🏼


container name changed from chanzuckerberg/idseq-web to ecs-idseq-web

Note that this was looking for the image name before, and now the container name. Should be fine, just FYI.


fix(scap): use strerror_r return value

Note: this assumes we're getting the XSI-compliant version, whose return value is an int, like strerror_s.
It's complicated: https://linux.die.net/man/3/strerror_r

What type of PR is this?

Uncomment one (or more) /kind <> lines:

/kind bug

/kind cleanup

/kind design

/kind documentation

/kind failing-test

/kind feature

Any specific area of the project related to this PR?

Uncomment one (or more) /area <> lines:

/area API-version

/area build

/area CI

/area driver-kmod

/area driver-bpf

/area driver-modern-bpf

/area libscap-engine-bpf

/area libscap-engine-gvisor

/area libscap-engine-kmod

/area libscap-engine-modern-bpf

/area libscap-engine-nodriver

/area libscap-engine-noop

/area libscap-engine-source-plugin

/area libscap-engine-savefile

/area libscap-engine-udig

/area libscap

/area libpman

/area libsinsp

/area tests

/area proposals

Does this PR require a change in the driver versions?

/version driver-API-version-major

/version driver-API-version-minor

/version driver-API-version-patch

/version driver-SCHEMA-version-major

/version driver-SCHEMA-version-minor

/version driver-SCHEMA-version-patch

What this PR does / why we need it:
Which issue(s) this PR fixes:

Fixes #
Special notes for your reviewer:
Does this PR introduce a user-facing change?:

NONE

cc @FedeDP

[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: gnosek
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

OWNERS [gnosek]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

I am going to test this in Falco to see if the bug is fixed!

/build/release/falcosecurity-libs-repo/falcosecurity-libs-prefix/src/falcosecurity-libs/userspace/libscap/strerror.c: In function 'scap_errprintf_unchecked':
/build/release/falcosecurity-libs-repo/falcosecurity-libs-prefix/src/falcosecurity-libs/userspace/libscap/strerror.c:41:51: error: ordered comparison of pointer with integer zero [-Werror=extra]
if(strerror_r(errnum, err_buf, sizeof(err_buf)) < 0)

still failing :/

LGTM label has been added.  Git tree hash: bf3442ec2d24fbe1784a4289173d5129e85839f7

[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: FedeDP, gnosek
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

OWNERS [FedeDP,gnosek]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: Andreagit97, FedeDP, gnosek
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

OWNERS [Andreagit97,FedeDP,gnosek]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

/milestone 0.10.0


Creation of arguments for scenario parameters

e.g.
public class Widget
{
    // has an implicit default constructor
}

[Scenario]
public static Scenario([Create]Widget widget)
{
   "Given a widget with..."
        .f(() => widget.Foo = ...); // the widget has been constructed
}

or
public class Widget
{
    public class Widget(string foo)
    {
        ...
    }
}

[Scenario]
public static Scenario([Create("bar")]Widget widget)
{
   "Given a widget with a foo of 'bar'"
        ....
}

At this stage I've no idea if this could work or not :stuck_out_tongue_closed_eyes:.
Create could be Auto.
I guess something like AutoFixture is designed for generating and supplying these things but I've no idea if it works with xBehave.net. Still, xBehave.net could come with a simple built in value generator to cover simple cases.

Let's let AutoFixture and friends fill this requirement.


Removed references to my personal email and physical address so other…

…s can pick up on this stuff

Coverage remained the same at 92.251% when pulling d0e8cb2c47d4eae3753c107be730a2480bb3c619 on generalize-points-of-contact into<PHONE_NUMBER>14cfb666e67c87410a6bda3720144d on master.


[question]why?

is it easier just making a issue in the xaero minimap issues?

originally i just made this mod for myself, and its only 1 mixin so quite easy to make tbh. feel free to make an issue in the xaero minimap issues though, id prefer if the bug be fixed than people having to download this mod


Introduces register_debug_event_callback()

Introduces Debugger::register_debug_event_callback() callback which fires on debug events.
Updates Debugger::register_modload_callback() (and Debugger::register_debug_event_callback()) to take Box<Fn()> as opposed to a standard function pointer.

Thanks for the improvements <3


Update repositories.txt

Hi @andhieSetyabudi. Your pull request doesn't make any changes at all:
https://github.com/arduino/library-registry/pull/845/files
Please tell me what you were trying to do and I'll help you out.

hi  per1234,
since i get the result that :
Linting library in MCP23017_LCD12864
WARNING: library.properties name value MCP23017_LCD12864 is longer
than the recommended length of 16 characters. (Rule
LP010)
I tried to reduce the length of the character, so I changed MCP23017_LCD12864
to I2C_LCD12864 I'm so sorry for doing that.. i'm very appreciate for your
team
best regards
Andhie setyabudi
Pada tanggal Sel, 28 Des 2021 pukul 14.58 per1234 @.***>
menulis:

Hi @andhieSetyabudi https://github.com/andhieSetyabudi. Your pull
request doesn't make any changes at all:
https://github.com/arduino/library-registry/pull/845/files
Please tell me what you were trying to do and I'll help you out.
—
Reply to this email directly, view it on GitHub
https://github.com/arduino/library-registry/pull/845#issuecomment-1001924175,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AKE64C4QC5N2CCBADOWL7G3UTFU25ANCNFSM5K3TPCJQ
.
Triage notifications on the go with GitHub Mobile for iOS
https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675
or Android
https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.
You are receiving this because you were mentioned.Message ID:
@.***>

I changed MCP23017_LCD12864
to I2C_LCD12864

OK, I have submitted a pull request on your behalf to update the registration of the library for the new name: https://github.com/arduino/library-registry/pull/847
Unlike submissions, this type of request is still handled manually. The Library Manager index maintainer occasionally comes through to clear all the outstanding requests and closes those issues/PRs when that is done. If you are subscribed to the linked issue/PR, you'll get a notification at that time.
After that, you can monitor the indexing of the library via its dedicated logs web page.
Information about that here:
https://github.com/arduino/library-registry/blob/main/FAQ.md#can-i-check-on-library-releases-being-added-to-library-manager


tool to update components

Some of our components - notably alpine versions - are falling behind. Since they live in a lot of different files, it is painful to update them.
I grabbed the update-component-sha.sh utility from linuxkit, updated it for our purpose, and installed it here.
One can do:
./tools/update-component-sha.sh --image alpine 3.13.1

And it will update all files in git that have Dockerfile in their name - so it includes our various Dockerfile.in but excludes anything not in git - to have the alpine tag changed to 3.13.1.
Of course, afterwards, one must check the changes in and open a PR. Which is good.

Once this is merged in, I will bump our various versions of alpine to 3.13.

I would like to add docs for this, but where is the right doc file for it?

Yes, I am consciously ignoring yetus on this. It is being too difficult about a simple script.

Sure @rvs ; that is why it is two distinct PRs, this one being just the tool to enable it.


Fineract 982ditchdrizzle

Description
Please read details here #1650
Ignore if these details are present on the associated Apache Fineract JIRA ticket.
Just a brief
Fineract's use of the un-maintained Drizzle JDBC driver continues to cause confusion and pains like FINERACT-980, and note e.g. the proposed removal of the alternative MySQL JDBC driver in https://github.com/apache/fineract/pull/887.
Some of the background to this is recorded e.g. in FINCN-26, FINERACT-761 and LEGAL-462.
Checklist
Please make sure these boxes are checked before submitting your pull request - thanks!

[ ] Write the commit message as per https://github.com/apache/fineract/#pull-requests

[ ] Acknowledge that we will not review PRs that are not passing the build ("green") - it is your responsibility to get a proposed PR to pass the build, not primarily the project's maintainers.

[ ] Create/update unit or integration tests for verifying the changes made.

[ ] Follow coding conventions at https://cwiki.apache.org/confluence/display/FINERACT/Coding+Conventions.

[ ] Add required Swagger annotation and update API documentation at fineract-provider/src/main/resources/static/api-docs/apiLive.htm with details of any API changes

[ ] Submission is not a "code dump".  (Large changes can be made "in repository" via a branch.  Ask on the developer mailing list for guidance, if required.)

FYI our guidelines for code reviews are at https://cwiki.apache.org/confluence/display/FINERACT/Code+Review+Guide.

Any ideas why this is failing?
CenterIntegrationTest > testCenterDeletion() FAILED

    org.opentest4j.AssertionFailedError: /fineract-provider/actuator/health returned

        <title>HTTP Status 404 – Not Found</title>

HTTP Status 404 – Not Found

          Type

     Status Report

          Description

     The origin server did not find a current representation for the target resource or is not willing to disclose that one exists.

Apache Tomcat/9.0.43

        at org.junit.jupiter.api.AssertionUtils.fail(AssertionUtils.java:39)

        at org.junit.jupiter.api.Assertions.fail(Assertions.java:117)

        at org.apache.fineract.integrationtests.common.Utils.awaitSpringBootActuatorHealthyUp(Utils.java:105)

        at org.apache.fineract.integrationtests.common.Utils.loginIntoServerAndGetBase64EncodedAuthenticationKey(Utils.java:119)

        at org.apache.fineract.integrationtests.CenterIntegrationTest.setup(CenterIntegrationTest.java:54)

Any ideas why this is failing?
CenterIntegrationTest > testCenterDeletion() FAILED

    org.opentest4j.AssertionFailedError: /fineract-provider/actuator/health returned

        <title>HTTP Status 404 – Not Found</title>

HTTP Status 404 – Not Found

          Type

     Status Report

          Description

     The origin server did not find a current representation for the target resource or is not willing to disclose that one exists.

Apache Tomcat/9.0.43

        at org.junit.jupiter.api.AssertionUtils.fail(AssertionUtils.java:39)

        at org.junit.jupiter.api.Assertions.fail(Assertions.java:117)

        at org.apache.fineract.integrationtests.common.Utils.awaitSpringBootActuatorHealthyUp(Utils.java:105)

        at org.apache.fineract.integrationtests.common.Utils.loginIntoServerAndGetBase64EncodedAuthenticationKey(Utils.java:119)

        at org.apache.fineract.integrationtests.CenterIntegrationTest.setup(CenterIntegrationTest.java:54)

@vidakovic  some builds will come with failed intergration tests not necessarily arising from ones PR.
Nevertheless, at the moment i have no idea why it is failing let us hear from others


Include release package in npm registry

I like that you include your source in your published npm package, but could you also include the same release files that you include in your bower package for those of us who no longer want to depend on bower?
I appreciate your consideration! Thanks!

Hi, I don't publish the release files to npm. Basically I was willing to publish build files to bower since it doesn't support deep dependencies. WIth npm I want people dynamically downloading the dependencies so when I (or another dev) release a bug fix on a dependency new downloads receive it automatically. Build files make extra work for me and eventually I intend to eliminate them entirely. When I do that I'll probably add a wzrd.in button and some instructions on how to download and save if desired.

unfortunately I still don't see how to build release/angular-stripe.js locally after having installed the package via npm.

This basically means that anyone not using a module loader cannot use your npm package. I'm a little confused why this would be the case. An NPM package is for others to refer to and use/depend on.  You get just a folder with a handful of files, including angular.js, angular.min.js, index.js, and package.json.
You said above that you want people dynamically downloading your new bug fixes as you release them, but this is not something that real life production systems want to happen. If I'm running an ecommerce site that depends on npm packages, I will likely be using npm-shrinkwrap so that I can be certain my production environment will be using the exact versions of npm packages (and their dependencies) that were tested all the way up the pipeline (dev, test, staging, etc.). I wouldn't want any of my dependencies to change without me choosing to update my package.json to point to the new version and then re-test before pushing to prod.
Please help me if I'm missing your point. I'm not trying to sound snooty, I'm just trying to understand why you wouldn't want to do this.

Locking this because I'm not interested in a discussion but I can give you a quick answer:

This basically means that anyone not using a module loader cannot use your npm package

Not really, I'm just not concerned with people using npm without a module loader. npm is full of JavaScript packages meant to be used with require. Most of them need a module loader to be useful. Angular isn't composed of modules to begin with so they just chose to treat npm as a generic artifact store. This project is composed of true modules and so I want to use npm's dependency features.

I will likely be using npm-shrinkwrap

As you should be. People who install for the first time should get the latest version of dependencies. If I update a credit card regex I should not be obligated to run a build here to get that change out.
npm + bundler users get the best experience with full control over their modules (locked down if they want but with updates when they want). The release/ file is just there for novice users/simple projects.


Sometimes I wonder…

src/main/java/com/minersstudios/mscore/command/api/Commodore.java
https://github.com/lucko/commodore

Did you just create essentially a similar thing and with the same name? It makes me wonder whether source code should be credited as MinersStudios’ afterwards.

@p0loskun shame


Include full git commit hash in ThisAssembly

If we're putting detailed version information into ThisAssembly why not also include the full git HEAD commit hash rather than just 10 characters?

Sounds fine to me. I'd welcome a pull request.


merge

merge

Hello,
why would you remove tensorflow from the package dependencies?

sorry sir，its a misoperation
发自我的iPhone
------------------ Original ------------------
From: Carlo Grisetti @.>
Date: Wed,May 12,2021 3:18 PM
To: tensortrade-org/tensortrade @.>
Cc: lucifer2288 @.>, Author @.>
Subject: Re: [tensortrade-org/tensortrade] merge (#322)
Hello,
why would you remove tensorflow from the package dependencies?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

Thanks


would like to have a custom id for all the clickable ui elements to be automaticly tested ?

Hello
Im using mui datatable 2.6.1 and i would like to have some custom ids for all the clickable elements to be tested with Katalon. it requires unique identifier to select each element. So is there any  way to add ids ?

This looks like a duplicate of https://github.com/gregnb/mui-datatables/issues/618, so you can follow the conversation over there.

@khalilmarzouk Test ids have been added to 2.7.0. If there are any missing that you would like, please let me know.


Adding SwaggerRoutes "hijacks" site root ASP.NET (non core) WebApi

By "hijacks" I mean that the site root returns swagger.json - file, instead of hitting a default controller.
Steps to reproduce
Using
ASP.NET, non core, webapi with OWIN.
app.UseSwagger(typeof(Startup).GetTypeInfo().Assembly, config =>
{
config.DocumentPath = documentpath;
});
app.UseSwaggerUi3(typeof(Startup).GetTypeInfo().Assembly, config =>
{
config.SwaggerRoutes.Add(new SwaggerUi3Route(versionWithV, documentpath));
});
However, this works, does not "hijack" site root:
app.UseSwaggerUi3(typeof(Startup).GetTypeInfo().Assembly, config =>
{
config.DocumentPath = documentpath;
});
Using version 12.0.4

Shouldnt it be:
app.UseSwagger(typeof(Startup).GetTypeInfo().Assembly, config =>
{
     config.Path = documentpath;
});
app.UseSwaggerUi3(config =>
{
     config.Path = "/swagger";
     config.SwaggerRoutes.Add(new SwaggerUi3Route(versionWithV, documentpath));
});

I can not find a property "Path" here:
app.UseSwagger(typeof(Startup).GetTypeInfo().Assembly, config =>
{
config.Path = documentpath;
});
If I use DocumentPath there, and change the other part to
app.UseSwaggerUi3(config =>
{
config.Path = "/swagger";
config.SwaggerRoutes.Add(new SwaggerUi3Route(versionWithV, documentpath));
});
I still get swagger.json when I go to the root.

I have the exact same problem. I need to use SwaggerRoutes in UseSwaggerUi3() to add multiple documents, but if I do that the site root gets "hijacked" and returns swagger.json instead of hitting the default controller.
@svenerp Did you ever find a solution?
@RicoSuter Can you please have look?
Thanks!

I have the exact same problem. I need to use SwaggerRoutes in UseSwaggerUi3() to add multiple documents, but if I do that the site root gets "hijacked" and returns swagger.json instead of hitting the default controller.
@svenerp Did you ever find a solution?
@RicoSuter Can you please have look?
Thanks!

I solved it, the key was to use the correct overload of UseSwaggerUi3() so it ONLY adds the Swagger UI to the OWIN pipeline.
Correct:
app.UseSwaggerUi3(config =>
{
config.Path = "/swagger";
config.SwaggerRoutes.Add(new SwaggerUi3Route(versionWithV, documentpath));
});
Not correct:
app.UseSwaggerUi3(typeof(Startup).Assembly, config =>
{
config.Path = "/swagger";
config.SwaggerRoutes.Add(new SwaggerUi3Route(versionWithV, documentpath));
});

UseSwaggerUi3 with assembly is marked deprecated, right?

UseSwaggerUi3 with assembly is marked deprecated, right?

No, it's not. But it should be :)


How to properly compose functionality in systems?

Recently I've been reinventing the wheel with systems. Crafty could do that for me, if I'd use an entity composed of multiple components:
// merge inits
if (typeof layerTemplate.init === 'function') {
    var layerInit = layerTemplate.init;
    var commonInit = common.init;
    layerTemplate.init = function() {
        layerInit.call(this);
        commonInit.call(this);
    };
}
// merge removes
if (typeof layerTemplate.remove === 'function') {
    var layerRemove = layerTemplate.remove;
    var commonRemove = common.remove;
    layerTemplate.remove = function() {
        layerRemove.call(this);
        commonRemove.call(this);
    };
}

What is the preferred way of handling this? I would like to decouple code and avoid writing everything into one large system template.
Would it make sense to allow systems to be composed of components?  See also discussion in #878).

What I've done in a few places was essentially just add functionality to systems as a mixin.  That's how event callback methods get added, and also how common methods for the graphics layer types get handled.
You could formalize this as some sort of "components-for-systems" concept but it's not clear to me that this would be worth the overhead.    Keep in mind that component init/remove methods don't necessarily care about the order they're run in, whereas I think most of the examples for systems do care.
I do think there's another approach you could use for most of this block of code.    The individual systems could just declare those methods as part of their events block -- all this common init code is doing is binding the events to specific named functions which are overridden.  Those default-no-op method blocks for resize/render/setpixelart shouldn't really be necessary in an event driven system, where events can just be ignored if the system doesn't care about them.
Another technique would be to use additional events instead of the explicit merging of init/remove; that is, instead of calling the two init methods in order, you could have the main init event trigger a LayerInit method instead.
Overall:

You can avoid some of these problems by using event binding over explicit method calls/names.
I'm not opposed to adding more helper methods for system mixins, but I'm my instinct is that it doesn't require the full flexibility of the components-entity system.

What I've done in a few places was essentially just add functionality to systems as a mixin. ... I'm not opposed to adding more helper methods for system mixins

Would you kindly elaborate on that, maybe with some example code? Is that what's being done in the example I posted above?
The other suggestions make sense for this particular case, thanks. Will make a PR that:

The individual systems could just declare those methods as part of their events block ...
you could have the main init event trigger a LayerInit method instead.

instead of calling the two init methods in order, you could have the main init event trigger a LayerInit method instead.

There is a problem with this approach: event callbacks, defined in the events block, get setup after the init method is called. Is this intentional, or could this be changed to call the init method after all other special properties are setup from component / system template?

Keep in mind that component init/remove methods don't necessarily care about the order they're run in, whereas I think most of the examples for systems do care.

Btw, initialization order can be enforced with "required" components.

If you want to get fancy, you can use higher-order functions. As an example, say you wanted to add a more sophisticated logging that includes the entity's name in the message. You could do this.
function withLogging(c) {
    return Object.assign({
        logWithName: function(message) {
            Crafty.log(this.getName() + ": " + message);
        }
    }, c);
}

Crafty.c("MyComponent", withLogging({
    events: {
        FrameStart: function() {
            this.logWithName("Got frame start event"); // prints "EntityName: Got frame start event"
        }
    },
});

Crafty.e("MyComponent", { name: "EntityName" });


Fix Review Queue Sizer (out of date dependency)

Wanikani moved to a JSON representation of the Queue at some point over the summer, breaking the Review Queue Sizer much to my dismay.
Turns out the underlying library for manipulation fixed this issue in v17 (https://community.wanikani.com/t/for-userscript-authors-wk-queue-manipulator/61302) but the library version was pinned in the require here.
Removing the version pin, which will make it default to latest, meaning future fixes from Review Queue Manipulator will come "for free."
Alternately, we could pin to the explicit latest version (version=1448112), but given the fact that this userscript has been broken for at least two months, I think pinning to latest is the lesser evil.

Thanks!


CModal closing if clicked element is removed from dom

Somewhere along the line CModal's click listener that evaluates if you clicked outside the model or not has changed.  It used to be attached to the modal content div but now it's attached to document, meaning it runs after React event handlers.
If you have a modal where elements are removed as they're clicked, to replace with something else, the modal will close prematurely.
Please see my test case here --> stackblitz

Windows
Edge/Firefox

In my case,
When i click CFormCheckbox element inside CModal then visible prop is changed false and onClose function is fired.

@ncavallo-dell I'm working on it

@mrholek: I'm having the similar problem too
CModal closes even when I click the CFormCheck button, it doesn't happen if it's normal html input. but with some custome component like react-select, rc-date-picker
Check my CSB: https://codesandbox.io/p/github/codesandbox/codesandbox-template-vite-react/csb-n7wj5l/coreui-hf-modal-errs
I found the problem is in the handleClickOutside function, const isInclude = modalContentRef.current.contains(event.target as HTMLElement) returns false when i click CFormCheck radio
But I don't know how to fix it. By the way my project is using useOnClickOutside of usehooks-ts so I did the temparory solution:

Clone CModal.tsx into new component
Remove click listenr

 useEffect(() => {
-  document.addEventListener('click', handleClickOutside);
   document.addEventListener('keydown', handleKeyDown);

   return() => {
-     document.removeEventListener('click', handleClickOutside);
     document.removeEventListener('keydown', handleKeyDown);
   };
 }, [_visible]);

Then use

+ import { useOnClickOutside } from 'usehooks-ts';
+ useOnClickOutside(modalContentRef, handleDismiss);

I hope you solve this problem soon💥

@nhahv @nhahv thank you for your solution, but I that easier will be change  document.addEventListener('click', handleClickOutside) to document.addEventListener('mousedown', handleClickOutside) because the logic of handleClickOutside and useOnClickOutside is the same.
I need to investigate why CFormCheck causes this issue when normal input works well.

@mrholek Same problem here. We are using Core UI React Pro and the problem occurred when updating from<EMAIL_ADDRESS>to<EMAIL_ADDRESS>Problem appears when clicking on a select option from react-select wich uses a portal.
Looks like the bug was introduced in 2b0b70d (CModal.tsxL132-L137).
Forking CModal.tsx and changing this:
 useEffect(() => {
    document.addEventListener('click', handleClickOutside)
    document.addEventListener('keydown', handleKeyDown)

    return() => {
        document.removeEventListener('click', handleClickOutside)
        document.removeEventListener('keydown', handleKeyDown)
   };
 }, [_visible]);

back to this:
useEffect(() => {
   modalRef.current && modalRef.current.addEventListener('click', handleClickOutside)
   modalRef.current && modalRef.current.addEventListener('keydown', handleKeyDown)

   return() => {
       modalRef.current && modalRef.current.removeEventListener('click', handleClickOutside)
       modalRef.current && modalRef.current.removeEventListener('keydown', handleKeyDown)
  };
}, [_visible]);

seems to solve it for now (I also had to fork CModalHeader.tsx for it to import the correct CModalContext from my forked CModal component). Will it cause any problems that I don't see yet?
Here is a simple stackblitz  with a custom portal to simulate this behavior.

@danielhoegel I will check this, but not until the beginning of next week.

@mrholek this bug has bitten us really badly, could we get some eyes on it?

FYI to fix this, we added this component to our component library.
The only change is this function:
    const handleClickOutside = (event: Event) => {
      // modalRef.current is the modal backdrop. If we detect a click on that, then dismiss the modal.
      // See https://github.com/coreui/coreui-react/issues/361
      if (modalContentRef.current && modalRef.current == event.target) {
        handleDismiss()
      }
    }

import classNames from 'classnames'
import React, { HTMLAttributes, createContext, forwardRef, useEffect, useLayoutEffect, useRef, useState } from 'react'
import { Transition } from 'react-transition-group'

import { CBackdrop, CConditionalPortal, CModalContent, CModalDialog, useForkedRef } from '@coreui/react-pro'

export interface ShimmedCModalProps extends HTMLAttributes<HTMLDivElement> {
  /**
   * Align the modal in the center or top of the screen.
   */
  alignment?: 'top' | 'center'
  /**
   * Apply a backdrop on body while modal is open.
   */
  backdrop?: boolean | 'static'
  /**
   * A string of all className you want applied to the base component.
   */
  className?: string
  /**
   * @ignore
   */
  duration?: number
  /**
   * Puts the focus on the modal when shown.
   *
   * @since v4.10.0
   */
  focus?: boolean
  /**
   * Set modal to covers the entire user viewport.
   */
  fullscreen?: boolean | 'sm' | 'md' | 'lg' | 'xl' | 'xxl'
  /**
   * Closes the modal when escape key is pressed.
   */
  keyboard?: boolean
  /**
   * Callback fired when the component requests to be closed.
   */
  onClose?: () => void
  /**
   * Callback fired when the component requests to be closed.
   */
  onClosePrevented?: () => void
  /**
   * Callback fired when the modal is shown, its backdrop is static and a click outside the modal or an escape key press is performed with the keyboard option set to false.
   */
  onShow?: () => void
  /**
   * Generates modal using createPortal.
   */
  portal?: boolean
  /**
   * Create a scrollable modal that allows scrolling the modal body.
   */
  scrollable?: boolean
  /**
   * Size the component small, large, or extra large.
   */
  size?: 'sm' | 'lg' | 'xl'
  /**
   * Remove animation to create modal that simply appear rather than fade in to view.
   */
  transition?: boolean
  /**
   * By default the component is unmounted after close animation, if you want to keep the component mounted set this property to false.
   */
  unmountOnClose?: boolean
  /**
   * Toggle the visibility of modal component.
   */
  visible?: boolean
}

interface ModalContextProps {
  visible?: boolean
  setVisible: React.Dispatch<React.SetStateAction<boolean | undefined>>
}

export const CModalContext = createContext({} as ModalContextProps)

export const ShimmedCModal = forwardRef<HTMLDivElement, ShimmedCModalProps>(
  (
    {
      children,
      alignment,
      backdrop = true,
      className,
      duration = 150,
      focus = true,
      fullscreen,
      keyboard = true,
      onClose,
      onClosePrevented,
      onShow,
      portal = true,
      scrollable,
      size,
      transition = true,
      unmountOnClose = true,
      visible,
      ...rest
    },
    ref
  ) => {
    const activeElementRef = useRef<HTMLElement | null>(null)
    const modalRef = useRef<HTMLDivElement>(null)
    const modalContentRef = useRef<HTMLDivElement>(null)
    const forkedRef = useForkedRef(ref, modalRef)

    const [_visible, setVisible] = useState(visible)
    const [staticBackdrop, setStaticBackdrop] = useState(false)

    const contextValues = {
      visible: _visible,
      setVisible,
    }

    useEffect(() => {
      setVisible(visible)
    }, [visible])

    useEffect(() => {
      if (_visible) {
        activeElementRef.current = document.activeElement as HTMLElement | null
        document.addEventListener('mouseup', handleClickOutside)
        document.addEventListener('keydown', handleKeyDown)
      } else {
        activeElementRef.current?.focus()
      }

      return () => {
        document.removeEventListener('mouseup', handleClickOutside)
        document.removeEventListener('keydown', handleKeyDown)
      }
    }, [_visible])

    const handleDismiss = () => {
      if (backdrop === 'static') {
        return setStaticBackdrop(true)
      }

      setVisible(false)

      // biome-ignore lint/complexity/useOptionalChain: copy-paste from CoreUI-react
      return onClose && onClose()
    }

    useLayoutEffect(() => {
      // biome-ignore lint/complexity/useOptionalChain: copy-paste from CoreUI-react
      onClosePrevented && onClosePrevented()
      setTimeout(() => setStaticBackdrop(false), duration)
    }, [staticBackdrop])

    // Set focus to modal after open
    useLayoutEffect(() => {
      if (_visible) {
        document.body.classList.add('modal-open')

        if (backdrop) {
          document.body.style.overflow = 'hidden'
          document.body.style.paddingRight = '0px'
        }

        setTimeout(
          () => {
            focus && modalRef.current?.focus()
          },
          transition ? duration : 0
        )
      } else {
        document.body.classList.remove('modal-open')

        if (backdrop) {
          document.body.style.removeProperty('overflow')
          document.body.style.removeProperty('padding-right')
        }
      }

      return () => {
        document.body.classList.remove('modal-open')
        if (backdrop) {
          document.body.style.removeProperty('overflow')
          document.body.style.removeProperty('padding-right')
        }
      }
    }, [_visible])

    const handleClickOutside = (event: Event) => {
      // modalRef.current is the modal backdrop. If we detect a click on that, then dismiss the modal.
      // See https://github.com/coreui/coreui-react/issues/361
      if (modalContentRef.current && modalRef.current == event.target) {
        handleDismiss()
      }
    }

    const handleKeyDown = (event: KeyboardEvent) => {
      if (event.key === 'Escape' && keyboard) {
        handleDismiss()
      }
    }

    return (
      <>
        <Transition
          in={_visible}
          mountOnEnter
          nodeRef={modalRef}
          onEnter={onShow}
          onExit={onClose}
          unmountOnExit={unmountOnClose}
          timeout={transition ? duration : 0}
        >
          {(state) => (
            <CConditionalPortal portal={portal}>
              <CModalContext.Provider value={contextValues}>
                <div
                  className={classNames(
                    'modal',
                    {
                      'modal-static': staticBackdrop,
                      fade: transition,
                      show: state === 'entered',
                    },
                    className
                  )}
                  tabIndex={-1}
                  {...(_visible ? { 'aria-modal': true, role: 'dialog' } : { 'aria-hidden': 'true' })}
                  style={{
                    ...(state !== 'exited' && { display: 'block' }),
                  }}
                  {...rest}
                  ref={forkedRef}
                >
                  <CModalDialog alignment={alignment} fullscreen={fullscreen} scrollable={scrollable} size={size}>
                    <CModalContent ref={modalContentRef}>{children}</CModalContent>
                  </CModalDialog>
                </div>
              </CModalContext.Provider>
            </CConditionalPortal>
          )}
        </Transition>
        {backdrop && (
          <CConditionalPortal portal={portal}>
            <CBackdrop visible={_visible} />
          </CConditionalPortal>
        )}
      </>
    )
  }
)

@aidanlister thank you for your help. I'm testing your solution.

I just released a new version, please check it.


09-perform-data-analysis-in-power-bi-desktop.md

Images do not appear correctly in PDF file. All images must be checked

Now, the image shows it.


ImportError: Symbol not found on Mac OS

Referenced from: /Users/skravi/Desktop/logisticsProject/env/lib/python3.10/site-packages/reportlab/graphics/../.dylibs/libpng16.16.dylib
Expected in: /usr/lib/libz.1.dylib
in /Users/skravi/Desktop/logisticsProject/env/lib/python3.10/site-packages/reportlab/graphics/../.dylibs/libpng16.16.dylib
if i'm use the Xhtml2pdf python library

How is this related to xhtml2pdf? This seems like a reportlab issue which should posted to their discussion forum if support is required.

I agree, @skravi1996 if your issue still exists, please ask for help at https://groups.google.com/g/reportlab-users


ImportError: No module named core.module

Trying to use binwalk in a virtualenv, and I get the following error trying to import binwalk
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/username/src/sahara/venv/lib/python2.7/site-packages/binwalk/__init__.py", line 3, in <module>
    from binwalk.core.module import Modules, ModuleException
ImportError: No module named core.module

This occurs both when the venv is activated via source venv/bin/activate or when the venv python is called directly via venv/bin/python
Thoughts?

Does the file /Users/username/src/sahara/venv/lib/python2.7/site-packages/binwalk/core/module.py exist?

sudo apt purge binwalk
sudo apt autoclean
sudo apt-get install binwalk
python3 -m pip install git+https://github.com/ReFirmLabs/binwalk


Electron: app.allowRendererProcessReuse is deprecated

Steps to reproduce

Run npm start

Description
When running the project with npm start a warning is thrown in the terminal with the following text:
(electron) The default value of app.allowRendererProcessReuse is deprecated, it is currently "false".  It will change to be "true" in Electron 9.  For more information please check https://github.com/electron/electron/issues/18397

Resolved with #7


app: run on port 8080 instead of 80

Running on port 80 requires admin which is unnecessary for development.
Plus we are using gunicorn which doesn't require running the code as it
is using python kwoc/app.py.

Hello @pranitbauva1997! Thanks for submitting the PR.

In the file kwoc/app.py, following are the PEP8 issues :

Line 5:1: E402 module level import not at top of file
Line 6:1: E402 module level import not at top of file
Line 7:1: E402 module level import not at top of file
Line 13:1: E302 expected 2 blank lines, found 1
Line 62:1: E302 expected 2 blank lines, found 1
Line 80:1: E305 expected 2 blank lines after class or function definition, found 1


Pinning dm-haiku to 0.0.10

I was trying to run the examples/baselines/rl_continuous/run_sac.py example and ran into the following issue (trying multiple versions of python3 in clean virtual environments):
>>> from acme.agents.jax.d4pg import learning
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/data/venvs/acme/lib/python3.8/site-packages/acme/agents/jax/d4pg/__init__.py", line 17, in <module>
    from acme.agents.jax.d4pg.builder import D4PGBuilder
  File "/data/venvs/acme/lib/python3.8/site-packages/acme/agents/jax/d4pg/builder.py", line 24, in <module>
    from acme.agents.jax import actor_core as actor_core_lib
  File "/data/venvs/acme/lib/python3.8/site-packages/acme/agents/jax/actor_core.py", line 21, in <module>
    from acme.jax import networks as networks_lib
  File "/data/venvs/acme/lib/python3.8/site-packages/acme/jax/networks/__init__.py", line 17, in <module>
    from acme.jax.networks.atari import AtariTorso
  File "/data/venvs/acme/lib/python3.8/site-packages/acme/jax/networks/atari.py", line 27, in <module>
    from acme.jax.networks import base
  File "/data/venvs/acme/lib/python3.8/site-packages/acme/jax/networks/base.py", line 23, in <module>
    from acme.jax import utils as jax_utils
  File "/data/venvs/acme/lib/python3.8/site-packages/acme/jax/utils.py", line 27, in <module>
    import haiku as hk
  File "/data/venvs/acme/lib/python3.8/site-packages/haiku/__init__.py", line 19, in <module>
    from haiku import data_structures
  File "/data/venvs/acme/lib/python3.8/site-packages/haiku/data_structures.py", line 18, in <module>
    from haiku._src.data_structures import to_haiku_dict
  File "/data/venvs/acme/lib/python3.8/site-packages/haiku/_src/data_structures.py", line 30, in <module>
    from haiku._src import utils
  File "/data/venvs/acme/lib/python3.8/site-packages/haiku/_src/utils.py", line 42, in <module>
    def auto_repr(cls: type[Any], *args, **kwargs) -> str:
TypeError: 'type' object is not subscriptable

The same issue seems to exist in the Acme quickstart Colab notebook as well. In both cases, I was able to fix it by pinning dm-haiku==0.0.10. dm-haiku 0.0.11 has been released a couple of days ago so I guess it would be better to pin to 0.0.10 for now so that new users are able to run the examples and the Colab notebook.

I can confirm this and would appreciate a merge, as figuring out the dependencies can be somewhat of a daunting task for new users.
However, version 0.0.10 of dm-haiku actually requires jax version >= 0.4.13 compared to acme's 0.4.3. In practice this is not an issue though. dm-haiku version 0.0.9 also works, but that version pins jax to 0.3.16. Ultimately I suspect this is only a short-term fix that only compounds the problem by pinning another dependency version.


I am confused how to get the value in date input

I am confused how to take the value in the input date field and trigger change on that field
so i can call another function on change

like alert( ) the value of date?

my bad i got how to deal with it, thank you
on.dpchange


Re-opening a file fails when it was closed during compaction

Hi another edgy case when running many CubDB instances back to back:
there is CubDB.stop() happening just before this, but it seems as if the error message is indicating the on the next CubDB.start_link() the old compaction process still has a lock on the name?!
I tried adding halt_compaction before the stop:
CubDB.halt_compaction(db)
CubDB.stop(db)

but that didn't help either.
11:03:36.326 [error] GenServer #PID<0.266.0> terminating
** (ArgumentError) file "tmp/test_file_detsplus_bench_large_write_Elixir.CubDBWrap/1.compact" is already in use by another CubDB.Store.File
(cubdb 2.0.0) lib/cubdb/store/file.ex:43: CubDB.Store.File.ensure_exclusive_access!/1
(cubdb 2.0.0) lib/cubdb/store/file.ex:34: CubDB.Store.File.init/1
(elixir 1.13.4) lib/agent/server.ex:8: Agent.Server.init/1
(stdlib 3.15) gen_server.erl:427: :gen_server.init_it/2
(stdlib 3.15) gen_server.erl:394: :gen_server.init_it/6
(stdlib 3.15) proc_lib.erl:226: :proc_lib.init_p_do_apply/3
Last message: {:EXIT, #PID<0.263.0>, {%ArgumentError{message: "file "tmp/test_file_detsplus_bench_large_write_Elixir.CubDBWrap/1.compact" is already in use by another CubDB.Store.File"}, [{CubDB.Store.File, :ensure_exclusive_access!, 1, [file: 'lib/cubdb/store/file.ex', line: 43]}, {CubDB.Store.File, :init, 1, [file: 'lib/cubdb/store/file.ex', line: 34]}, {Agent.Server, :init, 1, [file: 'lib/agent/server.ex', line: 8]}, {:gen_server, :init_it, 2, [file: 'gen_server.erl', line: 427]}, {:gen_server, :init_it, 6, [file: 'gen_server.erl', line: 394]}, {:proc_lib, :init_p_do_apply, 3, [file: 'proc_lib.erl', line: 226]}]}}
State: %DynamicSupervisor{args: {{:temporary, 5000}, []}, children: %{}, extra_arguments: [], max_children: :infinity, max_restarts: 3, max_seconds: 5, mod: Task.Supervisor, name: {#PID<0.266.0>, Task.Supervisor}, restarts: [], strategy: :one_for_one}

Thanks for reporting @dominicletz ! This is indeed a bug, I am looking into it.


MacOS: molecule is not compatible with py37: weird error

Issue Type

Bug report

Molecule and Ansible details
Using molecule from master installed inside a tox virtualenv:
    TASK [Log into a Docker registry] **********************************************
    task path: /Users/ssbarnea/rdo/tripleo-ci/.tox/molecule/lib/python3.7/site-packages/molecule/provisioner/ansible/playbooks/docker/create.yml:8
    The full traceback is:
    Traceback (most recent call last):
      File "/Users/ssbarnea/.pyenv/versions/3.7.1/lib/python3.7/site-packages/ansible/executor/task_executor.py", line 96, in run
        items = self._get_loop_items()
      File "/Users/ssbarnea/.pyenv/versions/3.7.1/lib/python3.7/site-packages/ansible/executor/task_executor.py", line 215, in _get_loop_items
        convert_bare=False)
      File "/Users/ssbarnea/.pyenv/versions/3.7.1/lib/python3.7/site-packages/ansible/utils/listify.py", line 34, in listify_lookup_plugin_terms
        terms = templar.template(terms.strip(), convert_bare=convert_bare, fail_on_undefined=fail_on_undefined)
      File "/Users/ssbarnea/.pyenv/versions/3.7.1/lib/python3.7/site-packages/ansible/template/__init__.py", line 481, in template
        disable_lookups=disable_lookups,
      File "/Users/ssbarnea/.pyenv/versions/3.7.1/lib/python3.7/site-packages/ansible/template/__init__.py", line 686, in do_template
        myenv.filters.update(self._get_filters(myenv.filters))
      File "/Users/ssbarnea/.pyenv/versions/3.7.1/lib/python3.7/site-packages/ansible/template/__init__.py", line 302, in _get_filters
        plugins = [x for x in self._filter_loader.all()]
      File "/Users/ssbarnea/.pyenv/versions/3.7.1/lib/python3.7/site-packages/ansible/template/__init__.py", line 302, in <listcomp>
        plugins = [x for x in self._filter_loader.all()]
      File "/Users/ssbarnea/.pyenv/versions/3.7.1/lib/python3.7/site-packages/ansible/plugins/loader.py", line 435, in all
        module = self._load_module_source(name, path)
      File "/Users/ssbarnea/.pyenv/versions/3.7.1/lib/python3.7/site-packages/ansible/plugins/loader.py", line 345, in _load_module_source
        module = imp.load_source(full_name, path, module_file)
      File "/Users/ssbarnea/.pyenv/versions/3.7.1/lib/python3.7/imp.py", line 171, in load_source
        module = _load(spec)
      File "<frozen importlib._bootstrap>", line 696, in _load
      File "<frozen importlib._bootstrap>", line 677, in _load_unlocked
      File "<frozen importlib._bootstrap_external>", line 728, in exec_module
      File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
      File "/Users/ssbarnea/rdo/tripleo-ci/.tox/molecule/lib/python3.7/site-packages/molecule/provisioner/ansible/plugins/filters/molecule_core.py", line 23, in <module>
        from molecule import config
    ModuleNotFoundError: No module named 'molecule'

    fatal: [localhost]: FAILED! =>
      msg: Unexpected failure during module execution.
      stdout: ''

This is a very weird error because if I activate the same virtualenv and do do "import molecule" from python it works just fine. Still, when run like this it fails.

I run molecule under 3.7.2 and get no errors like this. I suspect it is something in your environment?

@ssbarnea try finding out what env vars you have before running that. Do you have PYTHONPATH modified? etc.

And also you can try patching that /Users/ssbarnea/rdo/tripleo-ci/.tox/molecule/lib/python3.7/site-packages/molecule/provisioner/ansible/plugins/filters/molecule_core.py just to log env vars at that point as well. It should provide more clue on what's going on.

Oh, and I see you run this under macOS, is it reproducible under GNU/Linux as well?

It looks like this is a result of some weird interplay between Tox/Pyenv/Virtualenv and not Molecule.
Can we close this?

Unless we get someone else on MacOS confirming that is working well with python 3.7, lets keep this open a litle bit more. I plan to investigate more but is not a no1 priority right now.

I’m having weird version incompatibilities when installing from pip on macOS. It’s downgrading a bunch of other packages I already have installed, including ansible-lint. Should I install via Homebrew? Or via pip from source?

@jonbackhaus I totally agree with you on that aspect, this annoyed me too can caused problems: the pinning of dependency versions in molecule. Please create a new bug for this issue as is not specific to MacOS. I will try to see what we can do about it because pinning vs unpinning is a very controversial subject in general.

Wait a second, that shouldn't be happening with ansible-lint, we don't pin (note: we exclude lower version of 4.0.x due to a bug, IIRC) https://github.com/ansible/molecule/blob/master/requirements.txt#L2. Can you provide some logs @jonbackhaus? Thanks.

@decentral1se -- I figured it out: if you're trying to install from pip you're getting v2.19.0. Based on the commit history, that version has ansible-lint==3.4.23; see https://github.com/ansible/molecule/blob/0272bc0560df4f76e1c00617ca0e0dd8b5a46b58/requirements.txt#L1. Special thanks to [wimglenn/johnnydep] for the awesome tool that helped me track down the issue!


morgen: 3.5.9 -> 3.6.3

Upgrades Morgen from 3.5.9 to 3.6.3
This is a follow-up of #361802
I tried making the PR as skimmable and easy-to-process as possible. I would love to hear how I can make the process easier on the maintainers. Thank you for the work you're doing here!
Things done

Built on platform(s)

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

For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)

[ ] sandbox = relaxed
[ ] sandbox = true

[ ] Tested, as applicable:

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

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

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

Add a :+1: reaction to pull requests you find important.

I tried making the PR as skimmable and easy-to-process as possible.

You failed :)

You made the nix expression invalid.
Check the CI pipeline, after proposing the change, if it fails fix it!
If your confident, that your changes are ready to be merged contact the maintainers of the package (here: justanotherariel, see meta section of the file you edited...)
And again: Do not create a new pr for each version bump because a new patch has been released, simply update your pr.

You failed :)
You made the nix expression invalid.

Thank you! I fixed and tested the changes locally. I'll keep an eye on the checks.

If your confident, that your changes are ready to be merged contact the maintainers of the package (here: justanotherariel, see meta section of the file you edited...)

Thanks, that's helpful because it gives me agency. If all the tests pass, I'll reach out to them.

Looks good so far, ofborg will take very long time to finish, but your change looks good. If you tested it locally and it all still works (which is the case usually for simple patch updates) you can ping him to check it too.
Due to the fact that morgen hasn't been merged to the new structure (pkgs/by-name), he won't be able to merge it though (He may have rights, I didn't check)... With the new structure package maintainers can merge their packages themself using a bot.

Line re-introduced :-)

Looks good so far, ofborg will take very long time to finish, but your change looks good. If you tested it locally and it all still works (which is the case usually for simple patch updates) you can ping the maintainer to check it too. Due to the fact that morgen hasn't been moved to the new structure (pkgs/by-name) yet, he (at least as a simple package maintainer) won't be able to merge it though (He may have merge rights for the whole repo, I didn't check). With the new structure package maintainers can merge their packages themself using a bot.

Thanks for the information. I'm learning a lot! But if that's the case, shouldn't I just move the whole thing to pkgs/by-name/mo/morgen?

Yea, I planned doing that at some point but didn't get to it. Sorry for the late reply - things have been very busy latetly. Seems like something broke in the auto update script... that needs fixing too, then ryantm will take care of creating these PRs.
I'll test your PR, and then make my own PR moving morgen to the pkgs dir and fixing the update script - hopefully in the next couple of days.
Cheers

And you can (and should) test your chages in nixpkgs by checking out the repository/branch, and then executing nix run .#morgen in that directory, if you have nix experimental commands enabled. There's probably a way to do it with nix-shell too. If you need an update quickly, you can include your own git patches when importing nixpkgs in your flake - but that may be a bit too advanced.


add charset=utf-8 to withJson response

Requesting the addition of a charset with the withJson response. This PR sets it to uff-8; maybe a parameter with a default value would be preferable.

I'm not sure adding charset=utf-8 really has an effect since the default JSON text encoding is UTF-8.

Hi, thanks for your review! The absence of the explicitly declared charset was picked up by our security scanner. Here is an explanation:

The encoding hasn't been declared either through the meta-tag, the byte-order-mark or the header, so the browser will make an attempt to detect the document's encoding. This exploit only works if the document reflects user input and the browser can be tricked into encoding the page as UTF-7 instead of UTF-8. Some of the browsers actually support UTF-7.

But I am also seeing that is exploit is pretty old and maybe not possible any more:

Older versions of Internet Explorer can be tricked into interpreting the page as UTF-7. This can be used for a cross-site scripting attack as the < and > marks can be encoded as +ADw- and +AD4- in UTF-7, which most validators let through as simple text. (https://en.wikipedia.org/wiki/UTF-7#Security)

What do you think of allowing users to set the charset with an optional parameter, and having no charset by default?

Coverage remained the same at 100.0% when pulling 9c911215299e8b2e071e3a4f21bfb94adfe6c5e4 on pzzd:withjson-charset into 4000ed92f20211ff4d0c0d0d149c925d625f98e1 on slimphp:master.

The application/json media type does not support charset as per https://www.iana.org/assignments/media-types/application/json.


"Release History and Acknowledgment" section in docs does not list 4.0.0

Done -- https://github.com/grails-plugins/grails-spring-security-core/commit/de758f838d50b67c7537d9c5596f9177d24da568


upgrade code to current werkzurg

werkzurg 1.0.1 has moved werkzurg.cached_property to werkzurk.utils.cached_property

Did you get a stacktrace/error for this? We don't use werkzurg directly -- I assume it's one of our dependencies

I believe this is resolved now.


wish: toml++

Library features

Header-only (optional!)
Supports the latest [TOML] release ([v1.0.0]), plus optional support for some unreleased TOML features
Passes all tests in the toml-test suite
Supports serializing to JSON and YAML
Proper UTF-8 handling (incl. BOM)
C++17 (plus some C++20 features where available, e.g. experimental support for [char8_t] strings)
Doesn't require RTTI
Works with or without exceptions
Tested on Clang (6+), GCC (7+) and MSVC (VS2019)
Tested on x64, x86 and ARM

Basic usage

ℹ The following example favours brevity. If you'd prefer full API documentation and lots of specific code snippets
instead, visit the project homepage

Given a TOML file configuration.toml containing the following:
[library]
name = "toml++"
authors = ["Mark Gillard<EMAIL_ADDRESS>
[dependencies]
cpp = 17

Reading it in C++ is easy with toml++:
#include <toml.hpp>

auto config = toml::parse_file( "configuration.toml" );

// get key-value pairs
std::string_view library_name = config["library"]["name"].value_or(""sv);
std::string_view library_author = config["library"]["authors"][0].value_or(""sv);
int64_t depends_on_cpp_version = config["dependencies"]["cpp"].value_or(0);

// modify the data
config.insert_or_assign("alternatives", toml::array{
    "cpptoml",
    "toml11",
    "Boost.TOML"
});

// use a visitor to iterate over heterogenous data
config.for_each ([](auto& key, auto& value)
{
    std::cout << value << "\n";
    if constexpr (toml::is_string<decltype(value)>)
        do_something_with_string_values(value);
});

// you can also iterate more 'traditionally' using a ranged-for
for (auto&& [k, v] : config)
{
    // ...
}

// re-serialize as TOML
std::cout << config << "\n";

// re-serialize as JSON
std::cout << toml::json_formatter{ config } << "\n";

// re-serialize as YAML
std::cout << toml::yaml_formatter{ config } << "\n";

You'll find some more code examples in the examples directory, and plenty more as part of the API documentation.
CC @marzer ☕

FYI, we have https://queue.cppget.org/toml11 sitting in a queue but the packaging quality needs quite a bit of work. The package repository is here (for now): https://github.com/good770326/toml11-build2-package

I wanted to look into packaging this library soonish. Still have some other packages to finish first. I'll keep you updated 👍

Oh cool, let me know if you need anything from me

FYI @marzer and @wroyca
I have started working on this package here
https://github.com/build2-packaging/tomlplusplus

Anything special for me to do here if/when I publish a new TOML++ release?

@marzer If you want that the tomlplusplus build2 package kind of stays up to date, then I guess its best if you post an issue on the package repo. At some point someone (maybe me) will pick the ticket up.
If you really want the package to stay up to date (in parallel with your repo), you can even post a PR for the package repo.
If you don't take any action, I guess the community will take care of updating the package to the latest version whenever someone needs / wants to use it.
@boris-kolpackov Anything to add or correct?

Anything to add or correct?

Nope, you've outlined the options pretty accurately. I guess the only option not mentioned would be to add build2 support upstream but to get the separate tests package arrangement (which is desirable due to the dependency on catch2) some restructuring of upstream would be needed. So it's probably not worth the trouble just for keeping things up to date.


feat: get gRPC descriptor from dp set

Now we can use descriptor set as descriptor source to invoke gRPC method.
About dp set: https://protobuf.dev/programming-guides/techniques/#self-description

Glad to see you already implemented the protoSet feature. I left some comments. And the relevant document is highly recommended. Users might want to know the following informations from it:

The description about the gRPC feature
How to use it
The explanation about the important fields

Since grpc is generally available, I will write a document to describe how to use it.

Since grpc is generally available, I will write a document to describe how to use it.

The gRPC official document is good enough for the gRPC itself. You can just give it a reference. You could only provide what you did in this project.

The gRPC official document is good enough for the gRPC itself. You can just give it a reference. You could only provide what you did in this project.

I means the document will be about how to create and run gRPC testcase, like a manual.

I means the document will be about how to create and run gRPC testcase, like a manual.

Sure.

A friendly reminder, the unit test is required, and the deadline of this program is very close. Please feel free to complete it if you have time.

A friendly reminder, the unit test is required, and the deadline of this program is very close. Please feel free to complete it if you have time.

Thanks. The unit tests are almost complete and only need a little time. I'll push the commits later today and verify the effect.

This is great. Do you still want to make any changes on this PR?

Yes, I will complete docs about secure today.

A little change to struct secure, please review it. Meanwhile, I think the works for this feature is completed.


Double upload in URL cl-image

I used the cl-image in an ng-for and from the second image on the ng-reflect-src="https://res.cloudinary.com/.../image/upload/upload/...jpg"
a double upload
"upload/upload"

Sorry Disregard! Was a typo..


Added support for sticky headers

This adds support for sticky headers when scrolling vertically. If there's need for horizontal support, I can look into that as well.

Here's the demo for it: http://rudolfrck.github.com/iscroll/

+1 (@cubiq : do you think this might be considered as a plugin? )

this is a very good experiment but I don't think it should be included into the main script. A plugin would be much better.

I have tried to create it as a plugin, but iScroll isn't extensible enough in it's current form to allow plugins of this kind.
You need more events/callbacks and access to more private features like vendor.
I could of course rewrite parts of iScroll to make it more extensible and then add it as a plugin.

Yes, I know, it's not your fault. I'll do my best to make it more extensible with the next release.

I've now created a "plugin" for this: https://github.com/rudolfrck/iscroll-stickyheaders
It's not the prettiest, cause I need to override/augment some of iscrolls-methods instead of using events/listeners, but it gets the job done.

We have a deal then, you try to make it more extensible, and I'll update my plugin with cleaner code :)
Thanks for the feedback!


Fix receive cert error handling

The runner seemed to swallow errors in receiveCertificate. Return them and log at caller.
 Hence, the logging only.

Ok, I'm confused. I changed this. StartInstanceAt shouldn't return an error.

Oh! I never actually removed the error return and can't because we catch panics.

I pushed another commit that reverts the rest of #674. I had thought I could remove errors from StartInstanceAt, and I'm not entirely sure how that patch ended up half-finished.


Stacked bar chart

Hello,
I have stacked bar chart (x & y axis stacked) - first chart on image, and I want make chart as second chart.

I've studied the code and ChartJS store data like this:
data: {
labels: ["1.12", "2.12"],
datasets: [
{
label: "Red",
backgroundColor: '#ff0000',
data: [1,2], // 1 - 1.12, 2 - 2.12
},
{
label: "Yellow",
backgroundColor: '#b7be3f',
data: [3,3], // 3 - 1.12, 3 - 2.12
},
... // Red and green
]
},
And I think, that need to store it something like bellow:
data: {
datasets: [
{
label: "1.12",
data: [
[1, red], [2, yellow]
], // Define first day
},
{
label: "2.12",
data: [
[3, green], [3, yellow]
], // Define second day
},
...
]
},

To make a chart like the 2nd picture, you're going to need a lot of datasets. Right now, the bar is created by slicing across the datasets at the given index to figure out all the items that will be present. This is not really ideal for your use case.
CC @chartjs/maintainers thoughts on how we could improve this?

Thank you for fast answer. I've studied ChartJS and I thought the same solution, but its need very large datasets and its not good.
So if I understand good - chartjs library is not good for realise this type graph? So if I will try create new graph, it wont work? Or do you know any other chart library, which is better for this type of graph?
Thank you for much.

In general, chart.js bar graphs are not meant for this kind of data. It might be possible to create a new chart type where each dataset becomes the column but I do not know how much work that would be.

Closing as answered. This is a request for a new chart type that probably should live as an extension


Leecher cannot download file from seeder twice

Seems like the scenario where I:

Start seeding as A
Download successfully as B
Reload page of B
Try to download as B again

Fails — B cannot connect to A (channel opens but you see Connecting UI)
Possibly because A has a record of having already served this file to B. That is my guess.

Possibly because A has a record of having already served this file to B. That is my guess.

I don't think this is true based on short inspection.

This might be related: https://github.com/statechannels/monorepo/issues/1851#issuecomment-629274401

So, I've been playing around this issue.
I've got a couple of logs of when I replicated this issue:
seeder logs.log
leecher logs.log
Some findings:

The seeder creates a new channel for the leecher (which is correct).
If the seeder reloads the page and re-seeds the torrent, the leecher goes back into the normal flow of downloading, so this might point to some data not being correctly cleaned up in the seeder side.
The seeder seems to behave correctly, one thing I suspected was that some data in web3torrent would be repeated, or something like that, but that doesn't seem to be the case.
The issue mainly that I see is that the leecher never even attempts to make a payment to the channel. Is there any other data that might be no longer valid that get's persisted outside the realm of web3torrent?.

One reason why leeching might be broken:

web3torrent client maintains a peerList[infoHash][peerId] dictionary that contains every wire for a torrent.
The keys of the dictionary are peer ids, aka the state channel participant id or signing address (I am not sure which one...)
The peer id for a leecher remains constant across reloads. So the peerList[infoHash][peerId] will contain stale data when a reloaded leecher tries to connect to a seeder.

My proposal is to index the peerList dictionary on seeding channel id aka peerList[infoHash][pseChannelId].
Thoughts? @spersico

Latest progress on this issue. To observe the behavior:

Seed a file with the seeder.
Leech the file successfully.
Reload the leecher.
Try to leech the file again.
Observe the deadlock.

Observe the following:

The last xstate transition on the seeder is to acquiringLock state in the ledger-funding workflow.
In the logs above, on the seeder, note that after the transition to defundGuarantor: {ledgerUpdate: "supportState"} state in virtual-defunding-as-leaf workflow, we see the warning of utils.js:424 Warning: No implementation found for action type 'releaseLock'.

Any insight from @lalexgap or @andrewgordstewart is appreciated!

That should be pretty easy to fix!
I think this'll do: https://github.com/statechannels/monorepo/pull/1914

This issue is resolved by https://github.com/statechannels/monorepo/pull/1914


Code block in nested lists can't display the header

@mugiwara85 Thank you for creating this beautiful and useful plug-in.
I have found in use that when placing a code block in a list (both ordered and unordered) , which means that each line of the code block is preceded by an tab/indent), the header with code language doesn't show up anymore.
Here is my test code:

Here is how it renders in code/edit/read view:

All tests were conducted in sandbox mode without any interruptions，
with both the "Always display codeblock language" switch in on/off mode.
I hope this issue can be resolved，
because the code blocks in the list are often used when recording steps.
Thank you for your reading.

Obsidian: v1.3.5
Codeblock Customizer: v1.1.9

Hi! Yes, someone already told me this in another issue. I will fix this also in the next release (that's why the release takes a little longer than usual).

@mugiwara85 Thank you vary much, waiting for your nice job 😊!


docs(readme): add a short summary line

approved by @sgoudham implicitly

@sgoudham approved now :heavy_check_mark:


Date Cell

Hello, I would to thank you of the selection cell type to have implemented.
I've something to point out about the date cell. The current type should be named "DateTime", and a new cell "Date" should be implemented. Suppose we have to make a birthday field in the form, the time is useless, just to make the user to select the date is the best practice. Do you agree?

Yes, I agree.
I implemented this and we can change date format by setting date formatter and date picker mode of date cell's property.
You can check this update at latest commit currently.
This update will be included in the next version.
Thank you.


xmas: new runtime driver for directed messaging

I've updated this driver to target the WIP vane from urbit/urbit#6932 (%mesa). Note that most of these changes were first staged on the yu/mesa branch of this repo.


Improve PR #496

PRs are not shown on the issues page, so this issue is just a placeholder. Please go to #496 for the details.

Hi @mhils . Shall I make those changes made by @gato and send a new PR ?

See #496 - if you want to pick this up, please briefly comment there, no need to ask for permission. :-)

@mhils I think it'd be a bit easier for me if you can merge this to a different branch so that I can pull from that branch and send a new PR ?

@Sentient07, I don't see any issues with working on @gato's branch, you can fork that as well.

@mhils https://github.com/mitmproxy/mitmproxy/pull/499 .
I wasn't actually sure if there was any merge conflicts from gato's fork. That's why clarified with you on pulling from his branch :)