[Bug - Crash] Getting crash in RNNotificationStore

Hello everyone, I am seeing this crash in Crashlytics, it's happening sporadically.  Not sure why this is happening, just that its happening in (RNNotificationsStore.m:61) and (RNNotificationsStore.m:51).
here is the crash log
BUG IN CLIENT OF LIBDISPATCH: Unbalanced call to dispatch_group_leave()
Crashed: com.apple.main-thread
0  libdispatch.dylib              0x39a80 dispatch_group_leave.cold.1 + 36
1  libdispatch.dylib              0x4878 _dispatch_group_wake + 130
2  App                                   0x36ab74 __69-[RNNotificationsStore completePresentation:withPresentationOptions:]_block_invoke + 61 (RNNotificationsStore.m:61)
3  libdispatch.dylib              0x1e6c _dispatch_call_block_and_release + 32
4  libdispatch.dylib              0x3a30 _dispatch_client_callout + 20
5  libdispatch.dylib              0x11f48 _dispatch_main_queue_drain + 928
6  libdispatch.dylib              0x11b98 _dispatch_main_queue_callback_4CF + 44
7  CoreFoundation                 0x51800 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 16
8  CoreFoundation                 0xb704 __CFRunLoopRun + 2532
9  CoreFoundation                 0x1ebc8 CFRunLoopRunSpecific + 600
10 GraphicsServices               0x1374 GSEventRunModal + 164
11 UIKitCore                      0x514b58 -[UIApplication _run] + 1100
12 UIKitCore                      0x296090 UIApplicationMain + 364
13 App                    0x4ed4 main + 7 (main.m:7)
14 ???                            0x104b31da4 (Missing)

And it happens here as well, seems to happen when removing key from handler dictionary.
Crashed: com.apple.main-thread
0  libdispatch.dylib              0x39a80 dispatch_group_leave.cold.1 + 36
1  libdispatch.dylib              0x4878 _dispatch_group_wake + 130
2  App                                   0x36aa50 __39-[RNNotificationsStore completeAction:]_block_invoke + 51 (RNNotificationsStore.m:51)
3  libdispatch.dylib              0x1e6c _dispatch_call_block_and_release + 32
4  libdispatch.dylib              0x3a30 _dispatch_client_callout + 20
5  libdispatch.dylib              0x11f48 _dispatch_main_queue_drain + 928
6  libdispatch.dylib              0x11b98 _dispatch_main_queue_callback_4CF + 44
7  CoreFoundation                 0x51800 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 16
8  CoreFoundation                 0xb704 __CFRunLoopRun + 2532
9  CoreFoundation                 0x1ebc8 CFRunLoopRunSpecific + 600
10 GraphicsServices               0x1374 GSEventRunModal + 164
11 UIKitCore                      0x514b58 -[UIApplication _run] + 1100
12 UIKitCore                      0x296090 UIApplicationMain + 364
13 App                    0x4ed4 main + 7 (main.m:7)
14 ???                            0x1054a5da4 (Missing)

I'm actually having the exact same issue, sporadic crashes on the same lines.

I'm seeing that same issue too - 77 occurences in 2 weeks, across different OS versions and phones. I'm not sure what's happening, or how to recreate it.
-[RNNotificationsStore completePresentation:withPresentationOptions:] RNNotificationsStore.m, line 60

That's the problem with me, I can never catch it in the act but it always happens when calling the completionHandler. I've checked the timing and it shouldn't be timing out as there was 8 seconds in processing which is not enough to have the expiry timer being triggered.

I am also dealing with this issue for IOS, specifically related to the second crash report provided:
RNNotificationsStore completeAction:]_block_invoke + 2394552 (RNNotificationsStore.m:51)
The issue on my end frequently appears the first time a user receives a notification, but after the app crashes the issue seems to go away. Has anyone had any luck solving this?

Same error to me.
i used react native 0.63.5 and react native notification 4.3.3
in debug mode ios crash when foreground notification. but it's okay to get notification in the background
I don't get any notification and crash log when I send it to testflight or production.

With me it happens always on background notifications and if I remove the completion callback it still happens.

I found out when I remove the completion callbacks the crash goes away.
I got the same crash (RNNotificationsStore.m:51) everytime I opened a notification from the background. Foreground notifications had no problems.
The app is deployed to Testflight, with v. 4.3.3 and react-native v. 0.70.5

@hstorz removing the completion callback appears to be working on our end as well (when app is running in the background or not), thanks for sharing! Do you know why this resolves the issue? We haven't seen any yet, but have you experienced any other issues after removing the callback?

Just got this when testing, looks like the same thing:

I was running into this same problem and figured out it was being caused by calling the registration methods on Notifications.events() multiple times. In my case, these event listeners were initialized inside of a useEffect hook that would re-trigger every time the app was backgrounded and then foregrounded. I solved it by moving the handlers to a useEffect hook without any dependencies.
Example:
useEffect(() => {
  Notifications.events().registerNotificationReceivedForeground(() => { ... });
  ... etc
},[]);

@brianarpie-forme  if you need dependencies, you need to remove the subscription when component unmounted to avoid that scenario.
useEffect(() => {
  const notification Notifications.events().registerNotificationReceivedForeground(() => { ... });
  return () => {
     notification.remove();
  }
},[dependencies]);

Thanks @KhimGurung! I was having issues with the app reloading when I tapped a notification.  Every time that happened the events would register again and I'd get many notifications displayed for each one sent.  The .remove() fixes that.
Now I just have to figure out why it keeps reloading the app.

I was running into this same problem and figured out it was caused by calling the registration methods on Notifications.events() multiple times and then receiving a push notification. In my case, these event listeners were initialized inside a useEffect hook that would re-trigger every time the app was backgrounded and then foregrounded. I solved it by moving the handlers to a useEffect hook without any dependencies.
Example:
useEffect(() => {
  Notifications.events().registerNotificationReceivedForeground(() => { ... });
  ... etc
},[]);

Perfect, I could reproduce the crash as you mentioned by calling twice without the .remove() and then trying to open a notification.
And preventing two calls by using listener.remove() fixed it.
Awesome, thank you so much!


Have you fine-tune the Reid model on MOT dataset?

Hi @longcw , I've replaced the Reid part of extracting features by my own trained model, the evaluation result gets worse. Have your fine-tune the Reid model on the MOT dataset?

No, the reid model was trained on a combination of market1501 and duke reid dataset.
I implemented the part-aligned reid (https://arxiv.org/abs/1707.07256) and got about 79.7 rank-1 on market 1501 dataset. Then the trained model was used for tracking without finetuning.

I found that the order of magnitudes of our Reid feature are different, maybe I need to normalize the Reid feature

@longcw Hi, what's the reference when you set min_ap_dist and gating_threshold? Now I tried exclusive process to find the best min_ap_dist for my Reid model, but I have no idea on how to set the gating_threshold. Could you please explain to me?

Hi @longcw , after I normalize my Reid feature, I found the distribution of dists changes from approximately [0.1, 1.5] to [0.003, 0.08] (my feature size is 1x2048, and the original is 1x512), so I tried some min_ap_dist(0.05,0.06, etc.), but the result's always worse than the original ones. It's strange because I didn't change any other part and my Reid model is tested to be stronger on Market1501(90.0% rank-1), do you have any reminder on this condition?

I am wondering why the distance changed to [0.003, 0.08] after you normalized the feature. L2 distance on two normalized features is same to the cosine distance (only different from some constants). So it should be in [0, 1] or something similar.
Second, I also tested resnet50 model with about 90% rank-1 on market1501 while the tracking performance is similar or even worse. I tried to train the model on market1501 and test it on duke and only got about 20%-30% rank-1. Reid models are very easy to overfit on the training set. So I train the model on three datasets to achieve better generation ability. Worse reid performance doesn't imply a worse tracking result. I think this is one reason you got a worse result.
To improve the model for tracking, the first thing is to improve the generation ability rather than achieve a higher score on the training set, unless you train the model on the tracking dataset directly.

Thank you, you've got a great point. I think the distance range still in [0,1], but the numbers are really small. I gonna train the Reid model on more dataset and let you know the results~

Hi, what's the third dataset you trained on? I trained the model on the combination of Market1501 and DukeMTMCreid, the generation still seems not good, the distances becomes in the range [0, 0,2]

market1501, duke, and cuhk03.
But I am still wondering why you got the range of [0, 0.2]. It's an unnormal small range for cosine distance or L2 distance on normalized features.
For example, the following image is the distance distribution on MOT16-02.

I didn't normalize the feature in training, that's the only reason I can think about...

I varies the min_ap_dist and visualize the result, it seems not bad...

Hi, I tried with a reid model using normalized feature in training, the distance value is still small.
While, as I add more data into training set, the distance value gets larger, e.g. [0,0.1] for model on Market1501, [0, 0.2] for model on Market1501+Duke, [0, 0.3] for model on Market1501+Duke+Msmt17.
Maybe it's because of the network structure? For my model, I use resnet50 as backbone and get the conv5_x feature for further classification, while your model split the feature and align the feature with body part, so your feature map differs more in each part?

Maybe you can try to plot the distribution of positive and negative distances as I showed before, to find the best threshold and check the range.

so I have a question ，how to train the reid model in MOT dataset? fine-tune the trained  Reid model(we have trained on Market1501,Duke etc)on the MOT dataset or train on MOT dataset from other imgnet pretrain model?

so I have a question，how to train the reid model for  MOT dataset or others? fine-tune the trained Reid model(we have trained on Market1501,Duke etc)on the MOT dataset or train on MOT dataset from other imgnet pretrain model? @longcw

So I have a question，how to train the reid model for MOT dataset or others? fine-tune the trained Reid model(we have trained on Market1501,Duke etc)on the MOT dataset or train on MOT dataset from other imgnet pretrain model? @longcw

@longcw I plot the cosine distance of MOT-02 with my Reid model:

@ I'm trying to reproduce your reid model and I notice you define 'SpatialCrossMapLRN' in googleNet, what is this used for?

@Kewenjing1020 It's a LRN layer https://www.reddit.com/r/MachineLearning/comments/52jjmi/lrn_layer_with_googlenet/

@Kewenjing1020 @YgRen The reid model was trained by my pytorch re-implementation of https://github.com/zlmzju/part_reid.
Maybe I can share the training code later if you are interested in it.

@longcw Your work is very interesting！I'm very interested in your training process.Looking forward to your sharing so that I can reproduce your results.Thx！

Hi @longcw, @Kewenjing1020 can you tell me how to re-train Patchclassifier from scratch?

@shibu38 Hi, I didn't try to reproduce patch classifier yet.

@longcw I tried to retrained reid by adding a classifier after your network and fine-tune from your model, but the code always corrupts. Then I removed the LRN layer, then it runs well but with a really bad result...

@Kewenjing1020 Hi, do you have any idea how to do that?? or Do you have any plan in future to that??

@longcw
Hi, my features distance finally become normal. It's because the image preprocess part doesn't consist with that in my model training code.
Shame of me taking so long to find the bug. TT

Is googleNet for Reid? And squeezeNet for what?

Are they both from https://github.com/zlmzju/part_reid?

Please read the paper.
Crazy-stones<EMAIL_ADDRESS>于2019年5月10日周五 下午5:22写道：

Are they both from https://github.com/zlmzju/part_reid?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/longcw/MOTDT/issues/8#issuecomment-491222301, or mute
the thread
https://github.com/notifications/unsubscribe-auth/ABPJJAARU73XSA4OFUMYQFDPUU5D7ANCNFSM4F3PKZYA
.

I generally know that you get the re-id model from https://github.com/zlmzju/part_reid which uses part-aligned reid and GoogleNet. But I still do not understand why you need two models and what are their functions?

@longcw Can you solve my question? Thanks!

I generally know that you get the re-id model from https://github.com/zlmzju/part_reid which uses part-aligned reid and GoogleNet. But I still do not understand why you need two models and what are their functions?

Section 3.2, 3.4 here
@Crazy-stones: As the author mentioned, reading the paper might help.


After host recover from reconnecting stack's don't update in that same host

After a host recover from a reconnecting state the stack's in that host don't update automatically. I have to update the stack again to changes take effect in the affected host.

@fernandoneto is referring to global services, whenever you get a host online or add a new host, it should schedule a deployment of a container into those, thats not occurring. (it was on older versions)
Reproducible steps:

Create an empty environment
Create a stack
Add a global service
Add a host
At this time, service should be scheduled on the recently added host, it won't be unless you edit the service and save it.

I am unable to reproduce. If I add a host, the service is schedule on the recently added host.
When you "edit" the service, what are you doing? Are you just clicking on edit and then save?
What version of Rancher are you using? Can you share your docker-compose.yml of the global service.

Has happened with a host that went from Reconnecting state to Active, and with a host we added back up.
The services affected with this behavior were: a load-balancer and one maintenance image, both are running as global services.
It initially happened with me more than once, always with Reconnecting hosts being back up (instances were being deleted but not populated). Seems this behavior is intermittent because today it didn't happened once.
Component	Version
Rancher	v0.51.0
Cattle	v0.130.0
User Interface	v0.78.0
Rancher Compose	v0.7.0

autotune:
  environment:
    net__ipv4__tcp_max_orphans: '40000'
    net__ipv4__tcp_fin_timeout: '30'
    docker_remove_containers: '0'
    docker_remove_images: '1'
  labels:
    io.rancher.scheduler.global: 'true'
  tty: true
  image: cusspvz/autotune:1.1.1
  privileged: true
  volumes:
  - /var/run/docker.sock:/var/run/docker.sock
  stdin_open: true
  net: host

To be clear, you had a host in reconnecting state, while it was in reconnecting state, you added a global service to Rancher. The reconnecting host became "Active", but the service never got deployed onto this host (Even though it should have?)?
This will be a bit harder for me to test out, but let me first get the use case correct.

while it was in reconnecting state, you added a global service to Rancher

Nope, the service was already deployed on that host, it went into Reconnecting state, all the global services were destroyed (main load balancers, maintenance instances and others we have as global for haendpoints such as STUN services). After it went up, it didn't schedule none of them.
Same was reproducible with a host we've added into the environment, but that one didn't had any services on it.

This is strange because I definitely don't have any issues with global services and having them schedule onto hosts that were just introduced into the environment.
Are you saying that in this environment, when you add any host, none of the global services are being scheduled onto it?

Are you saying that in this environment, when you add any host, none of the global services are being scheduled onto it?

Only after we edit and save those services.
We have migrated our rancher-server into another machine, and since then I didn't catch (til yet) any reconnecting host (because we are restarting the server every 2 hours, which solves temporarily our issue, we had to do so because our endpoint hosts were having their main load balancers removed once they went into reconnecting mode). As soon as we got a similar situation I could screencast it and share it here.
Little bit off-topic, I've seen that @ibuildthecloud is working on a new network agent and has already built-in on latest rcs. Do you know when the next minor release will be available?

@deniseschannon I've experienced the same a few minutes ago but unfortunately didn't screencasted.
But I have more info, I think it might be related with issue #2196 and last @alena1108 fix regarding the removal of instances when a host goes down, because the global services that weren't deployed were the ones removed while the host was on Reconnecting state.

It seems that it is working properly in version v0.59.1 . I just add a new host to the cluster and services marked as global start automatically.

@fernandoneto @cusspvz I think this is related to https://github.com/rancher/rancher/issues/3480, but I don't see it fixed on v0.59.1
Since it seems to be working for your issues, could i close in favor of #3480?

@deniseschannon: Nice catch, seems that our "reconnecting hosts" could be the culprit on this.
Yes, you can close this.
So far I've seen, we are always experiencing the deepest issues, the "reconnecting hosts" one is still unsolved, our work around is a cron job restarting rancher-server each 2 hours, which has already demonstrated to cause some side effects. x) On the other hand, we can now deploy faster. <3 rancher & docker
I'm a little bit out of rancher's management by now, @fernandoneto is mostly more involved and on charge of it, but feel free to include me on and mention me!


support caveats with multiple queries

currently a caveat contains only one query, so it is difficult to model caveats using OR logic.
previously, it was possible to make intermediate rules for each case, and have a caveat that checks the rule's result, but with the recent block merge, any block could just generate the facts for those rules in advance.
This would change the format at https://github.com/CleverCloud/biscuit/blob/master/schema.proto#L28 to have each caveat contain a list of rules.
When executed, the caveat would try each rule until one of them succeeds, or return an error if all failed.

currently testing in https://github.com/CleverCloud/biscuit-rust/commit/15b7fbd8b790bbe19163f339544dcb299837b587


Incorporate FAST subject selection into CORE repo upload

Incorporate FAST subject selection into CORE repository upload.

New prototypes
Running notes


Pass chatSessionId to chat agents for use with telemetry

VS Code internally maintains a chatSessionId for purposes of firing telemetry:
https://github.com/microsoft/vscode/blob/5cd08236ffc1f480f6d26d249b6336d67d14ab79/src/vs/workbench/contrib/chat/common/chatServiceImpl.t
s#L54
It would be helpful if we had access to that chatSessionId so we could fire our own telemetry with it and correlate it, especially if the chat window were to add more telemetry going forward.
Note: This request is similar to #202779 which also asked for an ID. In that case, rather than the ID being offered, the ability to round-trip results was added. We absolutely can use that to create our own ID which we could use to correlate with our own events, but that wouldn't let us correlate well to built-in events.

Tagging @isidorn per their request.


FlexItem can not acces

Cannot access 'FlexItem': it is package-private in 'com.google.android.flexbox'
why do you named the demo package name same as the lib package name ?

Not sure if this library is still actively maintained, but opening up the visibility of FlexItem will improve the usage experience from Kotlin/Compose UI.


from keras.layers.attention import AttentionLayer

--> from keras.layers.attention import AttentionLayer
ModuleNotFoundError: No module named 'keras.layers.attention'
Can you provide requirement.txt of this project?
thanks!

delete it is okay

sorry , I havn't sign in for a long time.Actually I have forgot some details.It seems that layers.attention is just a failure instance that I havn't remove.


Fixed typo

Fixed a typo in the readme resulting in a slightly broken link.

Hi @giovannicalo, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution!

This seems like a small (but important) contribution, so no Contribution License Agreement is required at this point. Real humans will now evaluate your PR.

TTYL, MSBOT;

Hi @giovannicalo, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution!

This seems like a small (but important) contribution, so no Contribution License Agreement is required at this point. Real humans will now evaluate your PR.

TTYL, MSBOT;


Authentication Failure in Copilot Mode: Missing Headers

I've been considering that anything related to tokens would likely utilize header_auth_callback(headers: Dict). I attempted to create a mock login (which guarantees authentication success regardless of the situation) to capture headers sent by the nginx reverse proxy. This approach works in app mode, but fails to receive headers in copilot mode, as illustrated in the attached screenshot:
mock login

App mode do return headers

Using the developer tools, I noticed an error message at index.js:78, indicating an unauthorized access attempt:
GET http://localhost:8889/project/settings?language=zh-TW 401 (Unauthorized)

Copilot mode

App mode

This issue does not occur in app mode, only in copilot mode. The current problem is that I intend to use headers for authentication in copilot, but the server side does not receive any headers, thus failing to verify identity. Even with mock login (which should ensure authentication success), my simple HTML page displays an unauthorized access error.
Could you advise on how to resolve this issue? Thank you.

Hi
I am facing the same error!!
Did you got it working?

@karankapur999 Not yet

Hi,
I am facing a similar error!!
Did you get it working?

facing the same error, anybody got it working?

That's so bad! I'm facing the same error. I found that Copilot uses WebSocket, while the web uses HTTP. Perhaps the error occurs because of this

Authentication works differently in copilot mode than when using the full app. Instead of relying on the header_auth_callback, you have to supply an access_token via your frontend Javascript in the call to window.mountChainlitWidget(). header_auth_callback is not called in copilot mode.
You can see access_token in the widget configuration section here: https://docs.chainlit.io/deploy/copilot
You can see how to create the access_token in the Authentication section at the bottom of that page.

Authentication works differently in copilot mode than when using the full app. Instead of relying on the header_auth_callback, you have to supply an access_token via your frontend Javascript in the call to window.mountChainlitWidget(). header_auth_callback is not called in copilot mode.
You can see access_token in the widget configuration section here: https://docs.chainlit.io/deploy/copilot
You can see how to create the access_token in the Authentication section at the bottom of that page.
This is also discussed here: #756

We just discussed that we really kind of want to move away from this custom approach towards supporting:

Header-based auth (e.g. behind a proxy).
OAuth (e.g. 3rd party auth is done through normal OAuth).

I'll keep you posted.


Change Implementation from ArrayList to List in ListOrder Command

Change Implementation from ArrayList to List in ListOrder Command

LGTM.


Expose asyncIterable, keys(), values() and entries()

Need to do this for all storage adapters

[x] Mongo
[x] Redis
[x] PostgreSQL
[x] MySQL
[x] SQLite

why this? iterate a large collection will be performed very bad 🤔

Its probably the most requested feature for keyv, we can maybe expose this and not put it into keyv directly and let the end user get it if needed from store?

redis has scan, mongo has cursor, its the sql libs that dont expose some kind of chunked iteration

Is my implementation alright?

the iterator can be consumed with a for await loop, and extensions can use the iterator to get keys(), values() and entries(), which should be storage adaptor independent

Added key iterator, should add for values and entries as well? and maybe add some tests for those

Tests needed to get coverage back to acceptable levels

Thanks for all the effort 🙏


remix 1.4.0 breaks integration with turborepo & workspaces libraries

What version of Remix are you using?
1.4.0
Steps to Reproduce
Here's my sample repo which is working with remix 1.3.5: https://github.com/nareshbhatia/custom-react-stack.
Build & run to make sure everything is working ok:
npm install
npm run dev

Point your browser to the remix app at http://localhost:3002/.
Now change remix dependencies to 1.4.0 in apps/movie-magic-remix/package.json. Do a clean build and run.
npm run clean
rm package-lock.json
npm install
npm run dev

Expected Behavior
Build does not produce any errors and application runs.
Actual Behavior
Build produces the following error and application does not run. Note that packages/ui-lib is a library package in the monorepo. The remix server is not able to resolve its path.
movie-magic-remix:dev: ✘ [ERROR] [plugin server-bare-modules] Couldn't resolve the base path of "ui-lib". Searched inside the resolved main file path "/Users/naresh/projects/custom-react-stack/packages/ui-lib/dist/index.js" using "node_modules/ui-lib"
movie-magic-remix:dev:
movie-magic-remix:dev:     ../../node_modules/@remix-run/dev/compiler/plugins/serverBareModulesPlugin.js:181:10:
movie-magic-remix:dev:       181 │     throw new Error(`Couldn't resolve the base path of "${package...
movie-magic-remix:dev:           ╵           ^
movie-magic-remix:dev:
movie-magic-remix:dev:     at resolveModuleBasePath (/Users/naresh/projects/custom-react-stack/node_modules/@remix-run/dev/compiler/plugins/serverBareModulesPlugin.js:181:11)
movie-magic-remix:dev:     at warnOnceIfEsmOnlyPackage (/Users/naresh/projects/custom-react-stack/node_modules/@remix-run/dev/compiler/plugins/serverBareModulesPlugin.js:126:20)
movie-magic-remix:dev:     at /Users/naresh/projects/custom-react-stack/node_modules/@remix-run/dev/compiler/plugins/serverBareModulesPlugin.js:96:11
movie-magic-remix:dev:     at callback (/Users/naresh/projects/custom-react-stack/node_modules/esbuild/lib/main.js:920:34)
movie-magic-remix:dev:     at processTicksAndRejections (node:internal/process/task_queues:96:5)
movie-magic-remix:dev:     at handleRequest (/Users/naresh/projects/custom-react-stack/node_modules/esbuild/lib/main.js:700:30)
movie-magic-remix:dev:
movie-magic-remix:dev:   This error came from the "onResolve" callback registered here:
movie-magic-remix:dev:
movie-magic-remix:dev:     ../../node_modules/@remix-run/dev/compiler/plugins/serverBareModulesPlugin.js:47:12:
movie-magic-remix:dev:       47 │       build.onResolve({
movie-magic-remix:dev:          ╵             ~~~~~~~~~
movie-magic-remix:dev:
movie-magic-remix:dev:     at setup (/Users/naresh/projects/custom-react-stack/node_modules/@remix-run/dev/compiler/plugins/serverBareModulesPlugin.js:47:13)
movie-magic-remix:dev:     at handlePlugins (/Users/naresh/projects/custom-react-stack/node_modules/esbuild/lib/main.js:842:23)
movie-magic-remix:dev:
movie-magic-remix:dev:   The plugin "server-bare-modules" was triggered by this import
movie-magic-remix:dev:
movie-magic-remix:dev:     route:/Users/naresh/projects/custom-react-stack/apps/movie-magic-remix/app/routes/__layout/index.tsx:5:26:
movie-magic-remix:dev:       5 │ import { MovieList } from 'ui-lib';
movie-magic-remix:dev:         ╵                           ~~~~~~~~
movie-magic-remix:dev:
movie-magic-remix:dev:  ✘ [ERROR] [plugin server-bare-modules] Couldn't resolve the base path of "ui-lib". Searched inside the resolved main file path "/Users/naresh/projects/custom-react-stack/packages/ui-lib/dist/index.js" using "node_modules/ui-lib"
movie-magic-remix:dev:
movie-magic-remix:dev:     ../../node_modules/@remix-run/dev/compiler/plugins/serverBareModulesPlugin.js:181:10:
movie-magic-remix:dev:       181 │     throw new Error(`Couldn't resolve the base path of "${package...
movie-magic-remix:dev:           ╵           ^
movie-magic-remix:dev:
movie-magic-remix:dev:     at resolveModuleBasePath (/Users/naresh/projects/custom-react-stack/node_modules/@remix-run/dev/compiler/plugins/serverBareModulesPlugin.js:181:11)
movie-magic-remix:dev:     at warnOnceIfEsmOnlyPackage (/Users/naresh/projects/custom-react-stack/node_modules/@remix-run/dev/compiler/plugins/serverBareModulesPlugin.js:126:20)
movie-magic-remix:dev:     at /Users/naresh/projects/custom-react-stack/node_modules/@remix-run/dev/compiler/plugins/serverBareModulesPlugin.js:96:11
movie-magic-remix:dev:     at callback (/Users/naresh/projects/custom-react-stack/node_modules/esbuild/lib/main.js:920:34)
movie-magic-remix:dev:     at processTicksAndRejections (node:internal/process/task_queues:96:5)
movie-magic-remix:dev:     at handleRequest (/Users/naresh/projects/custom-react-stack/node_modules/esbuild/lib/main.js:700:30)
movie-magic-remix:dev:
movie-magic-remix:dev:   This error came from the "onResolve" callback registered here:
movie-magic-remix:dev:
movie-magic-remix:dev:     ../../node_modules/@remix-run/dev/compiler/plugins/serverBareModulesPlugin.js:47:12:
movie-magic-remix:dev:       47 │       build.onResolve({
movie-magic-remix:dev:          ╵             ~~~~~~~~~
movie-magic-remix:dev:
movie-magic-remix:dev:     at setup (/Users/naresh/projects/custom-react-stack/node_modules/@remix-run/dev/compiler/plugins/serverBareModulesPlugin.js:47:13)
movie-magic-remix:dev:     at handlePlugins (/Users/naresh/projects/custom-react-stack/node_modules/esbuild/lib/main.js:842:23)
movie-magic-remix:dev:
movie-magic-remix:dev:   The plugin "server-bare-modules" was triggered by this import
movie-magic-remix:dev:
movie-magic-remix:dev:     route:/Users/naresh/projects/custom-react-stack/apps/movie-magic-remix/app/routes/__layout/settings.tsx:5:34:
movie-magic-remix:dev:       5 │ import { Button, MovieList } from 'ui-lib';
movie-magic-remix:dev:         ╵                                   ~~~~~~~~

Same issue, I am installing a dependency using the fs resolution package: "file:../../package". Pinning to 1.3.5 fixed it.

I think this might be related to #2845, which I submitted as a separate issue since the use case is a little different, but it looks like the same bug.

I found this same issue using npm workspaces

I found this same issue using npm workspaces

I upgraded Remix to 1.4.3, and the issue was fixed for me. I just had to add this to my remix.config.js https://remix.run/docs/en/v1/pages/gotchas#importing-esm-packages


tests(e2e): add cert-manager test

Description:
This change adds a simple e2e test with one pod trying to reach one
server using cert-manager to issue certificates.
Fixes #1734

Affected area:

New Functionality      [ ]
Documentation          [ ]
Install                [ ]
Control Plane          [ ]
CLI Tool               [ ]
Certificate Management [ ]
Networking             [ ]
Metrics                [ ]
SMI Policy             [ ]
Security               [ ]
Tests                  [X]
CI System              [ ]
Performance            [ ]
Other                  [ ]

Please answer the following questions with yes/no.

Does this change contain code from or inspired by another project? If so, did you notify the maintainers and provide attribution?
No

Codecov Report

Merging #1866 into main will increase coverage by 0.01%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##             main    #1866      +/-   ##
==========================================
+ Coverage   59.26%   59.28%   +0.01%
==========================================
  Files         126      126
  Lines        5177     5177
==========================================
+ Hits         3068     3069       +1
+ Misses       2106     2105       -1
  Partials        3        3

Impacted Files
Coverage Δ

pkg/envoy/route/config.go
95.83% <0.00%> (+0.83%)
:arrow_up:

Continue to review full report at Codecov.

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


Unhandled Exception - NetBIOSTimeout

Command string used
crackmapexec <IP_ADDRESS>/24 --shares -t 20
CME verbose output (using the --verbose flag)
Traceback (most recent call last):
  File "/root/.virtualenvs/CME/local/lib/python2.7/site-packages/gevent/greenlet.py", line 536, in run
    result = self._run(*self.args, **self.kwargs)
  File "/root/.virtualenvs/CME/local/lib/python2.7/site-packages/cme/connection.py", line 62, in __init__
    smb = SMBConnection(self.host, self.host, None, self.args.smb_port)
  File "/root/.virtualenvs/CME/local/lib/python2.7/site-packages/impacket/smbconnection.py", line 63, in __init__
    self.negotiateSession(preferredDialect)
  File "/root/.virtualenvs/CME/local/lib/python2.7/site-packages/impacket/smbconnection.py", line 83, in negotiateSession
    self._timeout, True, flags1=flags1, flags2=flags2, data=negoData)
  File "/root/.virtualenvs/CME/local/lib/python2.7/site-packages/impacket/smbconnection.py", line 147, in _negotiateSession
    resp = self._nmbSession.recv_packet(timeout)
  File "/root/.virtualenvs/CME/local/lib/python2.7/site-packages/impacket/nmb.py", line 855, in recv_packet
    data = self.__read(timeout)
  File "/root/.virtualenvs/CME/local/lib/python2.7/site-packages/impacket/nmb.py", line 933, in __read
    data = self.read_function(4, timeout)
  File "/root/.virtualenvs/CME/local/lib/python2.7/site-packages/impacket/nmb.py", line 918, in non_polling_read
    raise NetBIOSTimeout
NetBIOSTimeout: The NETBIOS connection with the remote host timed out.
Wed Feb 22 11:20:31 2017 <Greenlet at 0x7fbd601a12d0: Connection(Namespace(content=False, cred_id=[], depth=10, dis, <cme.database.CMEDatabase instance at 0x7fbd6171ff, '<IP_ADDRESS>', None, None)> failed with NetBIOSTimeout

OS
Linux phlegethon 4.6.0-kali1-amd64 #1 SMP Debian 4.6.4-1kali1 (2016-07-21) x86_64 GNU/Linux
Detailed issue explanation
It seems like when connection with a target takes too long (time-out) an unhandled NetBIOSTimeout exception is raised.

I've noticed this while spidering as well, thanks for the report.

@AresS31 Think I've fixed this in the latest version. Can you confirm?
Thanks!

Closing due to inactivity


Delete spell_check_results.tsv from the gitignore

Purpose/implementation Section
What changes are being implemented in this Pull Request?
Related to: https://github.com/jhudsl/OTTR_Template/issues/580#issuecomment-1287250410

Looks good to me! not sure what the url checker issue is about - this was fine with no updates to the urls in the previous PR

Yeah, the urls have been an issue in all of my other repos in the last day or so.

It’s a separate problem: https://github.com/jhudsl/OTTR_Template/issues/590 that I’m actively trying to fix but it isn’t related to this repo so you can ignore it for now. Hope to have a fix for it by the end of today

It seems to dislike having a link inside at the end of a  statement in parentheses

Yeah, the urls have been an issue in all of my other repos in the last day or so.

Trying to get that fixed today. Ignore for now.

@cansavvy no rush / worries! Just making it clear that it's not this repo.

@cansavvy no rush / worries! Just making it clear that it's not this repo.

agreed! no rush!


MySQL: if two tables in different databases have the same foreign key, FK list becomes incorrect

System information:

macOS Big Sur 11.4
DBeaver version: Community Edition 21.2.1
MySQL version: 8.0.25 for macos11 on x86_64 (MySQL Community Server - GPL)

Describe the problem you're observing:
When you have a foreign key in a table with a same name in 2 databases, foreign key constraints list shows incorrect one.
Imagine that you have 2 databases named "x" and "y" accordingly, and a table "sample_table" a foreign key "account_id_fk" in both.
account_id_fk in sample_table in database x "On Delete" constraint is "Cascade", but in y it is "Restrict".
You will see both are the same in foreign key list. However, when you run a SQL command like "SHOW CREATE TABLE sample_table", it will get the correct foreign keys in script.

Steps to reproduce, if exist:

Create 2 databases and tables with a foreign key that has a same name in both database and tables
Set "On Delete" to "Restrict" in one table, and "Cascade" in the other table.
Go to the database > table > Foreign Keys.
See that the result is incorrect.

@canercanbaz unfortunately, cannot reproduce the issue.
Could you provide ddl to reproduce it?

Of course, here are the dumps for the sample databases.

lessondb
lessondb_test

You will see foreign key as "CASCADE" although one of them is "RESTRICT".
-- MySQL dump 10.13  Distrib 8.0.25, for macos11 (x86_64)
--
-- Host: localhost    Database: lessondb
-- ------------------------------------------------------
-- Server version	8.0.25

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!50503 SET NAMES utf8mb4 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

--
-- Table structure for table `account`
--

DROP TABLE IF EXISTS `account`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `account` (
  `id` int unsigned NOT NULL AUTO_INCREMENT,
  `email` varchar(100) NOT NULL,
  `name` varchar(100) DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `account`
--

LOCK TABLES `account` WRITE;
/*!40000 ALTER TABLE `account` DISABLE KEYS */;
/*!40000 ALTER TABLE `account` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `lessons`
--

DROP TABLE IF EXISTS `lessons`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `lessons` (
  `id` int unsigned NOT NULL AUTO_INCREMENT,
  `student_id` int unsigned NOT NULL,
  PRIMARY KEY (`id`),
  KEY `lessons_student_id_fk` (`student_id`),
  CONSTRAINT `lessons_student_id_fk` FOREIGN KEY (`student_id`) REFERENCES `account` (`id`) ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `lessons`
--

LOCK TABLES `lessons` WRITE;
/*!40000 ALTER TABLE `lessons` DISABLE KEYS */;
/*!40000 ALTER TABLE `lessons` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Dumping routines for database 'lessondb'
--
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

-- Dump completed on 2021-10-04 11:40:33

-- MySQL dump 10.13  Distrib 8.0.25, for macos11 (x86_64)
--
-- Host: localhost    Database: lessondb_test
-- ------------------------------------------------------
-- Server version	8.0.25

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!50503 SET NAMES utf8mb4 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

--
-- Table structure for table `account`
--

DROP TABLE IF EXISTS `account`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `account` (
  `id` int unsigned NOT NULL AUTO_INCREMENT,
  `email` varchar(100) NOT NULL,
  `name` varchar(100) DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `account`
--

LOCK TABLES `account` WRITE;
/*!40000 ALTER TABLE `account` DISABLE KEYS */;
/*!40000 ALTER TABLE `account` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `lessons`
--

DROP TABLE IF EXISTS `lessons`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `lessons` (
  `id` int unsigned NOT NULL AUTO_INCREMENT,
  `student_id` int unsigned NOT NULL,
  PRIMARY KEY (`id`),
  KEY `lessons_student_id_fk` (`student_id`),
  CONSTRAINT `lessons_student_id_fk` FOREIGN KEY (`student_id`) REFERENCES `account` (`id`) ON DELETE RESTRICT
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `lessons`
--

LOCK TABLES `lessons` WRITE;
/*!40000 ALTER TABLE `lessons` DISABLE KEYS */;
/*!40000 ALTER TABLE `lessons` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Dumping routines for database 'lessondb_test'
--
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

-- Dump completed on 2021-10-04 11:40:41

thank for the answer.
Unfortunately, still cannot reproduce :(

Oh really? Tried from scratch and updated the client to version 21.2.2 but still exists on my end.
I create the database with a collation utf8mb4_general_ci. I don't know if it is related or not.

Hello @canercanbaz
What driver version do you use?

Hey @LonwoLonwo, here is my driver info:

Ok... So it is a very strange story because we use info from the driver and the driver (8.0.25) read foreign keys from the SHOW CREATE TABLE statement.
Can you show us a screen from the query manager?
-- Load imported keys - this statement is very interest for me.

Here it is.

You downloaded the keys for different "lesson" tables in different catalogs or simply downloaded the foreign keys for the  lessondb_test.lessons, and then refreshed the table lessondb_test.lessons?

Actually, I deleted both databases and created again. Then, executed the db schema queries I provided above.

Yes the problem still exists on 21.2.4.

Hello @canercanbaz
Maybe you can give us a dump of these databases? Without data, only metadata.

Maybe you have some special connection settings? Default database?

Actually it seems to be the same.

Yep, I caught it.

And I can say, that problem is with from the driver side. You can see on the image one database read with 2 driver versions.
Now we will try to understand if we can fix it on our side.

Hmm, it’s great to hear that you found it out. Good luck!

So we can't fix the driver issue and do not have good ways to read foreign key info for MySQL/MariaDB.
Reading metadata from information_schema.REFERENTIAL_CONSTRAINTS looks to expensive.
Maybe someone can create bug about this driver somewhere.

I created the bug report for MySQL. And I hope it will help.
https://bugs.mysql.com/bug.php?id=108088

https://github.com/mysql/mysql-connector-j/pull/101 🤞


ENH: add two-sample test (Epps-Singleton) to scipy.stats

Another two-sample test for equality of distributions which can be applied to discrete and continuous distributions and which has high power.
Output Format: TBD, currently tuple, probably a good idea to change to Bunches, need to find the related discussion.

Re: related discussion https://github.com/scipy/scipy/pull/6335 and references therein.

Further analysis and tests are in a gist: https://gist.github.com/chrisb83/3a057aebf2cd1d61d81ae0b6c198a7f1

I decided to return a named tuple as for the other tests for consistency. Using a Bunch would not bring a big advantage in my view (see discussion in #3665).
@rlucas7 I tried to address most of your comments regarding the documentation.
I don't see that the implementation can be changed easily to handle integers in the way you propose, so I leave that question for the future :)

I decided to return a named tuple as for the other tests for consistency. Using a Bunch would not bring a big advantage in my view (see discussion in #3665).

I agree with named tuple approach-it works and is clear to read.

@rlucas7 I tried to address most of your comments regarding the documentation.
I don't see that the implementation can be changed easily to handle integers in the way you propose, so I leave that question for the future :)

I looked at it closer and I agree. Although weights would be nice to handle, adding that is non-trivial. For example, iqr would need to be modified to support weights, something non-trivial by itself. This method would also need to be modified to support weights, something else non-trivial.
Let's shelve the weights idea for now and maybe someone will open ENH pull requests to implement support for weights in the future.
The pull request LGTM.

Pycodestyle isn't happy with _hypotests.py, but unclear why. I checked locally and all looks good. A rebase may fix the CI failures.

I don't have access to [1] and can't find a freely available version. Can someone send me a copy by email?

Can someone send me a copy by email?

Done, I think

awesome, thanks!
I'll remove these comments again, since they're not particularly useful

Pycodestyle isn't happy with _hypotests.py, but unclear why. I checked locally and all looks good. A rebase may fix the CI failures.

yes, i can rebase but i think the PR already passed all tests at some point, not sure why it failed last time

@rgommers the failure was due to non-ascii characters. They often happen If I copy the title of the reference from a PDF or website, so good that we have a check for it now.
I also added more checks in the input

Last commits look good to me. I resolved all comments that were addressed. There seem to be two comments of @rlucas7 left that may require a small tweak (or just pushing the resolve button, not sure).

@rgommers @rlucas7 I marked all conversations as "resolved" (including a comment why the feedback of rlcuas is addresed).

Okay thanks @chrisb83, in it goes! And thanks @rlucas7 for reviewing

@chrisb83 could you add a release note at https://github.com/scipy/scipy/wiki/Release-note-entries-for-SciPy-1.3.0?


Upgrade Antrea K8s API version and Octant version to support Traceflow UI plugin

Describe what you are trying to solve
We need to upgrade octant to its latest version for traceflow UI plugin
because we need these two issue fixes https://github.com/vmware-tanzu/octant/issues/948 and
https://github.com/vmware-tanzu/octant/issues/951.
But the latest octant uses K8s API v0.19.0-alpha.3 and<EMAIL_ADDRESS>(which also has a broke API issue https://github.com/googleapis/gnostic/issues/156).
What I propose here is that we decouple K8s API dependency with octant and upgrade octant to its latest release.
Describe the solution you have in mind

Move Octant plugins to a separate folder like plugins and make it a separate sub project.
Upgrade Antrea K8s API to 1.18 which already contains some broken API changes for generated client like extra field of context. In this way, we can just use same client for both Antrea and plugins. There will be no duplicate code introduced in this way.
Use octant latest 0.13.0/0.13.1 for UI.

LGTM
@jianjuns @antoninbas do you have concern about moving octant plugins to sub-folder to decouple their library dependency conflict?

I'm fine with the approach. I commented in more details in the corresponding PR.


Coverage showing up as 0% for single line method with ignore statement

When we have a single line function and that line is ignore, the coverage line will be removed from the coverage file. However, when you run go tool cover using the coverage file, it will report each method of each package, but since this single line function has no coverage, it will show up as 0%.
It works file if the function has some code that is not ignored from coverage.

Possible solution could be to change go-ignore-cov to insert "fake" coverage instead of removing it. So that one line function would show as 100% coverage instead of 0%. However, when using go tool cover in html mode, it's nice to see ignored lines in gray and not in green.
Not sure how to solve this otherwise.


else is not highlighted

else is gray colored. Screenshot here

Hi
Please provide more complete code snippet.
I retype the line but works fine here.

Hi! I noticed broken colours with another filetypes today, so it may not to be related to yajs.vim. Closing for now. Thank you for your attention!

I use NeoVim v0.1.0. Its :echo version is 704.
I'm trying this snippet:
let a = 1;
if (a) {
  console.log(a);
} else {
  a = 3;
}
if (!a) a = 4; else a = 6;

if is highlighted, but else is not :(.
If I put cursor to if/else and then try to inspect highlighting group I see hi<javaScriptConditional> trans<javaScriptConditional> lo<javaScriptConditional> and hi<javascriptConditionalElse> trans<javascriptConditionalElse> lo<Conditional> respectively.
I think javascriptConditionalElse is defined by yajs, but javaScriptConditional defined by standard (Neo)Vim's syntax file for JS.
Any help?

Screenshot here.

Here I use vim and nvim are all ok on else
Do you update to latest reversion?
javascriptConditionalElse is defined by yajs but it should link to statement group.
You can try vim-hilinks to get more info
https://github.com/kergoth/vim-hilinks

@othree I found the reason: my colorscheme (Tomorrow) has no setting for javascriptConditionalElse and falls back to default Conditional which is simply foreground colour. (Or something like that, because I don't fully understand how Vim syntax highlighting works). Thank you!


Fix version

Detect the latest tag using git ls-remote, as checkouts no longer contain all tags.

I can help to review this, but there is not enough context. Can we add a description to the PR, at least?

It doesn't look like my fix took, fwiw. Going to review a bit more.


Fix bug & improve Windows support

Based on tales of success by @jbmaggard in issue #435
Fixes #435
Error in the type def of an argument to MPI_Type_extent
long int string_len; → MPI_Aint string_len; on mpi_caf.c:4140

Avg response time
coverage on master

Summary of changes
Fixed bug with improper type of argument to MPI_Type_extent found in #435
Rationale for changes
Build fails on windows vs MS-MPI using mingw GCC 7.1. Definitely a bug, regardless of whether or not it works on Windows, but add'l changes added to attempt to improve windows support.
Additional info and certifications
This pull request (PR) is a:

[x] Bug fix
[ ] Feature addition
[ ] Other, Please describe:

I certify that

[x] I reviewed and followed the contributing guidelines, including
- Increasing test coverage for all feature-addition PRs
- Increasing test coverage for all bug-fix PRs for which there
does not already exist a related test that failed before the PR
- At least maintaining test coverage for all other PRs
- Ensuring that all tests pass when run locally
- Naming PR  to indicate work in progress (WIP) and to attach the PR
to the appropriate bug report or feature request issue
- White space (no trailing white space or white space errors may
be introduced)
- Commenting code where it is non-obvious and non-trivial
- Logically atomic, self consistent and coherent commits
- Commit message content
- Waiting 24 hours before self-approving the PR to give another
OpenCoarrays developer a chance to review my proposed code

@jbmaggard: I think my latest commit, 111d775ad040a51629cb9cdc66e572c6a12f90f0, is a half decent attempt at system introspection to deal with -D_POSIX and -DUSE_GCC. For the former I check with CMake if signal.h provides SIGKILL and if not, I check again passing -D_POSIX. If -D_POSIX fixes it (regardless of platforms) then it gets passed at compile time. Later I then check for I_MPI_VERSION in mpi.h. If it's there and the platform is Windows, then I pass -DUSE_GCC.
I'm fairly confident that this is a decent approach. There's still the issue of the impi.dll interface library, I'll study your notes to try to figure that out, perhaps it can be automatically generated? At any rate, if you're able to test this branch it would be much appreciated, if not, a brief code review with your thoughts on the feasibility of this approach would certainly be appreciated. Even if you don't get to this I'll probably merge if all CI tests pass, since it's closer to a Windows solution than without it.

LGTM

@zbeekman : comments per your request.
Both your testing for -D_POSIX with define of SIGKILL, and inspecting mpi.h for I_MPI_VERSION for -DUSE_GCC both seem sound (LGTM).
impi.dll is installed with the Intel MPI Windows Runtime.  The I_MPI_ROOT environment variable is set to the location where %I_MPI_ROOT\intel64\bin\impi.dll is installed.
libimpi.a is an import library created to interface with impi.dll (the MSYS2/mingw64/ subsystem has both of the utilities needed to create this import library during the build; gendef and dlltool).

I was pleasantly surprised by how far the install.sh got using the MSYS2/MinGW64 command line environment.  It didn't fail until it couldn't find the MPICH installation.  I remember reading that windows-install.sh (for Win10-WSL) is similar to install.sh, except that the parts to get and build GCC and/or MPICH (if needed) has been removed.  I think a similar "msys2-install.sh" running in the MSYS2 MinGW64 bash prompt environment is very possible; which would test for the MSYS2/mingw64/ subsystem verisons of GCC (gcc.exe and gfortran.exe), cmake (cmake.exe), and make (mingw32-make.exe), and test for the Intel MPI Windows runtime (%I_MPI_ROOT%\intel64\binimpi.dll)
I've also been spending some time with cmake tutorials, utilizing the MSYS2/mingw64/ verision of cmake (3.9.1), and so far everything looks good.  This increases my confidence that using cmake to generate a native Win64 libcaf_mpi.a is possible:
OS:  Win64 (7, 8.1, 10)
GCC: MSYS2/mingw64 (currently at 7.2.0, older versions available for install if needed)
cmake:  MSYS2/mingw64 (currently at 3.9.1, older versions available for install if needed)
make: MSYS2/mingw64 (currently at 4.2.1, older versions available for install if needed.
MPI: Intel MPI Windows Runtime (building an import library to impi.dll could be done by cmake)
OpenCoarrays: 1.9.1 (no assumption that MPI_Aint is long int)
MSYS2 provides two ways to approach building a native Win64 app on MSYS2.

Use only the tools from the MSYS2/mingw64/ subsystem.  These tools could be run from the Windows Command Prompt if bash is not needed.  The c:\msys64\mingw64\bin folder would need to be in the Windows Command Prompt PATH (and should be the only folder from the c:\msys64 folder tree in the PATH), enabling the MSYS2/mingw64 applications installed.

Use the MSYS2/mingw64/ subsystem for the GCC, cmake, and make packages, along with any other needed build tool packages from the MSYS2/msys/ subsystem, with the MSYS/mingw64 GCC generating native Win64 libcaf_mpi.  Using the MSYS2 MinGW64 command line environment provides a bash shell, and allows using other packages from the msys/ subsystem.  How this works is that the MSYS2 MinGW64 command line environment has /mingw64/bin in the PATH ahead of /usr/local/bin:/usr/bin:/bin: putting the MSYS2/mingw64/ tools ahead of the MSYS2/msys/ tools in the PATH.

Awesome! @jbmaggard thanks so much for  your time, insight, analysis and phenomenally detailed defect report and notes! 💯 🎉

@jbmaggard: I would be glad to work with you on a msys2-install.sh as you suggest.  If you're interested, then I suggest we set up some time to talk about it and do some interactive pair programming to develop an initial draft.  Time can be booked at https://rouson.youcanbook.me.  If that seems helpful, I could walk you through an overview of the installer.  In fact, if we can reliably detect that the installer is running inside MinGW, then we can just incorporate an automatic invocation of msys2-install.sh from install.sh.

@rouson: most of the CMake machinery is there... probably need to add a target to build the libimpi.a using gendef and dlltool. Another interesting question for @jbmaggard: does msys2 have bash >= 3.0? Otherwise we'll need a batch script like you used in your notes.

@rouson
From the MSYS2/msys bash command line:
AUTH+bmaggard@PE-MGR-LAPTOP MSYS ~
$ uname -a
MSYS_NT-6.1 PE-MGR-LAPTOP 2.8.2(0.313/5/3) 2017-07-14 08:19 x86_64 Msys
From the MSYS2/mingw64 bash command line (build a native Win64 libcaf_mpi.a and libimpi.a import library)
AUTH+bmaggard@PE-MGR-LAPTOP MINGW64 ~
$ uname -a
MINGW64_NT-6.1 PE-MGR-LAPTOP 2.8.2(0.313/5/3) 2017-07-14 08:19 x86_64 Msys
In addition to Win7-64 reported above, I have Win8.1-64, and Win10-64 systems, so I'll take a look at the uname -a results on each, and report in a followup comment.
I'll be working my way through install.sh, windows-install.sh, and the cmake over the next week or two, so I will be able to use your time more efficiently, if we decide to go forward with an msys2-install.sh.
@zbeekman
MSYS2/mingw64 bash command line:
AUTH+bmaggard@PE-MGR-LAPTOP MINGW64 ~
$ echo $PATH
/mingw64/bin:/usr/local/bin:/usr/bin:/bin:/c/Windows/System32:/c/Windows
$ echo $BASH_VERSION
4.4.12(1)-release
AUTH+bmaggard@PE-MGR-LAPTOP MSYS ~
$ bash --version
GNU bash, version 4.4.12(1)-release (x86_64-pc-msys)
Version is the same on both the MSYS2/mingw64 and MSYS2/msys bash command line, because bash is an MSYS2/msys package.  Recall the MSYS2/mingw64 command line has /mingw64/bin first in the path, but since there is no mingw64/ package installed having bash, it falls through to /usr/bin in the path to execute bash.exe from the MSYS2/msys package (not a windows native bash.exe, requires the msys-2.0.dll (partial) POSIX emulation layer)
MSYS2/msys bash command line (used for package management); results excerpted to be concise.
$ pacman -Ss bash
msys/bash 4.4.012-1 (base) [installed]
The GNU Bourne Again shell
msys/bash-devel 4.4.012-1 (development)
Bash headers and libraries
I expect one way to use gendef and dlltool to build libimpi.a might be with add_custom_command and add_custom_target.  I thought this example was interesting, https://gist.github.com/socantre/7ee63133a0a3a08f3990

@jbmaggard Great, thanks for the additional details and help! If we can do it right, the best option would be to bake in the introspection and steps needed for the windows build into CMake. If it only requires minor adjustment, then install.sh could handle these cases rather than an extra script. Just food for thought, but less bifurcation of the build system is always better IMO.

@zbeekman @rouson
Here is a first try from a cmake beginner.  Using the MSYS2/mingw64 bash command line.  Not happy about having to create libimpi.a.stamp for a build dependency in add_library, but I haven't yet found another way that works correctly (perhaps set_property could add the dependency after add_library).  Criticism would be appreciated.
On uname -a the only parts that changed on Win10-64 and Win8.1-64 were "6.1 PE-MGR-LAPTOP"
Here are my notes on my CMakeLists.txt build:
$ uname -a
MINGW64_NT-6.1 PE-MGR-LAPTOP 2.8.2(0.313/5/3) 2017-07-14 08:19 x86_64 Msys
$ tree .
.
├── run_cmake.sh
├── run_make.sh
└── src
├── CMakeLists.txt
├── common
│   └── caf_auxiliary.c
├── extensions
│   └── opencoarrays.F90
├── libcaf.h
├── libcaf-gfortran-descriptor.h
└── mpi
└── mpi_caf.c
4 directories, 8 files
$ cat ./run_cmake.sh
rm -rf ./build
cmake -Bbuild -Hsrc -G "MSYS Makefiles" -DCMAKE_MAKE_PROGRAM=/mingw64/bin/mingw32-make.exe
$ cat ./run_make.sh
cd build
mingw32-make
#mingw32-make VERBOSE=1
cd ..
$ cat src/CMakeLists.txt
cmake_minimum_required(VERSION 3.9.1)
project("libcaf_impi" NONE)
enable_language(C Fortran)
message("---- Begin: CMAKE Variables")
message("---- SYSTEM=" ${CMAKE_SYSTEM} ", SYSTEM_NAME=" ${CMAKE_SYSTEM_NAME} ", SYSTEM_VERSION=" ${CMAKE_SYSTEM})
message("---- UNIX=" ${UNIX} ", WIN32=" ${WIN32} ", APPLE=" ${APPLE} ", MINGW=" ${MINGW} ", MSYS=" ${MSYS} ", CYGWIN=" ${CYGWIN})
message("---- BORLAND=" ${BORLAND} ", WATCOM=" ${WATCOM} ", MSVC=" ${MSVC})
message("---- C_COMPILER_ID=" ${CMAKE_C_COMPILER_ID} ", COMPILER_IS_GNUCC=" ${CMAKE_COMPILER_IS_GNUCC})
message("---- End: CMAKE Variables")
set(CMAKE_C_FLAGS
${CMAKE_C_FLAGS}
" -g -Og -DPREFIX_NAME=gfortran_caf -DALLOCA_MISSING -D_POSIX -DUSE_GCC -DGCC_GE_7 -DUSE_FAILED_IMAGES"
)
set(CMAKE_Fortran_FLAGS
${CMAKE_Fortran_FLAGS}
" -g -Og -DPREFIX_NAME=gfortran_caf -DALLOCA_MISSING -D_POSIX -DUSE_GCC -DGCC_GE_7 -DUSE_FAILED_IMAGES"
)
include_directories(
${CMAKE_SOURCE_DIR}
${CMAKE_SOURCE_DIR}/../..
)
add_library(
caf_impi STATIC
extensions/opencoarrays.F90
common/caf_auxiliary.c
mpi/mpi_caf.c
${CMAKE_CURRENT_SOURCE_DIR}/libimpi.a.stamp
)
add_custom_command(
OUTPUT ${CMAKE_CURRENT_SOURCE_DIR}/libimpi.a.stamp
MAIN_DEPENDENCY ${CMAKE_CURRENT_BINARY_DIR}/libimpi.a
COMMAND touch ${CMAKE_CURRENT_SOURCE_DIR}/libimpi.a.stamp
COMMENT "    * Updating libimpi.a.stamp (touch)"
)
add_custom_command(
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/libimpi.a
MAIN_DEPENDENCY ${CMAKE_CURRENT_BINARY_DIR}/impi.def
COMMAND dlltool -d impi.def -l libimpi.a -D $ENV{I_MPI_ROOT}/intel64/bin/impi.dll
COMMENT "   ** Generating libimpa.a import library to impi.dll (dlltool)"
)
add_custom_command(
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/impi.def
MAIN_DEPENDENCY $ENV{I_MPI_ROOT}/intel64/bin/impi.dll
COMMAND gendef $ENV{I_MPI_ROOT}/intel64/bin/impi.dll
COMMENT "  *** Generating .def for impi.dll (gendef)"
)
$ . ./run_cmake.sh
-- The C compiler identification is GNU 7.2.0
-- The Fortran compiler identification is GNU 7.2.0
-- Check for working C compiler: C:/msys64/mingw64/bin/gcc.exe
-- Check for working C compiler: C:/msys64/mingw64/bin/gcc.exe -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working Fortran compiler: C:/msys64/mingw64/bin/gfortran.exe
-- Check for working Fortran compiler: C:/msys64/mingw64/bin/gfortran.exe  -- works
-- Detecting Fortran compiler ABI info
-- Detecting Fortran compiler ABI info - done
-- Checking whether C:/msys64/mingw64/bin/gfortran.exe supports Fortran 90
-- Checking whether C:/msys64/mingw64/bin/gfortran.exe supports Fortran 90 -- yes
---- Begin: CMAKE Variables
---- SYSTEM=Windows-6.1.7601, SYSTEM_NAME=Windows, SYSTEM_VERSION=Windows-6.1.7601
---- UNIX=, WIN32=1, APPLE=, MINGW=1, MSYS=1, CYGWIN=
---- BORLAND=, WATCOM=, MSVC=
---- C_COMPILER_ID=GNU, COMPILER_IS_GNUCC=1
---- End: CMAKE Variables
-- Configuring done
-- Generating done
-- Build files have been written to: C:/msys64/home/bmaggard/oca/try1/build
$ . ./run_make.sh
[ 14%]   *** Generating .def for impi.dll (gendef)

[C:\Program Files (x86)\IntelSWTools\compilers_and_libraries_2017.4.210\windows\mpi/intel64/bin/impi.dll] Found PE+ image
[ 28%]    ** Generating libimpa.a import library to impi.dll (dlltool)
C:\msys64\mingw64\bin\dlltool.exe: Path components stripped from dllname, 'C:\Program Files (x86)\IntelSWTools\compilers_and_libraries_2017.4.210\windows

\mpi/intel64/bin/impi.dll'.
[ 42%]     * Updating libimpi.a.stamp (touch)
Scanning dependencies of target caf_impi
[ 57%] Building Fortran object CMakeFiles/caf_impi.dir/extensions/opencoarrays.F90.obj
[ 71%] Building C object CMakeFiles/caf_impi.dir/common/caf_auxiliary.c.obj
[ 85%] Building C object CMakeFiles/caf_impi.dir/mpi/mpi_caf.c.obj
[100%] Linking Fortran static library libcaf_impi.a
[100%] Built target caf_impi
libcaf_impi.a, libimpi.a, impi.def, opencoarrays.mod end up in the build folder (-Bbuild)
$ ls -al build
total 3620
drwxr-xr-x 1 AUTH+bmaggard AUTH+Domain Users       0 Aug 26 08:40 .
drwxr-xr-x 1 AUTH+bmaggard AUTH+Domain Users       0 Aug 26 08:39 ..
-rw-r--r-- 1 AUTH+bmaggard AUTH+Domain Users    1309 Aug 26 08:40 cmake_install.cmake
-rw-r--r-- 1 AUTH+bmaggard AUTH+Domain Users   14766 Aug 26 08:40 CMakeCache.txt
drwxr-xr-x 1 AUTH+bmaggard AUTH+Domain Users       0 Aug 26 08:40 CMakeFiles
-rw-r--r-- 1 AUTH+bmaggard AUTH+Domain Users   54825 Aug 26 08:40 impi.def
-rw-r--r-- 1 AUTH+bmaggard AUTH+Domain Users  218860 Aug 26 08:40 libcaf_impi.a
-rw-r--r-- 1 AUTH+bmaggard AUTH+Domain Users 2073652 Aug 26 08:40 libimpi.a
-rw-r--r-- 1 AUTH+bmaggard AUTH+Domain Users    7227 Aug 26 08:40 Makefile
-rw-r--r-- 1 AUTH+bmaggard AUTH+Domain Users    2030 Aug 26 08:40 opencoarrays.mod
Plus - make seems correct after touch on any or all:
impi.dll
impi.def
libimpi.a
libimpi.a.stamp
libcaf.h
libcaf-gfortran-descriptor.h
opencoarrays.F90
caf_auxiliar.c
mpi_caf.c
Plus - uname -a and cmake variables seem sufficient for introspection
Minus - creation src/libimpi.a.stamp (install.sh might clean that up...)
To check for installation of x86_64 prerequisite packages:
pacman -Qi mingw-w64-x86_64-gcc-fortran
pacman -Qi mingw-w64-x86_64-gcc
pacman -Qi mingw-w64-x86_64-gcc-libgfortran
pacman -Qi mingw-w64-x86_64-gcc-libs
pacman -Qi mingw-w64-x86_64-tools-git
pacman -Qi mingw-w64-x86_64-cmake
pacman -Qi mingw-w64-x86_64-make
$ pacman -Qi mingw-w64-x86_64-gcc-fortra | grep "^error: package '* ' was not found$"
error: package 'mingw-w64-x86_64-gcc-fortra' was not found
$ pacman -Qi mingw-w64-x86_64-gcc-fortran | grep "^error: package '* ' was not found$"
or, preferably, due to additionally checking for MSYS2/mingw64 subsystem with "^mingw64/...", could compare to "[installed]" with:
pacman -Ss gcc | grep "^mingw64/mingw-w64-x86_64-gcc-fortran " | tail -c 12
pacman -Ss gcc | grep "^mingw64/mingw-w64-x86_64-gcc " | tail -c 12
pacman -Ss gcc | grep "^mingw64/mingw-w64-x86_64-gcc-libgfortran " | tail -c 12
pacman -Ss gcc | grep "^mingw64/mingw-w64-x86_64-gcc-libs " | tail -c 12
pacman -Ss tools-git | grep "^mingw64/mingw-w64-x86_64-tools-git " | tail -c 12
pacman -Ss cmake | grep "^mingw64/mingw-w64-x86_64-cmake " | tail -c 12
pacman -Ss make | grep "^mingw64/mingw-w64-x86_64-make " | tail -c 12
$ pacman -Ss gcc | grep "^mingw64/mingw-w64-x86_64-gcc-fortran " | tail -c 12
[installed]
$ pacman -Ss gcc | grep "^mingw64/mingw-w64-x86_64-gcc " | tail -c 12
[installed]
$ pacman -Ss gcc | grep "^mingw64/mingw-w64-x86_64-gcc-libgfortran " | tail -c 12
[installed]
$ pacman -Ss gcc | grep "^mingw64/mingw-w64-x86_64-gcc-libs " | tail -c 12
[installed]
$ pacman -Ss tools-git | grep "^mingw64/mingw-w64-x86_64-tools-git " | tail -c 12
[installed]
$ pacman -Ss cmake | grep "^mingw64/mingw-w64-x86_64-cmake " | tail -c 12
[installed]
$ pacman -Ss make | grep "^mingw64/mingw-w64-x86_64-make " | tail -c 12
[installed]
Note the package version is between the " " at the end of grep string and "[installed]", in case you need to set a minimum package version.
May not have to check for install of gcc, gcc-libs, gcc-libgfortran packages, since they install as dependencies of gcc-fortran.
pacman -Qn and pacman -Qs provide more alternatives on verifying package installation (and list only installed packages), but the -Ss method above allows for
checking whether the package was installed for the mingw64/ subsystem (rather than msys/ or mingw32/ subsystems).


fetch-kde-qt: Store downloaded files directly in nix/store

Motivation for this change
Prevents redownloading files :)
@ttuegel
Things done

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

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

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
[ ] Tested execution of all binary files (usually in ./result/bin/)
[x] Fits CONTRIBUTING.md.

An older version of the script did this, but it turned out not to be a good idea. It is possible to generate URLs with the script that nobody else can download. If we store the pre-fetched files, then whoever is running the update script will not realize the problem. I have myself uploaded broken updates this way. Is there some way we can address this problem while also storing the pre-fetched files?

Are the urls working for the same person twice? Or could we just check a second time that the url is valid?

Are the urls working for the same person twice? Or could we just check a second time that the url is valid?

Well, it's not really checking a second time, it's that with Nixpkgs' mirror:// syntax, the URL used by the script is not necessarily the same as the URL used by Nix. If the download is cached in the store, the download is never made by Nix.

Yeah I know that it is currently not loaded a second time. That was the "solution", I thought of.
Any idea why an url is generated in the first run, that does not work? Maybe we can fix it that way.

Any idea why an url is generated in the first run, that does not work? Maybe we can fix it that way.

wget needs the full URL, but fetchurl takes the trailing part of the URL and appends it to mirror://kde/. If wget understood the mirror:// syntax, it would not be a problem; we could use exactly the same URLs for both. We cannot use curl like fetchurl does because it does not know how to recursively download directories (AFAIK).


net: TCPListener fails to return errors after Close on js/wasm

The test in https://go.dev/play/p/TO_F52CqMt8 consistently passes locally.
However, it consistently fails under js/wasm (CC @neelance):
$ GOOS=js GOARCH=wasm go test -v
=== RUN   TestTCPListenAfterClose
    listener_test.go:51: after l.Close(), l.Accept() = _, <nil>
        want use of closed network connection
--- FAIL: TestTCPListenAfterClose (0.01s)
FAIL

As far as I can tell this violates the net.Listener interface, which requires (emphasis mine):

Close closes the listener.
Any blocked Accept operations will be unblocked and return errors.

I noticed this via #22926.

package main

import (
	"context"
	"errors"
	"net"
	"sync"
	"testing"
	"time"
)

func TestTCPListenAfterClose(t *testing.T) {
	l, err := net.Listen("tcp", "<IP_ADDRESS>:0")
	if err != nil {
		t.Fatal(err)
	}

	var wg sync.WaitGroup
	ctx, cancel := context.WithCancel(context.Background())

	d := &net.Dialer{}
	for n := 2; n > 0; n-- {
		wg.Add(1)
		go func() {
			defer wg.Done()

			c, err := d.DialContext(ctx, l.Addr().Network(), l.Addr().String())
			if err == nil {
				<-ctx.Done()
				c.Close()
			}
		}()
	}

	c, err := l.Accept()
	if err == nil {
		c.Close()
	} else {
		t.Error(err)
	}
	time.Sleep(10 * time.Millisecond)
	cancel()
	wg.Wait()
	l.Close()

	c, err = l.Accept()
	if !errors.Is(err, net.ErrClosed) {
		if err == nil {
			c.Close()
		}
		t.Errorf("after l.Close(), l.Accept() = _, %v\nwant %v", err, net.ErrClosed)
	}
}

From further testing in CL 372714, it appears that the client ends of the buffered connections are not closed until the server ends have been returned (and closed) by Accept.
If the server closes the listener without subsequently draining the Accept queue, that can cause the client sides of those pending connections to hang indefinitely.


Can this plugin be used for BDD testing using Cucumber for Grails 3.2?

Hi,
Does anyone know how I might get this working with Grails 3.2?
Thanks In Advance,
David

Is this still an issue? @dap10


Panic on tree.get_child("mpuPresent")

Hi,
I'm beginning a project based on the ST SensorTile module and have a little problem generating the rust cmsis library with svd2rust. Here is the panic message :
thread 'main' panicked at '/home/greg/.cargo/registry/src/github.com-1ecc6299db9ec823/svd-parser-0.5.2/src/lib.rs:148 tree.get_child("mpuPresent")', /checkout/src/libcore/option.rs:823
stack backtrace:
   0: std::sys::imp::backtrace::tracing::imp::unwind_backtrace
             at /checkout/src/libstd/sys/unix/backtrace/tracing/gcc_s.rs:49
   1: std::sys_common::backtrace::_print
             at /checkout/src/libstd/sys_common/backtrace.rs:71
   2: std::panicking::default_hook::{{closure}}
             at /checkout/src/libstd/sys_common/backtrace.rs:60
             at /checkout/src/libstd/panicking.rs:355
   3: std::panicking::default_hook
             at /checkout/src/libstd/panicking.rs:371
   4: std::panicking::rust_panic_with_hook
             at /checkout/src/libstd/panicking.rs:549
   5: std::panicking::begin_panic
             at /checkout/src/libstd/panicking.rs:511
   6: std::panicking::begin_panic_fmt
             at /checkout/src/libstd/panicking.rs:495
   7: rust_begin_unwind
             at /checkout/src/libstd/panicking.rs:471
   8: core::panicking::panic_fmt
             at /checkout/src/libcore/panicking.rs:69
   9: core::option::expect_failed
             at /checkout/src/libcore/option.rs:823
  10: svd_parser::Device::parse
  11: svd_parser::parse
  12: svd2rust::main
  13: __rust_maybe_catch_panic
             at /checkout/src/libpanic_unwind/lib.rs:98
  14: std::rt::lang_start
             at /checkout/src/libstd/panicking.rs:433
             at /checkout/src/libstd/panic.rs:361
             at /checkout/src/libstd/rt.rs:59
  15: __libc_start_main
  16: _start

I'm quite new to Rust and can't know if the problem comes from the svd file or if it's an error coming from svd2rust. I've uploaded the sensorTile's mcu svd here --> stm32l4x6
I hope I'm on the right place to discuss about this problem!
Thanks for your answers!
Greg

Looks like some fields are missing in the cpu section of your svd file. You can try to add them manually. There is an example in documentation:
https://siliconlabs.github.io/Gecko_SDK_Doc/CMSIS/SVD/html/group__cpu_section__gr.html

But did you manage to fix the issue? Maybe svd2rust needs a better error messages...

Yes! Has you said, some fields were missing in the svd file. I've added the mpu field and another error has shown up, I've added this field as well and then it was OK.
Yes, a better error message would be great, just before the panic to announce that maybe some fields are missing.

FWIW, these panics come from the parser not from svd2rust. Sadly the parser doesn't have proper error handling so we can improve error messages in svd2rust until that is fixed in the parser.


Bump cm-promql to v0.15.0

upgrade codemirror-promql to v0.15.0
inject the metricNames in the PromQLExtension
update the import paths accordingly to the changes provided by this new release.
I also took the opportunity to move the @types packages from the dependencies list to the dev-dependencies. I hope you don't mind that I did it.
the @types/ packages are only used for the development, and not used to run the webapp. So these should move to the dev-dependencies part.

This PR synchronizes the changes performed on Prometheus side through the PRs https://github.com/prometheus/prometheus/pull/8706 and https://github.com/prometheus/prometheus/pull/8719

Oh cool thanks @bwplotka.

At one point... would like to help us maintaining Thanos on UI side?

Maybe it could be nice at some point, but maybe before saying a definitive yes, it would be nice to know what is the expectations and what does it mean to do that :D.

You can always chat with us about those things on our CNCF Slack with @onprem (@Prem Saraswat on Slack, maintainer currently the most familiar of frontend part) and me (@bwplotka on Slack) 🤗
Also: https://thanos.io/tip/thanos/maintainers.md/#how-to-be-maintainer

You can always chat with us about those things on our CNCF Slack with @onprem (@Prem Saraswat on Slack, maintainer currently the most familiar of frontend part) and me (@bwplotka on Slack) 🤗

And anyone else interested to help in any part of Thanos project!


Command to show outdated plugins

There are times when it's convenient to see which plugins are outdated — without actually updating them. Perhaps something like:
:PluginOutdated

Such a command could be used to show a list of outdated plugins, much like Homebrew and Pip do with brew outdated and pip list --outdated, respectively.

+1

I've created a plugin exactly for what you're asking, but it has no support of Vundle. So PR is welcome.
https://github.com/semanser/vim-outdated-plugins


instillation help

can anyone help me run this, i downloaded the zip and extracted it, copied the command lines and pasted them into miniconda, but its not doing anything

Hi! Since this is not an issue with the code, we created a discord server for the community to discuss DIAMOND usage, including installation and training support. Please feel free to post your issue (including as much detail as possible on your setup and any error messages) and we'll plan to provide support there, and hope that the community may be able to help too!


How to set openldap server name?

On deploy, servername is set as:
openldap-openldap-stack-ha.my-namespace.svc.cluster.local:389

How can I set servername to:
openldap.my-namespace.svc.cluster.local:389

Hi ,
you could use Values.fullnameOverride and Values.nameOverride .
Those are not defined in the Values.yaml but are referenced in the helper
let me know if this is working for you

fullnameOverride: openldap results in:
OpenLDAP has been installed. You can access the server from within the k8s cluster using:

  openldap.operator.svc.cluster.local:389

You can access the LDAP adminPassword and configPassword using:

  kubectl get secret --namespace operator openldap -o jsonpath="{.data.LDAP_ADMIN_PASSWORD}" | base64 --decode; echo
  kubectl get secret --namespace operator openldap -o jsonpath="{.data.LDAP_CONFIG_PASSWORD}" | base64 --decode; echo

You can access the LDAP service, from within the cluster (or with kubectl port-forward) with a command like (replace password and domain):
  ldapsearch -x -H ldap://openldap-service.operator.svc.cluster.local:389 -b dc=example,dc=org -D "cn=admin,dc=example,dc=org" -w $LDAP_ADMIN_PASSWORD```

What is appending the `-service` ?

The -service Is just hardcoded in the Note.txt that are displayed at the end of the. Deployement.
You should be able to access the service on openldap.my-namespace.svc.cluster.local:389

related to #21

Thanks, this works for me.


Add verification scripts

@deads2k @sttts ptal

 (3) Add verify script for client-go and api

/lgtm, only some nits

@soltysh I synced with the rebase branch and this now conflicts.  Sorry.

@soltysh I synced with the rebase branch and this now conflicts. Sorry.

No worries, I'll update it later today.

Rebased and some nits addressed. Ready for merge on green travis.

Rebased and some nits addressed. Ready for merge on green travis.

Thanks


Add API for refreshing task locks

Add task/:id/refreshLock API endpoint for refreshing an active
task lock, thereby extending its allowed duration

Add refreshItemLock method to Locking trait that updates the lock's
locked_time to the current time

Add evolution that adds created column to locked table for
tracking the creation time of the lock, allowing the total lock duration
to be tracked even if a lock is refreshed multiple times

Add basic Postman tests for starting a task, refreshing the task lock,
and releasing the task lock

So while you are in this part of the code, could you also make the lock time configurable. Currently it is 1hr, and we should continue to default to that, but making it default to different times could be useful. `SchedulerActor.scala line 76.

Good idea, @mgcuthbert , support added.

Thanks.


Use GitHub releases for versioning

Would you mind using GitHub releases so that users can install a specific version? This is really useful to avoid pulling in changes from master until we decide to upgrade.
Allows you to create a requirements.yml like this:
- src: nickhammond.logrotate
  version: v1.0.0

+1

Great idea, just added v0.0.1. I'll bump with changes.

:heart:


Update sbt-scalajs-bundler to 0.16.0

Updates ch.epfl.scala:sbt-scalajs-bundler from 0.14.0 to 0.16.0.
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Have a fantastic day writing Scala!

Ignore future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "ch.epfl.scala", artifactId = "sbt-scalajs-bundler" } ]

labels: semver-minor

Subsumed by https://github.com/coursier/coursier/pull/1715.


Remove MaxAttempts for CalculateBackoffTime

The variable name MaxAttempts is misleading. This variable is used for preventing the case that the attempts is larger than the bit number of long int. For example, 1 << 65  will give the same result as 1 << 1.
I think the name MaxSafeShiftBit or something similar will be more informative. The name MaxAttempts is quite misleading because it feels like if the attempts reach the MaxAttempts, the retry will be ended.
However, in the code,
//
// IMPORTANT: This can overflow
double calculatedMilliseconds = Math.Max(1, minDuration.TotalMilliseconds) * ((long)1 << Math.Min(attempts, MaxAttempts));

if (calculatedMilliseconds > maxDuration.TotalMilliseconds ||
        calculatedMilliseconds <= 0 /*overflow*/)
{
    calculatedMilliseconds = maxDuration.TotalMilliseconds;
}

In fact, attempts will never reach MaxAttempts, because maxDuration is usually very small.
In Python Provider, the implementation is the same as dotnet provider.
The max_attempts = 63 makes no sense in python provider to keep the same behavior since there is no overflow in python.
In this PR, I suggested using Math.Pow instead of << operation.
I tested the performance difference, it is only about 0.01 ms.
Double type will not have the overflow issue. The "overflow" will return double.PositiveInfinity which is larger than any double number. We can remove the code to work around overflow.
Also, I found the discussion about the exponential strategy which called out the possibility to adjust the factor.
Also, I feels Math.Max(1, minDuration.TotalMilliseconds) weird. I suggest adding some out range check for all TimeSpan parameters.

I agree with most of above points.
Btw I just glanced at the original discussion mentioned above, where a good analysis of factor was done and 1.5 was decided to be the value. Just wondering why it  eventually used 2 (with bitwise operation)? Performance or any other concern.

Just wondering why it eventually used 2 (with bitwise operation)? Performance or any other concern?

Because 2 is the de-facto approach for exponential backoff. Using 1.5 instead was proposed as an attempt to increase the amount of retry attempts performed on startup. An offline discussion was had about this. Changing the exponential growth factor isn't a real solution to the problem that was trying to be solved. After discussion to pin down what was actually desired when the original suggestion was made, it revealed that the desire was to have a max time between attempts on startup. So the final design was to keep an exponential growth factor of 2 over the long term, but design certain cut off points on startup where the max time between attempts is determined.

In this PR, I suggested using Math.Pow instead of << operation.
I tested the performance difference, it is only about 0.01 ms.

Bitwise operations are much faster than arithmetic operations because bit manipulation is optimized at the hardware level. Math.Pow is more generic and designed to handle floating point calculations better. Hence, it's not optimized for the special case that is calculating powers of 2. I think we should keep that optimization until we decide to change the exponential factor of 2.

The name MaxAttempts is quite misleading because it feels like if the attempts reach the MaxAttempts, the retry will be ended.

I agree with this, we can change the name of the variable to clarify the intended behavior.

The max_attempts = 63 makes no sense in python provider to keep the same behavior since there is no overflow in python.

@mrm9084 and I discussed this a while ago. Matt mentioned that 1 << 14284 can overflow in Python. Realistically, we will never reach that limit but it's still a good practice to have some upper bound for safeguarding. That's why we chose 63 to be consistent with other providers.

The max_attempts = 63 makes no sense in python provider to keep the same behavior since there is no overflow in python.

@mrm9084 and I discussed this a while ago. Matt mentioned that 1 << 14284 can overflow in Python. Realistically, we will never reach that limit but it's still a good practice to have some upper bound for safeguarding. That's why we chose 63 to be consistent with other providers.

I'll still update the variable name as I agree it isn't a good one.

@RichardChen820 The name "MaxSafeShiftBit" is more informative and indicate this variable is only for safeguarding the shift operation. When I was reading the code of dotnet provider, I was confused about the "MaxAttempts", I expected there would be some logic to end refresh when Attempts reachs MaxAttempts.


Reinstate a negative test to check that the format exception is caught in AnalyzeSkeletonWrapper

We used to have a negative test to ensure the format exception is caught as expected by the AnalyzeSkeletonWrapper, and that the correct error message relayed to the user in this case. See e.g. here for an idea how it worked. However, the way we mocked a File with a faulty format has become out of date. We should reinstate this test as soon as we figure out how to mock a File with a faulty format well.

https://github.com/bonej-org/BoneJ2/pull/283#issuecomment-776519017


End Portal No Spawn Location Error

I am running Multiverse-Core (+ MV-Inventories and MV-Portals) and am running into an issue where if you don't set a spawn point before entering the end portal, you will be permanently stuck in the end unless you TP out using commands. Basically, the end portal doesn't work, whenever you try to go through it it'll display "You have no home bed or charged respawn anchor, or it was obstructed" and then spawn you on top of the bedrock pillar on the portal. I encountered this issue both on Spigot and Paper (1.16.1) and both on the stable build (v4.1.0) and dev build (v4.1.1 snapshot).

Same issues as in #2160


Add support on @nestjs/testing

I am using @testjs/testing library to test nestjs application: https://docs.nestjs.com/fundamentals/testing.
But I found it doesn't work with hooks.
class ExampleHook {
      // Here we're including a value for manipulation
      value = 1;
    }

    @HookAction(ExampleHook)
    class DoubleValueAction implements IHookAction {
      // the handle function can be sync or async
      async handle(hook: ExampleHook) {
        //simulate an async call
        console.log('hook action')
        await new Promise((r) => setTimeout(r, 1000));
        //Optionally mutate data inside of the privded hook
        hook.value = hook.value * 2;

        /**
         * Optional: return a new value to be passed to the next hook
         *
         * After all hooks are run, the final value is passed back to runHook
         */
        return hook;
      }
    }

    @Injectable()
    class MyService {
      constructor(private hookService: HooksService){}
      async run(d: any) {
        console.log('xxxxx')
        return await this.hookService.runHook(new DoubleValueAction());
      }
    }

    const moduleRef = await Test.createTestingModule({
      imports: [
        HooksModule,
      ],
      providers: [
        DoubleValueAction,
        MyService,
      ],
    }).compile();
    service = await moduleRef.get(MyService);
    await service.run()

when I call the run method, the hook action is not triggered. And it doesn't have any error.

Hi @zhaoyi0113
Sorry for the late response.
It looks like you're calling runHook with an Action, instead of the hook itself.
        return await this.hookService.runHook(new DoubleValueAction());

Should be
        return await this.hookService.runHook(new ExampleHook());

Closing this issue, but feel free to ask more questions.


[BUG] Normals and bi-normals are broken on generated meshes

[ ] Box
[ ] Cone
[ ] Sphere
[x] Displacement
[ ] Plane

#97 Fixes displacement


How to generate an encoded public key?

Does anyone have idea how to?
Thanks!

The bnb prefixed string is known as an address, not a public key. Try using crypto.getAddressFromPublicKey.

Hey,
What I'm referring to is bnbp1addwnpepq0grg7xh2d3c90flp7mus8e0u3zz0wzycfnevwmtag0426k5uydnjpsl69d (PUBKEY), not the address tbnb1xjvftkyk0hhn4atmwwfye0kux8ktpfe5lcrxmx.  It seems current sdk api cannot generate the PUBKEY?

Ah, my bad. For that you can use the bech32 lib directly. check this example

Thank you Luke.
I've tried to use bech32 encode() and fromWords(), but it seems I'm still not able to get the same out as tbnbcli does. Can you please give some concrete example?
What I'm trying:
const bnbsdk = require('@binance-chain/javascript-sdk');
const bech32 = require('bech32');

const privateKey = bnbsdk.crypto.getPrivateKeyFromMnemonic(process.env.MNEMONIC);
const publicKey = bnbsdk.crypto.getPublicKeyFromPrivateKey(privateKey);
var words = bech32.toWords(Buffer.from(publicKey, 'hex'));
bech32.encode('bnbp', words, 200)

Hi @notatestuser Luke I still have trouble to get it generated PUBKEY.
I'm guessing the bech32 encoding doesn't work directly on the EC public key, but the EC public key may get some compression / encoding / truncating before applying the bech32 encoding on it.
Can you please share more details or concrete examples? I'll be more than appreciated !

It would help to know what you're trying to do. We just support hexadecimal encoding in the SDK so if you're just trying to compare the outputs: you could decode the bech32 and compare the output bytes with the hex returned by crypto.getPublicKeyFromPrivateKey.

I'm just trying to derive everything from mnemonics: privateKey, publicKey, address.
The decoded result of PUBKEY actually doesn't match what's yielded from private key, so that's what confuses me and I'd like to figure out why:
mnemonic: stumble chase victory bright iron plug laugh loud return recycle silk truck waste region hole spot crucial rifle detect tiny lecture wink airport buyer
> const bnbsdk = require('@binance-chain/javascript-sdk');
> const bech32 = require('bech32')
> const privateKey = bnbsdk.crypto.getPrivateKeyFromMnemonic(process.env.MNEMONIC);
> const publicKey = bnbsdk.crypto.getPublicKeyFromPrivateKey(privateKey);
> publicKey
'04d03478d7536382bd3f0fb7c81f2fe44427b844c267963b6bea1f556ad4e11b39dee7ad18f5f2f95f86482c5d63ba834a999e7cf47fdbeaf72eebee0100c19a0f'

> Buffer.from(bech32.decode('bnbp1addwnpepq0grg7xh2d3c90flp7mus8e0u3zz0wzycfnevwmtag0426k5uydnjpsl69d').words, 'hex').toString('hex')
'1d0d0d0e13011901000f0803081e06170a0d1118050f091f011e1b1c1007190f1c1102020f0e0204180913190c0e1b0b1d080f150a1a16141c040d1312'

You could clearly see the bech32 decoded result differs from the EC public key. They even have different lengths.
Can you help?

The bech32-encoded public key with the bnbp1 prefix is encoded differently (more specifically, it's encoded with Amino).
Here's a breakdown:

The Amino type prefix for a Tendermint secp256k1 public key is 0xeb5ae987
Then there is a length prefix that follows: 21 (which is 33 in decimal)
Then you have your encoded public key: 03d03478d7536382bd3f0fb7c81f2fe44427b844c267963b6bea1f556ad4e11b39

Therefore, you can go both ways like this with the SDK:
Decode bnbp string to address:
> aminoPrefixLen = 10
> pubkey = Buffer.from(bech32.fromWords(bech32.decode('bnbp1addwnpepq0grg7xh2d3c90flp7mus8e0u3zz0wzycfnevwmtag0426k5uydnjpsl69d').words), 'hex').toString('hex')
'eb5ae9872103d03478d7536382bd3f0fb7c81f2fe44427b844c267963b6bea1f556ad4e11b39'
> address = sdk.crypto.getAddressFromPublicKey(pubkey.substr(aminoPrefixLen))
'tbnb1xjvftkyk0hhn4atmwwfye0kux8ktpfe5lcrxmx'

Encode to bnbp string:
> aminoPrefix = 'eb5ae98721'
> mnemonic = 'stumble chase victory bright iron plug laugh loud return recycle silk truck waste region hole spot crucial rifle detect tiny lecture wink airport buyer'
> pubkey = sdk.crypto.getPublicKeyFromPrivateKey(sdk.crypto.getPrivateKeyFromMnemonic(mnemonic))
'04d03478d7536382bd3f0fb7c81f2fe44427b844c267963b6bea1f556ad4e11b39dee7ad18f5f2f95f86482c5d63ba834a999e7cf47fdbeaf72eebee0100c19a0f'
> compressed = sdk.crypto.getPublicKey(pubkey).encodeCompressed('hex')
'03d03478d7536382bd3f0fb7c81f2fe44427b844c267963b6bea1f556ad4e11b39'
> bech32.encode('bnbp', bech32.toWords(Buffer.from(aminoPrefix + compressed, 'hex')))
'bnbp1addwnpepq0grg7xh2d3c90flp7mus8e0u3zz0wzycfnevwmtag0426k5uydnjpsl69d'

and you have arrived back at the encoded string you see printed by your tbnbcli.
The Amino prefix string eb5ae98721 is a constant for any public key, so you can try this yourself with other mnemonics.

@notatestuser  Thanks very much for your detailed answer Luke!
Does the Amino prefix also applies to other types of public keys, like consensus node public key ('bcap'), validator operator public key ('bvap'), etc. ?

Just based on the type/curve. Here is a helpful table.

hit this wall, and this issue was perfect. Thanks @notatestuser!


Use callbacks internally instead of async funcs

Tests are passing but that may not actually mean anything due to the low coverage.
This PR replaces all internal use of Route with direct calls to Connection#request, which now takes an additional argument to transform the promise result before resolving.
This should improve the performance of most functions without affecting the external API.

Review is currently blocked by test coverage.


Release 5.0.0 RC1

This branch is live on PyPi as alerta-server 5.0.0rc1 https://pypi.python.org/pypi/alerta-server/5.0.0rc1

👍


vuetify typography classes don't work

I'm trying to use some of the typography classes but none of them work.
import ipyvuetify as v
v.Html(tag="div", class_="text-h1",  children = ["I don't work"])

it seems a bug to me

Be careful I think ipyvuetify is not yet wired to the latest version of vuetify. As a consequence it only wire typography prior to v2.3.0 (https://v2.vuetifyjs.com/en/styles/text-and-typography/#typography):
.display-4
.display-3
.display-2
.display-1
.headline
.title
.subtitle-1
.subtitle-2
.body-1
.body-2
.caption
.overline

import ipyvuetify as v
v.Html(tag="div", class_="display-1",  children = ["I do work"])

thank you, I didn't see that huge green message.


Add: GoLang bindings

:tada: This PR is included in version 0.12.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


hit

how long do i need to wait for a hit its been a very long time and i have not gotten a hit. is there a way to fix this

how many threads,timeout did you, did you enter yes for proxy scrap if yes what proxy type did you choose ?

i am using socks4 but i tried all the other ones to  my timeout is 3 and i picked yes and 200 threads

download the new one


(9.7.10) mod fails to import laws/districts

This error is thrown into server console when attempting to.
[19:05:21.399] [16] [ Info] [Eco] [CivicsImpExpPlugin] ERROR: Failed to import stub for civic DistrictMap:"District Map": System.MissingMethodException: Attempted to access a missing method.
   at Eco.Mods.CivicsImpExp.BundledCivic.CreateStub()
   at Eco.Mods.CivicsImpExp.ImportContext.ImportStub(BundledCivic bundledCivic)
   at Eco.Mods.CivicsImpExp.CivicBundle.ImportAll(Settlement settlement)

Addressed in 0.6.3


Suggestions: course in Pluralsigth about wexflow

course in Pluralsigth about wexflow with full real world samples.

I'll try to do some video tutorials with real world samples soon.


ci: Integrate Zeus and release with the bot [WIP]

This PR enables the release bot via Zeus. Essentially, to push a new release to npm you just have to bump the version and push the tag. This has been adapted in scripts/deploy.js.
After the Travis build succeeds, the bot will download the npm package tarball from Zeus and publish it to npm with its user. The package needs to show up on the Sentry developers team on npm for this to work. Additonally, all built javascript sources will be uploaded to the GitHub releases page, so people can download bundles and source maps from there directly. CDN uploads are still missing.
Also, a release on GitHub is created and automatically gets the changelog from CHANGELOG.md.
Note that coverage and tests are still missing in Zeus. Also beware that once the package goes scoped, release.yml also needs to be updated.

CDN releases make this a little more complicated, plus there might be other things to change (e.g. dist/ folder vs Github releases page). We should revisit this once we have answered all the open questions.


Record type quotes

It looks like for record types the this.x=$arg0 are being wrapped in a quotes.
The following code:
type ElementBuilder = {
    TypeName: string
    Styles: (string * obj) list
}

emits this js:
  var ElementBuilder = Program.ElementBuilder = function () {
    function _class($arg0, $arg1) {
      _classCallCheck(this, _class);

      "this.TypeName=$arg0;this.Styles=$arg1";
    }

    return _class;
  }();

Strange, this works fine for me both in Mac and Windows. Are you using the last code (I changed something about this recently)? If so, can you please post or link to the full code? Cheers!

I've delete my repo and start again and everything seem to be working now.  Thanks