Unhandled errors do not provide enough information to debug

Describe the bug
We are migrating a large code base from webpack/jest to vite/vitest. Our test suite has about 500 specs, and we are receiving unhandled exceptions in CI only. These unhandled exceptions fail intermittently every 3 - 4 runs. When we ssh into the server and run the same command, they always pass.
The primary issue that we face is that we cannot trace these errors back to an individual test spec.
 Test Files  125 passed | 3 skipped (128)
      Tests  514 passed | 15 skipped (529)
   Start at  21:08:36
   Duration  105.22s (transform 80.64s, setup 488.51s, collect 1846.73s, tests 254.45s, environment 130.44s, prepare 32.53s)

⎯⎯⎯⎯⎯⎯ Unhandled Errors ⎯⎯⎯⎯⎯⎯

Vitest caught 1 unhandled error during the test run.
This might cause false positive tests. Resolve unhandled errors to make sure your tests are not affected.

⎯⎯⎯⎯⎯ Uncaught Exception ⎯⎯⎯⎯⎯
ReferenceError: Blob is not defined
 ❯ Response.Body._initBody ../../node_modules/whatwg-fetch/dist/fetch.umd.js:239:34
 ❯ new Response ../../node_modules/whatwg-fetch/dist/fetch.umd.js:462:10
 ❯ Timeout._onTimeout ../../node_modules/whatwg-fetch/dist/fetch.umd.js:529:19
 ❯ listOnTimeout internal/timers.js:557:17
 ❯ processTimers internal/timers.js:500:7

This error was caught after test environment was torn down. Make sure to cancel any running tasks before test finishes:
- cancel timeouts using clearTimeout and clearInterval
- wait for promises to resolve using the await keyword
⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed.
Exit code: 1
Command: /home/circleci/.nvm/versions/node/v14.19.3/bin/node
Arguments: /opt/yarn-v1.22.18/lib/cli.js test:unit
Directory: /home/circleci/repo/packages/slate
Output:

info Visit https://yarnpkg.com/en/docs/cli/workspace for documentation about this command.

Exited with code exit status 1

Reproduction
I am not able to provide a reproduction due to private software which is quite large.
System Info
System:
    OS: Linux 5.15 Ubuntu 20.04.4 LTS (Focal Fossa)
    CPU: (36) x64 Intel(R) Xeon(R) Platinum 8124M CPU @ 3.00GHz
    Memory: 1.81 GB / 68.58 GB
    Container: Yes
    Shell: 5.0.17 - /bin/bash
  Binaries:
    Node: 14.19.3 - ~/.nvm/versions/node/v14.19.3/bin/node
    Yarn: 1.22.18 - /usr/local/bin/yarn
    npm: 6.14.17 - ~/.nvm/versions/node/v14.19.3/bin/npm
  npmPackages:
    @vitest/coverage-c8: ^0.29.8 => 0.29.8
    vitest: ^0.30.1 => 0.30.1

Used Package Manager
yarn
Validations

[X] Follow our Code of Conduct
[X] Read the Contributing Guidelines.
[X] Read the docs.
[X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
[X] Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord Chat Server.
[X] The provided reproduction is a minimal reproducible example of the bug.

Side note for anyone else who experiences this issue, we are able to get our CI pipeline to pass by using this option in our vitest config:
  test: {
    dangerouslyIgnoreUnhandledErrors: true,
  },

We do not look at this as a long-term solution, but without being able to debug these unhandled exceptions we are using it for now.

It would be great to add more information to these errors for sure. Without being able to reproduce this issue it's not possible though. We'll need to be able to reproduce the issue to see if it's possible to capture more information.

had this while trying to migrate a legacy react codebase to vite. I extended this to debug  and exited as soon as the process finds an unhadled exception like this (in a setup file). Since process, vitest exited as soon as it happened I successfully tracked the problem by checking the last test before exit.
process.on("unhandledRejection", (reason) => {
  process.exit(1);
});

I can't code the share to reproduce, but here how it is basically happened.
in a util function, I have an async API call, which is a wrapper. wrapper rejects, but the util function does not catch this error. I call this util function inside a useEffect hook, as
useEffect(() => {
    const getXCards = async () => {
      const cards = await getCards(state);
    getXCards();
  }, [state]);

this is from a nested component where the parent of its parent is running in a snapshot test with react-test-renderer.
Hope it can help to track this issue.


Remove JSR 305 and missing nullability annotations added

Adds missing nullability annotations and replaces JSR 305 with Spotbugs.

[x] Make sure you are opening from a topic/feature/bugfix branch (right side) and not your main branch!
[x] Ensure that the pull request title represents the desired changelog entry
[x] Please describe what you did
[x] Link to relevant issues in GitHub or Jira
[x] Link to relevant pull requests, esp. upstream and downstream changes
[x] Ensure you have provided tests - that demonstrates feature works or fixes the issue

Partly subsumed by #230?

Indeed, PR updated.


Used 4 space hanging indent for dictionaries.

I would like to do a more comprehensive audit. Does anyone know of linters that detect this?

Does anyone know of linters that detect this?

Am not sure, but was looking at the footnotes under http://pycodestyle.pycqa.org/en/latest/intro.html#error-codes and it looks like this can at least be partially detected, but is opt-in.
It looks like you can explicitly enable E123, E121 and E126. (I haven't tried this out though.)
While we're at it, it looks like using the --max-doc-length=n switch to report W505 could be handy for Django too.

Also found http://flake8.pycqa.org/en/latest/user/options.html#cmdoption-flake8-hang-closing if that helps?

I didn't have any luck with the flake8/pycodestyle options but Mariusz suggested a grep expression which worked well enough. I added it to the PR description.


[Windows] There is no SOUND asset with an ID of...

Describe your problem here.
After compiling the game and attempting to load the custom week, I get hit with the error message below.

The Voices.ogg file is present in the correct directory. I am at a lost on what to do.
This is what the console outputs.
Link: ApplicationMain-debug.exe
source/Discord.hx:17: Discord Client starting...
source/Discord.hx:67: Discord Client initialized
source/Discord.hx:24: Discord Client started.
source/LoadingState.hx:162: Setting asset folder to shared
source/Conductor.hx:75: new BPM map BUDDY []
Called from hxcpp::__hxcpp_main
Called from ApplicationMain::main ApplicationMain.hx line 25
Called from ApplicationMain::create ApplicationMain.hx line 130
Called from lime.app.Application::exec lime/app/Application.hx line 150
Called from lime._internal.backend.native.NativeApplication::exec lime/_internal/backend/native/NativeApplication.hx line 146
Called from lime._internal.backend.native.NativeApplication::handleRenderEvent lime/_internal/backend/native/NativeApplication.hx line 370
Called from lime.app._Event_lime_graphics_RenderContext_Void::dispatch lime/_internal/macros/EventMacro.hx line 91
Called from openfl.display.Stage::__onLimeRender openfl/display/Stage.hx line 1950
Called from openfl.display.Stage::__broadcastEvent openfl/display/Stage.hx line 1166
Called from openfl.display.DisplayObject::__dispatch openfl/display/DisplayObject.hx line 1399
Called from openfl.events.EventDispatcher::__dispatchEvent openfl/events/EventDispatcher.hx line 402
Called from flixel.FlxGame::onEnterFrame flixel/FlxGame.hx line 545
Called from flixel.FlxGame::step flixel/FlxGame.hx line 677
Called from flixel.FlxGame::update flixel/FlxGame.hx line 724
Called from flixel.FlxGame::switchState flixel/FlxGame.hx line 637
Called from PlayState::create PlayState.hx line 669
Called from PlayState::generateSong PlayState.hx line 1620
Called from Paths::returnSound Paths.hx line 391
Called from openfl.utils.Assets::getSound openfl/utils/Assets.hx line 266
Called from lime.utils.Assets::getAudioBuffer lime/utils/Assets.hx line 158
Called from lime.utils.Assets::getAsset lime/utils/Assets.hx line 138
Called from lime.utils.Log::error lime/utils/Log.hx line 34

Are you modding a build from source or with Lua?
Source
What is your build target?
Windows x64
Did you edit anything in this build? If so, mention or summarize your changes.
Yes, drastically modified PlayState.hx, to add a scene for a custom week, and removed all weeks from assets then added a custom one. Project.xml was modified to use a new name for the application and to disable mods and awards.

update haxe to 4.2.4

I think it's an issue with disabling mods
I'm currently trying to figure out how to make it work properly while mods are disabled

I think it's an issue with disabling mods I'm currently trying to figure out how to make it work properly while mods are disabled

I figured it out
you wanna go to around line 375 in paths.hx and either comment out or delete the #if MODS_ALLOWED the #else what's under the else and the #end
should look something like this

honestly don't know why they have a mods allowed check there if it works just fine without mods allowed


Flag for EQC/QA information

Added a boolean flag on the database corresponding to the presence of the "quality_assurance_tab" inside the layout.json (see https://jira.ecmwf.int/browse/COPDS-1383)

 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.


TypeError: Cannot read property 'Symbol(get)' of undefined

The error is thrown when location prop is undefined.
const {name, type} = this.props.location;

Is this behavior intentional?

Yes, it is. You can not destructure undefined.


unify drc check semantic

There are currently 2 differents way used to test DRC assertions in the recent PRs:

DRC check functions like .width  that evaluate a condition and returns a list of violating shape: the condition is expressed as the passing condition before .output is called on the resulting shapes.
DRC selector functions like .with_length that evaluate a condition and returns a list of matching shapes: the condition is inverted to express the failing condition before .output is called on the resulting shapes.

We should make sure we use matching semantic to ease readability and maintainance by either:

(a) using inverse function like .without_length so that the we always express passing condition.
(b) using the universal drc method that always encode passing condition using an expression syntax.

I think I'd personally favor (b) but maybe @klayoutmatthias or @mithro have strong opinions on this?

@proppy drc command is very very slow and it's not recommended for performance concerns.

@atorkmabrains interesting, the documentation here https://www.klayout.de/doc/about/drc_ref_layer.html#drc mention

improved performance in some applications

does that mean that our drc deck has applications are not covered by those improvement?
/fyi @klayoutmatthias

@proppy That was the recommendations from @klayoutmatthias to avoid the use of drc command.

The drc function is not slow in general, but in this particular case it lacks an optimization (forced merging of inputs), which makes it slower. This is addressed by https://github.com/KLayout/klayout/issues/1195, but I did not have time yet to look into that problem. As of now, it is better to use the plain DRC functions ("space", "width", ...) when possible.
Matthias

@klayoutmatthias Thanks for chipping in!
@atorkmabrains I'd be in favor of keeping this open until there is progress and https://github.com/KLayout/klayout/issues/1195 and then consider switching to drc.

BTW @proppy, @klayoutmatthias reviewed this rule deck and he was the one who suggested the removal of drc command.
Thanks @klayoutmatthias on your help back then. It would be nice to get your feedback again this time. BTW, we have integrated everything in efabless version.

@atorkmabrains Of course - you mean you want feedback on the current version?

@klayoutmatthias Here is the link:
https://github.com/efabless/globalfoundries-pdk-libs-gf180mcu_fd_pv

@klayoutmatthias BTW, this time we have our DRC regression as CI. This way we could detect if the changes might have impact on the correctness of output.


feat(pmp-web): add repository ui implementation

Additionally, when you will amend your commit please refer to the issue which should be closed of add just refs to the commit message. Thanks :)


Unpredictable behavior when unmarshaling incorrect integer

This is a little strange situation albeit one that was encountered in our application.
It seems that if you try to unmarshal a floating point number into *int the behavior will be unpredictable depending on your JSON structure. In the native implementation if works fine.
Take for example this program
package main

import (
    "encoding/json"
    "fmt"
    jsoniter "github.com/json-iterator/go"
)

type DataStruct struct {
    Foo *string `json:"foo"`
    Bar *int    `json:"bar"`
}

func main() {
    data := `{"foo":"this is string", "bar":123.123}`
    unmarshaled := DataStruct{}
    json.Unmarshal([]byte(data), &unmarshaled)
    fmt.Printf("Build-in: foo = %s, bar = %d\n", *unmarshaled.Foo, *unmarshaled.Bar)

    unmarshaled2 := DataStruct{}
    var JsonPaser = jsoniter.ConfigCompatibleWithStandardLibrary
    JsonPaser.Unmarshal([]byte(data), &unmarshaled2)
    fmt.Printf("JSON Iter: foo = %s, bar = %d\n", *unmarshaled2.Foo, *unmarshaled2.Bar)
}

As it is now it will print:
Build-in: foo = this is string, bar = 0
JSON Iter: foo = this is string, bar = 123

But if you change the order of the data to:
data := `{"bar":123.123, "foo":"this is string"}
It will not be able to read "Foo" anymore
Build-in: foo = this is string, bar = 0
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x0 addr=0x0 pc=0x58ab68]

IMO, you should check the return value when you call Unmarshal and if the err it returns is not nil, you should handle the error and not read the variable you pass to Unmarshal function.

Ok fair enough.


M6 Repeatedly fails at getting trusted balance for alice

Sometimes we fail to send the trusted getter updates to the client due to:
calling into STF to get state
Account free balance is<PHONE_NUMBER>0
sending state
Could not send state to client FailedToSendUpdateToRpcClient("InvalidConnectionHash")
removing [0xa7452d3ae0dc9e3cad3b8ba1b78f551345e4ecb2cf8aca78fbb6439af8676726] from top pool
Removing invalid operations: [0xa7452d3ae0dc9e3cad3b8ba1b78f551345e4ecb2cf8aca78fbb6439af8676726]
Removed invalid operations: [TrustedOperation { hash: 0xa7452d3ae0dc9e3cad3b8ba1b78f551345e4ecb2cf8aca78fbb6439af8676726,
priority: 1048576, valid_till: 64, bytes: 100, propagate: true, source: External, requires: [], provides: [014054c593292c0651abe56b04c8d9030e053938e627c7582e2f240638ce11d61679c1a673154dfaec9299174f62d1098349c9541d2c6b2d65f3ff4625bd576e88],
data: get(trusted(TrustedGetterSigned { getter: free_balance(), signature: <wasm:stripped> }))}]

It with the introduction of #427 it also hanged twice in a row after a trusted call unshield.

seems solved


On YOG7DAS2K1, various settings are no longer visible when this superuser (ver. for YOG4PAS3JL) is installed

Examples that I've found so far:
-On-screen navigation bar is gone
-"Double tap to wake" option is gone
It's a really strange problem, because why does installing some superuser disable these options? Even if it's for version YOG4PAS3JL.

I just rebuilt the image with the freshly published debuggable boot image for YOG7DAS2K1:
http://jak-linux.org/cm/cm-unofficial-12.1-YOG7DAS2K1-bacon-signed-superuser.zip
Could you check if the bug still exists? I can't test right now.

Yup, that totally fixed it. Thanks!
Would still be interesting to know why this even happens. I previously tested just deleting /system/xbin/su from my system and rebooting, but that did not bring the options back. Just applying that update did. Any idea what might have been happening there?

It's probably not root related: It's flashing the debuggable boot image from Cyanogen, and that seems to have caused the issues.


Remove the use of the union-find structure during elaboration

Remove the UnionFind argument to Elaborator::new, and from the Elaborator structure, relying instead on the value_to_best_value table when computing canonical values. Running sightglass on the spideromonkey benchmark showed no difference in performance between main and this branch (compile time or run time).
Additionally, we compared the assembly produced with and without this change, and found the difference in generated code to be mostly negligible (lea instead of add, or a move between registers added or removed). The difference in the length of the disassembled output was only +15 lines, which out of 2212651 is pretty good.

The goal that we had in removing the use of the union find structure was to enforce the assumption that it was valid to refer to an inner node of the union tree as a subset of an eclass. Using the union find results from the rewriting pass over the whole function during elaboration may end up merging results from different branches in the dominator tree into the same eclass, which would mean that we might canonicalize to a node higher in the union tree than we originally intended. If that situation occurred, we would be at the mercy of the cost function for correctness. I think that with the changes you proposed to how we manage access to the gvn map as well, we'll be able to relax the new guideline we introduced for using subsume when the RHS forgets values from the LHS in egraph rules.
As to where we would add a comment, I'm not sure the best place to document this. Do we already document our use of sub-trees of the union tree to name subsets of the eclass? I think that's a super elegant implementation detail that's worth documenting, and we could call out careful management of eclasses in the same place.


SCB-973 update to remvoing the incubator

I just use the command to search in the plain text files.
find . -type f -exec grep -H 'incubator' '{}' \;

There are still two in the pom.xml and .travis.xml.setting which I'm not sure needing the changes. So maybe you can take a look.

Coverage remained the same at 91.869% when pulling a714c1b9b79ef92ea9082f17e9cdf99b0cdd4aaa on zhfeng:SCB_973 into 4e3539337fbcd3bf2b1bda653f425d670cb10669 on apache:master.


Chroniques Oubliees Contemporain : version 2.7

Changes / Comments
Added more buffs in sheet, plus changed names of roll buttons always start with roll_

@clevett
Sorry about that! I have absolutely no clue how this happened...
I don't have quite a clear idea how to remove those deletions from the pull request, but I'll work on it.

It seems simplest to me to close this request and open a new one.


eframe web: Only forward keyboard events if canvas has focus

Fixes https://github.com/rerun-io/rerun/issues/6638
Related? https://github.com/emilk/egui/issues/4563

This improves how an eframe canvas works inside of a larger web page, and how it works when there are multiple eframe apps in the same page.
eframe will set tabindex="0" on the canvas automatically, making it focusable.
Breaking changes
Add this to your CSS to prevent outline around the canvas:
canvas:focus {
    outline: none;
}

Optionally give it focus on start with
document.getElementById("the_canvas_id").focus();

Test setup
./scripts/build_demo_web.sh
./scripts/start_server.sh
open http://localhost:8888/multiple_apps.html

Then open the "Input Event History" and "Text Edit" windows
Tested

Chromium

[x] drag-and-drop of files
Test both when a TextEdit is focused and when it is not:

[x] Event::Key
[x] Event::Text
[x] copy-cut-paste
[x] Wheel scroll

[x] Event::PointerGone
[x] Mouse drag
[x] Mouse click
[ ] Mouse right-click
[x] Defocus all eframe canvas, and then start typing text

[x] Firefox (all of the above)
[x] Desktop Safari (all of the above)
[x] Mobile Safari

Future work (pre-existing issues)

https://github.com/emilk/egui/issues/4723
https://github.com/emilk/egui/issues/4724
https://github.com/emilk/egui/issues/4725
https://github.com/emilk/egui/issues/4726

This solves half of https://github.com/rerun-io/rerun/issues/6638
In a notebook context, Rerun no longer gets events when typing in notebook cells. However, it now fails to respect usage of any keyboard shortcuts at all.
Selecting a text-entry box works, but as soon as you leave a text-entry context it appears all events only get processed by the outer notebook environment.

Right click does not work in a notebook context (both classic and lab). For example, right click on a view in the blueprint panel should bring up its context menu, but instead it always opens the notebook's context menu

@jprochazk please see if the latest commit (616fa2b) fixes it

I can confirm it's fixed with that commit.


Data Store

Motivation and Context
Loading data from the API and storing it was very entangled with the controllers for the UI. This makes it harder if different components need to load the same data resulting in loading sections multiple times. This could also cause inconsistencies.
Description
A global store that stores the most update to date data, and can be subscribed to by different components, would solve the issues. This keeps the current data state consistent across all components that are using it.
Steps for Testing
Prerequisites:

1 Admin
1 Livestream

Log in
Navigate to a Course Admin panel
Check if section editing works as expected
Go to a live stream that has sections
See if sections are displayed correctly
Add / Edit / Remove Bookmarks and chek if UI responds correctly

Screenshots

@MatthiasReumann @joschahenningsen Please tell me wether you like the approach or not, its more or less just a proposal to make the data more accessible in the frontend ✌

Added the possibility of a cache layer behind the providers, currently disabled, probably super unnecessary, could remove it again to reduce complexity

@MatthiasReumann As you already know I ran into trouble with AlpineJS calling init()-Function twice. I fixed it now with some singleton like behaviour... :S
Further, I found an issue with Course Admin Page. You cannot edit or delete Chapters, but I have the same behavior indev-Branch. Should be fixed in a follow up i guess :)


The correct format with a SD-JWT VC that has no disclosures but has a holder binding JWT

received a question. What is the correct format with a SD-JWT VC that has no disclosures but has a holder binding JWT. Is it
<SD-JWT VC>~~<HB JWT> (double tilde), or <SD-JWT VC>~<HB JWT> (single tilde)
I think it is <SD-JWT VC>~<HB JWT> (single tilde) but the spec could probably clarify.

The case for ~~ would be that according to SD-JWT section 5  "the serialized format for the SD-JWT is the concatenation of each part delineated with a single tilde ('~') character". And zero disclosures is allowed in the disclosures part.
Double tilde is also consistent with the requirement to have a ~ even with the KB-JWT being an empty string. Thanks for raising the question! Would be great to confirm whether or not it is double or single.

The intention is certainly just one ~. I think the spec is relatively clear:

An SD-JWT is composed of the following:

an Issuer-signed JWT,
zero or more Disclosures, and
optionally a Key Binding JWT.

The individual parts will be explained in the following subsections.
The serialized format for the SD-JWT is the concatenation of each part delineated with a single tilde ('~') character as follows:

So a single ~ between each part.

Just one ~, while being the intention, is at odds with a single ~ between each part that the specification requires, no? There are three parts. I add one ~ between the Issuer-Signed JWT and the disclosures set, and then I add another ~ between the disclosures set and the KB-JWT.

The intention is definitely just one ~. I also think sec 5 in the spec is relatively clear about it. But perhaps some additional or slightly different text would be more clear?

Just one ~, while being the intention, is at odds with a single ~ between each part that the specification requires, no?

The intent is that each individual Disclosure is a part with each one is preceded by a tilde. No tildes in that area when there are no Disclosures.
Admittedly, as I try to comment here, I can start to see where different readings of that section come from. So there is likely an opportunity to improve that text. I'm not sure how though...

The following are the various permutations as intended by the current spec (as best I understand).
SD-JWT without disclosures and without KB JWT:
<Issuer-signed JWT>~
SD-JWT without disclosures and with KB JWT:
<Issuer-signed JWT>~<KB-JWT>
SD-JWT with disclosures and without KB JWT:
<Issuer-signed JWT>~<Disclosure 1>~<Disclosure N>~
SD-JWT with disclosures and with KB JWT:
<Issuer-signed JWT>~<Disclosure 1>~<Disclosure N>~<KB-JWT>

The bit of text starting with "i.e.," here in sec 5.3.1. maybe describes it more succinctly and accurately:

the Issuer-signed JWT, a tilde character, and zero or more Disclosures [...], each followed by a tilde character.

FWIW, the following are the various permutations as intended by the current spec (as best I understand anyway).
SD-JWT without disclosures and without KB JWT:
<Issuer-signed JWT>~
SD-JWT without disclosures and with KB JWT:
<Issuer-signed JWT>~<KB-JWT>
SD-JWT with disclosures and without KB JWT:
<Issuer-signed JWT>~<Disclosure 1>~<Disclosure N>~
SD-JWT with disclosures and with KB JWT:
<Issuer-signed JWT>~<Disclosure 1>~<Disclosure N>~<KB-JWT>

It could be valuable to list these four basic categories in the specification

It could be valuable to list these four basic categories in the specification

Agreed. Thanks for the clarification too!

This https://github.com/oauth-wg/oauth-selective-disclosure-jwt/pull/388 PR on the base SD-JWT spec lists those four basic categories and tries to make the language more clear.

PR on the base SD-JWT spec was merged.


Feedstock rerender master

Fixes https://github.com/conda-forge/eigen-feedstock/issues/3.
Replaces this PR ( https://github.com/conda-forge/eigen-feedstock/pull/2 ). Keeps the 64-bit VS 2008 workaround.

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

No need to wait for CI here. This is merely updating the AppVeyor environment, which is not exercised in these tests.


[1.16.5]Barrels have no texture

Whit the last update (lootr-1.16.5-<IP_ADDRESS>.jar) the barrels have missing textures. Whit lootr-1.16.5-<IP_ADDRESS>.jar all works fine

Could you upload your latest.log to gist for me? It looks like a model isn't loading for some reason, but there's no change between them that I'm aware of.

Didnt saw any other blocks whit missing textures from other mods it only happends whit barrels. Chest and shulkers works fine
latest (2).zip

[12:58:00] [main/INFO]: Reloading ResourceManager: Blur dummy resource pack, Default, Mod Resources, Better-Leaves-6.0-1.13+§6.zip, Elemental's+Custom+Armor.zip, EmbellishedStone.zip, Infernal Resources.zip, LootrChestRetexture_v1.zip, ...
``

I'm guessing it's this LootrChestRetexture that's responsible. Can you try it without that?

I'm unable to replicate in 1.16.5-<IP_ADDRESS>: ![](https://i.imgur.com/dlZKW60.png)

**Please note that if you're wanting to use Vanilla textures, there is now a client-side option configuration for that.**

yeah, I tried without the texture and works fine. Sorry for wasting your time 😥


Return FEE_INSUFFICIENT before checking balance for incoming low-fee HTLCs

Change Description
Incoming HTLCs with lower-than-advertised fees are rejected before checking if the channel balance is sufficient to route the payment. This helps to prevent channel probing.
Fixes #5721.
Steps to Test
Undoing the changes in link.go (basically moving the call to canSendHtlc above if incomingHtlcAmt < amtToForward || actualFee < expectedFee ...) should cause the new test in link_test.go to fail.

I updated the release notes to 0.16.0!
Hmmm that's strange, I feel like that test could be related to this change. I'll dig into that a bit and see what I can find.

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

Circling back to this...  I did rebase recently, so maybe that fixed it if it was an unrelated failure.

could you show me how/where it's failing?

It was failing in the last build when I reviewed (I think CI / run unit tests (btcd unit-cover), but don't remember). Everything green now, so it's probably an unrelated flake.

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

!lightninglabs-deploy mute 2022-Nov-01

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

!lightninglabs-deploy mute 2023-Mar-01

@tvolk131, remember to re-request review from reviewers when ready

@tvolk131, remember to re-request review from reviewers when ready

Replaced by #7490


Document row-no-border class

I needed a summary list without a bottom border - the design system has a useful class for this, but it's not mentioned.
My use case is a summary list appearing inside of another block - in this case the bottom border is redundant.

You can preview this change here:
Built without sensitive environment variables with commit a3b7ea17cb697b6f2cdbf4b6754ffc654bf93593
https://deploy-preview-1325--govuk-design-system-preview.netlify.app

Thanks for raising this @edwardhorsford . It looks sensible to me, but I'm just tagging @m-green to see if he has any opinions on the change.


Register Locale async

Expected behavior
Would like to register a locale for use by the datepicker on the fly. I can lazy load the file but registering it but it doesn't seem to work.
Actual behavior
Error with date-fns
Steps to reproduce
Load the language file in the componentDidMount. Register the language. Set the language in the date picker to the loaded language.

bump

bump

closing due to lack of activity :/


Show baselines

This is the bare minimum. You might want to add a new button to switch this on or off. Perhaps Aletheia already has an icon for that?
Also, I had to import org.primaresearch.dla.page.layout.physical.text.impl.TextLine, because there is no interface which gives get_Baseline().

Fixes #17

Note: 9cfcd81 fixes mouse scroll wheel behaviour. I never got ctrl+scroll zooming to work before (and was surprised to find an implementation). It seems that only the Canvas is in charge of events (not parent i.e. Shell). Also, when I did move the event receiver from parent to imageCanvas, I noticed that shift+scroll now did both horizontal and vertical scrolling, hence the extra checking. Plus MOD1 seems less reliable to me than CTRL|COMMAND.
I'll promptly rewrite (and rebase) that part of the PR if you find anything objectionable here.

Strangely, when I export the app as runnable JAR, I get a different behaviour for mouse wheel scrolling than running directly from Eclipse! When running from Eclipse, ctrl+scroll correctly zooms in or out, depending on the direction. But when running from the runnable JAR, MouseEvent e.count is always positive, so it always zooms in (regardless of direction). That's despite the fact that count sign does yield the correct direction for horizontal or vertical scrolling. (And yes, I have configured the Project JRE in Eclipse's Run/debug settings, and the Build path > Libraries uses the same java-11-openjdk as my command line invocation.) :confused:

Another strange thing is that in the new version, #15 re-appears. My unerstanding was that this was fixed by https://github.com/PRImA-Research-Lab/prima-page-viewer/commit/ad75ac2dc1b81701f529291bcebdd901d716a455 and https://github.com/PRImA-Research-Lab/prima-core-libs/commit/28db6c09bd7d50dcadebc31a1c67c7c047adf41b.
Since I have not changed the build settings, PrimaDla is included as a project, and I can see those commits are there.
So perhaps @chris1010010 you used some additional changes for the 1.4.06 binary release that you have not published yet?

Another strange thing is that in the new version, #15 re-appears. My unerstanding was that this was fixed by https://github.com/PRImA-Research-Lab/prima-page-viewer/commit/ad75ac2dc1b81701f529291bcebdd901d716a455 and https://github.com/PRImA-Research-Lab/prima-core-libs/commit/28db6c09bd7d50dcadebc31a1c67c7c047adf41b.
Since I have not changed the build settings, PrimaDla is included as a project, and I can see those commits are there.
So perhaps @chris1010010 you used some additional changes for the 1.4.06 binary release that you have not published yet?

Plus the prebuilt version can deal with TIFF images, whereas the configured build cannot.

Plus the prebuilt version can deal with TIFF images, whereas the configured build cannot.

I have merge in the baseline code

I have merge in the baseline code

I have merge in the baseline code

Splendid. So how about that part:

Note: 9cfcd81 fixes mouse scroll wheel behaviour. I never got ctrl+scroll zooming to work before (and was surprised to find an implementation). It seems that only the Canvas is in charge of events (not parent i.e. Shell). Also, when I did move the event receiver from parent to imageCanvas, I noticed that shift+scroll now did both horizontal and vertical scrolling, hence the extra checking. Plus MOD1 seems less ~reliable~ portable to me than CTRL|COMMAND.

I have merge in the baseline code

Splendid. So how about that part:

Note: 9cfcd81 fixes mouse scroll wheel behaviour. I never got ctrl+scroll zooming to work before (and was surprised to find an implementation). It seems that only the Canvas is in charge of events (not parent i.e. Shell). Also, when I did move the event receiver from parent to imageCanvas, I noticed that shift+scroll now did both horizontal and vertical scrolling, hence the extra checking. Plus MOD1 seems less ~reliable~ portable to me than CTRL|COMMAND.

Plus the prebuilt version can deal with TIFF images, whereas the configured build cannot.

(happens for me e.g. for 16-bit TIFF or grayscale TIFF)
org.eclipse.swt.SWTException: Unsupported color depth

Do you import some additional library for your GH release builds?

Plus the prebuilt version can deal with TIFF images, whereas the configured build cannot.

(happens for me e.g. for 16-bit TIFF or grayscale TIFF)
org.eclipse.swt.SWTException: Unsupported color depth

Do you import some additional library for your GH release builds?

No, it's all the same SWT as far as I'm aware.
Regarding the mouse scroll, I wanted to test in different OS

No, it's all the same SWT as far as I'm aware.
Regarding the mouse scroll, I wanted to test in different OS

No, it's all the same SWT as far as I'm aware.

I see. Then perhaps this is a change between OpenJDK 8 and 11? Or do you use a different JDK8 for your prebuilds?

Regarding the mouse scroll, I wanted to test in different OS

Understood. Did mouse wheel based horizontal/vertical scrolling and zooming work for you so far on any platform? (I've only ever tested Linux 64 bit with OpenJDK 8, and there neither horizontal scrolling nor zooming worked.)
But mind that extra trip of runnable JAR vs running in Eclipse...

No, it's all the same SWT as far as I'm aware.

I see. Then perhaps this is a change between OpenJDK 8 and 11? Or do you use a different JDK8 for your prebuilds?

Regarding the mouse scroll, I wanted to test in different OS

Understood. Did mouse wheel based horizontal/vertical scrolling and zooming work for you so far on any platform? (I've only ever tested Linux 64 bit with OpenJDK 8, and there neither horizontal scrolling nor zooming worked.)
But mind that extra trip of runnable JAR vs running in Eclipse...


Commands dropped / bridge overloaded (Err=429) / Connexion issues

Context : HUEMagic becomes more often unusable
Based on what I read, it seems HUE has became more and more strict in what it accepts in terms of external API call rates.
Where the bridge easily accepted many calls per second before, it now rejects them more frequently.
Official HUE dev documentation now mentions a maximum of 4 calls per second (but even more strict for calls to groups which are limited to 1 call / second...)
HUEMagic already handled a retry but :

it only managed it for error code '503'... but now the bridge responds -most of the time- with '429' in case of overload
retry was performed 3 times (after 2s, then 4s, then 8s)
These caused many issues with commands being delayed to completely lost (not executed).
The bridge connection was also often 'reset', with an error on console Error requesting info from the bridge. Reconnect in some secs. undefined. This was caused when HUEMagic polled the bridge to ensure connection was still OK at a moment when the bridge was overloaded (err=429)

Because of this, most of us were not able to enjoy HUEMagic nodes :-(
What did I change ?

Error '429' is now correctly taken into account (as was 503 before)
All calls will be retried up to 5 times
Retry delay will extended by 750ms each time (i.e. 0,75s, 1,5s, ... 3,75)
HUEMagic will no longer reset connection when it responds as being overloaded
(In case of connection error, the full returned content (page) is send to console for easier debug)
I have now been running this config for a few weeks and I do not have any connection / drops anymore.

Additional info : merge of other
This pull request also merged #390 from @traverseda and #381 from @Travelbacon, which corrected -very successfully- bugs #375, #374, #377 and #378.
Since then other group issues were reported which should also be solved since I think these are actually the same...
(such as #400)
What you need to do / change ?
I strongly recommend to configure your HUEMagic bridge node using a single 'worker'. Setting more than 1 will always -logically- worsen the overload effect on the bridge.
If you want to use it from now (not waiting for Foddy to merge & publish it), this is possible by installing it manually using command npm install git+https://github.com/fredblo/node-red-contrib-huemagic.git

Thank you so much for doing this!

Thank you for your work! I tested it and it works like charme! @Foddy can you please merge this PR soon?

@Foddy this is really necessary ,please can you consider giving @FredBlo merging rights since he contributes a lot lately. It would help everybody


Proposal: Generate package.json support

Add the "generate package.json" to the builder
This is the same code that exists in a couple other @nx packages. I think I took it from @nx/esbuild.
After the Astro project successfully builds, if flagged, it will build a package.json in the dist folder.
This is very useful for use with Docker or deploying Astro to something like Google Cloud Functions.
Testing needed
I did not have time to add tests. And there might be some better choices to be made. This would also add the peer dep @nx/js to the tree, so that would be something to make sure was installed.

hey @Brian-McBride! Thanks for the contribution!
The changes in this PR are doing several things and it will be better to split them:

Migrating Nx to latest (chore)
Updating the default TS settings (fix)
Adding support for generating a package.json when building (feat)

Can you remove from this PR the changes related to updating Nx and the default TS config? I'll handle the migration of Nx myself. Would you like to create a separate PR for the default TS config changes?
Also, note this repo uses Yarn. This is explained in the Contributing guidelines. It seems you're using NPM instead an in this PR you removed the yarn.lock and added a package-lock.json. Removing the Nx upgrade changes will remove those changes from the PR.

@Brian-McBride I already updated the generated tsconfig so it's in sync with Astro defaults. No need to worry about that.
I gave some more thought to generating the package.json in the executor and I think we shouldn't do it just yet. Nx recently introduced the @nx/dependency-checks ESLint rule and started to remove the automatic generation of package.json from some of its executors in favor of it. Let's hold this to avoid introducing a feature that might become obsolete soon.
I'm going to close this PR for now, but we can follow the conversation in an issue requesting this feature.


Logo

My friend have done logo for bloxparty but for some reason he doesn't want to expose himself. If you have
any suggestions or thoughts about current logo, feel free to comment in this PR and I'll give it to author.
Things to do before merge:

[x] Windows logo
[x] OSX logo
[x] Linux logo

Fixes #20

Awesome!  The layout looks good to me, but maybe we could get it in a darker color?
I've been using Ultimate Tetris as inspiration for the design: https://www.google.com/search?q=ultimate+tetris&espv=2&biw=1141&bih=637&source=lnms&tbm=isch&sa=X&ved=0CAYQ_AUoAWoVChMIt_vWwcv0yAIVTtpjCh11NAwb#tbm=isch&q=tetris+ultimate
If your friend wants to pick a color out of there to fit the darker theme then I can go back and incorporate the logo colors into the design of the game the next time I iterate over it.  The red I don't think I can work into the layout.

What do you think about this one?

Looks great!

Wow, you are fast, I'm don't even committed new logo yet.

Oops!  I wasn't paying attention :)


My graph doesn't appear

I cannot view my own graph, even when logged out on the Keybase website.
Here's my profile: https://keybase.io/imcpwn/graph
Here's the error in the JS console that I only get on my profile:
  at KeyGraph.window.KeyGraph.KeyGraph.to_vis (sitewide-js.js:95)
    at KeyGraph.window.KeyGraph.KeyGraph.draw_in_el (sitewide-js.js:95)
    at autofill (sitewide-js.js:95)
    at HTMLDocument.<anonymous> (sitewide-js.js:95)
    at fire (sitewide-js.js:15)
    at Object.fireWith [as resolveWith] (sitewide-js.js:15)
    at Function.ready (sitewide-js.js:15)
    at HTMLDocument.completed (sitewide-js.js:15)

Ah thanks for the report. Cc: @malgorithms

ok, I believe it's fixed! @IMcPwn


[BUG] Members cache does not function as intended

Describe the bug.
interactions currently has a (somewhat internal) cache for various items like users, roles, channels, etc. It also has one for members, too.
This is obviously a nice feature for developers; however, it does not function correctly. It assumes that a member's ID alone can be used as the key for a member. However, a member with the same ID from one guild is not the same as a member with the same ID from another guild.
(To simplify that: if you're in two guilds, in the API, despite having the same user ID everywhere, the "you" in each guild is different with differing nicknames, roles, etc., right? The cache forgot about that.)
List the steps.

Fetch a member with a set ID from a guild, guild X.
Use the cache to get a member with the same ID as the above from another guild, guild Y.

What you expected.
In this case, nothing should be returned as we never fetched the member from guild Y.
What you saw.
The member object for guild X.
What version of the library did you use?
release
Version specification
4.1.0, though this hasn't been fixed in unstable either.
Code of Conduct

[X] I agree to follow the contribution requirements.

An issue we've acknowledged about this is similar to our interactions storage in the cache where numerous items cannot be shared under the same ID key. It's an unfortunate edge case that is planned to be addressed alongside implementing TTL, however, it's been low prior'd.
Nonetheless we'll be flagging this and acknowledging as a bug.

See #909 for information. Closing as this affects the prior functionality.


Is it possible to show more than one value at the same time?

Is it possible to show more than one value at the same time?
To let you understand what I'm thinking, you can see the following image:

(image from http://www.datarevelations.com/wp-content/uploads/2016/06/Stacked-donut.png)

Hi @tmontanaro
This is not possible with angular-gauge natively. However, with tricks, you can stack multiple angular-gauge together to achieve it but I don't recommend that because it is a hack, not a sustainable solution.
You can look for other chart types which better match your situation. Maybe gauge is not the right fit for this problem.
Thanks!


Option to just set up the spdy conn without opening a new stream on top of it.

done in https://github.com/diasdavid/node-ipfs-swarm/commit/8911d726487c2a7c049e8c2cf41cd5c2033dcee4


Example that shows how to separate additive effects, e.g. time series decomposition of birthdays data

Hello,
I am trying to replicate something like shown here:
http://andrewgelman.com/2012/06/19/slick-time-series-decomposition-of-the-birthdays-data/
http://research.cs.aalto.fi/pml/software/gpstuff/demo_births.shtml
I currently cannot find out how after fitting a model I can use something like m.predict_y(xx) on only a part of the model? It would help if your set of examples would include something like this birthday demo.
Many thanks and best regards,
Christian

This was discussed in Issue #232.
I went ahead and implemented a solution.  It fits the full model, then makes separate models for each component and sets the hyperparameters correctly.  See the notebook here.  Note you will need to download the birthday dataset here

Thank you very much for your very useful solution! I have to look into it in more detail.
On first sight I have 2 questions:

If I would use a more complicated additive kernel it would help if I could refer to each component via a name or like in the GPstuff version via an index. I understand that the conversation in #232 was exactly around this point, e.g. how to offer the API to an end-user like me. I will continue my questions there then.
If I look at the graph generated by 'plot(m1, X, Y,N=1)', I cannot imagine that this is 'correct' as the delta between the mean line and the dots is too big and cannot be corrected by the small addition of the periodic component. The whole model on the other hand fits very well 'plot(m, X, Y,N=1)'!

I think this ticket #491 is still relevant and it would help others if there would be an example given in the documentation that shows how to separate additive effects.
Thanks a lot!
Christian

I've now used the insights I got from the example of @mathDR on a simpler data-set, the CO2 data of Mauna Loa as given by Gaussian Processes for Machine Learning in chapter 5.
I put my initial results in a jupyter notebook here. Use the nbviewer link for better visual display.
Either I am doing something wrong or I seem to have a major misunderstanding of what the components are supposed to mean. I was under the impression that the components should be additive, but my test-case does not look like addtive. I've described my confusion in more detail in the notebook.
I would be very grateful for any further hints.
I am willing to develop the CO2 and the birth date examples into full examples that could be used with the GPflow documentation if wanted.

Please correct me if I am wrong, but as far as I can tell predicting the components of an additive kernel does not work by looking at each individual kernel.
Have a look at The Kernel Cookbook and scroll down to "Additive decomposition" or look at equation 1.17 at the kernels chapter of David Duvenaud's Phd thesis.
I believe this functionality would need to be part of the core feature set of GPflow, wouldn't it?

Here is a blog post of some new development in PyMC3 that shows how to perform this additive decomposition using the new features: https://bwengals.github.io/looking-at-the-keeling-curve-with-gps-in-pymc3.html
It would be great to have a similar blog post/example how to achieve this via GPflow.

The simplistic idea on how to do the additive decomposition from above is not correct.
I did not find a way on how to make GPflow perform this additive decomposition and therefore I decided to implement it by hand. In that set-up GPflow is used to find the correct parameters and the hand written code is used to decompose the addtitive parts.
I've put the example code in a jupyter notebook here. Use the nbviewer link for better visual display.

@cs224 Thanks for posting this! (I was in the midst of writing up the same notebook!!)

@cs224 This notebook is very helpful.
One thing I've found while playing with GPflow is that you can access  the kernel functions, so you can replace your kernel matrix calculations using the built in Kernel.compute_K and Kernel.compute_K_symm functions which will have the trained parameters.
Another thing of note is that the noise you observe in the posteriors should not be real, and are probably result of ill-conditioning of inverting a matrix. If you replace np.linalg.inv(A).dot(y) with np.linalg.solve(A, y) it should give you better conditioned results.

@yunlinz Thanks for your comments. I'll try that.


[backport] Add a kernel for integer GEMM

Backport of #3994

[automatic post] Jenkins, test this please.

Jenkins CI test (for commit e7bf9034bba1a178faf8b793c3b8cb603af9b21c, target branch v8) succeeded!


TypeMap::include copies only mappings but preConverter and postConverter

TypeMap::include copies only mappings but preConverter and postConverter
Exmaple:
import lombok.Data;

@Data
class Person {
  String name;
  Address address;
}
@Data
class Address {
  String country;
  String zipCode;
}
@Data
class PersonDTO {
  String name;
  String country;
  String zipCode;
  String region;
}

class PersonConverter {
  ModelMapper modelMapper = new ModelMapper();

  public void configure() {
    modelMapper.emptyTypeMap(Address.class, PersonDTO.class)
      .addMapping(Address::getCountry, PersonDTO::setCountry)
      .addMapping(Address::getZipCode, PersonDTO::setZipCode)
      .setPostConverter(ctx -> convertRegion(ctx.getSource(), ctx.getDestination()));

    modelMapper.emptyTypeMap(Person.class, PersonDTO.class)
      .addMapping(Person::getName, PersonDTO::setName)
      .include(Person::getAddress, Address.class);
  }

  private PersonDTO convertRegion(Address address, PersonDTO personDTO) {
    if (address.getZipCode().startsWith("111")) {
      personDTO.setRegion("SOME REGION");
    } else {
      personDTO.setRegion("UNKNOWN");
    }
  }

  public PersonDTO convert(Person person) {
    return modelMapper.map(person, PersonDTO.class);
  }
}

class Main {
  public static void main(String[] args) {
    Person person = new Person();
    person.name = "NAME";
    Address address = new Address();
    address.country = "COUNTRY";
    address.zipCode = "111111";
    Person.setAddress(address);

    PersonConverter personConverter = new PersonConverter();
    personConverter.configure();
    PersonDTO dto = personConverter.convert(person);
    System.out.println(dto.region);
  }
}

it will print null, but I expect to see SOME REGION.

Hi @linarkou,
It's expected behavior to only include the mappings without providers/converters as it's not type safe.
Please let me know if you have any idea or new api we can introduce on handling for your scenario.
Thanks!

I think the type map inheritance is not suitable for your case. I think the converter for the property mapping is what you need.
modelMapper.emptyTypeMap(Person.class, PersonDTO.class)
      .addMappings(mapper -> {
         mapper.map(Person::getName, PersonDTO::setName);
         mapper.map(person -> person.getAddress().getCountry(), PersonDTO::setCountry);
         mapper.map(person -> person.getAddress().getZipCode(), PersonDTO::setZipCode);
         mapper.using(regionConverter).map(person -> person.getAddress().getZipCode(), PersonDTO::setRegion);
      });

it is just a simple example, we use more complex combinations of converters in real life.
I think it is not expected behaviour when I want reuse some mappings..

It's not type safe to inherit converters from base TypeMap so we decide to not include the converters to the new TypeMap.

Can you elaborate on that? Why should that be the case? By definition, a subtype of A exposes all API of A. I.e. if a pre- or post-converter is defined for A, it is applicable to B extends A. Especially if I explicitly register the inclusion via .include(Source.class, TargetSubtype.class). 🤔


nix-prefetch-git should use git's --recursive for --fetch-submodules

Issue description
nix-prefetch-git doesn't use the git --recursive flag for checking out submodules.  This causes the results to be slightly different than if it had used the git --recursive flag, which creates the submodule .git files as regular files rather than directories.
Some software expects its submodules to be cloned using --recursive rather than manually (https://github.com/pmodels/mpich/blob/4d7051752a9ea1bdce34654dc985d62665aea859/autogen.sh#L51). In general I think nix's git functions should behave as closely to what regular users are going to be doing as possible, to avoid weird problems when working with code that isn't Nix-aware.

This is still relevant.


Color input, Safari

Safari 10+ is listed as supporting color input, but when I'm testing in my own browser it doesn't.

Doesn't work for me either. MDN says that Safari doesn't support it either.

I just submitted a pull request updating this, as I have had the same experience. I marked Safari TP as unknown.

@Puffton @Fyrd It was fixed. So this issue can be closed. I've tested and it works in Safari TP.


Getting TypeError: Amount must be an integer on test value 315.15

The code snippet below throws Getting TypeError: Amount must be an integer
import MoneyLib = require('js-money');

MoneyLib.fromDecimal(300.15, 'PHP');

This line appears to be causing the problem:
https://github.com/davidkalosi/js-money/blob/10a4870fa8fd47eb27d0ac794ad4dfd24150277a/lib/money.js#L119
The result produced is 30014.999999999996 which is not the integer that's expected.

Can also reproduce with new Money(34.98, currency). Will occur in any value in which n * 100 cannot be precisely held as a JS.
bad solution: next line, resultAmount = Math.ceil(resultAmount);
good solution: do math with an appropriately precise decimal library: https://github.com/MikeMcl/decimal.js/

The Money.fromDecimal function allows you to pass a third parameter of "rounder" which should be one of Math.ceil, Math.floor, or Math.round.  You can then create your Money object without error like so:
Money.fromDecimal(300.15, Money.PHP, Math.round);

@mothman103182 Passing a "rounder" function just burdens the application using it. You just remove the issue in the library and let application handles it. Why not use big decimal instead for precise numeric operations?


Explanation of default values in lab05

The argument “tolerance” is omitted in the tests in pointsApproxEqualTest.cpp, as is “precision” in the boxToString/pointToString tests. Suggested fix: explain default values and point students to shapeFuncs.h to see where the default values are assigned?

Added a note to the lab with the suggestion.


GitLab credentialsSecret is not working

I'm trying to use this operator to sync groups with a on-premises GitLab instance using token authentication but I'm getting the following error from the controller-manager pod:
2022-09-12T19:37:18.348Z	ERROR	controller-runtime.manager.controller.groupsync	Reconciler error	{"reconciler group": "redhatcop.redhat.io", "reconciler kind": "GroupSync", "name": "gitlab-groupsync", "namespace": "group-sync-operator", "error": "GET https://my.internal.gitlab.domain/api/v4/groups: 401 {message: 401 Unauthorized}"}
GroupSync is configured as follow:
apiVersion: redhatcop.redhat.io/v1alpha1
kind: GroupSync
metadata:
name: gitlab-groupsync
namespace: group-sync-operator
spec:
providers:
- gitlab:
credentialsSecret:
kind: Secret
name: gitlab-group-sync
namespace: group-sync-operator
insecure: false
prune: false
url: https://my.internal.gitlab.domain/
name: gitlab
I've tried to access the GitLab api using curl with the same token in  gitlab-group-sync secret and got the groups list from GitLab as expected
Group Sync Operator version: 0.0.20
GitLab version: 11.10.4

@asterioproba Just tested this Community Edition 15.7.0 and was able to create a personal access token with API access and was able to synchronize groups.
Is there any additional information that you would be able to proivde?

personal access token

Hi! Only work with Personal Access Token? I tried to configure it with an Gitlab OAuth application but it didn't work for me.

@asterioproba @mbecca I took a look into the underlying go-gitlab and there is support for multiple token types (OAuth, Personal and Job). Based on the current codebase, OAuth should be the one that is supported. However, moving forward, it would be good to be able to make use of any of the above types.
Created #261 to track this enhancement

@sabre1041 thanks for the reply.  It's also not clear to me if with an Oauth application token currently, should it work?
Regards,
M.

@mbecca with som of the recent enhancements to the operator, would you be able to confirm that you are able to define the desired credential to communicate to GitLab?


[Feature]: Double Jack Dialog - Opponent should get an overlay instead of the dialog

Feature Summary
Opponent's should see a different perspective on the seven double jack dialog than the active player.
Detailed Description
When someone plays a 7, they get to play one of the top two cards of the deck. If both are jacks and the opponent can't be jacked at that time (has queen or no points) then the player with the 7 gets a dialog informing them that they can't play either card and must throw one in the scrap.
Currently the inactive opponent sees the same dialog, which is misleading because it looks like they have a choice to make but in reality they just need to wait.
We should replace what the opponent sees in this case with an overlay that says 'Opponent must discard a jack'

Closed by #226


repaired lesson2 and added notes

1, repaired the notebook for viewing
2, add notes about ipywidgets configuration and solve possible problem caused by widgets: https://github.com/fastai/fastai/issues/1539#issuecomment-505696380
3, correct json typos left by others

@sgugger Maestro, Do you know why i can't commit?

Thanks. I started on the videos and found this issue on the 2nd lesson. I copied your solution and it worked.

Thanks. I started on the videos and found this issue on the 2nd lesson. I copied your solution and it worked.

You are welcome. But i can not commit this pr. @jph00

Thanks a lot. @Light-- if your auestion why you couldn't merge directly it's because only the maintainers of the repo can, after reviewing.
Also, don't forget to run the command tools/run-after-git-clone in the course-v3 cloned repo so that the automatic scripts that strip the notebooks from metadata is run, I re-stripped the notebook after merging your PR here.

Thanks a lot. @Light-- if your auestion why you couldn't merge directly it's because only the maintainers of the repo can, after reviewing.
Also, don't forget to run the command tools/run-after-git-clone in the course-v3 cloned repo so that the automatic scripts that strip the notebooks from metadata is run, I re-stripped the notebook after merging your PR here.

Many thanks for helping me! Now i know it's not that i can't commit, it's the metadata in the commited notebook should be stripped out(otherwise the pr will not pass the azure-pipelines check), am i right? Just want to make sure if it is the right steps for commiting pr:

fork the repo and edit the notebook to correct;
run the script tools/run-after-git-clone  to make the edited notebook with no metadata;
commit the pr
one of the maintainers reviewed the pr and merge or reject

The reason why i got confused by "stripped out" azure-pipelines firstly is that, there are metadata in the original notebook already, i didn't change the metadata, all i did was edit the other contents, but the azure-pipelines still keep me from submitting. Haha :-D now i learned. Thank you.


Simplify installation for end-users

Before we publish Malevo we should make the installation as easy as possible for the end-user. That will increase the chance that user try malevo with their own datasets and we get real feedback.

As we only work an a minimal feasible version for the paper, is this still relevant?


Fix output col distinct issue

We can not modify the output result here. If so, it may cause misplacement in some test case.
e.g. in tpch
val q1 = spark.sql(
      """select
        |   avg(l_quantity) as avg_qty,
        |   sum(l_quantity) as sum_qty
        |from
        |   lineitem
        |group by
        |   l_returnflag,
        |   l_linestatus
        |order by
        |   l_returnflag,
        |   l_linestatus
      """.stripMargin)

More details on this issue may be added later.

If we change the order of sum and avg from
val q1 = spark.sql(
      """select
        |   avg(l_quantity) as avg_qty,
        |   sum(l_quantity) as sum_qty
        |from
        |   lineitem
        |group by
        |   l_returnflag,
        |   l_linestatus
        |order by
        |   l_returnflag,
        |   l_linestatus
      """.stripMargin)

to
val q1 = spark.sql(
      """select
        |   sum(l_quantity) as sum_qty,
        |   avg(l_quantity) as avg_qty
        |from
        |   lineitem
        |group by
        |   l_returnflag,
        |   l_linestatus
        |order by
        |   l_returnflag,
        |   l_linestatus
      """.stripMargin)

It works perfectly...

Related modification pr #45
Related issue in tikv-client-lib-java #tikv-client-lib-java#166

PTAL @ilovesoup @zhexuany


Jasper wan't start

Hello everybody.
I am trying to make Jasper running on a Raspberry Pi model B+
I tried to used PocketSphinx as a STT but every time i tried to make phonetisaurus the process stop and no phonetisaurus-g2p wasn't made.
Now i'm trying to use wit.ai but every time I lunch Jasper this apear:
*******************************************************
*             JASPER - THE TALKING COMPUTER           *
* (c) 2015 Shubhro Saha, Charlie Marsh & Jan Holthuis *
*******************************************************
ERROR:root:Error occured!
Traceback (most recent call last):
  File "jasper.py", line 143, in <module>
    app = Jasper()
  File "jasper.py", line 106, in __init__
    stt_passive_engine_class.get_passive_instance(),
  File "/home/jasper/client/stt.py", line 48, in get_passive_instance
    return cls.get_instance('keyword', phrases)
  File "/home/jasper/client/stt.py", line 42, in get_instance
    instance = cls(**config)
TypeError: __init__() takes exactly 2 arguments (1 given)

Can someone give me assistance?
I want to use Jasper as a voice control over my house but I am stuck here.
P.S. I have already edit profile.yml with the wit.ai and espeak lines.

You probaböy forgot the Wit.ai Access token.

I have insert it on the profile.yml with the "notepad" like this:
*other things
stt_engine: witai
witai-stt:
access_token: *access token code
Did I edit it in the wrong way?

You need to indent access_token: (with spaces).

I am not so good in Python now, can you make me an example ?

stt_engine: witai
witai-stt:
    access_token: YOURACCESSTOKEN

Nothing.... still get the same error.... even the access token is correct but, it keep not working

man im in the same boat

What branch are you on?  Also, how many spaces there?  And are you using the server token?
I have examples on my site that work if you just want to copy/paste ur key in.
http://www.mattcurry.com/projects-2/the-jasper-project/jasper-project-useful-links/
There are 'profile examples' there if you want to try those.  I have seen this before.  Also, make sure you stop the daemon if you are using my image.  Then try running it manually python jasper.py --debug

Please go ahead and close this, as it is actually not an issue with the code.  Join me either in our forums or slack room and I am happy to help.  We also have quite a few members in there that can help as well if I am not there.
https://groups.google.com/forum/#!forum/jasper-support-forum

hello friends, pls be aware of mattcurrycom. first he will ask you to join jasper forum and once you go there and start asking questions, he will force you to join slack channel. but if you refused to join slack channel and ask more questions...... dang.... blocked..... banned.....from jasper support forum.
he will delete your messages from forum if he dont like it or dont have answer for it.
i dont know his history but i think he has some mental problem!!!

I don't force anyone to join anything.  I only remove banned authors posts if they are hateful or hostile towards the community.  I warned you 3 times, and you were removed.

Also @wullu appears to be a duplicate account of another user we have an issue with previously...
Oct 8, 2016 - Creation Date...
I don't have time for such things.  I have blocked the user here from my account.


Keybinding is confusing if it has two different cases of enablement

Testing #213343
This is telling me alt+k does two different things:

Maybe things that only apply to when the accessibility help view is open should say that to avoid conflicts

@connor4312 i'm confused, the when clause makes that clear. also, we resolve the keybinding for the accessibility help view focused context, so isn't it clear that alt+k applies when in the help dialog?

Oh, I misread the help, I thought the two alt+k's were different keybindings. This is fine then 👍


Feature Request: Typescript Hello World Template

Hi Team,
First of all congratulations for your great new approach to mobile app development. I am very excited about it! Unfortunately I am missing a template for development with Typescript. This would be a great help since I can not find any information about how to get started if I want to work with Typescript. Thank you for considering it.
Best regards,
Christoph

Hello @ch-weiss,
You can use AppBuilder Windows client. It supports Hello World template with TypeScript. It also has 3 additional templates - Blank, Master Details and Tabbed App. All of them have TypeScript support.

Hello Fatme,
Thank you four your help. I tried this already. My missing link is how to get a CLI build done for Typescript. As far as I understand AppBuiler is made for cloud building but I want to do a Typescript build on my machine via cli and I do not how to do this.

Hi @ch-weiss,
Unfortunately NativeScript CLI supports only Hello World with JavaScript. We are planning to support all templates(JavaScript and TypeScript) in the feature versions of NativeScript CLI. I'll keep you updated in this thread.
In the meantime you can use hello world TypeScript template from here.. You can use $ tns create --copy-from  command or you can replace the content of app folder in your project with the template above.
Hope that helps.

Hi Fatme,
Thank you very much again for your great support. This is a good starter help. I got the sample running unchanged on an Android tablet . Now I am trying to find out the correct tsc parameters to get changes in TypeScript compiled to Javascript without errors.

Hi Fatme,
Thanks again for your help. Maybe you can take me another step forward. When I am trying to compile my changes I am getting the error TS2307: Cannot find external module './application'.
Independent of the changed file I am always starting the compile with app.ts:
tsc.cmd --module commonjs --target ES5 app.ts
Can you give me any hint how to tell the tsc compiler where to find the core tns_modules? By the way I am working with Webstorm using a TypeScript transpiler calling .../npm/tsc.cmd.

Hi Chris,
I'm sorry for the late reply.
It seems that you need definition files. You can download them from here. After that you need to put them into <your project>/app folder.
This tsc.cmd --module commonjs --target ES5 app.ts shouldn't work because you need to compile all .ts files. Just execute the following:
dir *.ts /b /s > ts-files.txt tsc.cmd --module commonjs --target ES5 @ts-files.txt
This will compile all *.ts files in working directory and its sub directories. If you don't want to include sub directories, just remove the /s part from the first line.
Hope that helps!

Hi Fatme,
thanks you veeery much! This was a big help. This was exactly what I was looking for. Now I got it working!
Just one thing as an information for you. When I run the tcs run android command, it finally tries to compile '\platforms\android\assets\tns_modules\ui\layouts/ts-files.txt' ending with an error. I can live with that. It is not for complaining, just to let you know.
A big thank you again!

Just one more thing. Is there any information about NativeScript unit testing? Is there a framework you can recommend?

Please have some traction on the typescript template. It will just make nativescript adoption much easier.

I was working on a feature that uses a TypeScript app managed by Grunt, which in turn calls the tns commands, so I decided to package it up as an example project that people can use until we have proper support.
You can find the project here.


Adding Support for RESTful URL in config

Description
Nowadays, it is very common to hit RESTful APIs such as /user/1234, /contact/12/55, etc.
In order to make those requests with axios, we generally use string concatenation or template like this:
axios.get('/contact/' + contactId + '/' + contactOffset)
    .then( ... )

or
axios.get(`/contact/${contactId}/${contactOffset}`)
    .then( ... )

that would produce quite not clean codes.
This PR introduces a new config value called resources (derived from R in restful) in order to create more clean and elegant RESTful requests. For example:
axios
    .get('/contact/:contactId/:offset', {
        resources: {
            contactId: '1234',
            offset: '12',
        },
    })
    .then( ... )

Coverage increased (+1.4%) to 93.812% when pulling 0d9882a9415084190229a467cf3aa81fbd661da8 on andresusanto:master into 322be107301c5c725b13e3c0c00108e55655f540 on mzabriskie:master.

Coverage increased (+1.4%) to 93.797% when pulling 0bb2dd49332c0606fd2bd795b86b1b863a44864f on andresusanto:master into 322be107301c5c725b13e3c0c00108e55655f540 on mzabriskie:master.

Coverage increased (+1.4%) to 93.812% when pulling 0bb2dd49332c0606fd2bd795b86b1b863a44864f on andresusanto:master into 322be107301c5c725b13e3c0c00108e55655f540 on mzabriskie:master.

Coverage increased (+1.4%) to 93.812% when pulling 6acb9c915b4592eebc3f54d7f976b2da762c9dc6 on andresusanto:master into 322be107301c5c725b13e3c0c00108e55655f540 on mzabriskie:master.

We're sorry but this is too opinionated to be included in axios core and it makes perfect sense to implement it in a plugin (where you can add an interceptor to process the config).
We've also rejected a proposal to implement URI templates which are similar to this.
Next time please open an issue requesting the feature so we can discuss this before making the effort to implement it.
Thanks for your contribution.