Add node script for token

I have added a node script so it will be easy to get tokens etc for this module. Please checkout the new installation guide and tell me if you got it working now @seattlecajun @dolanmiu @vivekpk007 @nitrogen73 @devmil @DaDonkDon @Albiorix2016 @atimon @NilSkilz @cowboysdude @adbang @sobrien556
Enjoy 🔥
Fixes #81

I am gonna try this :)

Browser does not open, I am on my Windows 10 machine!

im sorry im still fairly new to this, do i just download the new files on my windows pc and ftp them to the pi? i did a git pull but it did not update or add the new files you created

ok so i just merged the files and ran the first code and this is what it returns for me
` node src/aws-token-helper/aws-token-helper.js/home/pi/MagicMirror/modules/MMM-awesome-alexa/src/aws-token-helper/aws-token-helper.js:7

^
SyntaxError: Unexpected token <
at createScript (vm.js:56:10)
at Object.runInThisContext (vm.js:97:10)
at Module._compile (module.js:549:28)
at Object.Module._extensions..js (module.js:586:10)
at Module.load (module.js:494:32)
at tryModuleLoad (module.js:453:12)
at Function.Module._load (module.js:445:3)
at Module.runMain (module.js:611:10)
at run (bootstrap_node.js:387:7)
at startup (bootstrap_node.js:153:9)
`

@Albiorix2016 you need to npm install first

@dolanmiu thank you i just ran the install and i get this at the end. is that a problem?
npm WARN optional SKIPPING OPTIONAL DEPENDENCY<EMAIL_ADDRESS>(node_modules/chokidar/node_modules/fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for<EMAIL_ADDRESS>wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"}) npm WARN<EMAIL_ADDRESS>requires a peer of<EMAIL_ADDRESS>but none was installed.

@Albiorix2016 yup that looks normal, its not an ERROR, its a WARN, which isnt bad

Ok that seemed to have fixed that issue. Now i go through and enter the info the script asks for but it does not open a browser window

Awesome!
On Tue, Mar 6, 2018 at 12:50 PM, Henrik Raitasola<EMAIL_ADDRESS>wrote:

I have added a node script so it will be easy to get tokens etc for this
module. Please checkout the new installation guide and tell me if you got
it working now @seattlecajun https://github.com/seattlecajun @dolanmiu
https://github.com/dolanmiu @vivekpk007 https://github.com/vivekpk007
@nitrogen73 https://github.com/nitrogen73 @devmil
https://github.com/devmil @DaDonkDon https://github.com/dadonkdon
@Albiorix2016 https://github.com/albiorix2016 @atimon
https://github.com/atimon @NilSkilz https://github.com/nilskilz
@cowboysdude https://github.com/cowboysdude @adbang
https://github.com/adbang @sobrien556 https://github.com/sobrien556
Enjoy 🔥
You can view, comment on, or merge this pull request online at:
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82
Commit Summary

Disable eslint on this project because we are using tslint
Add base script
Ask user for clientId
Ask two questions
Ask for redirect uri
Remove logs
Remove encode
Remove variable which is not needed
Make script easier to understand
Remove old script
Add compiled code
Add refresh token helper
Update instructions
Remove old scripts

File Changes

M .vscode/settings.json
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-0
(3)
M docs/Installation.md
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-1
(26)
D help/bash-scripts/README.md
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-2
(9)
D help/bash-scripts/auth_code.sh
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-3
(15)
D help/bash-scripts/auth_code2.sh
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-4
(9)
M package-lock.json
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-5
(11)
M package.json
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-6
(2)
A src/aws-token-helper/aws-refreshToken-helper.js
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-7
(32)
A src/aws-token-helper/aws-refreshToken-helper.ts
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-8
(36)
A src/aws-token-helper/aws-token-helper.js
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-9
(43)
A src/aws-token-helper/aws-token-helper.ts
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-10
(47)
A src/aws-token-helper/common.js
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-11
(14)
A src/aws-token-helper/common.ts
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82/files#diff-12
(13)

Patch Links:

https://github.com/dolanmiu/MMM-awesome-alexa/pull/82.patch
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82.diff

—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82, or mute the
thread
https://github.com/notifications/unsubscribe-auth/AKgOEDpD5V0tM9aLJs614TWghQUc84Ztks5tbsxQgaJpZM4SfJh3
.

@Albiorix2016 Try to run those scripts on your own computer and not on Raspberry PI :D

Can we use async await on this? The nesting looks ugly

Hmm I am not sure if it is good idea because MagicMirror installs node v6 by default which does not have that feature yet Can we use async await on this? The nesting looks ugly

Also, i was thinking of adding it as an npm command:

This is a good idea!

@Albiorix2016 Did you run the script on OSX, Windows or what?

I have now update the branch with different opn library which should open browser. Make sure to pull the latest changes and run npm i before testing.

Lol there is avs-options.ts file too ;) Hmm are you sure? For example in audio-service.ts in url there is avs 🤔

Yeah, AWS should be AVS

@dolanmiu Fixed. Did you get your browser open now with opn library?

What directory do you run the "npm run avs-token-helper" command from?

Getting this everytime I run the command from the MMM-awesome-alexe root folder:
npm ERR! Linux 4.9.59-v7+
npm ERR! argv "/usr/bin/node" "/usr/bin/npm" "run" "avs-token-helper"
npm ERR! node v6.13.1
npm ERR! npm  v3.10.10
npm ERR! missing script: avs-token-helper
npm ERR!
npm ERR! If you need help, you may report this error at:
npm ERR!     https://github.com/npm/npm/issues
npm ERR! Please include the following file with any support request:
npm ERR!     /home/pi/MagicMirror/modules/MMM-awesome-alexa/npm-debug.log

@sobrien556 Have you used git before? You have to change branch first to add-node-script-for-token. Then you have to use git to pull latest files. Please watch this: https://www.youtube.com/watch?v=HVsySz-h9r4 and ask if you still dont have the new files :)

@dolanmiu Can you debug windows more because I dont have it? xD Try to modify generateQuery. For example change:
.map((key: string) => key + "=" + params[key])
to
.map((key: string) => key + "=" + encodeURIComponent(params[key]))

@dolanmiu Can you send me private message on gitter and tell me your parameters you gave to the script so I can test if they work on my machine?

@henrikra will do after work
Btw, how are you building those .js files? Can I build them too? It doesn't seem to be an npm command for that

Great. I just used tsc command to compile them

here is the error im getting when i run the npm, i thought i was using the right versions that worked with MM already, is that my problem?
`><EMAIL_ADDRESS>avs-token-helper /home/pi/MagicMirror/modules/MMM-awesome-alexa

node src/avs-token-helper/avs-token-helper.js

/home/pi/MagicMirror/modules/MMM-awesome-alexa/src/avs-token-helper/avs-token-helper.js:25
)
^
SyntaxError: Unexpected token )
at createScript (vm.js:56:10)
at Object.runInThisContext (vm.js:97:10)
at Module._compile (module.js:549:28)
at Object.Module._extensions..js (module.js:586:10)
at Module.load (module.js:494:32)
at tryModuleLoad (module.js:453:12)
at Function.Module._load (module.js:445:3)
at Module.runMain (module.js:611:10)
at run (bootstrap_node.js:387:7)
at startup (bootstrap_node.js:153:9)
npm ERR! Linux 4.9.59-v7+
npm ERR! argv "/usr/bin/node" "/usr/bin/npm" "run" "avs-token-helper"
npm ERR! node v6.13.0
npm ERR! npm  v3.10.10
npm ERR! code ELIFECYCLE
npm ERR<EMAIL_ADDRESS>avs-token-helper: node src/avs-token-helper/avs-token-helper.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the<EMAIL_ADDRESS>avs-token-helper script 'node src/avs-token-helper/avs-token-helper.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the mmm-awesome-alexa package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node src/avs-token-helper/avs-token-helper.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs mmm-awesome-alexa
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls mmm-awesome-alexa
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR!     /home/pi/MagicMirror/modules/MMM-awesome-alexa/src/npm-debug.log
`

@Albiorix2016 type git log and tell me latest commit message. It should work now

@henrikra
`commit a90b5ca2c1ab7c4bc69db72856d6056d76b67573
Author: Dolan<EMAIL_ADDRESS>Date:   Thu Mar 8 02:12:09 2018 +0000
Fix for windows

commit 79c4286fa49521e7950703be80cfcc4fedc70e98
Author: Dolan<EMAIL_ADDRESS>Date:   Thu Mar 8 02:05:53 2018 +0000
Rename files

commit e415176687d1f7bd77d51e8089c7bf47302f4f7f
Author: Henrik Raitasola<EMAIL_ADDRESS>Date:   Wed Mar 7 22:34:32 2018 +0200
Correct typo

commit dcac67fc5cd6fb9db238db1b567dada7a1fb23d2
Author: Henrik Raitasola<EMAIL_ADDRESS>Date:   Wed Mar 7 09:31:44 2018 +0200
Add npm scripts

`

@henrikra btw, ive messaged you on gitter
VERY VERY interesting
This script works flawlessly on my mac, and I even got the correct response!!
Windows gets the Amazon error that I print screened above.
http://localhost:4200/authresponse?code=ANj............&scope=alexa%3Aall

@dolanmiu Messaged you back

@henrikra Another interesting discovery:
I console logged the url and pasted it into Chrome, and it WORKS PERFECTLY
The URL for on Windows when it opens automatically is:
https://www.amazon.com/ap/oa?client_id=amzn1.application-oa2-client.9cfa748077654ec183867d32a^&scope=alexa:all^&scope_data={\alexa:all\:{\productID\:\avs_v2_test\,\productInstanceAttributes\:{\deviceSerialNumber\:123}}}^&response_type=code^&redirect_uri=http://localhost:4200/authresponse

Which is much different from:
https://www.amazon.com/ap/oa?client_id=amzn1.application-oa2-client.9cfa748077654ec183867d32a&scope=alexa:all&scope_data={"alexa:all":{"productID":"avs_v2_test","productInstanceAttributes":{"deviceSerialNumber":123}}}&response_type=code&redirect_uri=http://localhost:4200/authresponse

(I deleted some parts for security)

So second url is the url that you console logged? At least for some reason it adds these weird ^ characters

Second one is console logged yes

Hmm I can't debug this since I don't have windows. Can you still debug it more? Atleast we know that the link is ok right?  But I am pretty sure you can figure out how we don't need to do that :D

Found something maybe useful:
https://github.com/sindresorhus/opn/issues/44

Nice! Can you try to use that replacement in the script?

I actually found the line which does this:
https://github.com/sindresorhus/opn/blob/b9f7e569f5a3d5d520047df3e9f10a42d52fd9d4/index.js#L36
https://github.com/sindresorhus/opn/issues/77

Im not sure if we can, because the ^& is way after we call opn
It has something to do with adding spaces:
https://github.com/sindresorhus/opn/pull/47

But we are not adding spaces?

Maybe the problem isn't ^&, but it is to do with the JSON escaping
I will investigate tonight

Thanks 👍

Two issues:
^& and the json is also escaped, which breaks it
I even tried openner: https://www.npmjs.com/package/opener
And that still didn't work
Don't think its possible with windows, so I made it console.log the url out if its windows!
Moved the js files into a /avs-helper directory as I don't like the compiled files to be in /src
Made a build command to build the avs-helper files

True. Nice! I have to do some final testing. @Albiorix2016 Can you pull latest changes and try it now. You used windows right?

@henrikra @Albiorix2016 Oh I forgot, I need to amend avs-refreshToken-helper too :joy:
I only did avs-token-helper

@henrikra
seems to be getting further along now
npm run avs-token-helper

<EMAIL_ADDRESS>avs-token-helper /home/pi/MagicMirror/modules/MMM-awesome-alexa
node avs-helper/avs-token-helper.js

Welcome to the Amazon auth helper!
I will need three things from you:

Client ID
Product ID
Allowed return URL
[Press any key to continue]
Client ID? amzn1.application-oa2-client...
Product Id? ...
Redirect URI (allowed return URL)? https://localhost:9745/authresponse
Great! Next I will now open a browser where you can authorize your Alexa product
[Press any key to continue]
(node:7896) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: Exited with code 3
``

idk if its my return url or what but i never get past this part regardless of method lol

@Albiorix2016 Can you try again? I have added logging of the error, and then paste the error you are having.
It is failing on opn, so I am guessing it's something to do with your browser, but lets see

@dolanmiu
Redirect URI (allowed return URL)? https://localhost:9745/authresponse Great! Next I will now open a browser where you can authorize your Alexa product [Press any key to continue] Something went wrong with opening your browser Error: Exited with code 3     at ChildProcess.cp.once.code (/home/pi/MagicMirror/modules/MMM-awesome-alexa/node_modules/opn/index.js:84:13)     at ChildProcess.g (events.js:292:16)     at emitTwo (events.js:106:13)     at ChildProcess.emit (events.js:191:7)     at maybeClose (internal/child_process.js:920:16)     at Socket.<anonymous> (internal/child_process.js:351:11)     at emitOne (events.js:96:13)     at Socket.emit (events.js:188:7)     at Pipe._handle.close [as _onclose] (net.js:509:12)
i use google chrome on win10 if that helps using putty

@Albiorix2016 You should run these scripts on your host machine. Not on raspberry pi. Can you tell me what is your setup?

@henrikra i've been using a win10 machine with an 15 cpu and using putty to ssh into the pi3

@henrikra

Can we use async await on this? The nesting looks ugly

Hmm I am not sure if it is good idea because MagicMirror installs node v6 by default which does not
have that feature yet https://github.com/MichMich/MagicMirror/blob/master/installers/raspberry.sh#L85

A PR upping this to 9.x was just merged to dev a few days ago.

@Albiorix2016 can you use the scripts if you run them on your windows machine?

@henrikra I have noticed a potential problem, if @Albiorix2016 uses it on windows, he needs to also set up SoX and npm install etc, which is quite difficult on windows actually

True. Automatic browser opening is just a plus. Maybe even remove opn library and always just console.log it?

@henrikra

Maybe even remove opn library and always just console.log

yes good idea, opn add more complexity which makes our lives more difficult :joy:

Yeah. Everybody has browser open all the time anyways :D

I'm trying to test the scripts, but I'm stuck after copying them from repo to my local master clone. Not feeling like doing the entire compile install again, what are the missing installs needed for the scripts to work?
Now I get:
# npm run avs-token-helper

npm ERR! missing script: avs-token-helper
npm ERR! A complete log of this run can be found in:
npm ERR!     /home/pi/.npm/_logs/2018-03-15T19_57_47_376Z-debug.log

# OR after adding a shebang
# ./avs-token-helper.js

module.js:545
    throw err;
    ^

Error: Cannot find module 'opn'
    at Function.Module._resolveFilename (module.js:543:15)
    at Function.Module._load (module.js:470:25)
    at Module.require (module.js:593:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (/home/pi/MagicMirror/modules/MMM-awesome-alexa/avs-helper/avs-token-helper.js:6:13)
    at Module._compile (module.js:649:30)
    at Object.Module._extensions..js (module.js:660:10)
    at Module.load (module.js:561:32)
    at tryModuleLoad (module.js:501:12)
    at Function.Module._load (module.js:493:3)

Hehe. Actually I just update the branch. Please pull the latest changes :)

so do i need to pull again and try the scripts from putty or do i need to install sox and what not on my win box?

@Albiorix2016 pull latest yes. Then run those scripts on windows 👍

@henrikra  ok those seemed to work. is the refresh token extremely long?

i guess i did something wrong, i loaded the module in to my config and turned on visualization, i use alexa as the wake word and the white circle shows up when i say alexa but then after a command the circle fills to a white dot but never get a audio response

@Albiorix2016 Token scripts are working then! @dolanmiu can you do final testing and lets merge this?

Any idea why I’m not getting any response from commands other than the
circle/dot?
On Fri, Mar 16, 2018 at 4:57 PM Henrik Raitasola<EMAIL_ADDRESS>wrote:

@Albiorix2016 https://github.com/albiorix2016 Token scripts are working
then! @dolanmiu https://github.com/dolanmiu can you do final testing
and lets merge this?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/dolanmiu/MMM-awesome-alexa/pull/82#issuecomment-373855903,
or mute the thread
https://github.com/notifications/unsubscribe-auth/Abn-Obgn4t8YuGx88ziAyS3Qceev2NUgks5tfDUxgaJpZM4SfJh3
.

Ok, I just tried this using:

Redirect URI (allowed return URL)?  https://localhost:9745/authresponse

$ npm run avs-token-helper

><EMAIL_ADDRESS>avs-token-helper /home/pi/MagicMirror/modules/MMM-awesome-alexa
> node avs-helper/avs-token-helper.js

Welcome to the Amazon auth helper!
I will need three things from you:
- Client ID
- Product ID
- Allowed return URL
[Press any key to continue]

Client ID? amzn1.application-oa2-client.xxxx
Product Id? A1xxxxx
Redirect URI (allowed return URL)? https://localhost:9745/authresponse
Great! Copy paste the link below to your browser to authorize your Alexa product

https://www.amazon.com/ap/oa?client_id=amzn1.application-oa2-client.xxxx&scope=alexa:all&scope_data={"alexa:all":{"productID":"A1xxxx","productInstanceAttributes":{"deviceSerialNumber":123}}}&response_type=code&redirect_uri=https://localhost:9745/authresponse

Pasted this into chrome, got feedback that I login from unusual place, got feedback code, confirmed, went on to accept api usage... back to same "We're sorry message". No go!

For those of you, which this works, what country are you connecting from?
Are you using same URL

Questions:

What you call  Product ID, is that the same as Amazon developer console calls Amazon ID??

@E3V3A i finally got mine to work, its setup as a device and the product id should be able to find if you go to the "my projects dashboard"

@E3V3A when you get "We're sorry message" then there is usually a link that will open more details of your problem

Can this be merged now?

Yes! Let's try it out and let's fix if problems occur :)

im getting this error
This site can’t be reached
localhost refused to connect.

That is expected
All the info is in the address bar


Prevent the Landscape mode on mobile

Show a warning overlay and pause the game, if the user tilts the device to landscape mode.

Implemented in ce580785ebc264a805d6db89272e1cb531af907f


Add bernoulli_*Tensor to THC

Right now there's no way to sample from Bernoulli distribution with per-element probabilities. This it already implemented in TH.

fixed via https://github.com/torch/cutorch/pull/630


Handle HTTP 204 (No Content) Responses

Requests to endpoints that return a HTTP 204 status code without any response body end up failing with the following error: Decode response error: application/json => error decoding response body.
Sample Server
# ./example.py
# pip install "fastapi[standard]"
# fastapi dev example.py
from fastapi import FastAPI, status
from pydantic import BaseModel

app = FastAPI()

class Payload(BaseModel):
    name: str

@app.post("/test", status_code=status.HTTP_204_NO_CONTENT)
def reply_204(data: Payload):
    print("No return statement here")

Sample Client
use apisdk::serde_json::json;
use apisdk::{http_api, send_json, ApiResult};

#[http_api("https://localhost:8000/")]
pub struct SampleAPI;

impl SampleAPI {
    pub async fn reply_204(&self) -> ApiResult<()> {
        let payload = json!({"name": "test"});
        let req = self.post("/test").await?;
        send_json!(req, payload, ()).await
    }
}

Calling the reply_204 method of SampleAPI should return an Ok(()) but it always returns an error even when the sample server responds correctly with an HTTP 204 code.

I've published a new version (v0.0.16) to fix this issue

https://crates.io/crates/apisdk/0.0.16
commit: https://github.com/zhengcan/apisdk-rs/commit/8e7b8ce6fe9b25afbec78e9a8f87f94b4a48f068

Thanks for taking the time to fix this so quickly🙏


Navigate among the files while typing in the Explorer panel

VSCode Version:1.8.1
OS Version: Microsoft Windows [Version 10.0.14393]

Steps to Reproduce:
In Visual Studio, we could navigate between the files while typing to search the file or folder that we want to reach.
For example, let's suppose that we have the following structure on Explorer panel

resources
config

acl.php
app.php
+benchmark.php

config.testing
database
routes

If I start to type "c", "o", "n" with the focus inside the Explorer bar, so, the panel will set the focus to the config folder. Once inside the config folder and start to type "a", "p"... it will set the focus in the app.php file.
If the Explorer panel has the focus in the resource folder and we start to type "b", "e","n", the Explorer panel will set the focus to the benchmark.php or other file that starts with the chars "ben".

@DanZeuss nice idea! It sounds like this is already tracked by #10026 and #10839, so I'm going to go ahead and close this, and suggest following those issues for updates. Happy to reopen if you think otherwise. Happy coding!

Thank you so much @mousetraps


MudSlider Accessibility Issue

Feature request type
Enhance component
Component name
MudSlider
Is your feature request related to a problem?
We have had issues when the component is in focus with contrast ratios and highlighting. There is a subtle grey color that is added to the background when in focus which causes it to not pass accessibility. It is also hard to see in general.
Describe the solution you'd like
It would be great if the component passed contrast ratios for accessibility when focused.
Have you seen this feature anywhere else?
No response
Describe alternatives you've considered
We were unable to create a workaround and ended up using a different control instead for the solution we were creating.
Pull Request

[ ] I would like to do a Pull Request

Code of Conduct

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

It seems to match the Material Design 2 slider pretty well.
Do you have specific changes in mind?


GH-41317: [C++] Fix crash on invalid Parquet file

Rationale for this change
Fixes the crash detailed in #41317 in TableBatchReader::ReadNext() on a corrupted Parquet file
What changes are included in this PR?
Add a validation that all read columns have the same size
Are these changes tested?
I've tested on the reproducer I provided in #41317 that it now triggers a clean error:
Traceback (most recent call last):
  File "test.py", line 3, in <module>
    [_ for _ in parquet_file.iter_batches()]
  File "test.py", line 3, in <listcomp>
    [_ for _ in parquet_file.iter_batches()]
  File "pyarrow/_parquet.pyx", line 1587, in iter_batches
  File "pyarrow/error.pxi", line 91, in pyarrow.lib.check_status
pyarrow.lib.ArrowInvalid: columns do not have the same size

I'm not sure if/how unit tests for corrupted datasets should be added
Are there any user-facing changes?
No
This PR contains a "Critical Fix".

GitHub Issue: #41317

Will merge in 2days if no negative comments

is expected to be valid prior to using it with the batch reader

done

It seems the added ValidateFull() breaks one test
[----------] 1 test from TestTableSortIndicesForTemporal/1, where TypeParam = class arrow::Date64Type
[ RUN      ] TestTableSortIndicesForTemporal/1.NoNull
D:/a/arrow/arrow/cpp/src/arrow/table.cc:622:  Check failed: _s.ok() Operation failed: table_.ValidateFull()
Bad status: Invalid: Column 0: In chunk 0: Invalid: date64[ms] 1 does not represent a whole number of days

I will have to let more knownledgeable people of the code base than me to investigate that.

This PR should be ready for merge (as far as I can see the test failures are also found in other pull requests)

Will merge if no negative comment in one day


Diff bug

Description

Playground Example
Monaco Editor Playground Repro (click on "use latest dev" to verify a future bug-fix)

The diff looks code, though the original document looks weird. How did you arrive at this state?

Quite sure with staging selected ranges.

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!


Accounts objects, getFollowedBy returns always zero when using searchAccountsByUsername

When you use searchAccountsByUsername some properties are not pupulated as expected by the raw data return from Instagram.

@incatech-ai thank you for contribution


SAK-43537 - Tests&Quizzes: MCSC questions, the submission scores ques…

…tions are not aligned when answers have long text

Does the use of  make sense here?

Whats the JSF tag for a UL list?

If Tomahawk is being used: http://myfaces.apache.org/tomahawk-project/tomahawk/tagdoc/t_dataList.html

Thank you so much @ottenhoff , looks good to me as dataList:

Don't mention it Sam! Thanks Sam & Earle.


Increase Mongo Timeout

Keep articles for > 30 days

Just keep the articles until Matt starts complaining about disk usage. Easy.


fix build API response streaming

Set the "X-Accel-Buffering" header to "no" on the build API
response to disable nginx proxy buffering.
See: http://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_buffering

@tnine @whitlockjc how does this get into prod?

We need to accept the PR, rebuild the thirtyx/shipyard image and update the deployments on e2e/prod.


create_rlc_component() not working for rotated components

Before submitting the issue

[X] I have searched among the existing issues
[X] I am using a Python virtual environment

Description of the bug
For rotated components the create_rlc_component does not work correctly.
The rotation is not copied from the host component and the pads are placed on the wrong location.
Changing the SetPosition/GetPosition to SetTransform/GetTransform fixes this for my (mentor expedition ODB++) designs.
Steps To Reproduce
Read ODB++ file with rotated components (For example soic 4).
creata rlc on pins 2 and 3.
Check the EDB file with SiWave
Which Operating System are you using?
Windows
Which Python version are you using?
3.8
Installed packages
aiohttp==3.8.3
aiosignal==1.2.0
appdirs==1.4.4
async-timeout==4.0.2
attrs==22.1.0
autopep8==1.7.0
cffi==1.15.1
charset-normalizer==2.1.1
clr-loader==0.2.3
contourpy==1.0.5
cycler==0.11.0
fonttools==4.37.3
frozenlist==1.3.1
idna==3.4
imageio==2.22.0
kiwisolver==1.4.4
matplotlib==3.6.0
multidict==6.0.2
numpy==1.23.3
packaging==21.3
pandas==1.5.0
Pillow==9.2.0
pip-review==1.2.0
plumbum==1.7.2
psutil==5.9.2
pyaedt==0.6.5
pycodestyle==2.9.1
pycparser==2.21
pyparsing==3.0.9
python-dateutil==2.8.2
pythonnet==3.0.0rc6
pytz==2022.2.1
pyvista==0.36.1
pywin32==304
rpyc==5.0.1
scooby==0.6.0
six==1.16.0
toml==0.10.2
vtk==9.1.0
wslink==1.8.2
yarl==1.8.1

fixed currently merged in the main branch.


Strings are highlighted incorrectly with monokia on chrome tamper monkey

The quotation marks are highlighted correct but the contents of the string is not.

Thanks for reporting this, it's all fixed now.

To update this, you'll need to switch to a different syntax highlighting theme, then do a "force update". Then choose Monokai again.

Wow. That was fast.

:grin:

Still not working. I changed the syntax theme. Hit "Force Update Style" and changed back to Monokia. Same highlighting. Somehow it must still be cached.

Try again... sometimes the raw.githubusercontent.com file doesn't update immediately; and that is where the script pulls the file from.

Still not working.

Something about that force update isn't working for me either, checking it out.

Hey @2426021684! Add ?debug to the URL and look in the console after reloading the page... it should tell you which theme is being loaded; click the link and search for ".type-css" - if it's there, it's loading the newest Monokai file.

".type-css" is there

You're not also using the Stylish userstyle are you? Stylish overrides the script... the userstyle was also updated.

I think I found the issue, gimme a sec :)

Hmm, something is still wrong (e.g. theme not applying), sec.

I am not using the Stylish usersheet.

Hopefully fixed the theme update issue on master. Monokai strings still looking weird thought:

This is what Monokai is supposed to look like:

Guess we need to update the theme now to match it more closely.

Hmm, I only updated Monokai string colors for css:
I guess I should just change that to the overall .pl-s definition.

Ok, try it now... everything was updated.

Also, install through https://github.com/StylishThemes/GitHub-Dark-Script/raw/master/github-dark-script.user.js

Monokia works but many other themes have the same issue

Also I don't ever see the red/pink color in monokia

Like what themes? The GitHub syntax highlighter isn't as nice as pygments, so a lot of the themes had to be manually converted - it wasn't a perfect conversion.

Cobalt:

Monokia now has the red/pink color

Did a few more updates to Monokai so it closer matches the screenshot above. Theme work is usually a quite time intensive task, so I guess if you really love a theme, you can submit a pull request to perfect it.

The quote being a different color than the string is a bug in my eyes though, we should match the color of the involved classes.

It would really help out if you would share specific changes that need to be made. I get really frustrated trying to match colors when GitHub's syntax class names are limited.

Okay, cobalt strings should be fixed too:

If you have more theme issues, please bring them up at https://github.com/StylishThemes/GitHub-Dark/issues, ideally with a screenshot what's wrong and a screenshot on how it shall look like.

Looks fantastic now

@silverwind You :metal:! Let me know when you're done tweaking themes... I'll push an update to userstyles.

Go ahead, not in the mood for more theme work right now, it's so inconvenient to test. :stuck_out_tongue:

That's why I made this page: https://github.com/StylishThemes/GitHub-Dark/wiki/Highlighting


Can't download from some links

Eg Link: https://uploadrar.com/zd3lhwr2hx5x
I've tried on different instances but wasn't able to download from this link using the Kiwi browser. Other browser works as expected.

Wait, seems like something is wrong on my side.


Remove requires from codebase

Issue

Currently there are a lot of dynamic requires littered around, which makes static analysis, (e.g. webstorms find usages difficult. TS also resolves the type to any which would be nice to avoid.
Examples:
    require('path').__setBaseDir('./tests/tsconfig-test');
...
    const { getTSConfig } = require('../../src/utils');

I tried porting them to ES6 modules, and I see some problems with regards to mocking. I tried hoisting the jest.mock calls to the top myself, and I managed to get it to work. I think this is related to #90
I think we should consider always hoisting the mock statements to the top, and then systematically removing requires and using ES6 modules.
Let me know if I've misunderstood anything, such as the reasons for the requires :)

sounds good to me.
Don't hesitate to initiate changes that you think could improve ts-jest.
That said, let's try to keep the focus of the package on one thing only - helping Typescript users use Jest for testing.

Definitely agree on that, which is why I think we should keep the hoist semantics as similar as possible.


MedDRA to MONDO cross-references

Hi,
from an analysis of FAERS data, we have obtained a list of 1,770 MedDRA to MONDO mappings that we believe have a very high level of confidence:
meddra-mondo-xref-0995-1.json.zip
This is part of an emerging pipeline we are working on to integrate the different methods of automatic disease mapping into a single tool.
The algorithm performs very well as long as it is already captured in the ontology. However, we are aware of a systemic error when the MedDRA label refers to a less common/more severe disorder in a set of diseases and we map it to the closest EFO term, e.g:
{"traitId":"10032168","traitName":"Other insomnia","score":1,"efoId":"EFO_0004698","efoName":"insomnia"}
{"traitId":"10031712","traitName":"Other cardiovascular syphilis","score":0.999,"efoId":"EFO_1001206","efoName":"syphilitic aortitis"}
{"traitId":"10032033","traitName":"Other endocarditis","score":1,"efoId":"EFO_0000465","efoName":"endocarditis"}

Could you please examine the mappings and consider how best to include this annotation in the ontology? The SPOT team has already imported the MedDRA xrefs whose labels match an EFO/Orphanet term and are now in the process of curating the ones of less confidence. Both EFO and Open Targets would benefit a lot if you could include them similarly.
Any feedback or comments is much appreciated.
Thanks!

Hi!
Could you please provide some follow-up on this issue? I would love to know if you have this work on the scope for the coming months.
Please let me know whether you have any comments or questions. Thanks!

Hey @ireneisdoomed this is great work - but human review is extremely costly. I am afraid it is difficult to verify all these mappings in one go. To get this going would you be able to supply the mappings as an SSSOM tsv? The JSON file cannot really be handled by our curator team, and we use Google Sheets for all review activities.
Here are some examples:
https://github.com/mapping-commons/mh_mapping_initiative/tree/master/mappings
This will enable me to share the mappings on google sheets and have some of them reviewed.
Also, it would be hugely informative to know the mapping justification: why is a match considered a match?
Also, give us a bit more metadata so we can accurately attribute the match to you and your team. What is the tool you used, which version? Who is the creator/team that published the mapping?
I tried to reach you via email as well, but now I lost access to that (thanks to the new EBI regulations with VPN) - I would still be interested to talk to you about your efforts to sync up a bit and avoid redoing to much work on our end (if you do all this work, we dont have to :P).

Update - Irene will provide a SSSOM file with mappings.

Hello!
As @matentzn suggested in our conversation in August, we want to be able to accurately establish what are the levels of correspondence between terms so I've mapped our values of confidence to the corresponding predicates as follows:

OT confidence
EFO relation
SSOM predicate

1.0
exactName
owl:equivalentClass

0.999
exactSynonyms
skos:exactMatch

0.998
narrowSynonyms
skos:narrowMatch

0.997
broadSynonyms
skos:broadMatch

0.996
relatedSynonyms
skos:relatedMatch

To give you an idea of the quality of these MedDRA to MONDO mappings, here is an extract of how the predicates are distributed across the ≈ 2 000 xrefs:

predicate_id
count

skos:exactMatch
949

owl:equivalentClass
931

skos:relatedMatch
129

skos:narrowMatch
32

skos:broadMatch
9

Please let me know if you think the mappings are not equivalent.
Here is the table in the SSOM format:
meddra-mondo-xref.csv.zip
Attribution
Author: Miguel Carmona
ORCID iD: 0000-0002-7582-4771
Tool: opentargets-disease-meddra-word2vec v1
Organisation: Open Targets

Wow, supplying this file in sssom format is so super cool. We are also about to publish the first stable release of the spec, for example: https://mapping-commons.github.io/sssom/Mapping/
The file looks good, but just to double check on your curation rules:

if two labels match, you assign "equivalent class"
if a label matches to an exact synonym, you assign "exact match"
if a label matches to a narrow synonym, you assign  "narrow match"
if a label matches to a broad synonym, you assign "broad match"
if a label matches to a related synonym, you assign "related match"

Some questions about that.

You dont do anything if two exact synonyms match? if is it just the case that for meddra, you do not have synonyms?
Does this list include only mappings that are not already in mondo, or are these all matches you found?
What is the preprocessing going on on the labels/synonym fields? Do you do:

lower casing
stemming
anything else?

Very excited to see this, thank you!

Hi @matentzn! Yes, that is exactly the rationale the curation follows.

We haven't explored that. Correct me if I am wrong, but we don't have access to such synonyms since the MedDRA ontology is licensed.
These are all the matches we have found, i.e. a MedDRA term that our algorithm maps to an existing MONDO term.
There is a normalisation process being done. As you say: lower casing, stemming, lemmatization. You can see the code here: https://github.com/opentargets/platform-etl-backend/blob/master/scripts/opentargets-disease-meddra-word2vec.sc

I hope that helps!

Thank you @ireneisdoomed I have this on my list of things to deal with now, but it may take a few weeks before I get to it.
Very excited about all that and thank you for this contribution!
Just a few questions:

Would you be willing to keep this mapping "up to date", i.e. deploy the sssom file somewhere public and run the mapping code periodically to catch new and changed terms?
If I were to assist, would you be willing to provide additional metadata to the table (columns, etc)?
completely independent of the above, would you be able to provide a list of mappings that are not already in Mondo?

Thank you!

Thank you @matentzn, I will be very happy to know your comments.

Sure, this is something that we can do. These MedDRA terms are picked up from our FAERS pipeline in the first place. We could implement a systematic cross-reference lookup if that is beneficial for all of us.
Yes.
I am not sure I understand what you mean. Do you want a list of the MedDRA terms that we have not been able to accurately enough map to any ontology?

Re 3: I meant if there is a mapping MONDO:001 --[skos:exactMatch]--> Meddra:001 that is already in Mondo itself, would it appear in your mapping table? or did you already remove all the mappings that are already in Mondo? Anyways, so not worry :) Just wondering.

Thank you for the clarification. I don't think any checks of whether the Xref is already present were done.

@ireneisdoomed thank you!
@joeflack4 this is a very important ticket to me, but I dont want you to get too sidetracked. Could you do a quick python script taking @ireneisdoomed spreadsheet, and comparing it to

https://github.com/monarch-initiative/mondo/blob/sssom-rewrite/src/ontology/mappings/mondo_narrowmatch_mesh.sssom.tsv
https://github.com/monarch-initiative/mondo/blob/sssom-rewrite/src/ontology/mappings/mondo_exactmatch_mesh.sssom.tsv
https://github.com/monarch-initiative/mondo/blob/sssom-rewrite/src/ontology/mappings/mondo_closematch_mesh.sssom.tsv

INPUT: Irenes Table, and the three tables above,
OUTPUT: Irenes Table with only the rows that are not in any of these three files
For now, the key should just be subject_id, object_id, ignoring predicate id.

Hi @matentzn @joeflack4,
how is this work going? I'm interested to know if you have any initial thoughts on the quality of the data.
Thanks!

Hey @ireneisdoomed - we are at the moment all in on getting the Mondo paper done, so there is a bit of delay of addressing the mapping issues.. I am sorry. Please indicate if there is a rush for something that you or Open Targets specifically need urgently, else we will resume working on mappings after Christmas!
Apologies!

This is how we will conceptually work with mappings like meddra:

We add them as source mappings into disease mapping commons (https://github.com/mapping-commons/disease-mappings/issues/13)
Mondo slurps harmonised mappings up and adds them back into Mondo.owl

We are getting closer to working in this cycle, but Meddra is not yet a priority, but will be later in the year, after:

ICD10CM
ORDO/OMIM (not much to do)
DO
NCIT
(possibly SNOMED)
Meddra (this ticket)

Sorry @ireneisdoomed this is taking so long, we are doing what we can :)

Hi @matentzn. Thanks for the update.
Could you tell me if the plan is still to review these manually?
Please let me know when you start working in this so that I can rerun the pipeline and provide a more up to date table.

The way this works is like this:

We cycle all mapping candidates through an ontology merging pipeline (KBoom).
This will reveal all mappings that cause contradictions.
These mappings will be manual reviewed.
Mappings are accepted if no contradictions are left.

So no matter what, not all mappings are reviewed 1:1 - this is not possible with more that 150K mappings we need to manage.

@matentzn can we close this issue or is there more to be done? Thanks!

This ticket is not done but can be moved to mondo ingest repo.
It needs to be included in any concerted efforts integrating Meddra again.


Add lightbox to sessions preview images

The current session preview images are hard to see on large screens. Lightboxes would help make this easier to see

#227
I implemented a working lightbox but I'm not sure if its exactly what we want. Hopefully I didn't break anything since I ended up adding new scripts to baseof.html

Closed with #227


Filter metadata textracks in player APIs for src mode

Have you read the FAQ and checked for duplicate open issues? Yes
Is your feature request related to a problem? Please describe.

Right now if the stream loaded in src mode has a metadata track, it is shown in the subtitle selection UI.
Describe the solution you'd like

Filter theses tracks in getTextTracks, selectTextTrack, isTextTrackVisible and setTextTrackVisibility

I created a PR: https://github.com/google/shaka-player/pull/2519


Markdown cells not correctly detected and treated as SQL on opening a file

When an existing file is opened the markdown cells are not reliably identified as markdown.
Some open OK but others, particularly those containing tables and/or lists (OL and UL), open as 2 SQL cells. The first cell contains the markdown text preceded by the */markdown tag.  The closing */ tag appearing in a following 2nd SQL cell.
Once the cells are merged thercell type detection may recognise the correct type and there may be a suggestion to change cell type to markdown. This does not always happen and manual scrutiny and change is often required.

Same issue as of 25/11/2023

Same issue ...
and: one file /cloned from Git/ is rendered correctly for some VSCode instance while in others not


Typo fix

Glancing through the code, I found a few typos in wsgi.py and wrappers.py.
No code is changed, The typos were all in comments and docstrings.

Thanks!


Support custom error response extensions

Is your feature request related to a problem? Please describe.
Our GraphQL API returns customized data in error extensions. This plugin catches errors and parses them into aGQLException which includes a GQLError. This is convenient but the GQLError does not include the extensions object. Apollo documentation here: https://www.apollographql.com/docs/apollo-server/v2/features/errors.html. I need to be able to extract the error information as-is from the library.
Describe the solution you'd like
Add a simple Map<String, dynamic> extensions object to GQLError so that the host application can read the data when needed.
Describe alternatives you've considered
I don't know of any alternatives. Extensions are free-form so we can't build in a model witch which to parse them.
Additional context
none.

:tada: This issue has been resolved in version 1.0.0-beta.1 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:

:tada: This issue has been resolved in version 1.0.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


Fix search suggestions

Overview
This PR fixes a bug where search suggestions were not loading correctly.
Connects #1030
Issue summary
When a new visitor loads the page we request a Smartlogic token for them. However, we weren't waiting for the token to be granted and stored before setting up the search bar, causing a 403 error whenever it tried to get suggestions. The token was fetched after the bar had been configured.
On subsequent page loads, the search suggestions functioned as expected since the token was already stored in the browser.
Testing Instructions

Either open a private window or clear your browser's cookies/cache (note that in some browsers, e.g. Firefox, browser data persists across open private tabs)
Navigate to the homepage
Verify that you are able to load search suggestions

@antidipyramid Are we waiting on anything to deploy this?

@hancush Nope this one is good!


About code

Awesome work! Will you release the code and the pretrained weight? When will you release them?

@buzuyun Thanks for contacting. Yes, we were figuring out the license from the sponsors and then the authors were busy with conference deadlines. We hope to release this in about a week.

This is a very cool work. It will be wonderful if you release your pretrained weight. Wait it. I can't wait to have a try.


Add end-to-end integration tests + revert client

Add integration tests + README
Add support for IonQ solver
Add config file
Add bugfix for new BlobDetails model
Revert client back to track 1 version until compatibility issues are solved (see https://github.com/microsoft/qdk-python/pull/13)

Is that called in any of the CI pipelines, or should it be run manually?

See README.md; apologies for the large PR, this PR actually merges another one in as well; a more readable PR including just the integration test change is here: #14. These integration tests are still manual for now and will be included in CI/CD at a later stage.

Is that called in any of the CI pipelines, or should it be run manually?

See README.md; apologies for the large PR, this PR actually merges another one in as well; a more readable PR including just the integration test change is here: #14. These integration tests are still manual for now and will be included in CI/CD at a later stage.

@cgranade Thanks for the detailed review! I believe I have addressed all your comments. If it's okay with you I'd like to merge this in anticipation of the release - if you have any additional comments, would you mind posting them on PR #14 to main?

@cgranade Thanks for the detailed review! I believe I have addressed all your comments. If it's okay with you I'd like to merge this in anticipation of the release - if you have any additional comments, would you mind posting them on PR #14 to main?


Replace all remaining instances of reinterpret_cast with std::bit_cast

Sorry for interjecting, but isn't std::bit_cast designed to copy bits of one value as another value, and not to reinterpret pointers of different types?
cppreference doesn't have a single example of using it to replace reinterpret_cast on pointers. I'm no language lawer, but I have a feeling that in this context std::bit_cast is the same as reinterpret_cast and std::launder may still be needed

No, std::launder will not be needed for std::bit_cast. The reason that you need std::launder for reinterpret_cast is that reinterpret_cast is nothing more than an instruction to the compiler to ignore the type system for a moment. But the compiler is still free to perform optimizations that rely on the assumption that the thing pointed to is what it used to be rather than the reinterpretation.
By contrast, std::bit_cast is a much more invasive operation that prohibits such optimizations.
In fact, we have had a weird problem, where std::launder in combination with reinterpret_cast led to weird behaviour, but only for GCC 12 and only under certain compiler settings. These problems went away when we started using std::bit_cast in these places.

The crux is std::bit_cast only copies the underlying representation.
In the suggested change, it means it creates a const T*, a T* or a const Error* by copying the value representation of an unsigned char*. There is no guarantee that the representation of an unsigned char* is identical to the representation of a const T*, a T* or a const Error* for the same memory location.
It is not even guaranteed that the value representation of an unsigned char* be a valid value representation of a const T*, T* or const Error*. And if it is not, the bit_cast yields undefined behavior.
By contrast, reinterpret_cast performs implementation-defined conversion.
One could make this mental model: reinterpret_cast preserves the memory location (which might imply changing the representation), while bit_cast preserves the representation (which might be that of a different memory location).

@spectras, the problem is that in theory std::launder(reinterpret_cast(...)) should do the trick, but in practice we have had issues.
Specifically, we had a tuple implementation that used std::launder(reinterpret_cast(ptr + i)).
For GCC 12 (and only GCC 12, other compilers and GCC versions were fine) this led to a weird bug under some very specific compiler flags. Basically, ptr + i was transformed to just i.
The problem could be solved by simply removing std::launder or by using std::bit_cast. I am fairly certain that this is in fact a bug in GCC 12.
So how do you deal with this? In theory, std::launder(reinterpret_cast(...)) should be fine. In practice, it is not, but std::bit_cast is.

@spectras and @GregTheMadMonk , what are your thoughts on this solution?
template <class T1, class T2>
inline T1 ptr_cast(T2* _ptr) {
  return static_cast<T1>(static_cast<void*>(_ptr));
}

template <class T1, class T2>
inline T1 ptr_cast(const T2* _ptr) {
  return static_cast<T1>(static_cast<const void*>(_ptr));
}

...

T& get_t() noexcept { return *ptr_cast<T*>(t_or_err_.data()); }

const T& get_t() const noexcept {
  return *ptr_cast<const T*>(t_or_err_.data());
}

Error& get_err() noexcept {
  return *ptr_cast<Error*>(t_or_err_.data());
}

const Error& get_err() const noexcept {
  return *ptr_cast<const Error*>(t_or_err_.data());
}

In my view this most certainly isn't UB, because it is never UB to static_cast as pointer to a void* and it is never UB to static_cast a void* to some other type.

I am closing this in favour of https://github.com/getml/reflect-cpp/pull/298.


Fix incorrect rendering of vcs dialogs

I found that's glitched because window added as a child of PopupMenu.
Before the fix:

After the fix:

Fix https://github.com/godotengine/godot/issues/69509

Thanks!


Unable to call the shareChatWithBot method

I run it with all necessary parameters from td_api.tl after getting messageChatShared, but I get Error: (400, 'The method is not available to bots')
This is the method for adding a bot to groups, how can it not be available to bots?

Bots can't write to other bots and they can't join groups by themselves, hence they definitely can't use shareChatWithBot.

Look at td_api.tl (master), line 1576:
//@description A button that requests a chat to be shared by the current user; available only in private chats. Use the method shareChatWithBot to complete the request
...
keyboardButtonTypeRequestChat ...

Why is it phrased that way?
PS:
Overall solved. Setting parameters for keyboardButtonTypeRequestChat turned out to be quite a challenge, in case of omission of parameters user_administrator_rights and bot_administrator_rights the button appears, allows to select a chat, after selection even a notification about successful addition appears, but the actual addition does not happen. Taking into account this fact, as well as the text from the comment, it seems that it is necessary to run the shareChatWithBot method.

Why is it phrased that way?

Because TDLib documentation is for app developers and regular users. When a user receives the button, it can use the method shareChatWithBot to process the button. Bot API documentation can be found at https://core.telegram.org/bots/api.

De


镜像找不到啊，好绝望

好多国外的镜像dockerhub也找不到，真的实在是找不到，官方能把镜像打包到官方的openfunction 镜像仓库吗

What image are you looking for？
Most images are in openfunction or openfunctiondev dockerhub org,
for example openfunction/openfunction or openfunctiondev/openfunction

gcr.io/knative-releases/knative.dev/serving/cmd/defaultdomain@sha256:b14b7963dd809545a23959c6d98bcf76e84ab5de73b866261ea9c8aacab75836   这个没有具体的版本，找不到到底要哪个镜像，sha256没有对应上的

@Qiaoruiwu Please tell me which version of Knative Serving you have installed?

Or you can join our community WeChat for more help.


Does the browserify-uglify-sourcemap.md example work with AngularJS code?

With my current AngularJS I fail to use this recipe
https://github.com/gulpjs/gulp/blob/master/docs/recipes/browserify-uglify-sourcemap.md
Not sure if the problem is on my side but I wonder if somebody else managed it to implement this recipe for an AngularJS app?

Support questions http://stackoverflow.com/questions/tagged/gulp

Ok, here http://stackoverflow.com/questions/29043701/does-the-browserify-uglify-sourcemap-md-example-work-with-angularjs-code


[BUG] error logs appeared in uninstallation job

Describe the bug
According to manual test case Uninstallation Checks, there should be no error in uninstallation job(pod)
2. Check the logs of the job longhorn-uninstall, make sure there is no error.

However there are error logs in the uninstall pod below:

master

> kl logs longhorn-uninstall-s88ft | grep error
time="2024-08-26T01:10:31Z" level=warning msg="Failed to uninstall" func="controller.(*UninstallController).handleErr" file="uninstall_controller.go:293" controller=longhorn-uninstall error="failed to delete nodes: failed to mark for deletion: nodes.longhorn.io \"ip-172-31-83-204\" not found"
time="2024-08-26T01:10:31Z" level=warning msg="Failed to uninstall" func="controller.(*UninstallController).handleErr" file="uninstall_controller.go:293" controller=longhorn-uninstall error="failed to delete instance managers: failed to mark for deletion: instancemanagers.longhorn.io \"instance-manager-08f869dd142b1d51da0d3df74f8aaddb\" not found"

v1.7.0

> kl logs longhorn-uninstall-ffqln | grep error
time="2024-08-26T01:26:11Z" level=warning msg="Failed to uninstall" func="controller.(*UninstallController).handleErr" file="uninstall_controller.go:293" controller=longhorn-uninstall error="failed to delete instance managers: failed to mark for deletion: instancemanagers.longhorn.io \"instance-manager-1d6ccaba55264b58f0789471999c929f\" not found"

In the end, the uninstall complete, longhorn CRDs all removed, namesapce terminated successfully.
To Reproduce
Use kubectl to uninstall longhorn master, v1.7.0
Expected behavior
No error appeared in uninstall job log or modify the test plan
Support bundle for troubleshooting
N/A
Environment

Longhorn version:  master, v1.7.0
Impacted volume (PV): N/A
Installation method (e.g. Rancher Catalog App/Helm/Kubectl): kubectl
Kubernetes distro (e.g. RKE/K3s/EKS/OpenShift) and version: v1.30.0+k3s1

Number of control plane nodes in the cluster: 1
Number of worker nodes in the cluster: 3

Node config

OS type and version: SUSE Linux Enterprise Server 15 SP6
Kernel version: 6.4.0-150600.23.17-default

Underlying Infrastructure (e.g. on AWS/GCE, EKS/GKE, VMWare/KVM, Baremetal): AWS

Additional context
N/A
Workaround and Mitigation
N/A

@ChanYiLin Can you help check the error log? Thanks.

This is actually not a bug. The logs are quite misleading.
The installation process keeps reconciling and deleting all the resources by

listing all the CRs
delete all the CRs

failed to delete instance managers: failed to mark for deletion: instancemanagers.longhorn.io \"instance-manager-08f869dd142b1d51da0d3df74f8aaddb\" not found

The log indicates that the process failed to delete the CR because it could not be found.
Take the instance-manager CR as an example: it has an ownerReference to a Node. This means that when the Node is deleted, the instance-manager CR will also be deleted. Consequently, a race condition may occur where the installation process lists the instance-managers but fails to call the deletion API due to a "not found" error. In reality, these instance-managers are deleted immediately afterward by Kubernetes garbage collection, as the Nodes are already deleted.
For this issue, we don't need to fix any bug
but just ignore the not found error when printing the error.

Verified pass on longhorn v1.8.0-dev-20240825, perform below command to uninstall longhorn, did not find word error appeared in uninstallation job logs
kubectl create -f https://raw.githubusercontent.com/longhorn/longhorn/master/uninstall/uninstall.yaml
kubectl get job/longhorn-uninstall -n longhorn-system -w

logs
> kl get pods
NAME                          READY   STATUS      RESTARTS   AGE
longhorn-ui-9d7b4bfc6-8zw55   1/1     Running     0          25m
longhorn-ui-9d7b4bfc6-7kpvm   1/1     Running     0          25m
longhorn-uninstall-msrx7      0/1     Completed   0          113s
>
> kl logs longhorn-uninstall-msrx7 | grep error
>

Reopen this ticket as using master-head images test again, still can see error log appered in uninstall pod.
> kl get pods
NAME                           READY   STATUS      RESTARTS   AGE
longhorn-ui-77757fcdfb-p5llz   1/1     Running     0          2m59s
longhorn-ui-77757fcdfb-bmvkc   1/1     Running     0          2m59s
longhorn-uninstall-hwbxp       0/1     Completed   0          83s
>
> kl logs longhorn-uninstall-hwbxp | grep error
time="2024-08-26T12:07:11Z" level=warning msg="Failed to uninstall" func="controller.(*UninstallController).handleErr" file="uninstall_controller.go:293" controller=longhorn-uninstall error="failed to delete instance managers: instancemanagers.longhorn.io \"instance-manager-6d195cf9767afe0ae413a88033cc21bf\" not found"

I see.
@ChanYiLin Nee to clean up err.
https://github.com/longhorn/longhorn-manager/blob/master/controller/uninstall_controller.go#L912
This might be better.
			if errDelete = c.ds.DeleteInstanceManager(im.Name); errDelete != nil {
				if datastore.ErrorIsNotFound(errDelete) {
					log.Info("InstanceManager is not found")
				} else {
					err = errors.Wrap(errDelete, "failed to mark for deletion")
					return
				}
			} else {
				log.Info("Marked for deletion")
			}

Pre Ready-For-Testing Checklist

[ ] Where is the reproduce steps/test steps documented?
The reproduce steps/test steps are at:

Steps:

should not have not found error in the installation logs (try 10 times, it is a flaky issue)

PRs:

https://github.com/longhorn/longhorn-manager/pull/3107

Verified pass on longhorn master(https://github.com/longhorn/longhorn-manager/commit/1bbd143608bd3c875b28c11779fd4cb5ec812868)
Uninstall longhorn master several times, did not find error appeared in uninstall job log.


chore: set strum::Display for LogLevel to uppercase

Description
Set strum::Display for LogLevel to uppercase and add warning.
Definition of Done Checklist

Not all of these items are applicable to all PRs, the author should update this template to only leave the boxes in that are relevant
Please make sure all these things are done and tick the boxes

# Author
- [ ] Changes are OpenShift compatible
- [ ] CRD changes approved
- [ ] Integration tests passed (for non trivial changes)

# Reviewer
- [ ] Code contains useful comments
- [ ] (Integration-)Test cases added
- [ ] Documentation added or updated
- [ ] Changelog updated
- [ ] Cargo.toml only contains references to git tags (not specific commits or branches)

# Acceptance
- [ ] Feature Tracker has been updated
- [ ] Proper release label has been added

Where did this come up? Would it be more appropriate to not implement Display at all? I assume that the naming here was trying to align with something in the first place, are we drifting out of compat with that?


Could you pls update to Django 1.10?

When saving image, error appears:
Exception Value: Cannot force an update in save() with no primary key.
Exception Location: /home/simsim/www/testproject/lib/python3.5/site-packages/django/db/models/base.py in _save_table, line 880

With Django 1.9.9 everything is ok
Thank you.

What version are you using? Try install it from current master branch.

When I tried to use imagestore 6 months ago, I tried with master branch.

Yes, but all tests passed with 1.10 https://travis-ci.org/hovel/imagestore/builds/216934436

Strange. Initially I added Imagestore to my existing project which was based on Django 1.10. When I got the error above, If I remember correctly, I rechecked using fresh instalation of Django 1.10 and got the same error.

Maybe it was a bug in django? https://code.djangoproject.com/ticket/27419
Anyway I need more info to reproduce.

I will check again later this week and inform you.

Release 3.0.0 on pypi. 1.10 pass all tests. Feel free to reopen if need.


Physically based bloom

Objective

Make the bloom effect energy conserving
Make the bloom effect impossible to misconfigure
Add a physically based alternative to threshold to preserve existing flexibility

Explanation
What is bloom
Bloom occurs in real life when light passes through an imperfect medium such as a lens and slightly scatters around before continuing on its way to the sensor or the retina. Bloom is effectively just a blur effect created by imperfections in glass or human eyes.
Motivation
To emulate it in a natural-looking way it should be energy-conserving and based on its real-life counterpart. The existing implementation is quite close but it does not emulate the scattering perfectly and is certainly not energy-conserving. As a result, the current implementation is easy to configure in an obnoxious way and ruin the look of the game.
Examples

Bloom example with existing implementation:

Bloom example in this PR:

Lighting example with existing implementation of bloom:

Lighting example with bloom in this PR:

Note: The existing implementation could look closer to this PR if the intensity is turned down, however, the existing implementation never results in a natural look at high intensity values, that is what the examples try to highlight.

Existing implementation with intensity of 1 (not related to a physical parameter):

Bloom in this PR with intensity of 1 (light is equally as likely to exit at any point of the lens). This is still WIP since the whole screen should be the same color

Solution

[ ] Calculate mip amount differently so that there the screen can be averaged to a single color at intensity of 1.
[x] Interpolate between each mip based on bloom intensity rather than adding them together.
[ ] Implement "deblooming" (same as tinting the lens and increasing the exposure; that way light that scatters more loses energy. This restores the artistic control previously provided by threshold but in a physically-based manner)

Changelog
Changed:

Bloom has a more natural look.
Deblooming parameter replaces threshold and knee.

Migration Guide

Remove threshold and knee fields from all instances of core_pipeline::bloom::BloomSettings.
Optinally use the deblooming filed to approximate the look threshold values above 0 created.

Thanks! I'll close this PR and and see if my contribution can be useful in #6677 instead


v49 Update

Lethal Company v49 update - tracking mod update progress

[x] BepInEx-BepInExPack
[x] notnotnotswipez-MoreCompany
[x] anormaltwig-LateCompany
[x] x753-More_Suits
[x] Evaisa-HookGenPatcher
[x] Evaisa-LethalLib
[x] Evaisa-LethalThings
[x] Rune580-LethalCompany_InputUtils
[x] Renegades-FlashlightToggle
[x] sunnobunno-YippeeMod
[x] EliteMasterEric-Coroner
[x] jockie-LethalExpansionCore
[x] Nuts-LethalPlushies
[x] PopleZoo-BetterItemScan
[x] FlipMods-LetMeLookDown
[x] OrtonLongGaming-FreddyBracken
[x] Blorb-WeatherMultipliers
[x] Drakorle-MoreItems
[x] Pooble-LCBetterSaves
[x] HolographicWings-LethalExpansion
[x] sfDesat-Orion
[x] FlipMods-FasterItemDropship
[x] Hexnet111-SuitSaver
[x] monkes_mods-JumpDelayPatch
[x] Sv_Matt-HideModList
[x] TeamClark-SCP_Foundation_Suit
[x] NotAtomicBomb-TerminalApi
[x] NiceHairs-NuclearLib
[x] NiceHairs-Symbiosis
[x] Krayken-DynamicDeadline
[x] Giltong-LethalCompanyDRP
[x] anormaltwig-TerminalExtras
[x] sfDesat-Aquatis
[x] raydenoir-SCP173CoilheadSFX
[x] Jordo-NeedyCats
[x] NiaNation-AbsasCosmetics
[x] Ryokune-CompatibilityChecker
[x] itsmeowdev-DoorFix
[x] KayNetsua-E_Gypt_Moon
[x] Ceelery-Kast
[x] KodiCraft-TermSpeak
[x] Electric131-OuijaBoard
[x] TeamBridget-Peaches_Castle
[x] PortableNavi-BetterInverseTeleporter
[x] Supremo-Hit_Haste
[x] willis81808-LethalSettings
[x] Nebulaetrix-ScanFix
[x] Spyci-CozyImprovements
[x] PostMortem-BetterLightning
[x] femboytv-LethalPosters
[x] quackinggander-SCPPosters
[x] RugbugRedfern-Skinwalkers
[x] x753-Mimics
[x] Renegades-WalkieUse
[x] Thorlar-HealthStation
[x] FlipMods-MoreBlood
[x] ohotdog-LootableMusicTapes
[x] akechii-DiscountAlert
[x] Zduniusz-LBtoKG
[x] femboytv-LethalPaintings
[x] femboytv-DeepRockPosters
[x] Festive_Arms-FNAF_Suits
[x] TheBeeTeam-LandmineFix
[x] 2018-LC_API
[x] bizzlemip-NoPenalty
[x] CoNcept_Temple_Modding-Scooby_Doo_Crew_Suits
[x] AlexCodesGames-AdditionalSuits
[x] Verity-TooManySuits
[x] FlipMods-BetterStamina
[x] EladNLG-EladsHUD
[x] BatTeam-LethalFashion
[x] Owen3H-IntroTweaks
[x] scoopy-Scoopys_Variety_Mod
[x] NomnomAB-RollingGiant
[x] Jamil-Corporate_Restructure
[x] linkoid-DissonanceLagFix
[x] Monkeytype-HideChat
[x] red_eye-LethalAutocomplete
[ ] FlipMods-TooManyEmotes
[x] FlipMods-HotbarPlus

Removed LethalExpansionCore and LethalPlushies

Removed LethalSettings

Temporarily removed TooManyEmotes (camera bug)
Temporarily removed HotbarPlus (doesn't rebind emotes)

Re-enabled LethalExpansionCore and LethalPlushies
Added LethalExpansionCoreModules
Added LethalLevelLoader

Added IAmBatby-LethalLevelLoader
Added jockie-LethalExpansionCoreModules

Removed compatibilitychecker due to deprecation

-Re-added HotbarPlus

Added More_Emotes

Removed LBtoKG due to incompat with ELADSHUD

Added Infernice
Added Acidir
Added Atllas_Abyss
Added Aridion
Removed LethalExpansionCoreModules

Removed IntroTweaks


Integrate Flow for type annotations

This change integrates Flow for static type checking. It adds flow type definitions via flow-typed, required type annotations, and type definitions for container component props. The flow-react-proptypes Babel plugin is used to generate proptypes for runtime checks. Includes few other small fixes, along with two simple unit tests regarding proptype generation.
Resolves #22 and also #44

Hello @mikkom, thanks a lot for the contribution, I really appreciate it 😸
Going to review it now 👍  I'm curious what exactly fixed #44?

Hi, thanks for all comments! :)  I think it may have been just the version update of babel-presets and/or eslint-plugin-import that fixed #44. I can check once I'm back at my computer. I'll make the requested changes then, as well. Cheers!

Ok, I now added yarn.lock to .npmignore and updated .travis.yml to run the test script (ESLint, Flow & unit tests).
And it seems that it was just the updating of babel-preset-es2015-rollup to latest version that fixed #44.

Thanks a lot for the work you put in on this 👍


dotnet: add support for basic blocks

Add support to calculate IL basic blocks, enabling basic block scope and loop detection for .NET files.

@mr-tz / @williballenthin before I dig in here any thoughts as to why tests would only be failing on Python 3.7?

Nope, but looks like something with pydantic...

https://github.com/mandiant/capa/blob/master/capa/features/freeze/__init__.py#L49
this line recently changed but i have no idea why it would fail on 3.7. i'll try to reproduce locally in a 3.7 virtualenv and see whats going on.

I like the rendering in the screenshot you shared - lots of detail and the
important stuff is highlighted.
Do you think we should also try to include the function name, when
possible? Using tokens is very precise and I don't think this should go
away; however, I wonder if including the function name might give more
context (especially when the names aren't obfuscated).

I like the rendering in the screenshot you shared - lots of detail and the important stuff is highlighted. Do you think we should also try to include the function name, when possible? Using tokens is very precise and I don't think this should go away; however, I wonder if including the function name might give more context (especially when the names aren't obfuscated).

I'm honestly torn here. I think displaying un-obfuscated method names is valuable, however, my work has seen few samples where this is the case. More frequently, I see large, obfuscated names that would be a pain to handle (display) correctly.
We could take a route simliar to de4dot by attempting to identify and rename obfuscated method names but I see that potentially confusing users who pivot from capa to a tool like dnSpy.
Reading your original message I see you say "when possible" which could be a valid path forward, e.g., we only display method names when we can identify the name has not been obfuscated at all (or past an established threshold).

Nice work. A few comments and maybe a larger question if this should maybe life in dncil or dnfile?

@mr-tz This came to mind about halfway through writing the code haha. I think the basic block logic likely belongs in dncil. Unless there are objections, once we've addressed any issues here I'll move the basic block logic to dncil and update this PR to use the updated dncil APIs.

Nice work. A few comments and maybe a larger question if this should maybe life in dncil or dnfile?

@mr-tz This came to mind about halfway through writing the code haha. I think the basic block logic likely belongs in dncil. Once we've addressed any issues here I'll move the basic block logic to dncil and update this PR to use the updated dncil APIs.

@mr-tz @williballenthin see https://github.com/mandiant/dncil/pull/55

I'm honestly torn here. I think displaying un-obfuscated method names is valuable, however, my work has seen few samples where this is the case. More frequently, I see large, obfuscated names that would be a pain to handle (display) correctly.
We could take a route simliar to de4dot by attempting to identify and rename obfuscated method names but I see that potentially confusing users who pivot from capa to a tool like dnSpy.
Reading your original message I see you say "when possible" which could be a valid path forward, e.g., we only display method names when we can identify the name has not been obfuscated at all (or past an established threshold).

I agree with everything you say here. I'd only recommend including the name when its useful and helpful. I do not think we should do any renaming or show any obfuscated names. So, if its reasonably easy to determine if a name is non-obfuscated, then I think we should maybe do that.
How to determine if non-obfuscated? I guess ASCII only, something around entropy, not mixing casing or numbers too weirdly, ...?
We should probably move this into a separate feature request.

@mike-hunhoff, do we want to keep this around here or close it?

@mike-hunhoff, do we want to keep this around here or close it?

We can close - I'll link the corresponding dncil PR back to this for documentation purposes.


Suggestion

Hello,
I'd like to propose an enhancement to our guild backup system. When a saved message originates from the client user, it would be beneficial to send it as the client user rather than through a webhook. Additionally, I suggest implementing a feature to save message components for all messages, particularly those containing buttons with links, as they can be transmitted via webhooks.
Furthermore, for messages with components sent by the client user, it would be great to save all components for the ability to restore the entire message with its components.

Hi @SjogrenDev! Unfortunately we cant sent the messages as the user themselves, Discord does not provide programmatic access to take action on a users behalf and at the time of server restoration, there is no guarantee the user is in the server or even exists anymore. The closest we can get is sending the message on a webhook with the name and icon swapped to match the user who sent it, which is how this package currently works.
It does look like its possible for this package to support saving and restoring message components that don't require a bot to handle the interaction which likely is only the link buttons as you mentioned. I don't currently have the time to implement this, but if you would like to submit a PR for it, I would be happy to merge and release it. It would require changing the fetchChannelMessages function in utils.js

Hi, I’m referring to the client user. (Bot itself) not other Discord users,
so the messages owned by the bot loading the backup would send its own
messages. Sure, I’ll look into your repo and get back to you.
On Sun 31. Dec 2023 at 22.56, Jacob Leeson @.***> wrote:

Hi @SjogrenDev https://github.com/SjogrenDev! Unfortunately we cant
sent the messages as the user themselves, Discord does not provide
programmatic access to take action on a users behalf and at the time of
server restoration, there is no guarantee the user is in the server or even
exists anymore. The closest we can get is sending the message on a webhook
with the name and icon swapped to match the user who sent it, which is how
this package currently works.
It does look like its possible for this package to support saving and
restoring message components that don't require a bot to handle the
interaction which likely is only the link buttons as you mentioned. I don't
currently have the time to implement this, but if you would like to submit
a PR for it, I would be happy to merge and release it. It would require
changing the fetchChannelMessages function in utils.js
—
Reply to this email directly, view it on GitHub
https://github.com/OutwalkStudios/discord-backup/issues/18#issuecomment-1873036224,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AOUD35U3KUJLZXPHOJRENRTYMHGOFAVCNFSM6AAAAABBHVBNZWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNZTGAZTMMRSGQ
.
You are receiving this because you were mentioned.Message ID:
@.***>

Oh I see what you mean now, my bad. Its been a while since I have worked with this package but I will take a look at this. This package ideally works independently of the bot itself, only requiring the guild to be passed in, but this could be done by providing the client object to the function and falling back to the webhook when its not provided. If you want to include this in your PR if you add the message component support you can, otherwise I will add this next time I get the chance to work on this package.

Hi,
I've created a PR. I've tested it in different scenarios and seems like webhooks support all components not just the link buttons (Discord.ButtonStyle.Link).


Add Java tutorial on Reached end of the file while parsing

The post has been created and named according to the rules and the grammatical errors were also checked for.
Type of change
Tutorial on troubleshooting "Reached end of the file while parsing" in Java
What should this PR do?
close   #289
What are the acceptance criteria?
1. Add a new file in the posts directory using the correct naming convention.
2. The post should have the correct preamble at the top of the file
3. Content of the post should follow the same format as https://learn.sourcegraph.com/how-to-troubleshoot-python-zerodivisionerror
4. The author should be added to the authors.yaml (optional)
How should this PR be tested?

The post can be viewed locally by running npm run dev and navigating to the post at http://localhost:3000/how-to-troubleshoot-java-reached-end-of-file-while-parsing
Check that the post has correct spelling and grammar

Pull request process
Reviewers:

Test functionality using the criteria above.
Offer tips for efficiency, feedback on best practices, and possible alternative approaches and things that may not have been considered.
For shorter, "quick" PRs, use your best judgement on #2.
Use a collaborative approach and provide resources and/or context where appropriate.
Provide screenshots/grabs where appropriate to show findings during review.

Reviewees:

Prefer incremental and appropriately-scoped changes.
Leave a comment on things you want explicit feedback on.
Respond clearly to comments and questions.

@Ln11211 this tutorial is now live: https://learn.sourcegraph.com/how-to-troubleshoot-java-reached-end-of-file-while-parsing#


Bump LVGL version to latest release

Summary
LVGL
Bump version to 7.0.2, most Kconfig options are compatible, with a few new options.
LVGL Demo

Migrate touch calibrate programs to v7.

Previous demo are deprecated by upstream,  now we download lv_examples tarball from GitHub like LVGL library.

Impact
No impact for most boards, but imxrt1060-evk's lvgl defconfig contains some deprecated configs,
may make ci problems.
See https://github.com/apache/incubator-nuttx/pull/1261
Testing
Tested on stm32f429i-disco

Hi Huang Qi (@no1wudi) the issue appears on the build system not in the source code. Could you please check?

Ok, I restarted the workflow let to see if it will work now.

Ok, I restarted the workflow let to see if it will work now.

Ok, I restarted the workflow let to see if it will work now

It seems the error occurred here:

2020-06-17T12:53:32.5126480Z   Normalize imxrt1060-evk/lvgl
2020-06-17T12:53:33.2381085Z 23d22
2020-06-17T12:53:33.2381553Z < CONFIG_EXAMPLES_LVGLDEMO_THEME_2=y
2020-06-17T12:53:33.2381698Z 47,48d45
2020-06-17T12:53:33.2381840Z < CONFIG_LV_USE_THEME_ALIEN=y
2020-06-17T12:53:33.2381953Z < CONFIG_LV_USE_THEME_DEFAULT=y
2020-06-17T12:53:33.2382076Z 51,52d47
2020-06-17T12:53:33.2382201Z < CONFIG_LV_USE_THEME_NEMO=y
2020-06-17T12:53:33.2382328Z < CONFIG_LV_USE_THEME_NIGHT=y
2020-06-17T12:53:33.2382451Z 54d48
2020-06-17T12:53:33.2382572Z < CONFIG_LV_USE_THEME_ZEN=y

Ok, I restarted the workflow let to see if it will work now

It seems the error occurred here:

2020-06-17T12:53:32.5126480Z   Normalize imxrt1060-evk/lvgl
2020-06-17T12:53:33.2381085Z 23d22
2020-06-17T12:53:33.2381553Z < CONFIG_EXAMPLES_LVGLDEMO_THEME_2=y
2020-06-17T12:53:33.2381698Z 47,48d45
2020-06-17T12:53:33.2381840Z < CONFIG_LV_USE_THEME_ALIEN=y
2020-06-17T12:53:33.2381953Z < CONFIG_LV_USE_THEME_DEFAULT=y
2020-06-17T12:53:33.2382076Z 51,52d47
2020-06-17T12:53:33.2382201Z < CONFIG_LV_USE_THEME_NEMO=y
2020-06-17T12:53:33.2382328Z < CONFIG_LV_USE_THEME_NIGHT=y
2020-06-17T12:53:33.2382451Z 54d48
2020-06-17T12:53:33.2382572Z < CONFIG_LV_USE_THEME_ZEN=y

But no error or warning in my local build for this board.

Yes, you will need to update ALL defconfig files under boards/
find boards -name defconfig

And each of these configurations will have to go through tools/refresh.sh
tools/refresh.sh --silent

Then commit and push the result to your branch.

Ok, I restarted the workflow let to see if it will work now

It seems the error occurred here:

2020-06-17T12:53:32.5126480Z   Normalize imxrt1060-evk/lvgl
2020-06-17T12:53:33.2381085Z 23d22
2020-06-17T12:53:33.2381553Z < CONFIG_EXAMPLES_LVGLDEMO_THEME_2=y
2020-06-17T12:53:33.2381698Z 47,48d45
2020-06-17T12:53:33.2381840Z < CONFIG_LV_USE_THEME_ALIEN=y
2020-06-17T12:53:33.2381953Z < CONFIG_LV_USE_THEME_DEFAULT=y
2020-06-17T12:53:33.2382076Z 51,52d47
2020-06-17T12:53:33.2382201Z < CONFIG_LV_USE_THEME_NEMO=y
2020-06-17T12:53:33.2382328Z < CONFIG_LV_USE_THEME_NIGHT=y
2020-06-17T12:53:33.2382451Z 54d48
2020-06-17T12:53:33.2382572Z < CONFIG_LV_USE_THEME_ZEN=y

But no error or warning in my local build for this board.

Yes, you will need to update ALL defconfig files under boards/
find boards -name defconfig | xargs grep -l LVGL

And each of these configurations will have to go through tools/refresh.sh
tools/refresh.sh --silent

Then commit and push the result to your branch.

Thanks, only four board has lvgl related defconfig, and only this board use these options,
I fixed it manually, the ci flow should pass all check now.


Pull 3.0 CROSS_ARCH changes into 4.0

Going to make a separate commit -- the rebase approach is too messy.


[SPARK-47902][SQL]Making Compute Current Time* expressions foldable

What changes were proposed in this pull request?

This PR is a followed of this PR that made "compute current time" family of expressions Unevaluable. Implicitly, all Unevaluable expressions are also not foldable. Hence, we have a regression comparing to state prior to 44261 where "compute current time" expressions could have been used in places where constant folding is required.
Proposed change is to keep these expression Unevaluable in a sense that eval/codeGen  can't be called but to allow folding. This is a special case given that these expressions are supposed to be replaced by QO with literals (that are foldable) so proposal is to create new interface for this family of expressions.
Why are the changes needed?

Explained above.
Does this PR introduce any user-facing change?

Yes.
How was this patch tested?

Additional test is added that ensures that CurrentDate can be used in places that require folding.
Was this patch authored or co-authored using generative AI tooling?

No.

thanks, merging to master!


ServiceInstanceBindingDoesNotExistException extends RuntimeException and not ServiceBrokerException

I have stumbled upon this case where only the ServiceInstanceBindingDoesNotExistException in package  org.springframework.cloud.servicebroker.exception does not extend the ServiceBrokerException. Is this intended for any purpose, if not we should change it to be in line with other exceptions so as to have one base exception to handle.

Thanks for reporting. Yes, it should extend ServiceBrokerException to be consistent with the others.


Can you use AOE NP earlier than the last battle, while using skills?

This is specifically using the newest version, I don't think the old one ever had this problem.
Granted this is my first time using Arash.
When I tried to use
"g5,ahi1,d,f,e,bc"
It would break and no longer use any skills other than the first one.
I'm not 100% sure what the problem with other than it may because Arash is murdering the first wave and moving to the next.
I tried this with NP Spam ON and OFF and it broke regardless.
I'm using NA at the moment and not sure how I should fix it.
Not using NP's at all had it working but otherwise not sure what to do,

I also tried making it
"g,ahi1,d,f,e,bc"
While turning NP Spam on but that also failed unfortunately as it completely stops using NP's as long as there are any skills to be used.
It's only when I choose an empty list that's it willing to use my NP

Is this problem specific to Arash or something?  I'll try a different servant and see if that fixes it

Nope the same problem happens now if I use any AOE Servant, not sure if it would happen with ST NP as well

Hmm tried it with the old one and apparently this was always a problem

But then before I used NP on the final wave and not on the earlier one's, or I would chain multiple NP's to end it on that turn.

From your skill string, it seems that this is what's supposed to happen:
1/3 - Turn 1:
[g] Use 3rd Servant's 1st skill.
[5] Use 2nd Servant's NP.
1/3 - Turn 2:
[a] Use 1st Servant's 1st skill.
[h] Use 3rd Servant's 2nd skill.
[i1] Use 3rd Servant's 3rd skill on 1st Servant.
1/3 - Turn 3:
[d] Use 2nd Servant's 1st skill.
1/3 - Turn 4:
[f] Use 2nd Servant's 3rd skill.
1/3 - Turn 5:
[e] Use 2nd Servant's 2nd skill.
1/3 - Turn 6:
[b] Use 1st Servant's 2nd skill.
[c] Use 1st Servant's 3rd skill.
Can you describe what is happening instead?

I'm getting
Battle 1/3 - Turn 1:
[g] Use 3rd Servant's 1st skill.
[5] Use 2nd Servant's NP.
After that the round is over and it becomes
Battle 2/3 - Turn 2:
What should happen is
[a] Use 1st Servant's 1st skill.
[h] Use 3rd Servant's 2nd skill.
[i1] Use 3rd Servant's 3rd skill on 1st Servant.
Instead it just goes straight into attacking normally.
Do I have to put in a different command for rounds now?
Before it ignored the round unless you specified it.

Originally my string was
ad,ef,0,0,bc,456
I've never specified anything in regard to round and my first servants later skills came off in another round.
Is it because I had some 0 for skipping turns?

There are some changes in the code that prevented this, and from the first place your string should not be executable in other stages except 1/3. For stage counter, add # to indicate stage change (refer Autoskill doc)

Understood just to clarify then
I would change my line
"g5,#ahi1,d,f,e,bc"

It turns out it's the second and this fixed my problem.
Thank you for the help.


Code Generator for Bicep/ARM in resources.azure.com

Is your feature request related to a problem? Please describe.
The provider explorer "resources.azure.com" currently only provide generation of Ansible Playbooks to "consume" ARM Providers. It would be great to be able to create Bicep/ARM Templates directly as well, as a lot of customers struggle building the actual templates as they don't know what the provider actually supports.
Describe the solution you'd like
Currently resources.azure.com only generates Ansible Playbooks, but this would be great if ARM/Bicep could be selected here to get code generated to call the particular provider/operation as seen in the screenshot:

It's not directly related to Bicep itself, but not aware if/where we have a repo for the Resources Explorer. So hope you can coordinate further, as discussed in the Bicep Community Call.

Great suggestion!


fix: bump dependencies versions

Issue
https://gravitee.atlassian.net/browse/ARCHI-254
Description
BREAKING CHANGE: use apim version 4
Additional context

:tada: This PR is included in version 3.0.0-alpha.1 :tada:
The release is available on:

3.0.0-alpha.1
GitHub release

Your semantic-release bot :package::rocket:

:tada: This PR is included in version 3.0.0 :tada:
The release is available on:

3.0.0
GitHub release

Your semantic-release bot :package::rocket:


A wild console.log appears

Noticed this spitting out image dimensions in my console. Intentional?
https://github.com/akfish/node-vibrant/blob/master/src/browser-image.coffee#L25
console.log @width, @height

Also, awesome tool. Checking it out for the first time today. :+1:

Thanks for pointing it out. It's just some debug code being left over. I'll clean it up.


Frontend: Emit reference dependencies at the end of the frontend pipeline

As part of eliminating cascading dependencies, we need to make sure to
capture any dependencies discovered during SILGen and IRGen.
This is a little bit tricky because we exit early in various places in
the pipeline, so we want to do it after performCompileStepsPostSema()
returns, but we can't do it too late, because the ASTContext might
already have been deallocated.
So emit the dependencies manually before freeing the ASTContext if we
decide to do that, or just do it before returning from performCompile()
using a SWIFT_DEFER otherwise.
This should have no observable effect until we start recording dependencies
for lookups done on behalf of declarations in secondary files.

@swift-ci Please smoke test

@swift-ci Please clean smoke test macOS

@swift-ci Please clean smoke test


(Relay) Client is kicked when using the recipe book on xbox

When using relay and connecting to any server (That I have tried) using the recipe book disconnects the client.
This is my console output when I enable the debug mode, directly after any recipe is selected in the recipe book.

The code I have used is directly copied from API.md except the version is set to 1.20.0  and process.env.DEBUG = 'minecraft-protocol' has been added to the top of the code.

Can you explain how to replicate the issue and if it happens when you join or do something in-game? If you set logging: true option in the Relay options you'll get more packet debugging information, please provide the console output with that set. Also to confirm, you can't replicate this in-game, right?

Apologies, it has only now occurred to me that this only seems to happen only when joining a Relay server from an Xbox device so this issue may not be as striking as first thoughts might suggest.
When I added logging: true to the Relay options I was unable to join the world fully because of the constant stream of text being printed in my console.
To replicate this issue, I simply opened my inventory or a crafting table (presumably anything with a recipe book, such as a stonecutter, although I have not tested all available interactable blocks.) and clicked on any available item to craft.

(Clicking/Pressing A here would kick the client)
I cannot replicate this issue in a normal/vanilla session of the game.

Is this still an issue on latest?

Yes.

This is no longer an issue as of latest.


doctor: better handling of docker version

With Docker 17.03.0-ce I had this error:
$ ./bgperf.py doctor
Traceback (most recent call last):
  File "./bgperf.py", line 400, in <module>
    args.func(args)
  File "./bgperf.py", line 67, in doctor
    ok = int(''.join(ver.split('.'))) >= 190
ValueError: invalid literal for int() with base 10: '17030-ce'

$ docker version
Client:
 Version:      17.03.0-ce
 API version:  1.26
 Go version:   go1.7.5
 Git commit:   60ccb22
 Built:        Thu Feb 23 10:57:47 2017
 OS/Arch:      linux/amd64

Server:
 Version:      17.03.0-ce
 API version:  1.26 (minimum version 1.12)
 Go version:   go1.7.5
 Git commit:   60ccb22
 Built:        Thu Feb 23 10:57:47 2017
 OS/Arch:      linux/amd64
 Experimental: false

thanks!


GRPC server graceful shutdown

The context
We deploy our service in K8s and provide a gRPC streaming API so the server can hold open connections for a period of time.
We need to have a CD to redeploy the new version of the service, but we want to prevent K8s from killing our service if there is an open GRPC stream.
The question
Do we have a support for graceful shutdown of the service only when we don't have open connections?
I see this: https://github.com/grpc-ecosystem/grpc-spring/blob/master/grpc-server-spring-boot-starter/src/main/java/net/devh/boot/grpc/server/serverfactory/GrpcServerLifecycle.java#L58
But I don't see we check the state of the service itself

Have you tried this config:
https://github.com/grpc-ecosystem/grpc-spring/blob/e52df51897a4f5bebbe0e82d5fefe3d419d86c08/grpc-server-spring-boot-starter/src/main/java/net/devh/boot/grpc/server/config/GrpcServerProperties.java#L111

Thanks
I haven't tried it yet. I will test it with K8s and let you know the result

Looks like it works. At least I see that service waits for 5 minutes before shutdown. But I configured shutdownGracePeriod=-1
For K8s you should additionally adjust terminationGracePeriodSeconds for 24h (just for testing).
I tried to configure:
grpc:
  server:
    port: 6565
    reflection-service-enabled: true
    shutdown-grace-period: -1
    enable-keep-alive: true
    keep-alive-time: 86400
    keep-alive-timeout: 86400
    permit-keep-alive-without-calls: true
    permit-keep-alive-time: 86400

But service is getting killed after 5 minutes, I can't find what else we can configure and what is that 5 minutes timeout.
GrpcServerLifecycle          : Completed gRPC server shutdown

Looks like it works. At least now I see that K8s can't kill it for configured period of time.
Additionaly to shutdownGracePeriod =-1 I configured terminationGracePeriodSeconds for 24h (just for testing).
I also tried to adjust various confs:
grpc:
  server:
    port: 6565
    reflection-service-enabled: true
    shutdown-grace-period: -1
    enable-keep-alive: true
    keep-alive-time: 86400
    keep-alive-timeout: 86400
    permit-keep-alive-without-calls: true
    permit-keep-alive-time: 86400

But after 5 minutes the app is getting killed anyway. I can't find a conf that is responsible for that.
[SpringApplicationShutdownHook] [trace_id=, span_id=]n.d.b.g.s.s.GrpcServerLifecycle          : Completed gRPC server shutdown

You could add a log line/debug break point here:
https://github.com/grpc-ecosystem/grpc-spring/blob/e52df51897a4f5bebbe0e82d5fefe3d419d86c08/grpc-server-spring-boot-starter/src/main/java/net/devh/boot/grpc/server/serverfactory/GrpcServerLifecycle.java#L154
To check if the waiting gets interrupted somehow.

Thanks, I'm already looking into such a logic. It's not easy to debug everything with K8s. I will try to add more logs by DEBUG or use Telepresence or something to understand why the service is getting killed after 5 minutes.

The connection is closed from the K8 side. When I run the server without K8s and send kill -TERM to the Java process, it waits to close all connections properly.  Need to check ingress timeouts.

When running a Java process inside a Docker container, sending a SIGTERM signal (kill -TERM 1) results in immediate termination rather than a graceful shutdown. This issue does not occur when running the same Java process locally and do the same kill.
kubectl exec -it pod_id -- /bin/bash
kill -TERM 1

Locally, it works fine but when server is inside Docker container graceful shutdown and I can't understand why localServer.awaitTermination(); immediately kills the server.

I'm running out of ideas. Do you have any ideas on further investigation or narrowing down the scope?
Thanks!

Sorry, unfortunately not.

I think localServer.awaitTermination(); doesn't work as I expect :( . I'm working on implementing a custom ShutDown Hook to check the number of active streams before terminating.
This article describes similar problem https://fedor.medium.com/shutting-down-grpc-services-gracefully-961a95b08f8
Just FYI. Thanks for the help

Yes, I expected it should already be handled downstream. Creating an issue on grpc-java is a good thing.


Common Data Service Odata calls taking 20-30 seconds on first call

We are making odata calls using S2S authentication and it is taking 20-30 seconds sometimes more on first call. After that it takes 1-2 seconds or less.
Why is it taking time on first call and how we can improve this?

Can you please post this question on the Common Data Service for Apps forum: https://powerusers.microsoft.com/t5/Common-Data-Services/ct-p/PA_CommonDataServices
Closing the issue.


feat(cyclefold): implementation of cyclefold IVC

Implement cyclefold IVC with protogalaxy folding scheme

I created another issue for research. Since the TODO of removing the old IVC is after implementation of cyclefold

#373


Source Code

When I download source code there are several errors.
GPS.dll   not found    I found a copy and linked it
ADAM6060_AGILENT87106 not found
Error	47	'getNumChannels' is not a member of 'System.Diagnostics.Switch'.	C:\Users\emc1\Documents\Visual Studio 2013\Projects\85-EIS-PUMA-1.7.6\Supporting Controllers\AntennaSwitch.vb	51	34	PUMA

The source code does not include the dlls.  You must install the version of the program first.  This will install the appropriate dlls.  Then you can use the source code.


Support django Choices for graphql enums

With django 3.0 came the choices model field type See here. It would be nice if this integration converted those values into an enum for us so we don't have to declare the same enum twice and the source of truth can remain the model.
E.G.
Declaration in model
class PlayerTypes(models.TextChoices):
    FA = "FA", "Free Agent"
    PermFA = "PermFA", "Permanent Free Agent"
    Signed = "Signed", "Signed"
    Inactive = "Inactive", "Inactive"

Example usage?
@strawberry.django.type(models.Player)
class Player:
    name: auto
    type = strawberry.enum(models.PlayerTypes)

So far, I've found this to work just fine, like so:
PlayerType = strawberry.enum(models.PlayerTypes)

@strawberry.django.type(models.Player)
class Player:
    name: auto
    type: PlayerType

@LucidDan, thanks for the tip.
@deibeljc, does this solution work for you?

Works in the proposed way by @LucidDan  but should be documented somewhere.


mongoose.useDb() multiple databases

I want to use the (useDb feature)[https://github.com/Automattic/mongoose/wiki/3.7-(unstable)-Release-Notes#connection-pool-sharing] but I'm not sure how to do it with Typegoose.
I tried the following:
  const db2 = mongoose.useDb(myDatabaseName)

  const RoomModel = new Room().getModelForClass(Room, {
    existingConnection: db2 // tried existingMongoose too
  })

  const room = new RoomModel()

  await room.save()

This works the first time, a database is created if it didn't exist and the save is successful. But if I do another call where myDatabaseName is different, it will execute the call on the first database.
How do I get Typegoose to work dynamically with multiple databases?

Had some time to look into this again and figured out a working solution:
export async function addRoom(args: IAddRoomArgs) {
  const newConnection = mongoose.connection.useDb(args.organizationId)

  const NewModel = newConnection.model('Room', RoomModel.schema) as ModelType<Room>

  const room = new NewModel()

  await room.save()

  return room
}

Generic version:
import * as mongoose from 'mongoose'
import { ModelType, InstanceType } from 'typegoose'

export function getModelForDb<T>(databaseName: string, model: InstanceType<T>): ModelType<T> & T {
  const db = mongoose.connection.useDb(databaseName)

  const DbModel = db.model(model.modelName, model.schema) as ModelType<T> & T

  return DbModel
}

It's not working in my case.
Can you please Explain how to use this with an example and how to make connection with using of typegoose.

@joravkumar this repo & project got moved to a new location please open a new issue if you still encounter it

@hasezoey @Christilut Is usedb the most performant way to go for implementing multi tenancy?

I didn't use it at scale, only with a few users at a time but I didn't notice any problems

Use the following options to limit excessive memory consumption.
const useDbOptions = {    // makes sure that connections are reused for existing tenants     useCache: true,     // no listeners are attached on the main connection.      noListener: true }  mongoose.connection.useDb(databaseName, useDbOptions);


Deploy with latest caniuse-db version?

I like this website, thank you for providing it!
The version of caniuse-db currently in use is 1.0.30001019, released Jan 5, 2020. Since that date Edge Blink has been released and various versions of Firefox and Chrome. As a result the versions shown here are outdated: https://browserl.ist. We just run into this as we advertise something like last 2 Edge versions. However as we've updated caniuse to some newer version, that doesn't mean Edge 17 and 18, but Edge 81 and 83.

We are collecting funds for free big and important refactorings in Browserslist ecosystem including website.
https://opencollective.com/browserslist

For the time being you can use https://browserslist.innocore.pl/
It's automatically redeployed each week with latest caniuse version.