Thanks!

Hi @TheMicDiet,
Just wanted to say thanks for the repo, especially the extensive Readme.
I've just got my first fish tank and was planning to automate the lighting via Alexa and then only discovered that my AII401 speaks bluetooth ❤ (not much advertised when I bought it).
So now that I know It speaks BLE I came up with the idea of building an Alexa skill. I think there's a nice prebuild voice preset that I could connect to the dimmer: PowerLevelController.
I'll keep you posted on my progress, but didn't want to wait with giving you a shout out. :)
🙌
PS: Feel free to close the issue once the "thanks" have been received 😜

Hi @stigi,
I'm glad to hear that my project is helpful for you! When I bought the LED, I couldn't find any information about the BLE protocol, so I thought it would be a good idea to share my findings with future tinkerers.
Good to know that Dennerle kits also come with Chihiros LEDs, I bought mine separately.
Good luck with your Alexa integration. I wanted to build a Home Assistant addon, but didn't have the time yet ;)

are you still planimg to do a home assistant addon?
i also have the wrgb2 and that would be so awesome to have it in my house automations.
best regards

I got demotivated because of the state of Alexa dev docs. I was hoping to establish a bluetooth connection between my Alexa device and the light, but to no success.
I ended up just getting a Chihiros Wifi hub for dirt cheap (https://www.aquasabi.de/Chihiros-Wifi-Hub) and can control my lights now from outside of bluetooth reach. Automation still only works via the Chihiros app.


Display local gifs with ueberzug

I'm using ueberzug and I am able to view images and svg's but local gifs appear as small black rectangle and online gifs such as:
![Alt Text](https://media.giphy.com/media/vFKqnCdLPNOKc/giphy.gif)

only show the first picture of the gifs and freeze(I assume)
previewing the same gifs in vifm with ueberzug does work though.
unless there are two versions of ueberzug on my pc and vifm and image each use different version it's probably not ueberzug.
also in markdown image links don't get detected and previewed automatically after typing the link unless I save the file and restart nvim...
Reference to the local gif file I'm trying to run:
https://github.com/ray-x/files/raw/master/img/navigator/show_signnature.gif?raw=true

Hey, ueberzug is a second class citizen due to being slow and we don't support animations yet, we convert all images to PNG.
Will probably support this in the next version.

Huh that's racist just because I don't want to touch the degenerate parasite kitty doesn't mean I need to treated like a second class citizen!!!!
Anyhow I thought it does some direct rendering and inlay on terminal tiles with ueberzug directly with it's engine, looks like this repo is gonna need a lot of refinement...

also btw if we are already in it how is the "Virtual padding" spaces created for the images called in the nvim terminology or some nvim plugin term?
:h extmark


Cassandra (CQL) Support?

I was wondering, is there any possibility of adding support for Cassandra? I'd be willing to contribute.

New dialects will not be implemented within the scope of knex, they should be created as separate npm packages.
See https://github.com/tgriesser/knex/blob/master/CONTRIBUTING.md -> "I would like to add support for new dialect to knex, is it possible?"
If you implement a new dialect, though, please let us know, we'll link to it from our documentation.


better error message when required flag is missing

Perceived Problem
This is the feedback a user gets when they do not supply a required flag:

Problems:

The entire help is shown, which could be huge, but only some inputs were missing. So showing help for inputs that were given for example is probably useless.

There is no clear visualization between the input the user gave, the error, and the docs. That means it requires the reader (user) to piece this together.

Ideas / Proposed Solution(s)
Here is a monochrome sketch of better output:

iteration two:


Add unit tests for solvers interfaces.

Every solver should have a corresponding unit test (or test suite) for it's interface. This serve as the entry-point for top-down test-driven development (TDD) but also as a start for bottom-up user experience (UX) testing and design.

obsolete


Yarn test on master fails in amplify-appsync-simulator

Before opening, please confirm:

[X] I have installed the latest version of the Amplify CLI (see above), and confirmed that the issue still persists.
[X] I have searched for duplicate or closed issues.
[X] I have read the guide for submitting bug reports.
[X] I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.
[X] I have removed any sensitive information from my code snippets and submission.

How did you install the Amplify CLI?
git clone the source
If applicable, what version of Node.js are you using?
v16.13.1
Amplify CLI Version
master
What operating system are you using?
Amazon Linux 2
Did you make any manual changes to the cloud resources managed by Amplify? Please describe the changes made.
None
Amplify Categories
api
Amplify Commands
Not applicable
Describe the bug
yarn test fails with "AWSURL parse Should reject an invalid URL 1" in the tests within amplify-appsync-simulator:

Expected behavior
yarn test should complete successfully
Reproduction steps

Perform local env setup as described in https://github.com/aws-amplify/amplify-cli/blob/master/CONTRIBUTING.md#local-environment-setup
Run yarn setup-dev
Run yarn test

GraphQL schema(s)

# Put schemas below this line

Log output

# Put your logs below this line

Additional information
No response

I am able to reproduce this with Node 16. The tests do not fail on Node 14, which explains how the change made it past our CI. Marking as a bug.


Can I add music or record voice to video

Can I add music or record voice to video

Any success with this?


Command to run a full test suite

It would be good to have a command to run a complete test suite, as defined in phpunit.xml
For example, running the "unit" test suite:

I'm thinking about two ways to implement this.

allow configuring an option --testsuite <name> in commands and keymaps, fo example:

    { "keys": ["ctrl+shift+a"], "command": "phpunit_test_suite", "args": {"suite": "x"}}

and

a command that parses the xml configuration file and prompts with a select list of test suites to run.

You can now setup keymaps and commands to run specific test suites, for example:
        { "keys": ["ctrl+shift+a"], "command": "phpunit_test_suite"},
        { "keys": ["ctrl+shift+a"], "command": "phpunit_test_suite", "args": {"testsuite": "foo"}},
        { "keys": ["ctrl+shift+a"], "command": "phpunit_test_suite", "args": {"testsuite": "foo,bar"}},
        { "keys": ["ctrl+shift+a"], "command": "phpunit_test_suite", "args": {"testsuite": ["foo", "bar"]}},

You can now setup test runners with custom configurations:
// Key Binding to run two specific test suites
{"keys": ["ctrl+shift+a"], "command": "test_suite", "args": {"testsuite": "fizz,buzz"}},

See the README for more details.


RayCast3D.get_collision_shape() reports wrong faceID of -1 from ConcaveShape3D

RayCast3D reports a value that is normally reserved for non-Concave collision shapes.

I have isolated the issue to Jolt's response to the above scenario
The data was reported with this str() clause: str("Face ID: ", ray_cast.get_collision_face_index(), ", Collider Shape: ", shape.shape)
Jolt:

Godot:

Support for face_index was only just recently added in #955. I haven't yet published a release with it.
If you need it urgently you can always build from source yourself (and enable the somewhat costly project setting).

Thank you for your answer!
My hope is that using Jolt will fix an inconsistent collision bug that I have been running into. I'll figure it out on release of the next version.
Have a good one!

Support for face_index can now be found in the newly released 0.14.0-stable release.
Note that the release on Godot Asset Library is still pending approval, so you might need to download it from GitHub for the time being.
Also note that you have to explicitly enable support for it, by enabling the physics/jolt_3d/queries/enable_ray_cast_face_index project setting, since it comes at a non-trivial memory cost, as talked about in #702.

Sweet!
On Sun, Nov 3, 2024 at 12:13 PM Mikael Hermansson @.***>
wrote:

Support for face_index can now be found in the newly released
0.14.0-stable
https://github.com/godot-jolt/godot-jolt/releases/tag/v0.14.0-stable
release.
Note that the release on Godot Asset Library is still pending approval, so
you might need to download it from GitHub for the time being.
Also note that you have to explicitly enable support for it, by enabling
the physics/jolt_3d/queries/enable_ray_cast_face_index project setting,
since it comes at a non-trivial memory cost, as talked about in #702
https://github.com/godot-jolt/godot-jolt/issues/702.
—
Reply to this email directly, view it on GitHub
https://github.com/godot-jolt/godot-jolt/issues/973#issuecomment-2453516715,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/BASPJVXSNIJQ3JQ3FIDMGHDZ6ZRTLAVCNFSM6AAAAABNQ4DI6OVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDINJTGUYTMNZRGU
.
You are receiving this because you authored the thread.Message ID:
@.***>


Support aarch64 Linux with page sizes >= 16k

Description:
This adds support for aarch64 Linux with page sizes >= 16k, by compiling with jemalloc configured with largest possible page size.
It will still work for all other aarch64 Linux systems. To give you some confidence, I ran your Github actions in my fork, and compiled 1.5.1 release with this patch. You can grab the binaries and test for yourself!
https://github.com/maximbaz/swc/releases/tag/v1.5.1-1
I didn't touch Android as I don't have enough knowledge to confirm that this is needed for that platform or how to verify it.
Related issue (if exists):
Fixes https://github.com/swc-project/swc/issues/5967
I originally came to report this, because I wanted to fix Next.js swc plugin, which suffers from exactly the same issue and requires exactly the same fix. I can confirm that Next.js can finally be used on my aarch64 Linux machine with this patch.

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

I'm sorry, but I agree with this post:
https://drewdevault.com/2018/10/05/Dont-sign-a-CLA.html
My bad, I should have checked if you require CLA before opening a PR.
Feel free to take over getting the fix committed, if you want to support this CPU architecture 👍

Thanks for the contribution and sorry that you're stuck with our CLA policy. Unfortunately, we require CLA for the contributors for the various reasons, something we can't move it away. Let me close this PR since you'd like to avoid sign it. Still appreciate for taking time to contribute.


Arbitrary functions fail when the Gen instance on their return type sometimes fails

This means, among other things, that any Arbitrary instance that relies on Gen.suchThat cannot be used to generate arbitrary functions.
As an example:
import org.scalacheck._

implicit val nonZero: Arbitrary[Int] = Arbitrary(Arbitrary.arbitrary[Int].suchThat(_ != 0))
val prop = Prop.forAll { (f: String => Int) => f("foo"); true }

And then:
scala> prop.check
java.lang.StackOverflowError
  ...

See alexarchambault/scalacheck-shapeless#50 for a far more insidious example.

So, just to be clear, the generator has to fail many times (by default 100) before the function generator fails. See pureApply and doPureApply here: https://github.com/rickynils/scalacheck/blob/master/src/main/scala/org/scalacheck/Gen.scala#L73.
I think this is the only reasonable behavior for a generator that can be filtered (it is roughly the same behavior as the original QuickCheck's). By contrast, @xuwei-k's ScalaProps library does not even include suchThat or filter, which is a cleaner design (it removes the possibility of generator exhaustion during tests and also ensures function generators can't fail).
My sense is that ScalaCheck-Shapeless wasn't just failing some of the time, but a significant fraction of the time (e.g. 50% or more) which seems like it needed to be fixed anyway.

@non Per the source, doApply is only called once.

As @nrinaudo's example illustrate, it only takes one failure to make Gen.function1 fail.
import org.scalacheck._

implicit val nonZero: Arbitrary[Int] = Arbitrary(Arbitrary.arbInt.arbitrary.suchThat(_ != 0))
val prop = Prop.forAll { (f: String => Int) => f("foo"); true }

prop.check

gives
! Exception raised on property evaluation.
> ARG_0: <function1>
> Exception: org.scalacheck.Gen$RetrievalError: couldn't generate value
org.scalacheck.Gen.loop$1(Gen.scala:57)
org.scalacheck.Gen.doPureApply(Gen.scala:58)
org.scalacheck.Gen.pureApply(Gen.scala:72)
org.scalacheck.GenArities$$anonfun$function1$1$$anonfun$1.apply(GenArities.
  scala:15)

OK! Yes, there is a bug/typo, the method should read:
  def doPureApply(p: Gen.Parameters, seed: Seed, retries: Int = 100): Gen.R[T] = {
    @tailrec def loop(r: Gen.R[T], i: Int): Gen.R[T] = {
      if (r.retrieve.isDefined) r
      else if (i > 0) loop(doApply(p, r.seed), i - 1)
      else throw new Gen.RetrievalError()
    }
    loop(doApply(p, seed), retries)
  }

I've confirmed that with this change the property passes.

I'd appreciate your publishing this fix for Scala 2.11. Thanks a lot.


[BUG] Error running yarn dev

Describe the bug
Immediately after running yarn dev, I receive the following error:
Internal server error: Cannot read properties of undefined (reading 'forEach')
It points to the following code in @shopify/hydrogen/dist/node/framework/middleware.js on line 62:
eventResponse.headers.forEach((value, key) => {
    response.setHeader(key, value);
});

To Reproduce
I'm using version 0.11.0 of the Hydrogen framework. It was an existing project that I've upgraded from the last release.
Expected behaviour
I expect no error.
Node Version: v16.14.0

Hi! Can you please provide a repro in Stackblitz (https://hydrogen.new) or GitHub?

I'm seeing the same after upgrading to 0.11.1 from previous version 0.10.1.

Do you have a src/App.server.jsx file with a code line like export default renderHydrogen(App, {routes});? Full example is here.
Something wrong in that file could explain this error you are seeing, I think 🤔
Otherwise, try running yarn dev --force to make sure Vite cache is removed.

Hi folks - closing this for now, as we can't reproduce. Please provide a public repro, or help us isolate what might be different about your codebase vs the current starter template and feel free to re-open.


Improve UX of existing Skills contribution form

The current InstructLab Contribute Skill workflow is not intuitive and does not provide enough guidance to the user.
@beaumorley

UX is capturing the current flow and making initial comments in a miro board:
InstructLab Contribute Skill Flow evaluation

@Misjohns Most of the suggestion you provides in the Miro boards is implemented. Such as

Addition of page title and description
All the required fields are marked now, and it throws error if the field is not populated.
File path now shows a tree of taxonomy directory that user can use to choose the target directory. Further improvements to this feature is tracked through #147
Submit button is disabled till user fill all the required field and validated.
Download button is added to download the yaml and attribution file. Download button would be disabled till user fill all the required fields.
View button is added to show the yaml and attribution file.

Two of the other proposed enhancement are not yet done and I opened following issues to track those #171 and #172 specifically.

@Misjohns I am closing this issue, because the major changes in skill forms are implemented.
In general it improves the chances of contributors picking up issue if the issue is clearly scoped for specific enhancement, so I opened separate issues for those remaining improvements. If i missed any enhancement, please feel free to open an issue to track that. Thanks


NAS-123519 / 24.10 / Add system global ID to debug

Context
Change adds the system global ID to system info in system plugin. The change will help in uniquely identifying the systems.

Jira URL: https://ixsystems.atlassian.net/browse/NAS-123519

This PR has been merged and conversations have been locked.
If you would like to discuss more about this issue please use our forums or raise a Jira ticket.


About dataset

Hi, you provide a great method to detect the basketball, I also read the Avi Shah's work. But he didn't provide a sufficient dataset to train, I want to know how you could train a wonderful pt and which dataset you chosen.

I have added the notebook I used to train the model I used, training.ipynb. I ran it on Google Colab utilizing their hardware acceleration. After training go to ./runs/detect/train/weights to find the .pt files. You can find plenty of datasets to train at https://universe.roboflow.com/browse/sports/basketball.

Thank you very much


Extend scalar aggregate operators to support higher order statistics

Current distributed scalar aggregate operators only support primitive statistics (such as sum, min, max).
We need to extend the functionality for higher order statistics like mean, variance of columns.
Scalar aggregation becomes non-trivial when the local and global reduction operation are not identical.
ex: Count --> local reduction is count, but global reduction is sum (compared to sum, both operations are sum)
Suggested approach is as follows. Take variance for an example.

Calculate intermediate statistics from local data. i.e. for each partition calculate sum_of_squares, sum, and count. (it would be important to look at the )
All-reduce intermediate data. ie. use MPI_SUM for [sum_of_squares, sum, count] array.
Finalize the result. i.e. calculate E(X2) - E(X)^2 (there would be some degree-of-freedom adjustments)

This is very similar to #535
Aggregate operators

[ ] COUNT (simplest)
[ ] MEAN (straight forward)
[ ] VAR and STDDEV
[ ] NUNIQUE (complicated. May require a shuffle, rather than an all-reduce)
[ ] QUANTILE

@deHasara you may want to look at this as a good second issue.


Changing precision level of TIME and TIMESTAMP columns

Fixes #6901.

Added paragraph, examples about changing precision levels to TIME and TIMESTAMP docs.

This change is

Online preview: http://cockroach-docs-review.s3-website-us-east-1.amazonaws.com/6fabde47e785801b495c0590b1b9725e278054bd/
Edited pages:

v20.1/time.md
v20.1/timestamp.md

Online preview: http://cockroach-docs-review.s3-website-us-east-1.amazonaws.com/96bc3f0f83d72b8e76b39e73fa984e78cc55d396/
Edited pages:

v20.1/time.md
v20.1/timestamp.md

LGTM

TFTR @otan!


wireless-regdb: 2020.04.29 -> 2021.04.21

Motivation for this change
version bump
Things done

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

[x] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[x] Tested execution of all binary files (usually in ./result/bin/)
21.11 Release Notes (or backporting 21.05 Relase 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.

diff --color -r wireless-regdb-2021.04.21/db.txt wireless-regdb-2020.04.29/db.txt
377,378c377
< #    Resolución 98- 2019 Reglamento de Redes Inalámbricas:
< # https://www.mincom.gob.cu/sites/default/files/marcoregulatorio/r_98-19_reglamento_redes_inalambricas.pdf
---
> # Resolución 127- 2011 Reglamento de Banda de frecuencias de 2,4 GHz.
381,383d379
< 	(5150 - 5350 @ 80), (200 mW), NO-IR, NO-OUTDOOR
< 	(5470 - 5725 @ 80), (250 mW), NO-IR
< 	(5725 - 5850 @ 80), (200 mW)
523d518
< # https://www.tra.gov.eg/en/industry/importing-of-equipment/Pages/Regulations-for-use-of-Wireless-Networks-Devices.aspx
525,527c520,522
< 	(2402 - 2483.5 @ 40), (20)
< 	(5150 - 5250 @ 80), (23), NO-OUTDOOR, AUTO-BW, wmmrule=ETSI
< 	(5250 - 5330 @ 80), (20), NO-OUTDOOR, DFS, AUTO-BW, wmmrule=ETSI
---
> 	(2402 - 2482 @ 40), (20)
> 	(5170 - 5250 @ 40), (20)
> 	(5250 - 5330 @ 40), (20), DFS
534c529
< # ES: https://avancedigital.mineco.gob.es/espectro/Paginas/cnaf.aspx
---
> # ES: https://avancedigital.gob.es/espectro/Paginas/cnaf.aspx
600c595
< 	(5470 - 5730 @ 160), (500 mW), DFS, wmmrule=ETSI
---
> 	(5470 - 5725 @ 160), (500 mW), DFS, wmmrule=ETSI
602c597
< 	(5725 - 5875 @ 80), (100 mW), DFS
---
> 	(5725 - 5875 @ 80), (25 mW)
701,702c696,697
< 	(5150 - 5250 @ 80), (200 mW), AUTO-BW, wmmrule=ETSI
< 	(5250 - 5350 @ 80), (200 mW), DFS, AUTO-BW, wmmrule=ETSI
---
> 	(5150 - 5250 @ 80), (200 mW), NO-OUTDOOR, AUTO-BW, wmmrule=ETSI
> 	(5250 - 5350 @ 80), (100 mW), NO-OUTDOOR, DFS, AUTO-BW, wmmrule=ETSI
879,880c874,875
< # http://adilet.zan.kz/rus/docs/V1500010730
< # http://adilet.zan.kz/rus/docs/V1500010375
---
> # http://mic.gov.kz/sites/default/files/pages/pravila_prisvoeniya_polos_chastot_no34.pdf
> # http://adilet.zan.kz/rus/docs/P000001379_
882,883c877,878
< 	(2400 - 2483.5 @ 40), (20)
< 	(5150 - 5250 @ 80), (23), NO-OUTDOOR, AUTO-BW
---
> 	(2402 - 2482 @ 40), (20)
> 	(5150 - 5250 @ 80), (20), NO-OUTDOOR, AUTO-BW
885,887c880
< 	(5470 - 5725 @ 160), (20), NO-OUTDOOR, DFS
< 	(5725 - 5850 @ 80), (20), NO-OUTDOOR
< 	(57000 - 66000 @ 2160), (40)
---
> 	(5470 - 5725 @ 80), (20), NO-OUTDOOR, DFS
1253,1254d1245
< 	# https://fab.gov.pk/type-approval/
< 	# https://pta.gov.pk/media/Pakistan_Table_of_Frequency_Allocations.pdf
1256c1247
< 	(5725 - 5875 @ 80), (30)
---
> 	(5735 - 5835 @ 80), (30)
1555,1560c1546,1552
< # Source: https://zakon.rada.gov.ua/laws/show/z0201-15#n48
< # Although it is allowed to use up to 250 mW for some 5 GHz frequency ranges,
< # all of them are limited to 100 mW for IEEE 802.11n and IEEE 802.11ac.
< # 2.4 GHz band channels can be used outdoors when some requirements are met.
< # 5 GHz band channels must be used only indoors in some cases. They are neither
< # permitted nor denied outdoors in others.
---
> # Source:
> # #914 / 06 Sep 2007: http://www.ucrf.gov.ua/uk/doc/nkrz/1196068874
> # #1174 / 23 Oct 2008: http://www.nkrz.gov.ua/uk/activities/ruling/1225269361
> # (appendix 8)
> # Listed 5GHz range is a lowest common denominator for all related
> # rules in the referenced laws. Such a range is used because of
> # disputable definitions there.
1562,1566c1554,1558
< 	(2400 - 2483.5 @ 40), (100 mW), NO-OUTDOOR
< 	(5150 - 5250 @ 80), (100 mW), NO-OUTDOOR, AUTO-BW, wmmrule=ETSI
< 	(5250 - 5350 @ 80), (100 mW), DFS, NO-OUTDOOR, AUTO-BW, wmmrule=ETSI
< 	(5470 - 5725 @ 160), (100 mW), DFS, NO-OUTDOOR, wmmrule=ETSI
< 	(5725 - 5850 @ 80), (100 mW), NO-OUTDOOR
---
> 	(2400 - 2483.5 @ 40), (20), NO-OUTDOOR
> 	(5150 - 5250 @ 80), (20), NO-OUTDOOR, AUTO-BW
> 	(5250 - 5350 @ 80), (20), DFS, NO-OUTDOOR, AUTO-BW
> 	(5490 - 5670 @ 160), (20), DFS
> 	(5735 - 5835 @ 80), (20)
1568c1560
< 	(57000 - 66000 @ 2160), (40 mW), NO-OUTDOOR
---
> 	(57000 - 66000 @ 2160), (40)
1579,1582d1570
< # Channels 12 and 13 are not forbidden, but are not normally used with full
< # power in order to avoid any potential interference in the adjacent restricted
< # frequency band, 2,483.5–2,500 MHz which is subject to strict emission limits
< # set out in 47 CFR § 15.205. TODO: reenable and specify a safe TX power here.
1584c1572
< 	(2400 - 2472 @ 40), (30)
---
> 	(2400 - 2483.5 @ 40), (30)
diff --color -r wireless-regdb-2021.04.21/gen-pubcert.sh wireless-regdb-2020.04.29/gen-pubcert.sh
3,4c3,4
< if [[ $# -ne 3 ]]; then
< 	echo "Usage: $0 priv-key out-file common-name"
---
> if [[ $# -ne 2 ]]; then
> 	echo "Usage: $0 priv-key out-file"
16c16
< 		commonName = $3
---
> 		commonName = sforshee
diff --color -r wireless-regdb-2021.04.21/Makefile wireless-regdb-2020.04.29/Makefile
83c83
< 	./gen-pubcert.sh $(REGDB_PRIVKEY) $(REGDB_PUBCERT) $(REGDB_AUTHOR)
---
> 	./gen-pubcert.sh $(REGDB_PRIVKEY) $(REGDB_PUBCERT)
Binary files wireless-regdb-2021.04.21/regulatory.bin and wireless-regdb-2020.04.29/regulatory.bin differ
Binary files wireless-regdb-2021.04.21/regulatory.db and wireless-regdb-2020.04.29/regulatory.db differ
Binary files wireless-regdb-2021.04.21/regulatory.db.p7s and wireless-regdb-2020.04.29/regulatory.db.p7s differ
diff --color -r wireless-regdb-2021.04.21/sha1sum.txt wireless-regdb-2020.04.29/sha1sum.txt
1c1
< eefdcdb489db066cd4807a72199d468f4132fff8  db.txt
---
> 6fb563dd8cd662d23c1f2551a035de08e1e45ec5  db.txt


[release-1.12] Fix service invocation error due to slow app start up.

Description
Fix to avoid race condition in 1.12 (not present in 1.11) between service invocation and app's health.
Issue reference

Please reference the issue this PR will close: N/A
Checklist
Please make sure you've  completed the relevant tasks for this PR, out of the following list:

[ ] Code compiles correctly
[ ] Created/updated tests
[ ] Unit tests passing
[ ] End-to-end tests passing
[ ] Extended the documentation / Created issue in the https://github.com/dapr/docs/ repo: dapr/docs#[issue number]
[ ] Specification has been updated / Created issue in the https://github.com/dapr/docs/ repo: dapr/docs#[issue number]
[ ] Provided sample for the feature / Created issue in the https://github.com/dapr/docs/ repo: dapr/docs#[issue number]

Decided not to change this and recommend apps to wait for app channel to be healthy as a new feature in 1.13. See https://github.com/dapr/dapr/issues/6976


Improve latency

As of testing there is about a 1-1.5 second delay from talking to hearing it out of speakers.

Look at modifying buffer size
Try to modify blocking code

Removing printlns improved latency a bit.

Latency has been improved quite a bit. Having a way to track latency via TCP could be useful.


need to add download page of Apache APISIX

Apache APISIX has the Apache release now: https://dist.apache.org/repos/dist/release/incubator/apisix/0.9/, so we need to add download page like https://shardingsphere.apache.org/document/current/en/downloads/

will be published tonight

https://apisix.incubator.apache.org/downloads/


Added editing search result table columns

@DmitryKey Added the "edit columns" dialog in the search tab.
Allows selecting and reordering columns.

hi @yossivainshtein
thanks again for your contribution!
Don't worry, it is standard practice to have something not merging. I'm travelling now, but what we can do is:

Try to merge to thinlet branch by resolving conflicts.
We can checkout tag of https://github.com/DmitryKey/luke/releases/tag/luke-4.10.4 and merge to there -- anyway that is your intent.

As a result, we'll have two releases -- one for target luke 4.10.4 and the other for the latest version of thinlet luke.


Revert "Update manual.html"

Need to check layout more. Breaks current layout.
Reverts DIT112-V21/group-09#47

Looks to merge. Tested and works as expected. Thanks.


Sticky behavior of "back to top" button

The sticky behavior of this button should match the header behavior described here.

When scrolling down the page, button should not be visible
When a user reaches the bottom of the page, it will become visible by sliding in from the side of the page
When scrolling up the page, it will become visible by sliding in from the side of the page
When a user stops scrolling up the page, it will remain visible until the user scrolls down the page at which point it slides off the side of the page

In the proposed behavior, the button does not appear when scrolling down the page. It only appears when a user has reached the bottom of the page, or when a user scrolls up the page.
Currently, the button appears as a user moves down the page.
Additionally, when the button disappears, it should slide right (similar to how it appears by sliding left).
Currently, when the button disappears, there is no animation.


Default values for fields

Add a capability to add default values for fields.
for example like this:
import 'package:sealed_annotations/sealed_annotations.dart';

part 'weather.sealed.dart';

@Sealed()
abstract class _Weather {
  void sunny();

  void rainy({int rain = 10});

  void windy({@WithDefault('1e10') double velocity, double? angle = 100.0});
}

there is the question that if it should support dynamic defaults as well ?!

@SaeedMasoumi

There should be ability to set default values on constructor


Help with implementing the Reactive Scrabble benchmark

I'd like to implement the Reactive Scrabble benchmark with Reactors.IO but I have difficulties finding and applying the necessary operators (I'm not a Scala developer by the way). This is how far I've gotten. Any help would be appreciated.
1) chars: Streaming the characters of a String on-demand
In other libraries, one would create a range with the length of the string and map each index into a character. A twitter reply mentioned .toEvents which I'm not sure how to apply as this doesn't work on its own (missing import?).
(string: String) =>(0 until string.length).toEvents().map((i) => string.charAt(i))

2) flatMap: flatmapping an iterable sequence
I need to generate Events[Map.Entry[Int, Long]] from Events[Map[Int, Long]] by calling entrySet() then flattening the returned Set[Map.Entry[Int, Long]].
I found union that makes Events[Events[T]] into Events[T] but then I need a way to turn Set[T] into Events[T] in some way (unbatch?).
3) fromIterable: Turning an Iterable/Seq sequence into Events
Is there a way to turn into an Events that only sends out the elements if there is demand for it?

This should work if you import the io.reactors.protocol package:

import io.reactors.protocol._
(s: String) => (0 until s.length).toEvents.map(i => string.charAt(i))

Note that event streams in Reactors are lazy. This means that in order to start emitting events, you need to invoke one of the on* methods, such as onEvent, or one of the to* methods, such as toSignal.
The event stream obtained from a collection (such as range) is, in addition, cold. This means that the events are not emitted until you subscribe to this event stream. In the case of toEvents, all events are immediately available (since the range contains them), so they will all be emitted right away, synchronously.

The union combinator (which has the more familiar alias flatten) combines all events from nested event streams. You want to map the event stream of maps into an event stream of entry sets, and then to an event stream of event streams with those entries, then everything.

time     ----------------------------->
in       ---M1------------M2---------->
            e1-e2-e3-|
                          f1-f2-f3-|
out      ---e1-e2-e3----f1-f2-f3 ----->

Here's one way you could achieve what you want (note that you need to create the Java set to a Scala set):
import io.reactors._
import io.reactors.protocol._
import scala.collection.convert.decorateAll._

val mapEvents: Events[Map[Int, Long]] = new Events.Emitter[Map[Int, Long]]
mapsEvents.map(m => m.entrySet.toEvents).union

This does the same:
mapsEvents.map(m => m.entrySet).map(s => s.toEvents).union

Hm, if by demand you mean that there is a subscriber for it, then that's already the case with event streams created from collections. Such an event stream will traverse the collection, and emit all the elements as events. In other words, when you call toEvents on a collection, nothing will be emitted until somebody calls onEvent on that event stream. All "cold" event streams behave like this.

Hot event streams (such as system.clock.timeout) emit events regardless of whether there are onEvent calls.
Generally, though, there is the toCold combinator which converts an event stream into a signal that only subscribes to its event stream if there is someone subscribed to that signal.

Thanks for the reply, the suggestions now compile but the app now fails with an NPE. I'll post a separate issue.


Make tether-to-selection use fixed positioning relative to selection

Changes {{tether-to-selection}} to:

use "position: fixed". Avoids issues when the editor is in an
absolutely-positioned div
(bugfix) Do not position relative to ".mobiledoc-editor". This was
error-prone when there was more than one editor on the page, and also
unnecessary.
Add 'mobiledoc-selection-tether' class (escape hatch for styling by
consumers)
(bugfix) Read the window's selection metrics before element insertion. When
the yielded link-prompt component focuses its input field, that
changes the window selection. Reading before insertion fixes this
problem.

released in v0.4.1


P2P ref from UWP picks the win8 version instead of uap10.0 ver of cross-compiled lib

Moved from https://github.com/dotnet/roslyn-project-system/issues/937 on behalf of @onovotny:

A UWP project isn't getting the correct output of a cross-compiled project. Instead it's getting the win8 version.
Check out
https://github.com/onovotny/Zeroconf/tree/847ef218c7f94a1dc0b0dfa35a4c11d954c97f98
The ZeroconfTest.UWP project has a P2P ref to Zeroconf. Zeroconf has lots of targets. The product in the dll shows what TFM it was built for. When looking at what's in the UWP\bin\x86\Debug directory, I see the win8 version not the uap10.0 version and things break.

See https://github.com/dotnet/roslyn-project-system/issues/937#issuecomment-266874274 for the patch that fixed the issue. The problem is that it is $(NugetTargetMoniker) and not $(TargetFrameworkMoniker) that will result in nuget picking the correct "best" target for UAP.

I'm seeing this now in a .NET 4.5 test project referencing a project that multi-targets to the following:
netstandard1.2;netstandard1.3;net45;win81;wpa81;MonoAndroid70;Xamarin.iOS10
It's using the netstandard1.2 version (the first in the list?) instead of the net45 ver.

@nguerrera I'm seeing this across the board for "regular" projects referencing a multi-targeted one:
https://github.com/onovotny/microsoft-authentication-library-for-dotnet/tree/1336a410808341c5ab09efa04b096b82f476ade7
In there, every project seems to be choosing the netstandard1.2 version based on the path I see in the properties window when I select the reference. Those should all be choosing "closer" platform-specific versions.

@onovotny That's different and bizarre. Can you log a separate SDK bug and share repro steps?

@nguerrera done: https://github.com/dotnet/sdk/issues/535

@nguerrera -- have you made any progress on this fix? This is currently targeted for RC3 release.

I will re-validate the fix tomorrow and send a PR.

This is still happening with RC3 for me.

Yes. It's not fixed yet. PR coming shortly.


Model validator states and consensus participation

Our current staking implementation gets the basic economics mostly right, but doesn't actually model whether or not validators are part of the consensus set, or what the validator life cycle is.
We should map out the state transitions validators can make, and work out the interactions with the staking system.  Here is one sketch:
                                       ┌ ─ ─ ─ ─ ┐
                                         Genesis
                                       │Validator│
                                        ─ ─ ─ ─ ─
                                            │
                                            │
┌ ─ ─ ─ ─ ─ ─ ─ ─                           ▼
    Validator    │      ┏━━━━━━━━┓      ╔══════╗      ┏━━━━━━━┓
│   Definition    ─────▶┃Inactive┃─────▶║Active║─────▶┃Slashed┃
 (in transaction)│      ┗━━━━━━━━┛      ╚══════╝      ┗━━━━━━━┛
└ ─ ─ ─ ─ ─ ─ ─ ─            ▲              ▲             ▲
                             │              │             │
                             │              ▼             │
                             │         ╔═════════╗        │
                             └─────────║Unbonding║────────┘
                                       ╚═════════╝

Single lines represent unbonded stake, and double lines represent bonded stake.
Validators become known to the chain either at genesis, or by means of a transaction with a ValidatorDefinition action in them. Validators transition through four states:

Inactive, where the validator is not part of the consensus set, the stake in the validator's delegation pool is not bonded;
Active, where the validator is part of the consensus set, and the stake in the validator's delegation pool is bonded;
Unbonding, where the validator is not part of the consensus set, but the stake in the validator's delegation pool is still bonded;
Slashed, where the validator is not part of the consensus set, and the stake in the validator's delegation pool is not bonded.

Validators specified in the genesis config begin in the active state, with whatever stake was allocated to their delegation pool at genesis. Otherwise, validators begin in the inactive state, with no stake in their delegation pool.  At this point, the validator is known to the chain, and stake can be contributed to its delegation pool.  Stake contributed to an inactive validator's delegation pool does not earn rewards (the validator's rates are held constant), but it is also not bonded, so undelegations are effective immediately, with no unbonding period and no output quarantine.
The chain chooses a validator limit N as a consensus parameter. When a validator's delegation pool (a) has a nonzero balance and (b) its (voting-power-adjusted) size is in the top N validators, it moves into the active state during the next epoch transition.  Active validators participate in consensus, and are communicated to Tendermint. Stake contributed to an active validator's delegation pool earns rewards (the validator's rates are updated at each epoch to track the rewards accruing to the pool). That stake is bonded, so undelegations have an unbonding period and an output quarantine. An active validator can exit the consensus set in two ways.
First, the validator could be slashed.  This can happen in any block, not just at an epoch transition.  Slashed validators are immediately removed from the consensus set. Any pending undelegations from a slashed validator are cancelled: the quarantined output notes are deleted, and the quarantined nullifiers are removed from the nullifier set.  The validator's rates are updated to price in the slashing penalty, and are then held constant. Slashed validators are jailed, and permanently prohibited from participation in consensus (though their operators can create new identity keys, if they'd like to). Stake cannot be delegated to a slashed validator. Stake already contributed to a slashed validator's delegation pool is not bonded (the validator has already been slashed and jailed), so undelegations are effective immediately, with no unbonding period and no quarantine.
Second, the validator could be displaced from the validator set by another validator with more stake in its delegation pool. The validator is then in the unbonding state.  It does not participate in consensus, and the stake in its delegation pool does not earn rewards (the validator's rates are held constant).  However, the stake in its delegation pool is still bonded.  Undelegations from an unbonding validator are quarantined with an unbonding period that starts when the undelegation was performed, not when the validator began unbonding.  Unbonding validators have three possible state transitions:

they can become active again, if new delegations boost its weight back into the top N;
they can be slashed, if evidence of misbehavior arises during the unbending period;
they can become inactive, if neither (1) nor (2) occurs before the unbonding period passes.

If (2) occurs, the same state transitions as in regular slashing occur: all pending undelegations are cancelled, etc.
If (3) occurs, all pending undelegations are immediately removed from quarantine, short-circuiting the unbonding period that began when the undelegation was performed.  If (1) occurs, the validator stops unbonding, but this has no effect on pending undelegations, since they were quarantined with an unbonding period that started when the undelegation was performed (i.e., as if they were undelegations from an active validator).

We've implemented (a version of) this model, but we haven't written up a spec for it.  Following #507, we should extract the design + diagram above into the protocol spec, and cross-reference it with the behavior in the implementation as a way to self-validate our code.

xref #387; we'll want to model that state transition in this writeup.

@hdevalence can you provide the source monodraw files for this diagram?

@zbuc oops, sorry for missing this -- I don't still have it, it was a one-off. What's the current status of this issue?


The execution never ends

When I run the test, the execution never ends and what I have to do is in the last test put a process.exit(1)
My package.json looks like this:
"scripts": {
    "test": "tape ./test/*.js | tap-spec"
  }

there a better way?

The tests should finish automatically. Did you forget to put t.end() in one of your tests?

I'm having this same issue. It doesn't matter whether I use t.end() or t.plan(). After running all the tests, the process sits until I manually kill it.

Tests are ordinary node processes, so if you have open handles, the process will hang as it ought to.

that's true, I open connections to databases and then compare answers (among other things)
I guess that is why the process does not finish.
I have resolved to create a file named ztest.js:
const tape = require('tape')

tape('SUMMARY', function (t) {
  process.exit(0)
})

The file begins with z to be the last to be called, and and as I said before, this is my package.json:
"scripts": {
    "test": "tape ./test/*.js | tap-spec"
}

Just run into the same thing. Also open connections in a db connection pool.
Now the problem is - I am not sure how to gracefully shut everything down. Given that supertest is calling the express app directly I have no clue if there is a way to hook into this.
The interesting bit - it just works with mocha.
var request = require('supertest');

describe('bla', function(){
  it('test', function(done) {

    request(app)
      .post('/auth/token')
      .send({
        username: 'the_username',
        password: 'the_password'
      })
      .expect(200)
      .expect('Content-Type', /json/)
      .end(function(err, res) {
        done();
      });

  });
});

test('test', function(t) {

  request(app)
    .post('/auth/token')
    .send({
      username: 'the_username',
      password: 'the_password'
    })
    .expect(200)
    .expect('Content-Type', /json/)
    .end(function(err, res) {
      t.end();
    });

});

Tape doesn't do any magic like mocha, if anything keeps the event loop open, it will stay open and you are responsible for closing any connections, etc.  I personally think this method helps me understand my application better and avoids issues I've had with mocha's magic getting in the way.
That said, it can be confusing to track down what actually is keeping the event loop open!  In the case of express apps, usually its that I have a database connection open (for session storage for example) and need to either unref that in my tests or close it down at the end of my tests.

There is a module called leaked-handles that can be used for debugging.

https://github.com/Raynos/leaked-handles nice, thanks

Boom @Raynos @tcurdt thanks for posting - needed this.

This may be of interest: http://puigcerber.com/2015/11/27/testing-express-apis-with-tape-and-supertest/

Just encountered this and fixed it by stopping the HTTP server (hapi) and disconnecting from the Postgres database (knex) in my teardown test.

I've closed the db connection and it well perfect.

This can be hepful

// ES6
test.onFinish(() => process.exit(0));

// ES5
test.onFinish(function() {
  process.exit(0)
});

Quite the rabbit hole. Had an open handle to mongoDB using mongoose. Just needed to close the connection.

Just ran into this as well, want to note to anyone that this happens if you use setInterval in your tests as well (not just things like open db connections)

For some people here, make sure that when in test mode (usually best found via NODE_ENV) your server doesn't listen for any connections.

@substack tests are ordinary node.js processes, and therefore a test runner should force-close (with process.exit(x)) the test process after the final test case?

Calling process.exit() in your tests is not the best way to solve this problem, since a callback might otherwise double-fire and you wouldn't know about it. It's also useful to know if your code is leaking handles. Here's a way you can set up your tests to avoid this problem:
var test = require('tape')

var db
test('setup', function (t) {
  db = openDatabase()
})

test.onFinish(function () {
  db.close()
})

well process.exit is also bad because you don't know what exit code to use, the test runner knows the exit code.

@substack thanks for your answer, changing to your structure works for me. The code below was what I had before and it was not working- the db connection was opened but the test was never running, can you tell why?
var test = require('tape')

var db = openDatabase()
db.on('open', function () {

  test('setup', function (t) {
    t.ok('test passing')
    t.end()
  })

  test.onFinish(function () {
    db.close()
  })
})

Hey @mattlub I think I can answer that actually:
var test = require('tape');
var DB_CONN;

test('setup database', {timeout: 10000}, function(t) {
  openDatabase()
    .on('open'), function() {
      t.comment('Database connection established');
      t.end();
    })
})

... tests that use the database ...

test('Close the database connection', function(t) {
// not sure if this takes a callback or produces or promise, but I went ahead and assumed it took a callback -- I assume DB.close() is not synchronous?
  DB.close(function() {
    t.comment('Database connection closed');
    t.end();
  });
})

@mattlub @t3hmrman t.plan is also seems to fix

Run into this yesterday and yes closing mongoose connection did the job!

`const test = require('tape');
const supertest = require('supertest');
const app = require('../app');
const docJson = require('./docJson');
const mongoose = require('mongoose');
function dropDB() {
mongoose.connection.db.dropCollection('ingr_users');
}
test('Init database:', {timeout: 10000}, (t) => {
mongoose.connection
.on('open', () => {
t.comment('Database connection established');
dropDB();
t.end();
});
});
test('========== POST api/v1/user ==========', (t) => {
supertest(app)
.post('/api/v1/user/')
.send(docJson)
.expect('Content-Type', /json/)
.expect(200)
.end((err, res) => {
t.error(err, 'No error returned');
t.assert(res.body.name === docJson.name, 'Name inserted!');
t.assert(res.body.idade === docJson.idade, 'Age inserted!');
t.assert(res.body.email === docJson.email, 'Email inserted!');
t.end();
});
});
test('========== GET api/v1/user ==========', (t) => {
supertest(app)
.get(/api/v1/user/)
.expect('Content-Type', /json/)
.expect(200)
.end((err, res) => {
t.error(err, 'No error returned');
t.assert(res.body[0].name === docJson.name, 'Name catched!');
t.assert(res.body[0].idade === docJson.idade, 'Age catched!');
t.assert(res.body[0].email === docJson.email, 'Email catched!');
t.end();
});
});
test('Disconnect database:', (t) => {
mongoose.connection.close(() => {
t.comment('Database connection closed');
t.end();
});
});
`
Guy, I can't explain how, but now after implement more and more tests, I stop with "npm run test --silence" and I run "npm run test" before sends you the code, magically it's working without the error. I am scared because I don't undestand what happened hahaha.

Guy, I can't explain how, but now after implement more and more tests, I stop with "npm run test --silence" and I run "npm run test" before sends you the code, magically it's working without the error. I am scared because I don't undestand what happened hahaha.

I solved the problem using
tape.plan ()
tape.on Finish (() => {process.exit (0)})

Just to reiterate, as others have noted here, the right way to solve this is to write code that does not leave NodeJS hanging.
You can choose to either use tape.plan or just tape.assert & call t.end yourself, but your tests should not hang  -- they end up hanging whenever you do stuff that hangs the runtime/event loop, like:

uncaught exceptions
never ending setInterval
libraries that you run which use the event loop that need to be stopped/cleaned up

Generally, for setup of persistent testing utilities, just make a pseudo-test that sets the utility up. Here's an example from some recent code I've written with tape -- I'm not claiming it's the golden way, but it's a way:
let TEST_DB: DB; // Global DB component for this test file
let TEST_UGC: LocalDirUGC; // Global DB component for this test file
let app: Express = buildApplication();

// Tape test that sets up the DB -- passing a callback to set up the global TEST_DB in this file
TestUtil.setupTestDB((db: DB) => {
    TEST_DB = db;
    return TEST_DB.setup(app);
});

TestUtil.setupTestUGC((ugc: LocalDirUGC) => {
    TEST_UGC = ugc;
    return TEST_UGC.setup(app);
});

test("document creation by ugc upload works", (t: Test) => {
    // ... your test code, which uses TEST_DB
});

// ... other tests which make use of TEST_DB ...

TestUtil.cleanupTestDB(() => TEST_DB);

It's perhaps a little hard to see, but setupTestDB is a function that when evaluated runs the the test -- but by having setupTestDB be a function, you can pass it a callback to use to set a variable in the script-global state for the test file. setupTestDB finishes when the setup is finished, so the global variable is set before any other tests run.
You can use your global (in my case TEST_DB) in subsequent tests since tape runs tests in a sequential manner. I normally add some code to the test instance to ensure that I can reset it between tests if necessary (and if creating a new one is costly).
setupTestDB looks like this:
/**
 * Set up a database for test
 *
 * @param {Function} cb - Callback to run when the test database is set up (i.e. you could set a global value to the DB)
 */
export function setupTestDB(cb?: (db: DB) => Promise<any>) {
    // Run a test that setups the datbase
    test("setting up database for test", (t: Test) => {
        makeTestDB()
            .then((db: DB) => {
                t.ok(db, `db created for testing (database: ${db.getDatabaseName()})`);
                return cb ? cb(db) : Promise.resolve();
            })
            .then(() => t.end())
            .catch(t.end);
    })
}

and cleanupTestDB looks like this:
/**
 * Cleanup a database for test
 *
 * @param {Function} getDB - A function that returns the DB object
 */
export function cleanupTestDB(getDB: () => DB) {
    // Run a test that setups the datbase
    test("cleaning up database used in test(s)", (t: Test) => {
        // Get the DB out of the closure
        const db = getDB();
        if (typeof db === "undefined") { throw new Error("DB is undefined"); }

        const dbName = db.getDatabaseName();

        // Retrieve the default and actual connection being used by the db (in test they will likely be different, one pointing to a temp db)
        Promise.all([
            db.getDefaultConnection(),
            db.getConnection(),
        ])
            .then(([defaultConn, conn]) => {
                // Ensure conn is at least defined
                if (!conn) { return Promise.reject(new Error("DB is disconnected (not even default)")); }

                // Ensure we don't ever try to drop the default (ormconfig.js configured) DB, or a db named "happilease"
                if (defaultConn === conn || dbName === "master") {
                    t.comment("DB name is [master], will not remove");
                    return Promise.resolve();
                }

                // Close the connection then use default to drop the associated DB
                return conn.close()
                    .then(() => defaultConn.query(`DROP DATABASE ${dbName}`));
            })
            .then(() => t.ok(db, `db ${dbName} dropped`))
            .then(() => t.end())
            .catch(t.end);
    })
}

(apologies, some of this code is very specific to typeorm), but it should give a good example of the pattern I'm employing.
BTW, this pattern also scales well to parallel suite running with bogota -- since bogota runs the suites (test files) in parallel but still runs the tests inside serially.

Just to reiterate, as others have noted here, the right way to solve this is to write code that does not hang the NodeJS runtime. You can choose to either use tape.plan & a set number of tests or just tape.assert & call t.end, but your tests should not hang  -- they end up hanging whenever you do stuff that hangs the runtime/event loop, like:

uncaught exceptions
never ending setInterval
libraries that you run which use the event loop that need to be stopped/cleaned up

Generally, for setup of persistent testing resources, you can make a pseudo-test that sets the utility up. Here's an example from some recent code I've written with tape -- I'm not claiming it's the golden way, but it's a way:
let TEST_DB: DB; // Global DB component for this test file
let TEST_UGC: LocalDirUGC; // Global DB component for this test file
let app: Express = buildApplication();

// Tape test that sets up the DB -- passing a callback to set up the global TEST_DB in this file
TestUtil.setupTestDB((db: DB) => {
    TEST_DB = db;
    return TEST_DB.setup(app);
});

TestUtil.setupTestUGC((ugc: LocalDirUGC) => {
    TEST_UGC = ugc;
    return TEST_UGC.setup(app);
});

test("document creation by ugc upload works", (t: Test) => {
    // ... your test code, which uses TEST_DB
});

// ... other tests which make use of TEST_DB ...

TestUtil.cleanupTestDB(() => TEST_DB);

It's perhaps a little hard to see, but setupTestDB is a function that when evaluated runs the the test -- but by having setupTestDB be a function, you can pass it a callback to use to set a variable in the script-global state for the test file. setupTestDB finishes when the setup is finished, so the global variable is set before any other tests run.
You can use your global (in my case TEST_DB) in subsequent tests since tape runs tests in a sequential manner. I normally add some code to the test instance to ensure that I can reset it between tests if necessary (and if creating a new one is costly).
setupTestDB looks like this:
/**
 * Set up a database for test
 *
 * @param {Function} cb - Callback to run when the test database is set up (i.e. you could set a global value to the DB)
 */
export function setupTestDB(cb?: (db: DB) => Promise<any>) {
    // Run a test that setups the datbase
    test("setting up database for test", (t: Test) => {
        makeTestDB()
            .then((db: DB) => {
                t.ok(db, `db created for testing (database: ${db.getDatabaseName()})`);
                return cb ? cb(db) : Promise.resolve();
            })
            .then(() => t.end())
            .catch(t.end);
    })
}

and cleanupTestDB looks like this:
/**
 * Cleanup a database for test
 *
 * @param {Function} getDB - A function that returns the DB object
 */
export function cleanupTestDB(getDB: () => DB) {
    // Run a test that setups the datbase
    test("cleaning up database used in test(s)", (t: Test) => {
        // Get the DB out of the closure
        const db = getDB();
        if (typeof db === "undefined") { throw new Error("DB is undefined"); }

        const dbName = db.getDatabaseName();

        // Retrieve the default and actual connection being used by the db (in test they will likely be different, one pointing to a temp db)
        Promise.all([
            db.getDefaultConnection(),
            db.getConnection(),
        ])
            .then(([defaultConn, conn]) => {
                // Ensure conn is at least defined
                if (!conn) { return Promise.reject(new Error("DB is disconnected (not even default)")); }

                // Ensure we don't ever try to drop the default (ormconfig.js configured) DB, or a db named "master"
                if (defaultConn === conn || dbName === "master") {
                    t.comment("DB name is [master], will not remove");
                    return Promise.resolve();
                }

                // Close the connection then use default to drop the associated DB
                return conn.close()
                    .then(() => defaultConn.query(`DROP DATABASE ${dbName}`));
            })
            .then(() => t.ok(db, `db ${dbName} dropped`))
            .then(() => t.end())
            .catch(t.end);
    })
}

(apologies, some of this code is very specific to typeorm), but it should give a good example of the pattern I'm employing.
BTW, this pattern also scales well to parallel suite running with bogota -- since bogota runs the suites (test files) in parallel but still runs the tests inside serially.

Same problem using promises and sockets, the execution of script is end (debugged) but the test is not end:
const test = require('tape');
const { DNSResolve } = require('./');

test('Resolve UDP', async (t) => {
    const dnsResolve = new DNSResolve();
    await dnsResolve.resolve({
        server: 'udp://<IP_ADDRESS>:53',
        hostname: 'google.com',
        type: 'A'
    })
    .then(results => {
        results = results[0]
        t.ok(results.header.id == 13330);
        t.ok(results.header.type == 'response');
    })
    .catch(e => {
        t.error(e);
    });

    console.log('It is end!');
    t.end();
})

test.onFinish(() => process.exit(0));

The console.log is printed on finish of execution but the process is not finished.

@yhojann-cl you don't need the onFinish or the t.end() there, if you're using tape 5+; and that won't work at all using tape < 5, because you need to use t.plan for async tests (tape 5 added Promise support)

But creating an advance test plan is more tedious and more prone to errors when inserting new tests within a large code, it is safer that the quantity is not declared and declare the completion at a certain point, in this way it is not prone to errors due to test recounting.

@yhojann-cl yes, which is why tape v5 added support for a test function returning a Promise - which is why in your example, assuming you're using tape 5, you can omit the t.end() and also the onFinish, and it should Just Work. If it doesn't, please file a new issue instead of resurrecting this ancient one :-)


add bash to terminal commands

Thanks for the PR but this doesn't change anything on the look. The $ at the beginning is meant to show that visually, and semantically


Correct function of Keep-Alive header

The HTTP Keep-Alive response header [1] max parameter indicates the number of remaining requests that a client may make before the server closes the connection.
The current implementation seems to be trying to take into account the number of active connections to the server when responding, which does not seem correct. This PR changes the value sent to be a simple count of requests remaining.  Once the count becomes zero, a Connection: Close header is sent.
[1]: https://tools.ietf.org/id/draft-thomson-hybi-http-timeout-03.html#rfc.section.2

@carlbrown Please could you review?  I'd like to understand your original intention w.r.t. connection count.  If the intention is to limit the number of concurrent requests being handled by the server, I would suggest that instead we instead limit the number of connections at the point of acceptance.

@djones6 Section 2.2.1 of the RFC you included says the max parameter is deprecated anyway. Why don't we just throw it out? Do we actually need it?

To be clear - that would mean that the connectionCount logic is that superfluous and can be removed (I'm good if that's the case - it gives us something like a 15% perf hit).

The spec I referred to was a draft, apparently never made it to the RFC stage, and appears to have expired - though implementations exist (Firefox and Apache, among others).  HTTP 1.1 allows for the presence of Keep-Alive parameters (but doesn't actually define any), so clients are free to ignore them.
The max and timeout params are more a courtesy to the client, which is still expected to cope with being sent a Connection: Close, or with the connection being dropped between requests.  Whether we choose to send these params with the response headers is independent of whether we want the ability to enforce a limit on the number of requests made on a single Keep-Alive connection.
If we do retain this ability, I would like it to be user-configurable, and default to 'unlimited'.
@carlbrown what would be your preference?

If we do retain this ability, I would like it to be user-configurable, and default to 'unlimited'.
@carlbrown what would be your preference?

If we don't have a requirement for it, I'd rather omit it.  I'd like this code to be as simple as possible.

@carlbrown I removed the Keep-Alive header entirely.  There is no longer any counting of requests per connection,  but the timeout mechanism remains (which is important, as otherwise we would depend on clients to terminate their connections).


vllm could not be used because of CUDA kernal

hi, I got a problem when I was trying to use vllm.

nt PyTorch version is :

and my gpu machine is P100, Nvidia-driveris 470.141. could you please check this problem? thx

Hi, thanks for trying our codes. From our experience, the vllm is sometimes indeed hard to install because it depends on xformers. See this post. I think you need to load the model as dtype half on P100 with vllm. One of my server which has the similar environment that could run vllm successfully has the following package: torch 2.0.1+cu118, vllm==0.1.6. Another server with latest vllm is: torch 2.1.0+cu121 vllm==0.2.0. You could try different cuda versions (no need to upgrade the server's cuda, it can be shipped with pytorch installation in the env) or vllm versions. Note that we have found some differences in outputs from vllm 0.1.6 and vllm 0.2.0. You could also try build from source if you meet some installation or running issue.
If all above solutions cannot work well, maybe you could still stick to hugging face which is easier to install but slow. Plz let us know if you still meet the installation or running issues.


rabbit-task-pull

add pull ability to rabbit-task
add fax example

@hartuvofir thanks for this PR, @chenrozenes used your ideas and integrated that into rabbit-task.


Story: cli command to get the reference to the current stage

Summary / Background
I have an artifact registry built with git + dvc + gto.
In a pipeline, I would like to get the reference to the current prod stage of that registry, so that I can get the artifact I need.
The only way I found to achieve this is:
gto history --repo REPO_URL --json ARTIFACT_NAME | jq '[.[] | select(.stage == "prod") | {commit: .commit, version: (.version)}] | sort_by(.version) | .[-1].commit'

This is quite cumbersome. It would be more convenient to have a dedicated command.
Scope

user can use a command likegto get-ref --repo REPO_URL --stage prod ARTIFACT_NAME

and obtain in return the git commit reference to the current prod stage (e.g. 975ab374971367996379396eb88991d893a461f2).

Assumptions

Commit hash is all you need, no need for other references like tags.

Open Questions

Is there any another way to obtain the same in a simple manner?

@francesco086, I think you're looking for:
$ gto show -r http://github.com/iterative/example-gto churn#prod --ref
<EMAIL_ADDRESS>
or
$ gto show -r http://github.com/iterative/example-gto churn@latest --ref
<EMAIL_ADDRESS>
Am I correct?

In a pipeline, I would like to get the reference to the current prod stage of that registry, so that I can get the artifact I need.

Curious to learn more details about the use case. Do you have a cron job in your repo that deploys daily/weekly? Or it is something else?

Cool, thanks. Good to know how you use it!

@aguschin in few month I think I will reach out you or Jennifer or whoever you think is best at iterative, perhaps it could be useful if I share what I have done ;)


cannot create /dev/stdout: No such device or address

Hi,
i am having following issue (note that i am running this inside WSL2 Linux distro with concurrently installed globally):
concurrently 'echo HelloWorld > /dev/stdout'
[0] /bin/sh: 1: cannot create /dev/stdout: No such device or address
[0] echo HelloWorld > /dev/stdout exited with code 2

Hey, just so you know - looked into, couldn't replicate yet, and I don't have access to Windows virtualization at the moment.
If I may ask you - why are you piping to /dev/stdout?

Hey, just so you know - looked into, couldn't replicate yet, and I don't have access to Windows virtualization at the moment.
If I may ask you - why are you piping to /dev/stdout?

it's just an example to illustrate the error but you can imagine any process there writing to standard output. also i got it working by downgrading concurrently to 8.* and running concurrently --raw 'echo HelloWorld > /dev/stdout'


Use grep to find service, serverspec uses systemd

Serverspec assumes systemd, and chef 12 uses sys-v. So use grep to find the service, for our testing. Also refactor tests into shared spot, so the package TK suite can be tested as well. Fixes #181.

This looks good to merge to me.  I like the reorganization.  Maybe can you include in this upping the centos version to 6.6 in test-kitchen.  When I was testing the last PR learned that test-kitchen no longer supports 6.4 or 6.5.  All tests worked fine on 6.6 from what I noticed.

Thanks @zarry -- I added 6.6. Since that's the only change, I'll merge with your approval.


Html, css

Before opening an issue:

Search for duplicate or closed issues
Validate and lint any HTML to avoid common problems
Prepare a reduced test case for any bugs
Read the contributing guidelines

When asking general "how to" questions:

Please do not open an issue here
Instead, ask for help on StackOverflow, IRC, or Slack

When reporting a bug, include:

Operating system and version (Windows, Mac OS X, Android, iOS, Win10 Mobile)
Browser and version (Chrome, Firefox, Safari, IE, MS Edge, Opera 15+, Android Browser)
Reduced test cases and potential fixes using JS Bin

When suggesting a feature, include:

As much detail as possible for what we should add and why it's important to Bootstrap
Relevant links to prior art, screenshots, or live demos whenever possible

I'm looking for help with html/css refresher

Sorry, but we cannot help with how-to or general troubleshooting issues here; only bug reports and feature requests. You'll want to ask around in the official Slack team or Stack Overflow. See our readme for more details.


JEI and Creative Inventory not showing all items

When i search @Refined Storage in JEI or normal Creative Inventory it doesn't show all items.

But when i open the Refined Storage tab in the Creative Inventory it shows all items.

Minecraft:  1.12.2
Forge:  <IP_ADDRESS>59
Refined Storage:  1.6.12
FTB Continuum: 1.5.2

Does this issue occur on a server? no

A temporary work around is typing @refined.

Searching for @refined Storage will yield all items from refined storage that have the text "Storage" somewhere on the item description.
ModID's are only one word and as such you need to search for @refinedstorage to find all items from the mod.


PKIFailureInfo

It seems there is a bug in the TimeStampResponseGenerator.
The way the PKIFailureInfo in generated by assuming that if failInfo is not set if the value in 0, unfortunately badAlg has the value of ´0´ meaning that the generator cannot create a response with the ´badAlg´ identifier as specified by the RFC

badAlg is bit zero, not the value zero. The bit string syntax says which bit is set for a particular status.


high load

Which version are you using?
v0.23.2
Which operating system are you using?

[x] Linux amd64 standard
[ ] Linux amd64 Docker
[ ] Linux arm64 standard
[ ] Linux arm64 Docker
[ ] Linux arm7 standard
[ ] Linux arm7 Docker
[ ] Linux arm6 standard
[ ] Linux arm6 Docker
[ ] Windows amd64 standard
[ ] Windows amd64 Docker (WSL backend)
[ ] macOS amd64 standard
[ ] macOS amd64 Docker
[x] Other (Debian LXC)

Describe the issue
If you set the
runOnReady: ffmpeg -i rtsp://localhost:$RTSP_PORT/$RTSP_PATH -c copy -f segment -strftime 1 -segment_time 60 -segment_format mpegts saved_%Y-%m-%d_%H-%M-% S.ts

, then the load on the server increases (load average 6.12 6.30 6.05), memory and processor consumption rise to 30% -40%.
but if you run ffmpeg -i rtsp://localhost:$RTSP_PORT/$RTSP_PATH -c copy -f segment -strftime 1 -segment_time 60 -segment_format mpegts saved_%Y-%m-%d_%H-%M-%S.ts separately for each thread in the background, then the values of load average 0.40 0.37 0.35, processor and memory are not rises above 7%.
PS. 300 streams on the server
Describe how to replicate the issue

start the server
set runOnReady: ffmpeg -i rtsp://localhost:$RTSP_PORT/$RTSP_PATH -c copy -f segment -strftime 1 -segment_time 60 -segment_format mpegts saved_%Y-%m-%d_%H-%M-% S.ts
publish with rtsp
check load

Did you attach the server logs?
yes / no
Did you attach a network dump?
yes / no

hello, the only thing that comes to my mind is that maybe there's some load involved in processing and displaying log lines of all FFmpeg instances, since log lines are written sequentially to the terminal. Try disabling FFmpeg output:
paths:
  all:
    runOnReady: ffmpeg -loglevel error -i rtsp://localhost:$RTSP_PORT/$RTSP_PATH -c copy -f segment -strftime 1 -segment_time 60 -segment_format mpegts saved_%Y-%m-%d_%H-%M-%.ts

Other than that, i tested FFmpeg inside and outside runOnReady, and it consumed exactly the same.

closed since no additional feedback was provided.


Dynamic styled(component) by passing component as prop

Version
styled-components: ^2.2.1
babel-plugin-styled-components: ^1.1.7
Steps to reproduce

Create a styled component that takes a prop containing a component and return it.

const Icon = styled(({ component }) => component)`
  background: red;
`

Use the styled component in your render & pass it a 'component' prop.

<Icon component={<MyCustomIco fill={color} width={size} height={size} />} />

The outcome should be that the style is applied to

<MyCustomIco />

Expected Behavior
Created a generic styled component, for example Icon. Then I'm passing a component as a prop to the styled component. In the styled component, I write a function that takes out the component prop (containing my component) and returns it. I expect it to use this component to apply the styled component to.
Actual Behavior
Nothing is being applied to the passed component.

@kitten can you elaborate on or point me to some documentation explaining why dynamic render components are not recommended? Is it the same issue with using styled in render?

@probablyup's solution works well, but if you want React dev tools to have the node with a displayName, you need to pass a named function rather that anonymous to styled():
const Icon = styled(
  Icon = ({ component, ...props }) => React.cloneElement(component, ...props)
)`...`;

@kitten can you elaborate on or point me to some documentation explaining why dynamic render components are not recommended? Is it the same issue with using styled in render?

https://styled-components.com/docs/faqs#why-should-i-avoid-declaring-styled-components-in-the-render-method


Fixed image quality warning dialog appears 2 times if you quick on next quickly(#2442)

Description (required)
Fixes #2442
What changes did you make and why?
Add flag isChecking to class UploadItem to indicate whether it's being
checked for image quality. Checking this flag before starting a new
validation. This should avoid starting a new validation while another
validation is running, which causing image quality warning dialog
appears twice.
Tests performed (required)
Tested master betaDebug on Nexus 6P with API level 27.
Screenshots showing what changed (optional - for UI changes)
No screenshots but I tested that the warning dialog just appear once if image quality test failed.

Codecov Report

Merging #2482 into master will increase coverage by <.01%.
The diff coverage is 8.69%.

@@            Coverage Diff            @@
##           master   #2482      +/-   ##
=========================================
+ Coverage    5.81%   5.82%   +<.01%
=========================================
  Files         257     257
  Lines       12210   12231      +21
  Branches     1097    1099       +2
=========================================
+ Hits          710     712       +2
- Misses      11442   11460      +18
- Partials       58      59       +1

Impacted Files
Coverage Δ

...va/fr/free/nrw/commons/upload/UploadPresenter.java
10.36% <0%> (-0.63%)
:arrow_down:

...n/java/fr/free/nrw/commons/upload/UploadModel.java
32.18% <16.66%> (-0.56%)
:arrow_down:

...ree/nrw/commons/upload/ImageProcessingService.java
84% <25%> (-5.14%)
:arrow_down:

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 0ef60e0...d20e6f4. Read the comment docs.

@zhao-gang Thanks for the PR. :)
Your approach doesn't look correct to me at first look. I will take a look at the PR tonight.
You might be aware of Subject in Rxjava. If you are not familiar with the concept then this blog might be interesting for you.
https://blog.mindorks.com/understanding-rxjava-subject-publish-replay-behavior-and-async-subject-224d663d452f
FYI, we are using BehaviourSubject to get the processing result.

@mashawan Surely there may be a better way to solve this issue than mine :-) I think the reason caused this bug is that the first validation starts running, and then quickly the next button is pressed which caused the second validation starts. Since the first validation has not completed so it does not show the dialog to let the user set the IMAGE_KEEP flag in BehaviourSubject imageQuality, so the second validation also starts the checking(it does not see the IMAGE_KEEP flag, since it has not been set yet and starts the real checking work, which is duplicated to the first one).
The main point is that to the same UploadItem, we should not start a second validation before the first one finished. I add a flag to indicate whether an UploadItem is being checked. There may be other ways to do this.

Yes you are right. We should not start a second validation if the first is running. BehaviourSubject would return the latest result to the new callable. Do you mind if I make edits to your PR?

@mashawan Please feel free to edit my PR :-)

Rebased to current master.

I don't think this is an issue anymore, please reopen if this can be reproduced


There is dependency issue of react. While npm i, using node v16.


Avoid repeated scanning of siblings array

glob.ts part of #47187. I have left TODOs in explorerViewer.ts for the remaining work.

@chrmarti this is a great change, thanks for doing it. I can already see a speedup from 500ms to 100ms for filtering the explorer with 2000 children in a folder. And that is, without using the idea of parsing the expression.
Now for that topic, can you help me out? I tried to cache the expression as a parsed thing but I get compile errors now. Here is the explorer filter with the changes to try out:
// Explorer Filter
interface CachedParsedExpression {
	original: glob.IExpression;
	parsed: glob.ParsedExpression;
}

export class FileFilter implements IFilter {

	private hiddenExpressionPerRoot: Map<string, CachedParsedExpression>;
	private workspaceFolderChangeListener: IDisposable;

	constructor(
		@IWorkspaceContextService private contextService: IWorkspaceContextService,
		@IConfigurationService private configurationService: IConfigurationService
	) {
		this.hiddenExpressionPerRoot = new Map<string, CachedParsedExpression>();

		this.registerListeners();
	}

	public registerListeners(): void {
		this.workspaceFolderChangeListener = this.contextService.onDidChangeWorkspaceFolders(() => this.updateConfiguration());
	}

	public updateConfiguration(): boolean {
		let needsRefresh = false;
		this.contextService.getWorkspace().folders.forEach(folder => {
			const configuration = this.configurationService.getValue<IFilesConfiguration>({ resource: folder.uri });
			const excludesConfig = (configuration && configuration.files && configuration.files.exclude) || Object.create(null);

			if (!needsRefresh) {
				const cached = this.hiddenExpressionPerRoot.get(folder.uri.toString());
				needsRefresh = !cached || !objects.equals(cached, excludesConfig);
			}

			const excludesConfigCopy = objects.deepClone(excludesConfig); // do not keep the config, as it gets mutated under our hoods

			this.hiddenExpressionPerRoot.set(folder.uri.toString(), { original: excludesConfigCopy, parsed: glob.parse(excludesConfigCopy) } as CachedParsedExpression);
		});

		return needsRefresh;
	}

	public isVisible(tree: ITree, stat: ExplorerItem): boolean {
		return this.doIsVisible(stat);
	}

	private doIsVisible(stat: ExplorerItem): boolean {
		if (stat instanceof NewStatPlaceholder || stat.isRoot) {
			return true; // always visible
		}

		// Hide those that match Hidden Patterns
		const cached = this.hiddenExpressionPerRoot.get(stat.root.resource.toString());
		if (cached && cached.parsed(paths.normalize(path.relative(stat.root.resource.path, stat.resource.path), true), name => !!stat.parent.getChild(name))) {
			return false; // hidden through pattern
		}

		return true;
	}

	public dispose(): void {
		this.workspaceFolderChangeListener = dispose(this.workspaceFolderChangeListener);
	}
}

I pushed the additional changes to cache the expression and now I see around 20ms spend in filtering for a 2000 folder child 💯

@roblourens Let us know if you agree with the changes. Not much changes in Search. One thing I noted is that there is one call to fs.readdir() per match when there is a siblings clause due to the way things are wired up at https://github.com/Microsoft/vscode/blob/b74812161ec46c9011bba92d5ee1f4400aef0593/src/vs/workbench/services/search/node/ripgrepTextSearch.ts#L82 and https://github.com/Microsoft/vscode/blob/b74812161ec46c9011bba92d5ee1f4400aef0593/src/vs/workbench/api/node/extHostSearch.ts#L432. That hasn't changed with this change.

LGTM. It should only call fs.readdir for matches that match the LHS of the sibling clause. Not every result, so I haven't bothered to cache those files, but I could do that.

@chrmarti great work, thanks for doing this


Experimental paste actions break some common cases

You may be aware of these, but just in case you aren't:

Turn on "editor.experimental.pasteActions.enabled": true
Have multiple selections, and paste. 🐛 Where previously the value was pasted into every selection, only the first selection gets the value
Without a selection, press ctrl+c to copy and line, then ctrl+v to paste it 🐛 Where previously the new line was pasted above the current line, it's now pasted at the cursor position

Tagging on to this to report relevant copy-paste behavior bugs.
Apart from the full line copy paste scenario, there are problems with multi-cursor paste as well.
Should:

If number of lines of the text in the clipboard matches the number of selections active, one line of text is pasted per cursor.
Else, paste entire clipboard on every cursor location

Current:

Pastes full clipboard text to activeSelections[0]

The first issue should be mostly fixed. The one remaining problem is that multi-cursor copy+paste doesn't work as before (this is the case where you copy from X locations and the paste into X locations)

@mjbvz Another bug is that when turn on "editor.experimental.pasteActions.enabled": true
Open an md file, use the find command, and pasting some text.
The text will be pasted into the file instead of into the input box of the find command.

@liyuhang1997 Please open new issues for any other issues


Safari page load issue

TypeError: _.current.at is not a function. (In '_.current.at(-1)', '_.current.at' is undefined) — transition.js:1:4022
instrument.js:109

Page loads for a split second, then displays nothing. Issue only present in Safari (tested chrome, opera, firefox and safari)

Might be related https://github.com/tailwindlabs/headlessui/issues/1088


Skills reset

During the 23rd of July meeting the necessity of handling reset actions of skills emerged again. There are two ways to implement such actions in our interpreter:

The first, as suggested by @miccol, is to proceed as follows: every time a child of a Sequence node (which is not the last) returns Running or Fail, we send a "reset message" to each of the following children, indipendently from any previous execution. It is up to the code realizing the individual skills to decide what to do with this reset message (i.e., ignore it if the skill is not running, take the appropriate action otherwise)
The second, as suggested by @StefanoSoffiaUTRC, is to send the reset messages only when needed (i.e. to previously activated skills). Of course this needs some form of local memory in our representation of Behavior Trees. The simplest way to achieve this is to augment the BT data structure with a field cached_output of type return_enum which memorizes the previous return value of each node, and then modify slightly the semantics of Sequence and Fallback nodes (I sketched a possible algorithm on this page).

I have already implemented the first approach in the file reactive.v. The idea is that the implementer specifies a function to be called in order to reset a skill, similar to the ExecuteSkill interface we are already using. (The OCaml code is not yet updated to use the new semantics, however.)
The second approach needs a more radical modification of the BT data type, so it would be better to do it in a separate branch.
Comments/remarks?

Of course this is possible, but I don't see why this is a problem for reset messages. The cached information is only used to decide which skills should be reset, not which should be executed. At worst we just send a superflous reset.

A superfluous reset could be dangerous if the halt of a skill is not properly configured (by the user).
For example, if the code in the halt requires access to a resource and the resource is no longer available after the action has terminated (e.g. write on a log file).
I understand this is a very corner case.

I agree with @miccol.
AFAIK the idea was already described and implemented in the ALES proposal of alternative BT formulation included in this SMV file.
The approach is the same of the one in the first point from the first post. Basically, each tick visits all the leaves of the BT but either enabling or disabling (i.e. reset) them.
@altacch what you describe in the second point seems to me the discussion we had about the implementation of starred operators, which AFAIK is orthogonal to the skill reset, but still relevant. Do you have an update about the starred operators?

@miccol

A superfluous reset could be dangerous if the halt of a skill is not properly configured (by the user).
For example, if the code in the halt requires access to a resource and the resource is no longer available after the action has terminated (e.g. write on a log file).

That's right. In my opinion that would be a bug in the skill implementation, however.
In any case, if there is agreement on this point we can stick to the first solution; it also has the benefit of not requiring major changes in the BT data type. However I expect very little can be formally proved about this implementation, as basically every detail is left to the inner working of the skills (from a computational point of view the skills_reset function in reactive.v is totally useless, being of unit type).
@StefanoSoffiaUTRC

what you describe in the second point seems to me the discussion we had about the implementation of starred operators, which AFAIK is orthogonal to the skill reset, but still relevant. Do you have an update about the starred operators?

Starred nodes are not my priority at the moment (cf. the wiki page) -- I don't think it is necessary to provide them as primitives since they are trivial to implement via a fallback. We still miss a lot of other stuff though (spec extractor for BTs with arbitrary branching, relation between BTs operational semantics and execution of SMV state machines, integration of contracts, etc.) and the deadline is approaching quickly...

@miccol agreed.
W.r.t. your comment:

very little can be formally proved about this implementation, as basically every detail is left to the inner working of the skills

I'm not sure I can parse it correctly, but AFAIK the new approach does not diminish the amount of information available to the BT, thus to COQ. Specifically, you know which leaves are active  and which are not.

An update on the "reactive interpreter" status: modelling reset functions as terms of type skillSet -> unit turned out to be a bit naive. In fact Coq's extraction routines are quite smart, and will erase terms without computational content like our applications of reset (no amount of fiddling with extraction options has been able to override this).
So I just pushed another implementation in which reset functions are terms of type skillSet -> bool, i.e. they are supposed to return a boolean value which in practise will always be true (although we can cook up a meaning for false, e.g. "the reset has not succeeded and we should return Fail"). This implementation survives program extraction, so I will start working on the extended interpreter (will update this comment later).


Add bbox support for all default providers & update mapquest URL to use HTTPS

This change will add bbox support for all default providers and update the mapquest URL to HTTPS.

Great adding. Thanks.
Could you please update README to show this new property?

I've added it to the README.
The new property was already available, so I hope this is what you meant?


Ability to simply close the list programatically

I've checked the documentation but I didn't find a function that could achieve this.
My use-case is as follows:
I have a list of elements and in the same list I have a "add button". When the user clicks the button it should do the following:

Add the new item to the state
Select that item
Close the items-list

I am probably missing something in the API, but I am struggling with the 3rd part of this process, as the list remains open with the newly created item in display.
I want it the list to close after adding and selecting the new created item.

I have created a simple reproducible example (forked from the loading example) here:
https://codesandbox.io/s/choc-ui-chakra-autocomplete-loading-forked-h46qtl?file=/src/custom-debounce-loading.js
Thank you

Hi @joelclaudio
Would the creatable prop along with the AutoCompleteCreatable component accomplish what you want?  Below is a quick example, but you can style the AutoCompleteCreatable by passing in your own render prop to it along with using the value prop supplied to it.
This isn't an exact repro of what you created, but should get you started.
import React from "react";
import {
  AutoComplete,
  AutoCompleteCreatable,
  AutoCompleteInput,
  AutoCompleteItem,
  AutoCompleteList,
} from "@choc-ui/chakra-autocomplete";
import { Button, Flex } from "@chakra-ui/react";

const options = ["apple", "appoint", "zap", "cap", "japan"];

export default function App() {
  return (
      <AutoComplete rollNavigation creatable>
        <AutoCompleteInput
          variant="filled"
          placeholder="Search basic..."
          autoFocus
        />
        <AutoCompleteList>
          {options.map((option, oid) => (
            <AutoCompleteItem
              key={`option-${oid}`}
              value={option}
              textTransform="capitalize"
            >
              {option}
            </AutoCompleteItem>
          ))}
          <AutoCompleteCreatable>
            {({ value }) => <Button colorScheme='green'>Add {value}</Button> }
          </AutoCompleteCreatable>
        </AutoCompleteList>
      </AutoComplete>
  );
}

The truth is that my setup is a little bit more complex that what I've shown. I was doing API requests on onChange events and have 2 other buttons that both add or change options on the AutoCompleteList.
Previous implementations with the creatable component wasn't compatible with this approach, but after your message I tried and reviewed my approach and now it's working perfectly.
The problem was that I was changing my options on the onChange event of the AutoComplete, so that would always mess everything else.
Thank you very much for the help @Kysluss

No problem @joelclaudio .  I am glad it ended up working for you.  If anything, you can also pass a render prop to AutoCompleteList and one of the methods that you get is onClose.  If you find yourself needing more control, feel free to open another issue.
<AutoComplete>
    {({ isOpen, onOpen, onClose }) => (
...
    )}
</AutoComplete>


How does EasyRepro supports Dynamics 365 Online with ADFS authentication

Hi, we have a D365 Online environment with ADFS authentication, so in this case we need to login twice:
1 First login through the D365 login page (this step is supported by EasyRepro)
2 After signing, there is an additional page for ADFS login, we need to enter the credential again.
In the second ADFS login, the EasyRepro is no longer supported.
Just ask is it possible to use EasyRepro to supports both D365 and our own ADFS page?
Many thanks.

Never mind,
I implemented my own function for ADFS login, attached on LoginDialog.cs
`public BrowserCommandResult LoginADFS(SecureString username, SecureString password)
{
return this.Execute(GetOptions("Login"), this.ADFSLogin, username, password);
}
    private LoginResult ADFSLogin(IWebDriver driver, SecureString username, SecureString password)
    {

        //driver.FindElement(By.XPath(Elements.Xpath[Reference.Login.UserId])).SendKeys(username.ToUnsecureString());
        //driver.FindElement(By.XPath(Elements.Xpath[Reference.Login.UserId])).SendKeys(Keys.Tab);
        //driver.FindElement(By.XPath(Elements.Xpath[Reference.Login.UserId])).SendKeys(Keys.Enter);

        Thread.Sleep(1000);

        //Check if account selection screen is present (AAD vs MSA accounts)
        if (driver.IsVisible(By.Id("aadTile")))
        {
            driver.FindElement(By.Id("aadTile")).Click(true);
        }

        Thread.Sleep(1000);

        driver.FindElement(By.XPath(Elements.Xpath[Reference.Login.LoginPassword])).SendKeys(password.ToUnsecureString());
        driver.FindElement(By.XPath(Elements.Xpath[Reference.Login.LoginPassword])).SendKeys(Keys.Tab);
        driver.FindElement(By.XPath(Elements.Xpath[Reference.Login.LoginPassword])).Submit();

        if (driver.IsVisible(By.XPath(Elements.Xpath[Reference.Login.StaySignedIn])))
        {
            driver.ClickWhenAvailable(By.XPath(Elements.Xpath[Reference.Login.StaySignedIn]));
            driver.FindElement(By.XPath(Elements.Xpath[Reference.Login.StaySignedIn])).Submit();
        }

        driver.WaitUntilVisible(By.XPath(Elements.Xpath[Reference.Login.CrmMainPage])
            , new TimeSpan(0, 0, 60),
            e =>
            {
                e.WaitForPageToLoad();
                e.SwitchTo().Frame(0);
                e.WaitForPageToLoad();
            },
            f => { throw new Exception("Login page failed."); });

        return LoginResult.Success;
    }

`

@harryzang - Thanks for trying out EasyRepro! The method you have utilized should work fine, however you may miss out on future updates in the event the Login method is ever tweaked in the future.
The preferred approach would be to use the overloaded Login method that allows you to pass a CustomLoginAction. This would allow you to customize your actions depending on the layout/design of your ADFS portal.
The sample below shows how you could accomplish this. It looks like the ADFSLogin sample was accidentally cut from the v8.2, v9.0 and v9.0.2 branches - however if you take a look at the v8.1 branch there is an ADFSLogin.cs file in the Sample project that also includes a similar configuration.
The biggest items will be the element names in the event of a non-standard ADFS configuration. If you have any additional questions about this, please re-open this issue and let us know.
Best Regards,
Tyler
[TestMethod]
        public void TestCustomLogin()
        {
            using (var xrmBrowser = new XrmBrowser(TestSettings.Options))
            {
                xrmBrowser.LoginPage.Login(_xrmUri, _username, _password, CustomLoginAction);
            }
        }

        public void CustomLoginAction(LoginRedirectEventArgs args)
        {
            //Login Page details go here.  You will need to find out the id of the password field on the form as well as the submit button.
            //You will also need to add a reference to the Selenium Webdriver to use the base driver.

            //Example
            //--------------------------------------------------------------------------------------
            var d = args.Driver;
            d.FindElement(By.Id("passwordInput")).SendKeys(args.Password.ToUnsecureString());
            d.ClickWhenAvailable(By.Id("submitButton"), new TimeSpan(0, 0, 2));

            //Insert any additional code as required for the SSO scenario

            //Wait for CRM Page to load
            d.WaitUntilVisible(By.XPath(Elements.Xpath[Reference.Login.CrmMainPage])
                , new TimeSpan(0, 0, 60),
            e =>
            {
                e.WaitForPageToLoad();
                e.SwitchTo().Frame(0);
                e.WaitForPageToLoad();
            },
                f => { throw new Exception("Login page failed."); });
            //--------------------------------------------------------------------------------------
        }


Restructure documentation in lib/

Snabb documentation should be conveniently available as a HTML user manual. This is not the case today. This is an acute problem that we need to fix.
This change is one step in that direction: moving documentation for modules in lib/ out of source file comments and into per-module README files. There are now files README.ctable.md, README.checksum.md, and README.pmu.md that contain markdown-formatted API descriptions.
This could alternatively have been done by putting all module documentation into a single lib/README.md or by creating separate subdirectories like lib/ctable/README.md. I resisted because these approaches seem to be motivated by optimizing for Github and I don't think we can afford to be distracted with other mediums until we really have the up-to-date HTML manual always available at users' fingertips.
I am my own upstream on this. I plan to merge onto next today unless somebody talks me out of it. I had previously mentioned my concern that we were introducing too much inconsistency into the lib/ documentation this month and this PR is intended as a correction before release.
cc @eugeneia @wingo @kbara

For what it's worth, LGTM

I'm ok with it as well.

@lukego Any reason for the README. prefix? I think that is odd, otherwise LGTM.

Could remove the README prefix. The idea was mostly to keep the docs separate in directory listing and command-line completion. If somebody else says they want that then I will do it before merge :).


UnicodeDecodeError: 'gbk' codec can't decode byte 0xaf in position

Description
swagger-editer generator server python flask based connexion, when i run app.
Expected bahaviour
Traceback (most recent call last):
File "E:\eclipsephp\plugins\org.python.pydev_<IP_ADDRESS>601292234\pysrc\pydevd.py", line 1524, in
globals = debugger.run(setup['file'], None, None, is_module)
File "E:\eclipsephp\plugins\org.python.pydev_<IP_ADDRESS>601292234\pysrc\pydevd.py", line 931, in run
pydev_imports.execfile(file, globals, locals)  # execute the script
File "E:\eclipsephp\plugins\org.python.pydev_<IP_ADDRESS>601292234\pysrc_pydev_imps_pydev_execfile.py", line 18, in execfile
exec(compile(contents+"\n", file, 'exec'), glob, loc)
File "E:\pworkspace\testrest\examples\python-flask-server\app.py", line 6, in
app.add_api('swagger.yaml', arguments={'title': ''})
File "E:\pythonvenv\flaskvenv\lib\site-packages\connexion\app.py", line 146, in add_api
debug=self.debug)
File "E:\pythonvenv\flaskvenv\lib\site-packages\connexion\api.py", line 89, in init
swagger_template = swagger_yaml.read()
UnicodeDecodeError: 'gbk' codec can't decode byte 0xaf in position 266: illegal multibyte sequence
Actual behaviour
Steps to reproduce
orig:
with swagger_yaml_path.open() as swagger_yaml:
swagger_template = swagger_yaml.read()
change:
with swagger_yaml_path.open(encoding='utf-8') as swagger_yaml:
swagger_template = swagger_yaml.read()
and then is run success.
Additional info:
Output of the commands:

python --version3.5.1
pip show connexion | grep "^Version\:"
connexion-1.0.97
in windows10 64 run

By default, python tries to open files with your system's prefered encoding (as returned by locale.getpreferredencoding()) Hardcoding 'utf-8' breaking connexion for people that want to use other encodings. A solution would be to include an optional encoding argument to add_api


[DOCFIX] Merge Tencent COS & COSN Docs

What changes are proposed in this pull request?
Combined Tecent COS & COSN Docs
Why are the changes needed?
Redundant information can be consolidated via tabs

Does this PR introduce any user facing changes?
Web UI

alluxio-bot, merge this please


Keep getting 'sign in with Apple ID' when I want to check purchases

Version of flutter_inapp_purchase
2.0.3
Platforms you faced the error (IOS or Android or both?)
iOS
Expected behavior
User is logged in on the device. It should return the items the user has purchased. I'm using 'auto renewable subscription'.
Actual behavior
It shows a popup that the user must log in with Apple ID.
Tested environment (Emulator? Real Device?)
Both, also testers via Testflight
Steps to reproduce the behavior
do await _purchaseInstance.getAvailablePurchases();

If I am correct, user should login to apple id if they want to fetch their apis. If you want to check purchases without it, you should check the receipt which you should save somewhere else when user finish the payment.

I'm an Android guy, so this is new to me. On Android, I can use check the purchase status and all is fine.
But what if you get a new phone, you install my app on it, how do I check if you have subscribed to specific things? My app doesn't show ads to these people, so I want to check when starting the app if they have a subscription.
If they are bother with a pop-up, they won't understand why that is.