Unable to enter numbers in an input using trigger()

Version
1.0.0-beta.12
Reproduction link
https://codesandbox.io/s/n768kwm6wj
note: the dummy VueInput component and the spec code is correct, but I can't make vue-test-utils work there
Steps to reproduce
Following the keyboard example from the documentation, I'm trying to input arbitrary keys into an input.

Have a component VueInput that generated a top level input DOM element <vue-input type='text'>
With vue-test-utils, try to enter the keys home then 1 using:

describe('Dummy VueInput.vue', () => {
    it('should accept number keys', () => {
        const wrapper = mount(VueInput);
        const input = wrapper.find('input');
        expect(input.element.value).toEqual('');

        // Test inputting a number
        input.trigger('click'); //FIXME Is this really needed?
The input element value should be 1.
What is actually happening?
The input element value is unchanged and still equal to "".
Bonus question:
Do we need to manually (and painfully) convert each key we want to enter to its keyCode (which value), or is there a quicker and better way to enter multiple keys one after another in one go (like 1, then 5, then 8, perhaps using something like wrapper.keys('158')? (see how it's done in Selenium-based webdriver.io in that example)).

For me, which didn't work, but keyCode does when triggering keycodes.

Unfortunately, I added the three key, keyCode and which attribute to the keydown event just to be sure, and tried them separately, without success.

If you want to have a working reproducible example, you can checkout the code from the issue_1 branch of the vue-autonumeric repository (see here).
Then:
# Setup the repo
git clone -b issue_1  && cd vue-autoNumeric && yarn
# Run the test with jest
yarn test

You'll see all the tests that are currently failing, and if you want to check only the test that is the subject of this particular issue, change it( to fit( on that line.

For info, 1.0.0-beta.13 did not fix this issue.

Dispatching  an  event with a keycode does not  update an 's value.
To test  what  happens when triggering an event on an element, you must set the value manually.
There is an ongoing issue  on testing v-model —https://github.com/vuejs/vue-test-utils/issues/345

I'm not sure to follow; what do you mean by you must set the value manually? Using theInputElement.value = '1234'?
If so, that defeats the purpose of testing input keys event isn't?
If simulating a keydown event with input.trigger('keydown', { which: 49 }) does not change the input value accordingly (nor the v-model if any), then I'd say there is a major issue in trigger(), since being able to enter values in <input> element is an essential need.
I think this issue should not be closed.
Anyway, does this means we currently have no way to test any vue components that allows a user to interacts with it (ie. component that mask the user input, or a password input that displays an help tooltip once 3 or more characters have been entered, etc.)?

Trigger is a wrapper around dispatchEvent,  which dispatches a DOM event on an HTMLElement. If you dispatch a keydown event with a  keycode, the keycode  isn't added  to an  elements value.
You need to  set the value directly:
input.element.value = 'some value'

Anyway, does this means we currently have no way to test any vue components that allows a user to interacts with it

You can  test those things by changing the value and making sure the component  reacts correctly to it.

+1 @AlexandreBonneau , I'm currently facing exactly the same issue.

Sets the value of a text-control input or select element and updates v-model bound data.
Its worked
const input = wrapper.find('input');
 input.element.value = 'hello';
 input.trigger('input');
 input.trigger('keyup');
console.log(wrapper.vm.inputValue);
Output = 'hello'
Or
Can do this way
According to https://vue-test-utils.vuejs.org/api/wrapper/#setvalue
input.setValue('hello') is an alias of the following code
 input.element.value = 'hello';
 input.trigger('input');
So
input.setValue('hello');
input.trigger('keyup');
console.log(wrapper.vm.inputValue);
Output = 'hello'

Why is this closed? I am preventing some inputs using the keydown event. How should I be able to test that with the suggested solutions? If I set the value beforehand and trigger the keydown event, the value is already set...

@pinutz23 Maybe you can do something like:
const input = wrapper.find('input');

input.trigger('keydown', {
   key: '1',
};

I also think this should be reopened. I have a component that has to prevent certain keypresses because of the way number inputs work. This behavior is impossible to test by setting the value.

Not sure if this is related to the topic, yet this is also unable in vue-test-utils-next.


Fix HolidayBase::pop_named partial holiday names removal

Proposed change

Resolves #1321
Fix a bug introduced within a previous release.
Type of change

[ ] New country/market holidays support (thank you!)
[ ] Supported country/market holidays update (calendar discrepancy fix, localization)
[ ] Existing code/documentation/test/process quality improvement (best practice, cleanup, refactoring, optimization)
[ ] Dependency upgrade (version update)
[x] Bugfix (non-breaking change which fixes an issue)
[ ] Breaking change (a code change causing existing functionality to break)
[ ] New feature (new python-holidays functionality in general)

Checklist

[x] I've followed the contributing guidelines
[x] This PR is filed against beta branch of the repository
[x] This PR doesn't contain any merge conflicts and has clean commit history
[x] The code style looks good: make pre-commit
[x] All tests pass locally: make test, make tox (we strongly encourage adding tests to your code)
[x] The related documentation has been added/updated (check off the box for free if no updates is required)

coverage: 100.0%. remained the same when pulling d611042998a28cfb61e3afe1fe31b00f704c5299 on arkid15r:fix-pop-named into 2b0463684d23adacb331c03fda7b794534c16c6d on dr-prodigy:master.


python3Packages.python-engineio: 4.2.1 -> 4.3.0, python3Packages.python-socketio: 5.4.0 -> 5.4.1

Motivation for this change
Update to latest upstream releases
Change log:

https://github.com/miguelgrinberg/python-socketio/blob/main/CHANGES.md
https://github.com/miguelgrinberg/python-engineio/blob/main/CHANGES.md

Things done

Built on platform(s)

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

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested, as applicable:

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

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[ ] Tested basic functionality of all binary files (usually in ./result/bin/)
21.11 Release Notes (or backporting 21.05 Release notes)

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

[x] Fits CONTRIBUTING.md.

Result of nixpkgs-review pr 145215 run on x86_64-linux 1

13 packages built:

appdaemon
gdbgui
home-assistant
onionshare
onionshare-gui
python38Packages.aioambient
python38Packages.flask-socketio
python38Packages.python-engineio
python38Packages.python-socketio
python39Packages.aioambient
python39Packages.flask-socketio
python39Packages.python-engineio
python39Packages.python-socketio


improve design and look of all the pages

Use a single design for all the pages ovulatn, pregnancy, quiz, health etc.

Please assign this issue to me under JWOC @nisha331

go Ahead @S-ishita

Please change the labels to hard..

@nisha331
I would like to work on this issue under JWOC


Compare any arrays

We can try to fix https://github.com/expr-lang/expr/issues/371 with nested comparison of arrays' values but I'm not sure if it's worth it to increase amount of switch-cases for such rare (imo) case.
Also, I found that expr always goes to reflect.DeepEqual for bools and fixed it.

Okay, I opened separate PR for bools here.

But yes, I think we should not add cases for arrays.

We can add equalArrays just before reflect.DeepEqual and then we won't affect main switch-case statement
func Equal(a, b any) {
switch x := a.(type) {
    ...
}
if res, ok := equalArrays(a, b); ok {
    return res
}
return reflect.DeepEqual(a, b)

but decrease performance of non-primitive comparisons. Do you have any thoughts how frequently it happens?

Maybe a builtin deepEqual is needed which will be ignoring types of arrays (and maps?).

Could you please give me couple examples? I think I didn't get it.

We can add equalArrays just before reflect.DeepEqual and then we won't affect main switch-case statement

Sounds like a good solution. Make sure it is a deep equal as well: [1,[2,[3]]]==[1,[2,[3]]]

Do you have any thoughts how frequently it happens?

I don't know ¯\_(ツ)_/¯
I will be cool actually to vigure out what reflect.DeepEqual covers and add tests for those cases to make sure we will not break those in the future.
I also have an idea to test: add OpEqualInt & OpEqualBool & OpEqualString opcodes. I belive those will be the most common once. BUT, I'm not sure what adding more opcodes will be faster than OpEqual switch, so those changes should be benchmarked.

I don't know ¯_(ツ)_/¯
I will be cool actually to vigure out what reflect.DeepEqual covers and add tests for those cases to make sure we will not break those in the future.

The only case I found in my codebase involves fmt.Stringer objects. We can handle them at compile time (by calling .String() and then checking for equality) or simply add another switch-case to runtime.Equal.

I also have an idea to test: add OpEqualInt & OpEqualBool & OpEqualString opcodes. I belive those will be the most common once. BUT, I'm not sure what adding more opcodes will be faster than OpEqual switch, so those changes should be benchmarked.

Expr already includes OpEqualString and OpEqualInt opcodes so I compared these with OpEqual which is handled by the switch-case in runtime.Equal.
OpEqualString + OpEqualInt slightly better than OpEqual
❯ benchstat master.txt only-op-equal.txt                                                                                (gp-eu-central-1/delta)
goos: darwin
goarch: arm64
pkg: github.com/expr-lang/expr
                │ master.txt  │         only-op-equal.txt          │
                │   sec/op    │   sec/op     vs base               │
_expr-8           63.39n ± 0%   64.28n ± 0%  +1.40% (p=0.000 n=10)
_expr_reuseVm-8   44.30n ± 1%   45.11n ± 0%  +1.83% (p=0.001 n=10)
geomean           52.99n        53.85n       +1.62%

So if you find a ~2% improvement worthwhile, I can add OpEqualBool. Similarly, we can do the same with OpLess/OpMore for ints and floats.

So if you find a ~2% improvement worthwhile

I think we can postpone implementing it. We can focus on features with >10% performance boost.

So what is the status of this PR? Will we separate array equal cases to a func deepArrayEquals?

Firstly, I'm gonna write benchmarks for runtime.Equal to see how the quantity of cases impacts the switch-case statement. Looks like that dividing several cases into separate function isn't really beneficial.

I compared master vs extended switch-case:
❯ benchstat master.txt switch-case.txt
goos: darwin
goarch: arm64
pkg: github.com/expr-lang/expr/vm/runtime
                                         │  master.txt  │           switch-case.txt            │
                                         │    sec/op    │    sec/op     vs base                │
Equal/int_==_int-8                          2.081n ± 2%    2.119n ± 1%   +1.83% (p=0.003 n=10)
Equal/int_!=_int-8                          2.149n ± 1%    2.151n ± 0%        ~ (p=0.592 n=10)
Equal/int_==_int8-8                         2.185n ± 1%    2.201n ± 0%   +0.76% (p=0.003 n=10)
Equal/int_==_int16-8                        2.198n ± 1%    2.224n ± 1%   +1.18% (p=0.001 n=10)
Equal/int_==_int32-8                        2.179n ± 0%    2.209n ± 1%   +1.42% (p=0.000 n=10)
Equal/int_==_int64-8                        2.171n ± 1%    2.206n ± 1%   +1.59% (p=0.000 n=10)
Equal/float_==_float-8                      2.153n ± 1%    2.172n ± 1%   +0.91% (p=0.022 n=10)
Equal/float_!=_float-8                      2.162n ± 1%    2.174n ± 1%   +0.53% (p=0.027 n=10)
Equal/float_==_int-8                        2.266n ± 0%    2.317n ± 1%   +2.25% (p=0.000 n=10)
Equal/float_!=_int-8                        2.282n ± 0%    2.317n ± 0%   +1.58% (p=0.000 n=10)
Equal/string_==_string-8                    4.031n ± 0%    4.032n ± 0%        ~ (p=0.956 n=10)
Equal/string_!=_string-8                    4.308n ± 0%    4.285n ± 0%   -0.53% (p=0.002 n=10)
Equal/bool_==_bool-8                        2.253n ± 1%    2.168n ± 2%   -3.75% (p=0.000 n=10)
Equal/bool_!=_bool-8                        2.255n ± 0%    2.152n ± 1%   -4.57% (p=0.000 n=10)
Equal/[]any_==_[]int-8                      7.353n ± 1%   12.950n ± 1%  +76.13% (p=0.000 n=10)
Equal/[]any_!=_[]int-8                      7.368n ± 0%   12.920n ± 1%  +75.36% (p=0.000 n=10)
Equal/deep_[]any_==_[]any-8                103.90n ± 0%    83.84n ± 0%  -19.31% (p=0.000 n=10)
Equal/deep_[]any_!=_[]any-8                104.55n ± 1%    60.29n ± 1%  -42.34% (p=0.000 n=10)
Equal/map[string]any_==_map[string]any-8    219.1n ± 0%    214.3n ± 1%   -2.19% (p=0.000 n=10)
Equal/map[string]any_!=_map[string]any-8    56.47n ± 1%    53.26n ± 1%   -5.69% (p=0.000 n=10)
geomean                                     5.752n         5.842n        +1.57%

And extended switch-case vs separate function for arrays:
❯ benchstat switch-case.txt separate-func.txt
goos: darwin
goarch: arm64
pkg: github.com/expr-lang/expr/vm/runtime
                                         │ switch-case.txt │          separate-func.txt          │
                                         │     sec/op      │   sec/op     vs base                │
Equal/int_==_int-8                             2.119n ± 1%   2.093n ± 1%        ~ (p=0.085 n=10)
Equal/int_!=_int-8                             2.151n ± 0%   2.127n ± 0%   -1.14% (p=0.000 n=10)
Equal/int_==_int8-8                            2.201n ± 0%   2.194n ± 1%        ~ (p=0.128 n=10)
Equal/int_==_int16-8                           2.224n ± 1%   2.212n ± 1%        ~ (p=0.171 n=10)
Equal/int_==_int32-8                           2.209n ± 1%   2.191n ± 1%   -0.84% (p=0.024 n=10)
Equal/int_==_int64-8                           2.206n ± 1%   2.189n ± 1%   -0.75% (p=0.008 n=10)
Equal/float_==_float-8                         2.172n ± 1%   2.172n ± 0%        ~ (p=1.000 n=10)
Equal/float_!=_float-8                         2.174n ± 1%   2.183n ± 0%   +0.44% (p=0.014 n=10)
Equal/float_==_int-8                           2.317n ± 1%   2.282n ± 1%   -1.49% (p=0.000 n=10)
Equal/float_!=_int-8                           2.317n ± 0%   2.277n ± 1%   -1.75% (p=0.000 n=10)
Equal/string_==_string-8                       4.032n ± 0%   4.024n ± 0%        ~ (p=0.324 n=10)
Equal/string_!=_string-8                       4.285n ± 0%   4.288n ± 0%        ~ (p=0.590 n=10)
Equal/bool_==_bool-8                           2.168n ± 2%   2.164n ± 1%        ~ (p=0.077 n=10)
Equal/bool_!=_bool-8                           2.152n ± 1%   2.162n ± 2%        ~ (p=0.304 n=10)
Equal/[]any_==_[]int-8                         12.95n ± 1%   16.38n ± 1%  +26.45% (p=0.000 n=10)
Equal/[]any_!=_[]int-8                         12.92n ± 1%   16.41n ± 1%  +26.97% (p=0.000 n=10)
Equal/deep_[]any_==_[]any-8                    83.84n ± 0%   98.89n ± 1%  +17.96% (p=0.000 n=10)
Equal/deep_[]any_!=_[]any-8                    60.29n ± 1%   74.37n ± 1%  +23.36% (p=0.000 n=10)
Equal/map[string]any_==_map[string]any-8       214.3n ± 1%   217.8n ± 0%   +1.66% (p=0.000 n=10)
Equal/map[string]any_!=_map[string]any-8       53.26n ± 1%   56.91n ± 1%   +6.86% (p=0.000 n=10)
geomean                                        5.842n        6.098n        +4.37%

The difference is just a tiny fraction of a nanosecond. I think we can say they're pretty much the same. What do you think?

I percentage on ns is definitely not major. Probably is an artifact of benchmarking. Let's just choose the more readable solution.


Interface to provide privileged data to IOGroups

Related to #651
Needed to support IOGroups that use drivers or out-of-band interfaces that require root access.  This could be done on behalf of the IOGroup by the geopm daemon(s).
There is also a need for similar access to controls.

We did it!
https://geopm.github.io/service.html


Infinite timeout

This gives a better solution to PRED-1629 / PRED-1587 but using an infinite timeout as the default value. It is still possible to set with any other value. An infinite timeout works better with OSX and allows more threads to operate (as a side-effect).
The changes include:

fixes to tests
implementation of change
update to CHANGES.rst
removal of monkey-patch added in previous fix

Weirdness from rebasing off master instead of pulling first.

Coverage increased (+0.07%) to 82.575% when pulling 36a20f383360eb6e55dde2627c39095f6b402375 on infinite-timeout into ad0af6a0d4a1f0fef2f473323b7bf3d7ce2c1a07 on master.


[Bug] explode_json_array_json did not work

Search before asking

[X] I had searched in the issues and found no similar issues.

Version
2.0-beta
What's Wrong?

create example table

 create table example1 as select 1 as k1;

fire explode query

select k1, e1
from example1
lateral view explode_json_array_json('[{"id":1,"name":"John"},{"id":2,"name":"Mary"}]') tmp1 as e1 order by k1, e1;

doris will throw an errorERROR 1105 (HY000): errCode = 2, detailMessage = No matching function with signature: explode_json_array_json(varchar(*))
What You Expected?

How to Reproduce?
Do as I do in "What's Wrong?".
Anything Else?
https://github.com/apache/doris/issues/21422
Are you willing to submit PR?

[ ] Yes I am willing to submit a PR!

Code of Conduct

[X] I agree to follow this project's Code of Conduct

It will be supported in 2.0 GA #21795


Real-Time Language Translation Plugin

Is your feature request related to a problem? Please describe.
i saw a comment regarding the recent Venezuela vs RoT incident about us having to learn spanish to assimilate into the new OSRS community. Someone offhandedly mentioned a translator, which i though is a great idea as i frequently see people speaking their native tongue's from around the world.
Describe the solution you'd like
Plugin for real time translation of the game chat (player messages, private messages).
Describe alternatives you've considered
learn like 8 new languages
alt tab to google translate and try and type in what they typed in minus the fancy letters
ignore them
Additional context
everything is already in english, except player input stuff (names, chat) you could also put a little (xxxxx) after their osrs name showing if any of the words in it mean stuff in other languages. It would also be sick if we had the option to translate to a language while typing for speaking with people not using the client (dropdown menu or something)

This sounds like a very nice feature to have.

#5895 might be better as an external plugin though.

Polywoof translation plugin on the plugin hub does this


[1624] Display error summary at top of enrichment pages

Context
We need to display validation errors when users save course description fields.
Changes proposed in this pull request
Renders the shared errors template at the top of the about, fees, salary, and requirements pages.
The forms are updated to each contain a hidden field, for the page that they correspond to, to allow the courses#update action to render the correct page when responding with validation errors.
4 new patch routes are created, one for each page. This is because on the regular update endpoint, the URL is /organisations/ORG/courses/CRS. If a user takes this URL and submits it in the same browser tab, they'll be taken to the basic details, which is confusing.
Guidance to review
Needs tests, draft until then. There will be a follow-up PR to implement the red highlights on the form fields.
Screenshots

 Display validations when saving enrichments


Styling of contents is not precise

I can add effective styling to this portion

Ok. You are assigned

please assign this issue to me


Sling nix

the flake.nix has been initialized with:
nix flake init -t github:ipetkov/crane#quick-start-simple

This allows to build the project with
nix build

Which is useful to integrate the plugin in nix systems

Hi @RCasatta ,
thank you very much for this contribution. Unfortunately i have 0 experience with nix. I guess it's finally time to look into it 😄

thanks for merging,
sorry that I forgot to mention the experimental features were needed,


Make module server configurable

See https://github.com/cloudfour/pleasantest/pull/115

Also test with using a rollup vue plugin and see if loading .vue files works


Variables not replaced by nested macro SET

Describe the bug
variables not parsed in any case like V1 is doing.
To Reproduce
Steps to reproduce the behavior:
create contxt file like so
config:
  imports:
     - ctx-default.yml local-config

task:
  - id: local-config
    require:
      system: linux
      exists:
        - ${USER}.local.json
    script:
      - echo "loading local config file from user ${USER}.local.json"
      - "#@import-json-exec local-config cat ${USER}.local.json"

  - id: build-base-image
    needs:
      - local-config
    script:
      - echo "testing vars"
      - "#@set RUNCMD --build-arg CMP_KEYID=${local-config:HIDDEN.CMP_KEYID}"
      - "#@set RUNCMD ${RUNCMD} --build-arg CMP_ACID=${local-config:HIDDEN.CMP_ACID}"
      - "#@set RUNCMD ${RUNCMD} --build-arg LICENCE_KEY=${local-config:HIDDEN.LICENCE_KEY}"
      - echo "${RUNCMD}"

also create an json file with the needed keys in
named with  ${USER}.local.json
{
  "HIDDEN": {
    "CMP_KEYID": "0815",
    "CMP_ACID": "thisisAnExample",
    "LICENCE_KEY": "andthisisalsonotanrealkey"
  }
}

watch what is happen.
also compare with v1 what is doing well.
Expected behavior
variables have to replaced with the content any time. at least like v1 is doing
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):

OS: linux

all tests are working.
fixed by the way logger issues depending dependency injections, and accepting the mimic.NullLogger as valid logger.
this way i found this a real use case
INFO[0000] executeTemplate IGNORE because requirements not matching  reason="required file (${USER}.local.json) not found " target=local-config
${USER} is set and the placeholder handling is also in place. have to digg deeper

issue found.
v1 did it correctly already and includes the environment variables.
this was just not done yet.
fixed


x/crypto/ssh: host key algorithm selection prefers DSA over ED25519

When a server provides both a DSA host key and an ED25519 host key, the Go ssh library will select DSA instead. But DSA has been deprecated in OpenSSH (and in other libraries, I suppose).
This is because in crypto/ssh/common.go, ED25519 is at the end of supportedHostKeyAlgos, which is supposed to be in preference order:
var supportedHostKeyAlgos = []string{
	CertSigAlgoRSASHA2512v01, CertSigAlgoRSASHA2256v01,
	CertSigAlgoRSAv01, CertAlgoDSAv01, CertAlgoECDSA256v01,
	CertAlgoECDSA384v01, CertAlgoECDSA521v01, CertAlgoED25519v01,

	KeyAlgoECDSA256, KeyAlgoECDSA384, KeyAlgoECDSA521,
	SigAlgoRSASHA2512, SigAlgoRSASHA2256,
	SigAlgoRSA, KeyAlgoDSA,

	KeyAlgoED25519, // <-- lowest preference, unlike the other algo list constants that place ED25519 much higher
}

CC @neild, @rolandshoemaker.

I believe the equivalent in OpenSSH (SSH_ALLOWED_CA_SIGALGS) has ED25519 first, as per https://github.com/openssh/openssh-portable/blob/0d96b1506b2f4757fefa5d1f884d49e96a6fd4c3/myproposal.h#L81-L89.

Hello,
I definitely agree that we should update our algorithms to remove the insecure ones (dsa, sha-1 etc.), but since this is a backwards incompatible change we need a proposal.
In this specific case let's assume we have a client like this
config := &ssh.ClientConfig{
	....
	HostKeyCallback: ssh.FixedHostKey(pub),
       ....

with a server supporting DSA and ED25519, it expects to validate a DSA key, if we switch the order we'll break it.
After this CL is merged, we'll have a clear distinction between secure and insecure algorithm and I'll propose to switch to the (currently) secure algorithms.
For host keys we'll use this one
supportedHostKeyAlgos = []string{
		CertAlgoRSASHA256v01, CertAlgoRSASHA512v01,
		CertAlgoECDSA256v01, CertAlgoECDSA384v01, CertAlgoECDSA521v01,
		CertAlgoED25519v01,

		KeyAlgoRSASHA256, KeyAlgoRSASHA512,
		KeyAlgoECDSA256, KeyAlgoECDSA384, KeyAlgoECDSA521,
		KeyAlgoED25519,
	}

I think the proposal is also the right place to discuss the ordering of algorithms and perhaps change it.


Add TORoundedButton

Project URL
https://github.com/TimOliver/TORoundedButton
Category
Button
Description
A high-performance button control with rounded corners.
Why it should be included to awesome-ios (mandatory)
Most useful.
Checklist

[x] Has 50 Github stargazers or more
[x] Only one project/change is in this pull request
[x] Isn't an archived project
[x] Has more than one contributor
[x] Has unit tests, integration tests or UI tests
[x] Addition in chronological order (bottom of category)
[x] Supports iOS 9 / tvOS 10 or later
[x] Supports Swift 4 or later
[x] Has a commit from less than 2 years ago
[x] Has a clear README in English

          1 Warning

:warning:
Found 4 link issues, a project collaborator will take care of these, thanks :)

Link issues by awesome_bot

Line
Status
Link

1383
301
https://airship.com/products/mobile-app-engagement redirects tohttps://www.airship.com/products/mobile-app-engagement

1659
404
https://github.com/genadyo/Lyft

1806
404
https://github.com/loiclec/Apodimark

3323
302
http://consultpodcast.com/#_=_ redirects tohttps://consultpodcast.com/#_=_

  Generated by :no_entry_sign: Danger

Thanks


DOC: change picks description in ICA.plot_properties()

Fixes #10264.
Like discussed, I updated the description what info picks represent.

Not sure whether there is some pre-made pick information that can be applied to sources. So, I just oriented myself at the picks description in utils/docs.py

small nitpick: I think to maximize clarity its better to refer to "components", not "sources".


Minecraft Command Shortcuts Not Working

Howdy, when trying to run a command via the new Minecraft Shortcut Commands option, nothing seems to happen. I have the extension set up correctly and am connected to Minecraft, I can see my scripting logs appearing in the Debug Console, and the Diagnostics panel is working, just the command shortcuts aren't.
Is this a feature that requires a later version of Minecraft than 1.21.31? Or is more configuration required that hasn't been documented yet, or I missed somewhere?

The commands pane only works on Minecraft versions 1.21.50 preview or higher.  Sorry for not documenting that!


Issue when Installing Kaldifeat on Windows 11

Hello I get errors when trying to install Kaldifeat these are the logs
python setup.py install
running install
C:\ProgramData\anaconda3\lib\site-packages\setuptools\command\install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
C:\ProgramData\anaconda3\lib\site-packages\setuptools\command\easy_install.py:144: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
running bdist_egg
running egg_info
creating kaldifeat.egg-info
writing kaldifeat.egg-info\PKG-INFO
writing dependency_links to kaldifeat.egg-info\dependency_links.txt
writing top-level names to kaldifeat.egg-info\top_level.txt
writing manifest file 'kaldifeat.egg-info\SOURCES.txt'
reading manifest file 'kaldifeat.egg-info\SOURCES.txt'
reading manifest template 'MANIFEST.in'
adding license file 'LICENSE'
writing manifest file 'kaldifeat.egg-info\SOURCES.txt'
installing library code to build\bdist.win-amd64\egg
running install_lib
running build_py
creating build
creating build\lib.win-amd64-cpython-310
creating build\lib.win-amd64-cpython-310\kaldifeat
copying kaldifeat\python\kaldifeat\fbank.py -> build\lib.win-amd64-cpython-310\kaldifeat
copying kaldifeat\python\kaldifeat\mfcc.py -> build\lib.win-amd64-cpython-310\kaldifeat
copying kaldifeat\python\kaldifeat\offline_feature.py -> build\lib.win-amd64-cpython-310\kaldifeat
copying kaldifeat\python\kaldifeat\online_feature.py -> build\lib.win-amd64-cpython-310\kaldifeat
copying kaldifeat\python\kaldifeat\plp.py -> build\lib.win-amd64-cpython-310\kaldifeat
copying kaldifeat\python\kaldifeat\spectrogram.py -> build\lib.win-amd64-cpython-310\kaldifeat
copying kaldifeat\python\kaldifeat_init_.py -> build\lib.win-amd64-cpython-310\kaldifeat
running build_ext
Setting PYTHON_EXECUTABLE to C:\ProgramData\anaconda3\python.exe
build command is:
            cmake -DCMAKE_BUILD_TYPE=Release -DPYTHON_EXECUTABLE=C:\ProgramData\anaconda3\python.exe -Dkaldifeat_BUILD_TESTS=OFF  -DCMAKE_INSTALL_PREFIX=C:\Users\Fawaz Shaik\sherpao\kaldifeat\build\lib.win-amd64-cpython-310/kaldifeat  -B build\temp.win-amd64-cpython-310\Release -S C:\Users\Fawaz Shaik\sherpao\kaldifeat
            cmake --build build\temp.win-amd64-cpython-310\Release --target _kaldifeat --config Release -- -m
            cmake --build build\temp.win-amd64-cpython-310\Release --target install --config Release -- -m

CMake Error: The source directory "C:/Users/Fawaz Shaik/sherpao/kaldifeat/Shaik/sherpao/kaldifeat" does not exist.
Specify --help for usage, or press the help button on the CMake GUI.
Traceback (most recent call last):
File "C:\Users\Fawaz Shaik\sherpao\kaldifeat\setup.py", line 32, in
setuptools.setup(
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_init_.py", line 87, in setup
return distutils.core.setup(**attrs)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\core.py", line 185, in setup
return run_commands(dist)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\core.py", line 201, in run_commands
dist.run_commands()
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\dist.py", line 969, in run_commands
self.run_command(cmd)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools\command\install.py", line 74, in run
self.do_egg_install()
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools\command\install.py", line 123, in do_egg_install
self.run_command('bdist_egg')
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools\command\bdist_egg.py", line 165, in run
cmd = self.call_command('install_lib', warn_dir=0)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools\command\bdist_egg.py", line 151, in call_command
self.run_command(cmdname)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools\command\install_lib.py", line 11, in run
self.build()
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\command\install_lib.py", line 112, in build
self.run_command('build_ext')
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\cmd.py", line 318, in run_command
self.distribution.run_command(command)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools\dist.py", line 1208, in run_command
super().run_command(command)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\dist.py", line 988, in run_command
cmd_obj.run()
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools\command\build_ext.py", line 84, in run
_build_ext.run(self)
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\command\build_ext.py", line 346, in run
self.build_extensions()
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\command\build_ext.py", line 468, in build_extensions
self._build_extensions_serial()
File "C:\ProgramData\anaconda3\lib\site-packages\setuptools_distutils\command\build_ext.py", line 494, in _build_extensions_serial
self.build_extension(ext)
File "C:\Users\Fawaz Shaik\sherpao\kaldifeat\cmake\cmake_extension.py", line 90, in build_extension
raise Exception("Failed to configure kaldifeat")
Exception: Failed to configure kaldifeat

What if you switch to a directory that doesn't contain a space?
Your user name contains a space.

I tried in another direcory with no space, I get this error
python setup.py install
running install
C:\Users\Flanx\sherpa\Lib\site-packages\setuptools\command\install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
C:\Users\Flanx\sherpa\Lib\site-packages\setuptools\command\easy_install.py:144: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
running bdist_egg
running egg_info
writing kaldifeat.egg-info\PKG-INFO
writing dependency_links to kaldifeat.egg-info\dependency_links.txt
writing top-level names to kaldifeat.egg-info\top_level.txt
reading manifest file 'kaldifeat.egg-info\SOURCES.txt'
reading manifest template 'MANIFEST.in'
adding license file 'LICENSE'
writing manifest file 'kaldifeat.egg-info\SOURCES.txt'
installing library code to build\bdist.win-amd64\egg
running install_lib
running build_py
copying kaldifeat\python\kaldifeat_init_.py -> build\lib.win-amd64-cpython-311\kaldifeat
running build_ext
Setting PYTHON_EXECUTABLE to C:\Users\Flanx\sherpa\Scripts\python.exe
build command is:
            cmake -DCMAKE_BUILD_TYPE=Release -DPYTHON_EXECUTABLE=C:\Users\Flanx\sherpa\Scripts\python.exe -Dkaldifeat_BUILD_TESTS=OFF  -DCMAKE_INSTALL_PREFIX=C:\Users\Flanx\kaldifeat\build\lib.win-amd64-cpython-311/kaldifeat  -B build\temp.win-amd64-cpython-311\Release -S C:\Users\Flanx\kaldifeat
            cmake --build build\temp.win-amd64-cpython-311\Release --target _kaldifeat --config Release -- -m
            cmake --build build\temp.win-amd64-cpython-311\Release --target install --config Release -- -m

-- Building for: NMake Makefiles
CMake Error at CMakeLists.txt:5 (project):
Running
'nmake' '-?'
failed with:
The system cannot find the file specified
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!
Traceback (most recent call last):
File "C:\Users\Flanx\kaldifeat\setup.py", line 32, in
setuptools.setup(
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_init_.py", line 87, in setup
return distutils.core.setup(**attrs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\core.py", line 185, in setup
return run_commands(dist)
^^^^^^^^^^^^^^^^^^
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\core.py", line 201, in run_commands
dist.run_commands()
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\dist.py", line 968, in run_commands
self.run_command(cmd)
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools\dist.py", line 1217, in run_command
super().run_command(command)
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\dist.py", line 987, in run_command
cmd_obj.run()
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools\command\install.py", line 74, in run
self.do_egg_install()
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools\command\install.py", line 123, in do_egg_install
self.run_command('bdist_egg')
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\cmd.py", line 319, in run_command
self.distribution.run_command(command)
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools\dist.py", line 1217, in run_command
super().run_command(command)
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\dist.py", line 987, in run_command
cmd_obj.run()
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools\command\bdist_egg.py", line 165, in run
cmd = self.call_command('install_lib', warn_dir=0)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools\command\bdist_egg.py", line 151, in call_command
self.run_command(cmdname)
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\cmd.py", line 319, in run_command
self.distribution.run_command(command)
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools\dist.py", line 1217, in run_command
super().run_command(command)
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\dist.py", line 987, in run_command
cmd_obj.run()
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools\command\install_lib.py", line 11, in run
self.build()
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\command\install_lib.py", line 112, in build
self.run_command('build_ext')
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\cmd.py", line 319, in run_command
self.distribution.run_command(command)
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools\dist.py", line 1217, in run_command
super().run_command(command)
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\dist.py", line 987, in run_command
cmd_obj.run()
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools\command\build_ext.py", line 84, in run
_build_ext.run(self)
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\command\build_ext.py", line 346, in run
self.build_extensions()
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\command\build_ext.py", line 466, in build_extensions
self._build_extensions_serial()
File "C:\Users\Flanx\sherpa\Lib\site-packages\setuptools_distutils\command\build_ext.py", line 492, in _build_extensions_serial
self.build_extension(ext)
File "C:\Users\Flanx\kaldifeat\cmake\cmake_extension.py", line 90, in build_extension
raise Exception("Failed to configure kaldifeat")
Exception: Failed to configure kaldifeat

I have installed latest version of Pytorch and k2

Please install visual studio to compile kaldifeat from source.
Or please wait for a day or two before I manage to provide pre-compiled wheels for kaldifeat.

I can try compiling Kaldifeat from source by using Visual Studio, I need to try this in the Command Line of Visual Studio for this right?
And thanks for providing pre-compiled wheels, I will be sure to try using that once it is out.

We have a video demostrating how to install visual studio on Windows. Maybe it is helpful.
https://k2-fsa.github.io/sherpa/ncnn/install/videos.html

I need to try this in the Command Line of Visual Studio for this right?

Yes, you are right. The developer command prompt of visual studio.

This is ncnn right? I am trying to install the Python model on Windows. I was able to download the ONNX models perfectly without issue but need the Python model to so that I can extract the text and run analysis as I use Python and not C++.
If there is any demo on installing the Python model please let me know.
Also If there is any demo on the Client Server Build that would be very useful as I am trying to figure this out in ONNX Websocket example from the documentation. I am new to this so facing trouble. Your guidance will be very helpful thank you!

The way to install visual studio is not specific for sherpa-ncnn.
It is general.

If you want to use onnx models, then I recommend sherpa-onnx.
What you need is to run
pip install sherpa-onnx
You don't need to install visual studio in this case.

I am sorry if I was not clear previously.
I want to run Sherpa with Python and am trying to install Kaldifeat to run that, I have already instaled sherpa-ONNX but as I do not know C++ and I know Python I want to download the Python implementation.
Any guidance on installing the Python Implementation will be useful. I am trying to install Kaldifeat now in VS Terminal

How did you install sherpa-onnx?
k2-fsa/sherpa does not work with onnx models, only k2-fsa/sherpa-onnx does.
pip install sherpa-onnx installs the python stuff for you.

I followed instructions on https://k2-fsa.github.io/sherpa/onnx/install/windows.html#bit-windows-x64 to install sherpa-onnx
As per my understanding the inferencing here is done using the ./build/bin/Release/sherpa-onnx-microphone which is a .exe file. I wanted to do inferencing with Python files so I can understand the code.
For this I am trying to install Sherpa in Python implementation, can you guide me on this

For this I am trying to install Sherpa in Python implementation, can you guide me on this

As I have said twice, you only need to run
pip install sherpa-onnx

Yes, but i want to use Sherpa in my python files for inferencing as I want to extract the output. Is there any example of this after installing it with pip

Yes, we have detailed documentation.
Please have a look at
https://k2-fsa.github.io/sherpa/onnx/python/index.html

Do i need to run these in Terminal of Visual Studio to work?

Its working in Windows Command Line outside of Visual Studio, thank you so much for the help!!

Can I close this issue?

No,you can use what you are using for running python scripts.
There is nothing special about sherpa-onnx.
Please follow the documentation.

I didnt understand what you meant by using what I was using for running python scripts?

What environment you are currently using should work for running sherpa-onnx in Python. There is nothing special about sherpa-onnx. You don't need to use a special environment, e.g., visual studio commandline, to run sherpa-onnx.

Can I close this issue?

Yes, I think so. If you have any issues, please ask again.

Thanks for the clarification, if I have any other issue I will ask. Thanks again!

By the way, which version of Python and PyTorch are you using? I can provide a pre-compiled kaldifeat wheel for you.

Thank you so much for this
Python version 3.11.4
Pytorch version 2.0.1+cu117

Does a CPU version of kaldifeat work for you?
By the way, sherpa-onnx depends on neither PyTorch nor kaldifeat.

Yes CPU version would be great
I am using sherpa-onnx now, it works great!

You can find pre-compiled wheels of kaldifeat for windows at https://csukuangfj.github.io/kaldifeat/installation/from_wheels.html#windows-cpu

If you are using sherpa-onnx, then I think you don't need to install kaldifeat any longer.


Prefix for mesh not conform to OBO context

The prefix should be mesh instead of MESH. For reference, OBO Context at Bioregistry.
SSSOM-API can't expand or compress properly when it retrieves the' mesh' mappings, resulting in None.

Related to #29

The prefix does not have to conform to obo context if it is included in the mappings. No curie_map in there?

SSSOM-API only depends on the OBO Context.

I'm a little confused. The prefix mesh is a as expected (as per your first statement). @matentzn why am I tagged here?

Yes, those were added by me via #44

Yes, these new mappings are good. One more reason to update the others. I updated the issue to be more specific.

I moved this discussion here for now: https://github.com/mapping-commons/sssom-api/issues/85
@anitacaron we can attack this from two sides, but it must be from both:

Weaken the assumption of obo context (issue above)
Standardising as much as possible towards it.

@glass-ships can you make sure that all curies you output in gene mappings and chebi mesh are standardised uses curies.Converter.standardize() using the obo_converter()?

sure, I can try.


ecasound: unbreak

Motivation for this change
https://hydra.nixos.org/job/nixpkgs/trunk/ecasound.x86_64-linux
Things done

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

[ ] 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"
[ ] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Ensured that relevant documentation is up to date
[ ] Fits CONTRIBUTING.md.

Result of nixpkgs-review pr 117861 run on x86_64-darwin 1

Result of nixpkgs-review pr 117861 at dca6abeb run on x86_64-linux 1

2 packages skipped due to time constraints:

yuzu-ea
yuzu-mainline

2 packages built successfully:

ecasound
ssr

3 suggestions:

warning: maintainers-missing
Package does not have a maintainer. Consider adding yourself?
Near pkgs/applications/audio/ecasound/default.nix:61:3:
   |
61 |     description = "Software package designed for multitrack audio processing";
   |   ^

warning: unclear-gpl
gpl2 is a deprecated license, please check if project uses gpl2Plus or gpl2Only and change meta.license accordingly.
Near pkgs/applications/audio/ecasound/default.nix:63:5:
   |
63 |     homepage = "http://nosignal.fi/ecasound/";
   |     ^

warning: unclear-gpl
lgpl21 is a deprecated license, please check if project uses lgpl21Plus or lgpl21Only and change meta.license accordingly.
Near pkgs/applications/audio/ecasound/default.nix:63:5:
   |
63 |     homepage = "http://nosignal.fi/ecasound/";
   |     ^


Use dict instead of Jinja?

https://github.com/carlniger/acipdt/blob/b6da76c60c86419497188b76595d317549377d2e/acipdt/acipdt.py#L92
Hi,
I was scrolling through the code and thought to myself: "Why isn't he just using a dict in the first place?"
    def login(self):
        # Load login json payload
        payload = '''
        {{
            "aaaUser": {{
                "attributes": {{
                    "name": "{user}",
                    "pwd": "{pword}"
                }}
            }}
        }}
        '''.format(user=self.user, pword=self.pword)  # This creates a string
        payload = json.loads(payload,  # This parses the string to a dict
                             object_pairs_hook=collections.OrderedDict)

Is there any specific reason for this, instead of using this:
def login(self):
    # Load login json payload
    payload = dict()
    payload = {
        'aaaUser': {
            'attributes': {
                'name': self.user,
                'pwd': self.pword
            }
        }
    }
    # And so on...

Just wondering :)

Hello! I did use dicts to start with, but prior to 3.7(or maybe 3.6?) dicts were unordered so sometimes the  payload would get all screwed up and break things. Also, keeping all the Jinja stuff out of the main code helps with readability IMO. I suppose you could easily enough use a dict on modern Python, but at this point there is no going back :)


Fixed linting issues

Set name of 2 types back to the new standard
Issue
Link your PR to an issue
Fixes #___
Description
Please describe your pull request.
Testing
Describe the best way to test or validate your PR.

I work with Keith on ElectionGuard and wanted to get your linting fixes for you.  This should help with the pushing to the main branch.


Don't switch the login button to the logout.

Hi, I don't want to see the logut button after I login. Is there a way to not show the logout button after login?

You can use the login state to do a `v-if="loggedIn" on the button and that will hide it when the user is logged in.

Hi @adi518,
it is not clear, can you please provide an example?
Thanks!


Memory Usage Increase /w rxqt::run_loop

Hey tetsurom!  Thanks again for the library. 8)
I've boiled down what I think its some interaction that is leading to a consistent memory increase when using rxqt_run_loop.  Might be something else at play, but hopefully will get some clarity with discussion.
My testing setup is like this:

New GUI project /w stock main window
Add a rxqt::run_loop
One subject
MainWindow subscribes to subject
One QThread
Background QThread continuously fires the subject at 25ms interval

What I've noticed is that if MainWindow's subscription to the subject adds observe_on(rxqt_run_loop.observe_on_run_loop()) it leads to a slow and steady memory usage increase over time (with seemingly no upper limit?).  Over like 10-15 minutes it'll go up a megabyte or so, and just keep at that rate.
However, if that observe_on() instead uses rxcpp::observe_on_new_thread() or rxcpp::observe_on_event_loop() the memory usage is stable /w no increase over time.

Here's my source:
#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QMainWindow>

#include <rx.hpp>
#include <rxqt.hpp>

namespace Ui {
class MainWindow;
}

class MainWindow : public QMainWindow
{
  Q_OBJECT

public:
  struct PublishThread : public QThread
  {
    PublishThread()
    : stop_(false)
    {
    }
    void run();
    rxcpp::subjects::subject<bool> subj_;
    bool stop_;
  };

  explicit MainWindow(QWidget *parent = nullptr);
  ~MainWindow();
  void closeEvent(QCloseEvent *event);

private:
  Ui::MainWindow *ui;
  rxqt::run_loop rxqt_run_loop_;
  PublishThread thread_;
};

#endif // MAINWINDOW_H

#include "mainwindow.h"
#include "ui_mainwindow.h"

#include <QCloseEvent>

MainWindow::MainWindow(QWidget *parent) :
QMainWindow(parent),
ui(new Ui::MainWindow)
{
  ui->setupUi(this);

  thread_.subj_.get_observable()

    // No (or way less?) growth when observed on new thread
//    .observe_on(rxcpp::observe_on_new_thread())

    // No (or way less?) growth when observed on event loop
//    .observe_on(rxcpp::observe_on_event_loop())

    // Mem growth when observed on rxqt run loop
    .observe_on(rxqt_run_loop_.observe_on_run_loop())

    .subscribe([](bool p) {
      // Do some random work
      if (p) {
        p = !p;
      }
    });

  thread_.start();
}

MainWindow::~MainWindow()
{
  delete ui;
}

void MainWindow::PublishThread::run()
{
  while(!stop_) {
    subj_.get_subscriber().on_next(true);
    msleep(25);
  }
  QApplication::quit();
}

void MainWindow::closeEvent(QCloseEvent *event) {
  thread_.stop_ = true;
  event->ignore();
}

This very well could be me misunderstanding some C++ fundamentals, but I feel like I've simplified the scenario sufficiently to where I feel like the cause has something to do with the rxqt run loop.
Let me know what you think.
Thanks for your time!  8)

Out of curiosity, I rolled back the latest commit f5373b65cf4e8594725824f8cbe9ef21f562f9b9
Just to see if the actual implementation change to QSignalMapper as the way of swapping to another thread was the cause.
I did not see the same memory growth, which leads me to one of two conclusions:

It's caused somehow by the usage of QSignalMapper.  (They do mention it's depreciated, so maybe it's not behaved?)
The growth is caused by swapping threads, and since the old way potentially wasn't doing that properly, maybe it's just coincidentally not causing the growth because it's not actually getting the job done.

Heya.  I believe I have fixed the issue.
https://stackoverflow.com/questions/21646467/how-to-execute-a-functor-or-a-lambda-in-a-given-thread-in-qt-gcd-style
I followed this page's advice, and utilized QMetaObject::invokeMethod, passing in the rxqt_loop itself, and then just using a basic lambda to call the timer's start method.
This let me remove the QSignalMapper, which seemed to remove the memory usage growth.
Unfortunately I don't know if I can actually post the code, as I developed the fix at work... but hopefully you can follow that same post and get to the same conclusions.

I also made an upgrade/fix for the same code location.  the timer's start wasn't taking into account the fact that there might be an earlier wakeup registered.  The logic that ran if it was on the same thread did that check, but not the side that ran if it wasn't on the same thread.  I changed the parameter to be passed in the when, rather than the milliseconds, and utilized it inside the lambda call to calculate the possibility of an earlier wakeup.

Hi Noggog, thank you very much for using rxqt in production!
And sorry for the late reply.
Yes, I know QMetaObject::invokeMethod can take a lambda, but unfortunately that overload was introduced in Qt 5.10.
When I introduced that hacky QSignalMapper, even it was already deprecated, I tried to support older Qt versions, at least while they were supported by The Qt Company.

No problem, I know how it can be. 8)
Ah yeah, I wasn't considering any backwards compatibility concepts.  Do whatever feels best to you on that front.

Hi Noggog,
I have removed the hacky use of QSignalMapper.
I'm not sure it also fixes your problem but I'm happy if you let me know the result!

Good to hear!  Will play around with it soon and report back


Style/AndOr Cop changes output

Then(/^all reason for visit results should contain "(.*?)"$/) do |value|
  START_RESULTS_INDEX = 1
  MAX_RESULTS_INDEX = 200

  for i in START_RESULTS_INDEX..MAX_RESULTS_INDEX
    begin
      # Table sometimes contains empty rows, making this check necessary
      # in addition to catching the exceptions below.
      # binding.pry
      txt = @current_page.reason_for_visit_results_element[i].text.downcase
      if txt != "" and !txt.include? "diag code"
        txt.should include value
      else
        if i == START_RESULTS_INDEX
          fail 'No results in rfv cart.'
        end
        break
      end
    rescue Watir::Exception::UnknownObjectException, NoMethodError
      if i == START_RESULTS_INDEX
        raise 'No results in rfv cart.'
      else
        # At the end of the procedures list
        break
      end
    end
  end
end

results in this:
λ ~\Docu\reco\tool\wati\trunk rubocop --auto-correct
Inspecting 117 files
..................C..................................................................................................

Offenses:

features/step_definitions/procedures_steps.rb:86:20: C: Use && instead of and.
      if txt != "" and !txt.include? "diag code"
                   ^^^

117 files inspected, 1 offense detected

As soon as I change the and to && I get this output instead:
λ ~\Docu\reco\tool\wati\trunk rubocop --auto-correct
Inspecting 117 files
..................E..................................................................................................

Offenses:

features/step_definitions/procedures_steps.rb:86:37: E: unexpected token tSTRING
      if txt != "" && !txt.include? "diag code"
                                    ^^^^^^^^^^^
features/step_definitions/procedures_steps.rb:88:7: W: else without rescue is useless
      else
      ^^^^
features/step_definitions/procedures_steps.rb:94:5: E: unexpected token kRESCUE
    rescue Watir::Exception::UnknownObjectException, NoMethodError
    ^^^^^^
features/step_definitions/procedures_steps.rb:94:67: E: unexpected token tNL
    rescue Watir::Exception::UnknownObjectException, NoMethodError

features/step_definitions/procedures_steps.rb:103:1: E: unexpected token kEND
end
^^^

117 files inspected, 5 offenses detected

Changing the line to this removed solved the problem for me, but it still seems like a bug.
if !(txt == "" || txt.include?("diag code")) # De Morgan's Law

I had a chance to test this out and got the same result when I changed if txt != '' and !txt.include? 'diag code' to if txt != '' && !txt.include? 'diag code'. It is important to note that in my case RuboCop did not auto correct the source code to the invalid syntax.
Running ruby's syntax check with ruby -c produces the same warning on this code.
test.rb:13: syntax error, unexpected tSTRING_BEG, expecting keyword_then or ';' or '\n'
      if txt != '' && !txt.include? 'diag code'
                                     ^
test.rb:18: warning: else without rescue is useless
test.rb:19: syntax error, unexpected keyword_rescue, expecting keyword_end
    rescue Watir::Exception::UnknownObjectException, NoMethodError
          ^
test.rb:19: syntax error, unexpected '\n', expecting '='
test.rb:28: syntax error, unexpected keyword_end, expecting end-of-input

I am not sure of the exact reason why, but it appears as though ruby is confused about what is a part of the if statement. It seems like ruby is expecting the if statement to end at !txt.include?. It seems like this is one of those times in ruby where you need parenthesis.
Wrapping the entire if statement in parentheses did not fix the problem if (txt != '' && !txt.include? 'diag code')
It seems that the correct syntax for this is if txt != '' && !txt.include?('diag code') or what you included above.

I didn't notice it before, but it appears that there is a test case for this exact example. RuboCop purposefully does not auto correct this code because it knows that it could produce issues.
    it 'leaves *or* as is if auto-correction changes the meaning' do
      src = "x = y or teststring.include? 'b'"
      new_source = autocorrect_source(cop, src)
      expect(new_source).to eq(src)
    end

Precedence, operator precedence.
The Ruby parser is a complex and fearsome beast. In this case, && is binding tighter (higher precedence) than the method call txt.include? binds to its argument "diag code". So it's like you wrote:
((txt != "") && !txt.include?) "diag code"

When you look at it like that, it should be obvious why it complains about "unexpected token tSTRING".
The question is how to make Style/AndOr smart enough to understand the precedence of all the surrounding expressions.

I was under the impression that we test the entire AST of the file in question after we do such changes which is both simple and effective. @jonas054 correct me if I'm wrong (don't have time to check the code itself).

You are right. That is exactly what it does. So AndOr no longer breaks the code in this issue.
However, it doesn't autocorrect it either. If AndOr was a little bit smarter, it could autocorrect this code. Expect a PR soon...

I have a fix for this one ready, but am waiting for some other PRs to go through first.

With PR #2378, Style/AndOr will be able to autocorrect this code without breaking anything.

Very nice. Thank you!


Next-Auth Integration Design Doc

Introduction
Previously, we completed our discord integration with c0d3.com. Users are prompted to connect to discord after they log in.
Looking at the previous architecture, we notice quite a few moving parts and a lot of code, which would all be eliminated if we used the reputable library, next-auth, designed to help with OAuth integrations.
By migrating to next-auth, we would simplify our codebase and pave the way for other partner integrations like Github.
The goal of this document would be to document all the steps necessary to successfully implement next-auth. By the completion of this project (roughly in implementation order)

Login/Signup with c0d3 would be replaced with next-auth.
Users would continue to be prompted for "connecting to discord" if they haven't already after they log in. The architecture would be replaced by next-auth.
Users with a connected discord account would be able to sign in with discord.

By the end of this integration, our authentication logic would be simplified by Next-Auth, and for the future, it should be easy to add/connect other platforms like Google, Facebook, Github, etc.
Important: After this change, engineers would need to use useSession for React components and getSession for non-react components such as getServerSideProps.
Far graphql resolvers, we would continue to use req.user.
Drawbacks
next-auth doesn't support sending data in the response body, so it won't work well with our CLI as the CLI requires the cliToken that's sent with the login resolver
Solution: Use next-auth API for web, keep GraphQL login resolver for CLI
Architecture & Research
The diagram below shows the general flow of 3 cases:

C0D3's username / pw sign in
Connecting to Discord in a logged in user
Signing in to c0d3.com using Discord account

Below the diagram, documentation links are provided

Relevant documentation

Client Signin allows us to pass in a Provider we want to use as well as a redirection url for post signin.

SignIn Callback - Used to determine what kind of signin request it is. provider is passed in as an argument.

Note, the req object is accessed via the middleware closure. Sample code:
export default (req, res) => NextAuth(req, res, {
  providers: [
    DiscordProvider({
      clientId: process.env.DISCORD_CLIENT_ID,
      clientSecret: process.env.DISCORD_CLIENT_SECRET
    })
  ],
  callbacks: {
    async signIn({ account }) {
      const session = await getSession({ req })
      return true
    }
  },
})

For connecting to discord, getSession is used to retrieve the currently logged in c0d3 user.

Action Items
This step lists out what needs to be done for the following 3 scenarios:

Replace C0D3's Login/Signup with next-auth
Replace current "connecting to discord" logic with next-auth
Allow users with a connected discord account to sign in with discord
Deprecate the email to set a password on signup

Replacing C0D3's Login and Signup implementation
The current implementation uses GraphQL resolvers to handle login and signup
We need to do the following

Add Credentials Provider as a provider to next-auth middleware

Login
Current Flow - https://github.com/garageScript/c0d3-app/wiki/A-request-journey#sign-in
Changes

When user clicks login, we would run Next Auth's signin method with a redirection to /curriculum. By using the redirect: false option we could display the error if needed or redirect to /curriculum.
The request is sent to the SignIn Callback, then the authorize callback

Sign up
Current Flow - https://github.com/garageScript/c0d3-app/wiki/A-request-journey#sign-up
With NextAuth

SignIn Callback will take a password argument, hash it, and finally create a user account without the need to redirect to. /confirm/[token] page. SignupSuccess component will be removed from Signup page and upon the success of user registration, the user will be redirected to /curriculum.
The request is sent to the SignIn Callback, then the authorize callback. In the callbacks, we could differentiate between signin and signup via the form fields. (ie. signin would not have name property)

Changes

Client: Deprecate our login user method and signup user method and use next auth's sign in method
Client: Add password field for the form in signup page - Deprecates confirm page
Server: Move our login & signup validation logic to the auth request in the authorize function. Note We would need to keep the login code pertaining to our CLI login.

Reset/Change password
Create a custm next-auth credentials provider that once called, reset/set the user password..
Example code:
  CredentialsProvider({
    // Must be unique. Use like `signIn('confirm-token')`
    id: 'confirm-token',
    name: 'Verify token',
    credentials: {
      token: { label: 'Token', type: 'text' },
      password: { label: 'Password', type: 'password' }
    },
    authorize: authorizeEmailVerification
  })

Steps

It'll take the user password and token
Verify they're valid and proceed with calling changePw with the password and token
Lookup the user data from the db and return it so the session is set and the user can login

Session
Update the session callback to set the session.user as the user from the database. This callback runs every time we call getSession or useSession. The reason for this is because the data in the session isn't in sync with what gets updated in the database. If the user connected to discord, the session won't have this info.
Example code:
// jwt callback is first called then session callback
export const jwt = async ({
  token,
  user,
  account
}: {
  token: JWT
  user?: User
  account?: Account
}) => {
  // For Discord. Will only run once.
  if (get(account, 'type') === 'oauth' && user) {
    const dbUser = await prisma.user.findFirst({
      where: {
        discordId: toString(user.id)
      }
    })

    token.user = dbUser
  }

  // For Credentials or Login/Signup. Will only run once
  if (get(account, 'type') === 'credentials') {
    token.user = user
  }

  return token
}

export const session = async ({
  session,
  token
}: {
  session: Session
  token: JWT
}) => {
  // Will run for each getSession or useSession call
  const dbUser = await prisma.user.findFirst({
    where: {
      id: toNumber((token.user as User).id)
    }
  })

  session.user = dbUser as DefaultSession['user']
  return session
}

Client: Access the session by calling useSession
Server: Populate the req.user with the session in getSession, in the user middleware

Replacing current discord integration
Info: DTD refers to Discord Tokens which are discordAccessToken, discordRefreshToken, and discordAccessTokenExpires
Current Implementation - Connecting to Discord
We are implementing the OAuth flow ourselves in the current discord implementation. Most of the logic is in discord auth file.
Next Auth Connect to Discord and Sign In

Client - Deprecate ConnectToDiscord action button to call next-auth signIn method with the provider as Discord (same as login method above)

login with discord should have a callback url of /curriculum

Server - In the sign in callback, we should check the previous session by calling getSession to figure out if the request is for connecting or log in. If there's a session, it's connect to discord request.

connect to discord - We call getSession to get the currently logged-in user, and update the user's table with DTD and user's discord ID. Then we return /discord/success to cancel the auth flow so the session won't be created.
login with discord - We look up the user's table by discordId column and see if there is a match. If so, we return true.

If no user is found, we return a redirection URL: /discord/404user with a component telling the user that they cannot use sign-in with discord feature because they need a c0d3.com account first. In this component, there would be 2 prompts: one for login and connect your discord account and one for signing up to create a c0d3.com account.

Server - In the session callback check if the callback url is /curriclum, if so, it means request is login with discord -> Get the user info from the database, add it to the session object, and return the session object. Else, just return true

Sample code
callbacks: {
  async signIn({ account, user }) {
    const { provider } = account

    if (provider === 'discord') {
      const session = (await getSession({ req })) as Session
      const { access_token, expires_at, refresh_token } = account

      // Connect to discord
      if (session?.user) {
        await updateRefreshandAccessTokens(
          session.user.id,
          user.id,
          refresh_token!,
          access_token!,
          new Date(expires_at! * 1000)
        )

        // Cancel auth flow. Session won't be created
        return '/discord/success'
      }

      // Sign-in to discord
      const userInfo = await prisma.user.findFirst({
        where: {
          discordId: user.id
        }
      })

      if (userInfo) return true
      return '/discord/user404'
    }

    return true
  },
  async session({ session, token }) {
    const context = { req, res } as Context
    const callbackUrl = new URL(req.cookies['next-auth.callback-url'])
    let user = token.user as object

    // /curriculum means it's sign-in to discord request
    if (callbackUrl.pathname === '/curriculum') {
      const userData = await prisma.user.findFirst({
        where: {
          discordId: token.sub
        }
      })

      user = await populateUser({ id: userData?.id! }, req, context)
    }

    session = { ...session, ...user }
    return session
  },
  async jwt({ token, user }) {
    if (user) {
      token.user = user
    }
    return token
  }
}

Note: expires_at is the timestamp of when the access token will expire in seconds. new Date(1647029999) is ~March 12
Login with discord issue
When populating our req.user object in our user middleware, we would be getting the information by calling getSession. There would be 2 scenarios:

getSession() returns c0d3 credentials - all good!
getSession() returns discord credentials (because of discord login). In this scenario, we need to query the user table for the corresponding c0d3 user and set req.user to that.

These scenarios are less likely to occur because we set the session to the corresponding c0d3 user from the user table
References

Initializing next-auth
next-auth OAuth
next-auth credentials
next-auth callbacks

Completed

Completed


log traceback when crashing during startup

This makes it easier to debug problems with pydantic models, typehints etc.

good idea, thanks!


Database error when running test suite

Hello! I am trying to run the test suite and I think I did everything in the README but I'm still getting 15 tests failing with the same error.
[FAIL. Reason: backend: failed while inspecting: Database error: failed to get account for 0x1f9090aaE28b8a3dCeaDf281B0F12828e676c326: (code: -32603, message: failed to forward request, data: None)] testListingsCustom() (gas: 0)
I did install aave-cli and copy the .env and also forge and yarn is installed correctly. Is there anything I am missing?
Thank you!

@Jrigada database error is related to your rpc not being able to fetch fresh data(usually public rpcs only support a certain amount of blocks in the past).


pysqlite3-binary still using old SQLite version

Hi. Want to use SQLite v3.38.
Installed library and expected there'll be the new version of SQLite. But
pipenv install pysqlite3-binary
"version": "==0.4.7.post5"

Am I missing something?

I came across this cause I thought I had a similar issue.
Digging a bit more I realized I had mixed up which environment I has pysqlite3 and which environment I had pysqlite3-binary
Once I opened the python shell in the correct environment - it worked fine :+1:


Suggestion: gradle.xml be moved to .gitignore

Summary:
gradle.xml should be moved to .gitignore because I think it must not be tracked by git as it gets changed when we build the project.

SGTM.

(Sorry - sounds good to me - I meant to say). You are welcome to make a PR for precisely this change if you wish. Otherwise I will.

@jaydeetay should I proceed with the PR ?

I was going to leave it to @utkarsh530 since he filed the bug. Let's give him a chance to respond.

Sure

@jaydeetay okay I'm fixing it.


chore: add git config details

I'm hoping this will resolve the pipeline error seen here https://github.com/iambumblehead/react-dropdown-now/runs/1336547909
info => Output directory: /home/runner/work/react-dropdown-now/react-dropdown-now/docs
Author identity unknown

*** Please tell me who you are.

Run

  git config --global user.email<EMAIL_ADDRESS>  git config --global user.name "Your Name"

to set your account's default identity.
Omit --global to set the identity only in this repository.

fatal: empty ident name (for<EMAIL_ADDRESS>not allowed

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR<EMAIL_ADDRESS>deploy: `npm run build-storybook && gh-pages -d docs -m 'chore: deploy docs'`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the<EMAIL_ADDRESS>deploy script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/runner/.npm/_logs/2020-10-31T18_25_58_485Z-debug.log
Error: Process completed with exit code 1.

I'll test in a bit

feel free to use your email there if you prefer. I used mine there just to get things going.

oh cool you've made it so that isn't needed -- that looks awesome

:+1:

:+1:

ok i think its done now @iambumblehead


form-choice__label doesn't wrap in IE

Text in <label class="form-choice__label">...</label> breaks through the width set on a layout__item, found in IE10:

This might be a possible fix:
https://github.com/philipwalton/flexbugs#2-column-flex-items-set-to-align-itemscenter-overflow-their-container

I'll already tried it with max-width: 100%;, but that won't change a thing, even when i've set it to 10px. The other attributes are already there (box-sizing: border-box + padding on the container).

It look like we can only solve this by adding a browser hack to target IE10. The problem is that this is not possible without javascript. CSS browser hacks like:
@media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) { 	.selector { property:value; } }
Will also target IE11 where the problem doesn't occur. We could also stop using inline-flex but that's a step back in my opinion.
I suggest we leave this to the developer, if you have long radio / checkbox labels and you want to support IE10 and below you must insert a browser hack in your code.
For options see: https://gist.github.com/vidaaudrey/c16774076391d09e7ec7dbb7ed7a3189

Another problem found caused by the styling from this label.

This is solved if the :before has display: inline-block instead of block. And the label shouldn't have display: inline-flex..

Ok if more problems occur with using flexbox we should drop it and go for the safer option of using display inline-block. There are not many advantages of using inline-flex in this situation anyway.

Let't check if this problem still occurs and if PR should be merged. IE10 support is no longer required but it should also wrapping when other html elements are used it checkbox label.


Make client_secret optional since it's not always required

Why:
Apps using the device flow does not have a client secret and can generate new access tokens using the refresh_token grant without this parameter in the request.
Closes:

What's being changed (if available, include any code snippets, screenshots, or gifs):
Example request:
requests.post(
    "https://github.com/login/oauth/access_token",
    data={
        "client_id": "<YOUR CLIENT ID>",
        "refresh_token": refresh_token,
        "grant_type": "refresh_token",
    },
)

Check off the following:

[ ] I have reviewed my changes in staging, available via the View deployment link in this PR's timeline (this link will be available after opening the PR).

For content changes, you will also see an automatically generated comment with links directly to pages you've modified. The comment won't appear if your PR only edits files in the data directory.

[ ] For content changes, I have completed the self-review checklist.

@anderssonjohan Thanks so much for opening a PR! I'll get this triaged for review ✨


Windows on RKE2 for 2.6.0 [Meta Issue]

Here is the PR for k3s: https://github.com/k3s-io/k3s/pull/3411

For clarity, tracking on the UI work is now done in https://github.com/rancher/dashboard/issues/3222 since we consolidated the work into one ticket.

https://github.com/rancher/rke2/issues/1289
https://github.com/rancher/rke2/issues/1290

Instructions for QA can be found below:
Windows Agent (Worker) Node Installation
Invoke-WebRequest ((New-Object System.Net.WebClient).DownloadString('https://github.com/rancher/rke2/blob/release-1.21/install.ps1'))
./install.ps1

This will install the rke2.exe binary onto your machine.
Additional configuration options can be found here

What info do you need @slickwarren?

Waiting on further instruction details from @rosskirkpat (there was a missing step in the first set of instructions)

Instructions for 3 out of the 4 scenarios can be found in the SUSE Confluence https://confluence.suse.com/x/u4EMLw

I was able to test the following using v1.21.3-rc5+rke2r1/rke2-windows-amd64.exe:

deploy a linux rke2 cluster
deploy windows + install RKE2 windows binary using OS 20H2

Other tests are still in progress

Only known blocker for Windows on RKE2 has been moved into QA testing https://github.com/rancher/rancher/issues/33832

blocked https://github.com/rancher/rancher/issues/34408 , https://github.com/rancher/dashboard/issues/3990

Currently, Windows for RKE2 custom clusters is close to complete so let's close this epic and track individual issues going forward.


Overview No Longer Working

The overview page is not showing data, but the reddit and Markets sections are accurate.

Thanks, noticed this last night. I'll get it fixed by tomorrow!

Awesome - thanks for this nice tool

Fixed in 7805e506a71a2dcf661b4e16f7fdeac8e4fcfa37
A new release (v1.3.0) has been pushed to the Chrome Store and should update within 24 hours for you! It also includes some new features :)


Prev8-chrisda to Main

Docs Build status updates of commit 61c3978:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

exchange/docs-conceptual/exchange-online-powershell-v2.md
:white_check_mark:Succeeded
View (exchange-ps)

exchange/exchange-ps/exchange/Connect-ExchangeOnline.md
:white_check_mark:Succeeded
View (exchange-ps)

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel


Add a new Article

Add C# 9.0 Top-Level Statements Article of Thomas Claudius Huber. It's a new feature introduced in C# 9.0.
C# 9.0 released with .Net 5.0!

Hi @eslamisepehr,
Thanks for your sharing,
I've changed my table of content a little.
Please add your link to C# 9 section.
Thanks


refactor build process to use esbuild and API Extractor

Summary of changes:

tsdx build is replaced by build scripts for various targets using esbuild

entrypoint
description

oidc-client-ts.cjs
CommonJS target, useful for Node-based environments such as unit tests using Jest

oidc-client-ts.mjs
ESM bundle - bundlers will prefer this export, and browsers that support  ESM can import this directly from a CDN

oidc-client-ts.js
IIFE bundle that should be acceptable for most browser environments. The API is exported under a global oidc namespace

oidc-client-ts.min.js
minified version of the above

all of the above are compatible with environments implementing ES2019

as it is becoming the norm, IE compatibility is still feasible via bundlers that transpile and polyfill missing web features.

@microsoft/api-extractor is used for rolling up a .d.ts bundle

additionally, incremental TS compilation is now enabled for drastically faster builds. CI will need to cache *.tsbuildinfo files to take advantage of this.

disabled type-checking in the ts-jest process in favor of plain incremental compilation with tsc

since the build process doesn't use tsc (and therefore requires "isolatedModules": true" in tsconfig), we don't need tsc for unit tests either.

nice work, regarding etc/oidc-client-ts.api.md, our first plan was to generate the API doc using typedoc , the API Extractor looks really promising and easy to use. The docusaurus part of the library is not finished yet, but i guess the correct place for the oidc-client-ts.api.md file should be inside the ./docs folder. The idea is to move API related stuff from ./docs/intro.md to the source code and only add add link to the ./docs/oidc-client-ts.api.md file.

Ok I removed the commit hook for API extractor. I've intentionally left the building failing for now just to show what CI looks like when the public API changes.

really nice work, thanks for the contribution!


Update Readme doc links to the latest doc links.

In the react native repo readme files, it is still using the old gitbook link, we need to update that to the latest developer.com links.
This applies to all the react native scp-prefix repo.
Expected Behaviour
Actual Behaviour
Reproduce Scenario (including but not limited to)
Steps to Reproduce
Platform and Version
Sample Code that illustrates the problem
Logs taken while reproducing problem

All ACP react native GitHub repos are updated to the latest doc links.


Question about RobotCar data processing

Hi,
Thanks for your great work!
In your work, you used the 3D point cloud from OxfordRobotCar, which has been pre-processed by PointNetVLAD work, and the 2D camera image. These two data are obtained by sensors in different places on the car, and they can be transformed by extrinsic data. If I want to use raw point clouds from a LiDAR for place recognition or related purposes, such as Oxford Radar RobotCar (https://oxford-robotics-institute.github.io/radar-robotcar-dataset/).  Do I need to first transfer the point cloud coordinate to the camera by extrinsic data?

Hi, I got it. very thanks for your reply.


scripts: add genproto.sh

run ./scripts/genproto.sh will generate proto.

I hope we can remove the generated gopath by default.
Other than that, LGTM.

all comments are addressed and remove the dir by default.


Add --spawn and --spawn-to-controller options

Note that the tests are incorrect, I'm not sure what valid arguments to use, and what hoping maybe CI will show me what the expected transaction output should look like.

@chmllr Am I right in understanding that --spawn-to-controller $PRINCIPAL will transmit the funds to the account (at index 0, in keysmith terms) owned by $PRINCIPAL?

@chmllr Am I right in understanding that --spawn-to-controller $PRINCIPAL will transmit the funds to the account (at index 0, in keysmith terms) owned by $PRINCIPAL?

John, I do not know for sure, you would need to read the governance canister code. Maybe we should not introduce spawning to other controller just yet, if we did not test it and the use case is not exactly clear?

@chmllr I was adding it because it's a command accepted by the governance canister. I wonder how much of an "official" tool quill will become, and whether we should be offering a complete interface to Governance or not.

@chmllr I was adding it because it's a command accepted by the governance canister. I wonder how much of an "official" tool quill will become, and whether we should be offering a complete interface to Governance or not.

I see. I think quill should always be community driven. I don't think there is pressure to support everything what the governance API offers. So far I was only adding the bare minimum of the needed feature set, which I also tested myself. I think when we add new features we better make sure they really work as intended and are properly tested on a testnet or with real ICP. Although we're not liable, I see no good reasons to walk on thin ice.

@chmllr Sounds good, I'll offer only --spawn for now then.

For the record I was able to use this to spawn rewards yesterday!


Error in SHACL Dialog

https://spex.zazuko.com/#/?url=https://lindas.admin.ch/query&graph=https://lindas.admin.ch/egad/ric-o&forceIntrospection=false
SHACL Button -> Dialog Choose Turtle drop this intermittent error.
Uncaught (in promise) Error: Invliad concise-term string, prefixes are not allowed to start with an underscore: '_'
    at Object.c1_node (main.js:1394:34)
    at Object.c1 (main.js:1380:28)
    at o._encode_objects (main.js:317:34)
    at o._serialize_collection_object (main.js:442:22)
    at o._encode_objects (main.js:341:40)
    at o._serialize_c3 (main.js:260:27)
    at o._serialize_c4 (main.js:244:20)
    at o.serialize (main.js:273:27)
    at o._transform (main.js:173:19)
    at o._read (_stream_transform.js:177:10)

duplicate of #69


Add windows to test matrix

Should add Windows to test matrix since some collaborators are using Windows

https://github.com/softwareengineerprogrammer/python-geophires-x-nrel/tree/windows-test-matrix


Formik Polaris validates only when touch

Formik by default only validates on touch, is the validateOnChange prop what you are looking for?
If this is a bug with formik-polaris specifically please feel free to reopen :smile:


Optimization of unused code in command parsing

Description of changes
Fixes #115 (code cleanup / improvement)
Prevents compiling unused chunks of code in command parsing.

PR accidentally tied to wrong branch. Closed, will be resubmitted correctly.


PyPlot breaking parallel computing

@everywhere using PyPlot with julia -p 4 returns
LoadError: On worker 3:
LoadError("/home/mi/asik/.julia/v0.4/PyPlot/src/PyPlot.jl",10,UndefVarError(:PyObject))
 in include_string at loading.jl:233
 in include_from_node1 at ./loading.jl:274
 in require at ./loading.jl:210
 in eval at ./sysimg.jl:14
 in anonymous at multi.jl:1350
 in anonymous at multi.jl:892
 in run_work_thunk at multi.jl:645
 [inlined code] from multi.jl:892
 in anonymous at task.jl:68
 in remotecall_fetch at multi.jl:731
 in remotecall_fetch at multi.jl:734
 in anonymous at multi.jl:1352

...and 2 other exceptions.

while loading In[1], in expression starting on line 1

 in sync_end at ./task.jl:414
 in anonymous at multi.jl:1361

Maybe try:
import PyPlot  # this already imports it everywhere
@everywhere using PyPlot

in case you are running into JuliaLang/julia#12381
Also, it's not going to work if you don't have Python installed in the same path on all the nodes.

I updated PyCall and PyPlot to master and can't reproduce. Thanks anyhow.


[FEATURE] Managed Node groups to use Launch template module

I believe this would be made redundant with v5 and we could probably close this out https://github.com/aws-ia/terraform-aws-eks-blueprints/milestone/1

Closing as #753  will cover this.


Compiler hang on this complicated example

TypeScript Version:  2.9.0-dev.20180510
NodeJS Version: 9.11.1
OS Version: Mac OS X 10.13.4

Search Terms: hangs
Code
It's a pretty involved and complicated code. Put it up as a gist for better readability.
https://gist.github.com/shivawu/22053a9292ac694bfc87c97ef3c652bf
Note the last line, if it's commented it out, it compiles just fine. That particular line hangs the compiler.
Expected behavior:
It should type check just fine.
Actual behavior:
The compiler hangs. Taking 100% CPU, memory keeps increasing non-stop.
Playground Link: I would skip that since the code would hang the browser tab :)
Related Issues: #7344, #23458 looks similar as well

I've managed to simplify this a bit -- but this example has a 'Maximum call stack size exceeded' error instead:
interface HCons<Next> {
    readonly next: Next;
}

type Unionize<T> = keyof T extends infer K
  ? K extends string & keyof T ? Record<K, T[K]> : never
  : never;
type KeysRec<T> = T extends Record<any, infer V>
  ? { 1: HKeys<V>, 0: number }[V extends Whatever ? '1' : '0']
  : never;
type HKeys<T> = KeysRec<Unionize<T>>;

type Normalize<T> = T extends HCons<infer N>
  ? { 1: Normalize<N>, 0: Shabadoo }[N extends Whatever ? '1' : '0']
  : never;

type JustNumber<H extends HCons<any>> = number;

type Keys<T> = JustNumber<Normalize<HKeys<T>>>;

With the compiler currently in master we don't hang on the original example (probably because of #26558), but it still takes 7.5s to type check and allocates over 700,000 types.
The core issue here is the pattern of using indexed access types to write self-referencing conditional types. It is a Turing Complete device (#14833) and along with that comes the halting problem. It is effectively impossible for us to know if evaluation of such types will ever terminate. For this reason I strongly discourage use of the pattern.


Keeping it DRY and switching to home_url()

Ticket: #568
Reviewer: @jarednova
Solution

In response to latest comments on #568, switching to home_url and keeping it dry by just moving it to the base init method

Coverage decreased (-0.004%) to 88.284% when pulling 50718ecbb75124649f51d62b0d85162afe12d2f0 on cjb-multsite-home-url into 68d3c57fd45c16e71a1128cbea16c39a149c1842 on master.

@connorjburton — I definitely like this approach but the problem I keep hitting with this is fucking WordPress. The problem you hit is when I want to get information on a site other than the one currently set as the "active" blog. And unless I'm a total homer, there's no way to get the home_url for a specific blog without switching to it first (unless you wanted to directly query the options table, which might actually not be the worst idea in the world).
That said, there might be a more efficient way to NRY based on where/how switch_to_blog is called (or doing something dirty like querying the table directly, which the WordPress gods seem to generally not recommend)

@jarednova @connorjburton I'm not sure if I should reply to this PR or use the issues. Hope I'm not cluttering this up, but I've got some input that might help.
First of all, I get your frustration about Multisite. I was running into exactly the same issues about a month ago. Multisite is a bit wonky when it comes to almost all functions, switching blogs and using global variables.
Timber\Site object
When looking at the code in Timber\Site, I realized a Timber\Site object should be able to get initialized for any blog, by passing the ID. Which is a great effort. This indeed poses the problem of actually getting this information. For example, retrieving the Home URL:

get_home_url($blogId) can be called, but -internally in WP- this just calls switch_to_blog() and restore_current_blog()
get_blog_details() is already called in Timber\Site and contains the home URL, but also just calls switch_to_blog() to get it (on a similar note, there also is WP_Site::get_instance() since 4.5.0 which might be less expensive but contains less information). get_blog_details() doesn't pass the URL through the home_url filter.
get_blog_option() could retrieve home URL (used for $site->description right now) but also just calls switch_to_blog()

It might be more efficient to call switch_to_blog() once on initialization and then retrieve all information by using regular single-site functions.
Getting information directly from the database
This would be less expensive, but retrieving this information without using built-in WordPress functions would not apply any filters. This would lead to less compatibility with existing code. For example, it would be quite hard to create a Multisite network which sites run on separate domains if the Home URL was guessed based on information from wp_blogs.
Hope this helps.

Coverage decreased (-0.004%) to 88.284% when pulling 31beaeebab227b4f2ed0b32f7e5fd7993d7034b4 on cjb-multsite-home-url into 1ec4a7158ef53cb5743cf48f13dfe9f947e09ebb on master.

Hi guys, thanks for feedback. Not sure what code changes need to happen here, we do already switch_to_blog and you can init Timber\Site manually if you need to get details of a blog that isn't the current one. Am I missing something here? Don't have too much experience with multi-site

Coverage decreased (-0.004%) to 88.25% when pulling 8868ed35911b9c13dc9e7baaf34555016ba904ef on cjb-multsite-home-url into 73cae9ddd03da8ff380885597d432b0f0a1d805c on master.

You can init Timber\Site manually, but the properties would not be correct. For example, in case of $site = new Timber\Site(2) and 2 being a subdirectory Multisite install (using cjb-multisite-home-url branch):

$site->url contains the URL of the main install (blog ID: 1)
$site->language contains the language of the main install
$site->language_attributes() would output the language attributes of the main install

There might be other properties which return the wrong value, but the most critical one would be the URL.
Since that is what this PR is about, the code changes for the would require home_url() to be called inside Site::init_as_multisite() between switch_to_blog($info->blog_id) and switch_to_blog($old_id). This means it would need to be set in both Site::init_as_multisite() and Site::init_as_singlesite().
DRY solution
A more dryer solution would be to have an init() method that initializes all the properties. On Multisite, it just calls init like this:
if (is_multisite()) {
  switch_to_blog($blogId);
  $this->init();
  restore_current_blog();
} else {
  $this->init();
}

But that would be an idealistic (and probably too simplistic) approach and changing it would probably have impact on backwards compat.

Coverage increased (+3.3%) to 91.795% when pulling 82f425909afd2c0afcd5896ed1c27146f7ec61c5 on cjb-multsite-home-url into cd63e8686155d9c4e082dd355ad6fac327867d04 on master.

I'm not so sure @haroldangenent — I implemented your suggestion and it seems to do the trick. I'd love a second set of eyes before I go ahead and merge. Lemme know if this checks out for you!

Coverage decreased (-1.3%) to 87.194% when pulling a7b8d566e97c2eda2195746d5bad4a2f14f578a3 on cjb-multsite-home-url into cd63e8686155d9c4e082dd355ad6fac327867d04 on master.

Coverage increased (+3.2%) to 91.694% when pulling 00355b0c1c9ac726ec5b2b3b5f6a094fd1af27a6 on cjb-multsite-home-url into beff7b8692be17697c0759b3dfffd4d6824e9780 on master.

Coverage increased (+3.2%) to 91.694% when pulling 07e6e24bd3efd1c6e1d10c2b8a383703f30737bc on cjb-multsite-home-url into beff7b8692be17697c0759b3dfffd4d6824e9780 on master.

Coverage decreased (-1.3%) to 87.194% when pulling 07e6e24bd3efd1c6e1d10c2b8a383703f30737bc on cjb-multsite-home-url into beff7b8692be17697c0759b3dfffd4d6824e9780 on master.


Create a Figure summarizing Coq-BB5 decider pipeline

Coq-BB5 decider pipeline goes as follows (source):
Definition decider_all :=
  (HaltDecider_list
(decider2::decider3::decider4::decider5::decider6::decider7::decider8::
decider9::decider10::
decider11::decider12::
decider13::decider14::
table_based_decider::
(NF_decider table_based_decider)::
nil)).

We can divide the pipeline in three groups.

Coq-implemented deciders applied to all machines (source) with set parameters:

Definition decider2 := (loop1_decider 130 (1::2::4::8::16::32::64::128::256::512::nil)).

Definition decider3 := (NGramCPS_decider_impl2 1 1 100).
Definition decider4 := (NGramCPS_decider_impl2 2 2 200).
Definition decider5 := (NGramCPS_decider_impl2 3 3 400).
Definition decider6 := (NGramCPS_decider_impl1 2 2 2 1600).
Definition decider7 := (NGramCPS_decider_impl1 2 3 3 1600).

Definition decider8 := (loop1_decider 4100 (1::2::4::8::16::32::64::128::256::512::1024::2048::4096::nil)).

Definition decider9 := (NGramCPS_decider_impl1 4 2 2 600).
Definition decider10 := (NGramCPS_decider_impl1 4 3 3 1600).
Definition decider11 := (NGramCPS_decider_impl1 6 2 2 3200).
Definition decider12 := (NGramCPS_decider_impl1 6 3 3 3200).
Definition decider13 := (NGramCPS_decider_impl1 8 2 2 1600).
Definition decider14 := (NGramCPS_decider_impl1 8 3 3 1600).

Hardcoded custom parameters for approx 8000 machines (source)

Definition tm_list :=
  tm_RWL::
  tm_NG0::tm_NG2::tm_NG3::tm_NG4::tm_NG5::tm_NG6::tm_NG7::tm_NG_ge8::
  tm_Ha::
  tm_Lp1::
  tm_NG_LRU::
  tm_NG0'::tm_RWL'::
  tm_DNV::tm_WA::

Sporadic TMs: 13 individually-proven Turing machines (source):

Definition tm_holdouts_13 :=
  Finned1::Finned2::Finned3::Finned4::Finned5::
  Skelet1::Skelet10::Skelet15::Skelet17::Skelet26::Skelet33::Skelet34::Skelet35::
  nil.

Which themselves can be grouped in different categories but I'm not really the expert here. Shawn Ligocki is one person to ask here.
We need to make a Figure that visually summarizes this pipeline.

A subtask is, in the above post, point 2, replace "approx 8000 machines" by the exact number of machines concerned.

Update on the plan of the figure:


Cannot save ssh fs config

Does this issue occur when all extensions are disabled?: Yes/No

VS Code Version: 1.8.2
OS Version: elementaryOS 7.1 Horus (ubuntu 22.04 jammy)

Steps to Reproduce:

create a new config for ssh fs
enter hostname (either IP or DNS name)
click on save (or press TAB until Save is highlighted and press ENTER)
nothing happens, config is not updated also (after vscode restart and reboot)

Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.82.2. Please try upgrading to the latest version and checking whether this issue remains.
Happy Coding!

Sorry, it's not clear what you are actually doing. A screenshot might help me understand what you're seeing.

This issue has been closed automatically because it needs more information and has not had recent activity. See also our issue reporting guidelines.
Happy Coding!


CircleCI Merge PRs Failing

The past few merge PR workflows have failed on CircleCI:
build finished with problems, 248 warnings.
Makefile:115: recipe for target 'html-scipyorg' failed
make: *** [html-scipyorg] Error 1
make: Leaving directory '/home/circleci/repo/doc'
Exited with code 2

The nitpicky mode + treat-warnings-as-errors seems to have become problematic. I assume it's due to a sphinx version bump making the nitpicking more accurate. The best thing to do would be to fix the warnings, but I'm not sure how easy that will be.


feat: add add_subdirectory compatible cmake config

This enables cmake in-tree builds with libextism such as with the cpp-sdk: https://github.com/extism/cpp-sdk/pull/7

Nice, tested and it works! I keep going back and forth on CMakeLists.txt in the root of the project vs in libextism but I think it makes sense like this since the documentation and everything is in that directory.

It's worth considering. I avoided it as the root directory has a lot already and didn't want to create confusion with the root Makefile.


Added marathi and hindi names for "My Drive"

Relates to #1015
Marathi

Hindi

Thank you very much @Rushi98. LGTM!


Fix build with latest OpenSearch

OpenSearch recently merged some code that cause buid failure for this
module, as spotted in #585.
This change the import to match the new one after
https://github.com/opensearch-project/OpenSearch/pull/9103

There are still quite a few failures like
D:\a\anomaly-detection\anomaly-detection\src\test\java\org\opensearch\ad\transport\ADStatsTests.java:167: error: cannot find symbol
String json = Strings.toString(builder);
^
symbol:   variable Strings
location: class ADStatsTests

I'll fix the rest of failures in another PR. Merge current PR.

There are still quite a few failures like
D:\a\anomaly-detection\anomaly-detection\src\test\java\org\opensearch\ad\transport\ADStatsTests.java:167: error: cannot find symbol String json = Strings.toString(builder); ^ symbol: variable Strings location: class ADStatsTests

Dang, I was running ./gradlew run instead of ./gradlew build.  It worked so I opened this PR before going to eat.
I think I see your errors now, I am having a look!