need the document about the config arguments settings

I am trying to training the SELOR using another data (Bert model) to do experiment of detecting the sentence is risk or not risk.
But some error happend when create_pretrain_dataset, for example:
Creating datasets for antecedent length 1 antecedents
torch.Size([1106, 1])
Creating datasets for antecedent length 2 antecedents
torch.Size([249, 2])
n_sample = 249
Traceback (most recent call last):
File "/home/joshua/SELOR/pretrain_consequent_estimator.py", line 121, in
pretrain_dataset = ds.create_pretrain_dataset(
File "/home/joshua/SELOR/selor_utils/dataset.py", line 956, in create_pretrain_dataset
p_ds = PretrainDataset(
File "/home/joshua/SELOR/selor_utils/dataset.py", line 299, in init
assert n_sample % num_classes == 0
AssertionError
Another problem is:
PretrainDataset 's init never end because the following line dead loop:
while not all(sample_dict[i].done for i in range(num_classes)):
I think maybe these problems are related to the config arguments setting, so would you please provide the document about the config arguments settings and explain how to set the config accroding to the train/test data.
Thanks!

Hi, you can find the explanation about config arguments in the help messages from selor_utils/utils.py.
And it seems that your dataset is highly imbalanced.
If the init of PretrainDataset fell into the dead loop of "while not all(sample_dict[i].done for i in range(num_classes))",
it means that your chosen antecedents all belongs to one class, risky or non-risky.
I suggest you several way that may works.

Make min_df=0 and max_df=1.0
It would help that the seldom cases would not be filtered out.

Check you atoms.
Make the class ratio of atoms to be uniform if it is possible.

Manual Sampling.
If the class ratio of atoms is highly imbalanced, It is possible that the random sampling code choose the antecedents only from the dominating class. In this case, manually giving some constraint in the sampling would help.

Check you atoms.
Make the class ratio of atoms to be uniform if it is possible.
Manual Sampling.
If the class ratio of atoms is high

Yes, the dataset is highly imbalanced,
Thanks a lot! I will try your suggestion.

Thanks @archon159  very much, the code run successfully on my dataset.
I have another question: the antecedents are AND between the atoms, I wonder how to implement the OR (only OR is enough for me) between atoms, Thanks!

Hi @joshua-xia,
The easiest way to implement "OR" is using multiple heads.
If you see selor.py line129, you can control the number of heads.
Thanks.

line129

Thanks, it is real easy implementation, I am testing your suggestion;
I just confirm you understood my means:
I want antecedent to be OR between atoms:
line 629 in selor_utils)/train_eval.py:
antecedent_str = ' & '.join([atom.display_str for atom in antecedent])
should be
antecedent_str = ' | '.join([atom.display_str for atom in antecedent])
just change heads = 2 or 3 or 4 works?

So, each heads gives you rule individually.
As they are independent, we regards them as OR.
For example, if you want 4-length OR rules, please use antecedent_len=1, heads=4.

So, each heads gives you rule individually.
As they are independent, we regards them as OR.
For example, if you want 4-length OR rules, please use antecedent_len=1, heads=4.

got, both antecedent_len and heads need to be modified.

selor.py line 121:
Freeze the consequent estimator
for p in ce_model.parameters():
    p.requires_grad=False

Why we need freeze the consequent estimator? it seems performance of selor is better if we don't freeze.

It depends on dataset.
If it is better, it may not be the problem.

another question, use the yelp dataset and bert model as example:
The atoms and antecedents are generated from the train dataset, so if a test case (test instance) contain the Positive or Negative words which not exist in train dataset, then the Positive or Negative words can NOT be in the explanation results, right?
It seems the defect of SELOR?

Right. Our basic assumption is, the training dataset and test dataset has come from the same distribution.

@archon159  where can I download clickbait and adult dataset? can you provide the url links? Thanks!


Fred French QC text

ADO-XXX
Description
List of proposed changes:

Fred French text QC changes

What to test for/How to test
Additional Notes

@Fbasham  already made changes to French content. #350


[regression-9.0.0] "Image could not be created" JavaScript error when opening app

Bug description
When opening the built app a JavaScript error occurs.

[x] I looked at nativefier --help and https://github.com/jiahaog/nativefier/blob/master/docs/api.md
[x] I searched existing open & closed issues. Yes, my bug is new.
[x] I'm using the latest version available at https://github.com/jiahaog/nativefier/releases

Steps to reproduce

Run nativefier https://google.com --name MyApp
Open app
See error :)

Expected behavior
The app should open properly
Actual behavior
An JavaScript Error occurs
Debug info

Context

Nativefier: 9.0.0
Node.js: v14.4.0
Npm: 6.14.4
OS: Mac OSX Catalina 10.15.5 (19F101)
Last working: Nativefier 8.0.7

Came here to report this very issue.
Nativefier: 9.0.4 (installed via HomeBrew)
OS: Mac OSX Mojave 10.14.6
This is my first install of Nativefier. So "Last working" = never.

nativefier --version
9.0.0

nativefier --name "Roam" https://roamresearch.com/#/app/primarydb

Preparing Electron app...

Converting icons...

Packaging... This will take a few seconds, maybe minutes if the requested Electron isn't cached yet...
Packaging app for platform darwin x64 using electron v9.0.4

Finalizing build...
App built to /Users/adamz/Roam-darwin-x64

A JavaScript error occurred in the main process
Uncaught Exception:
TypeError: Cannot read property 'show' of undefined
    at App.<anonymous> (/Users/adamz/Roam-darwin-x64/Roam.app/Contents/Resources/app/lib/webpack:/src/main.ts:101:18)
    at App.emit (events.js:223:5)

@zethraeus What is your node and npm version?

@zethraeus What is your node and npm version?

I can also confirm a similar error that happened after upgrading to version 9.0.0 on macOS Catalina 10.15.5

❯ node --version
v14.4.0

~
❯ npm --version
6.14.5

~
❯ nativefier --version
9.0.0

Tested on Windows 10 1909 with:
> node --version
v12.18.0

> npm --version
6.14.4

> nativefier --version
9.0.0

Same result on macOS Catalina as others have posted above.

Thanks for the reports everybody! Very little changed between Nativefier 8.0.7 and 9.0.0, apart from a new major Electron, and Nativefier 9.0.0 works for me under Linux. So, I suspect Electron trouble.
@TFisicaro @zethraeus @schloram @MalEbenSo @kris-anderson, and all the voters of this issue (by the way, thaaaaaaaanks a million for just using the vote button if you want to confirm a bug and have nothing to add :heart:), can you try with an {older, beta} version of Electron?

Try passing -e 8.3.2 for the latest Electron 8.x
Try passing -e 10.0.0-beta.3 for the latest Electron 10 beta

, and report here with:

Full call of nativefier, with options & url passed, and using --verbose. So, should be nativefier --verbose -e [version] [your other options] [your url]
--verbose build console output
Resulting bug/screenshot (as already done a few times above)

Thanks for your input @ronjouch!
Curiously, using, --verbose produces a different error message after the app has been built.
Here is my output for nativefier -i coda.icns -n "Coda" --clear-cache --verbose coda.io:
`URL "coda.io" lacks a protocol. Will try to parse it as HTTPS: "https://coda.io". Please pass "http://coda.io" if this is what you meant.
Running in verbose mode! This will produce a mountain of logs and is recommended only for troubleshooting or if you like Shakespeare.
Performing async options post-processing.
Inferring user agent for electron 9.0.4 / darwin
Grabbing electron<->chrome versions file from https://atom.io/download/atom-shell/index.json
Got icon from options. Using it, no inferring needed
Got name Coda from options. No inferring needed
Sanitized filename for Coda : Coda
Associated electron v9.0.4 to chrome v83.0.4103.104
Given chrome 83.0.4103.104 on darwin, using user agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.104 Safari/537.36
Preparing Electron app...
Copying electron app from /Users/sebastian/.npm-global/lib/node_modules/nativefier/app to /var/folders/99/dj_bt_kj7410dlry793g5g5m0000gn/T/nativefier-15-36-19-app--54349-2Lh2915o295o
Writing app config to /var/folders/99/dj_bt_kj7410dlry793g5g5m0000gn/T/nativefier-15-36-19-app--54349-2Lh2915o295o/nativefier.json
No files to inject, skipping copy.
Updating /var/folders/99/dj_bt_kj7410dlry793g5g5m0000gn/T/nativefier-15-36-19-app--54349-2Lh2915o295o/package.json 'name' field to coda-nativefier-f8b47c
Converting icons...
Building for macOS and icon is already a .icns, no conversion needed
Packaging... This will take a few seconds, maybe minutes if the requested Electron isn't cached yet...
electron-packager Electron Packager 14.2.1
electron-packager Node v8.11.1
electron-packager Host Operating system: darwin 19.4.0 (x64) +0ms
electron-packager Packager Options: {"arch":"x64","asar":false,"darwinDarkModeSupport":false,"dir":"/var/folders/99/dj_bt_kj7410dlry793g5g5m0000gn/T/nativefier-15-36-19-app--54349-2Lh2915o295o","electronVersion":"9.0.4","icon":"coda.icns","name":"Coda","out":"/Users/sebastian/Downloads/coda packaging","overwrite":true,"platform":"darwin","targetUrl":"https://coda.io/","tmpdir":false,"win32metadata":{"ProductName":"Coda","InternalName":"Coda","FileDescription":"Coda"}} +1ms
electron-packager Target Platforms: darwin +1ms
electron-packager Target Architectures: x64 +0ms
electron-packager Inferring appVersion from version in /var/folders/99/dj_bt_kj7410dlry793g5g5m0000gn/T/nativefier-15-36-19-app--54349-2Lh2915o295o/package.json +0ms
electron-packager Application name: Coda +19ms
electron-packager Target Electron version: 9.0.4 +0ms
electron-packager Ignored path regular expressions: [ '/\.git($|/)', '/node_modules/\.bin($|/)', '\.o(bj)?$' ] +0ms
electron-packager Downloading Electron with options {"platform":"darwin","arch":"x64","version":"9.0.4","artifactName":"electron"} +0ms
Packaging app for platform darwin x64 using electron v9.0.4
electron-packager Creating /Users/sebastian/Downloads/coda packaging/darwin-x64-template +12ms
electron-packager Extracting /Users/sebastian/Library/Caches/electron/httpsgithub.comelectronelectronreleasesdownloadv9.0.4electron-v9.0.4-darwin-x64.zip/electron-v9.0.4-darwin-x64.zip to /Users/sebastian/Downloads/coda packaging/darwin-x64-template +1ms
electron-packager Initializing app in /Users/sebastian/Downloads/coda packaging/Coda-darwin-x64 from /Users/sebastian/Downloads/coda packaging/darwin-x64-template template +0ms
electron-packager Ignored paths based on the out param: [ '/Users/sebastian/Downloads/coda packaging/Coda-darwin-x64',
'/Users/sebastian/Downloads/coda packaging/Coda-linux-ia32',
'/Users/sebastian/Downloads/coda packaging/Coda-linux-x64',
'/Users/sebastian/Downloads/coda packaging/Coda-linux-armv7l',
'/Users/sebastian/Downloads/coda packaging/Coda-linux-arm64',
'/Users/sebastian/Downloads/coda packaging/Coda-linux-mips64el',
'/Users/sebastian/Downloads/coda packaging/Coda-mas-x64',
'/Users/sebastian/Downloads/coda packaging/Coda-win32-ia32',
'/Users/sebastian/Downloads/coda packaging/Coda-win32-x64',
'/Users/sebastian/Downloads/coda packaging/Coda-win32-arm64' ] +5s
electron-packager Copying icon "coda.icns" to app's Resources as "electron.icns" +0ms
electron-packager Renaming Electron to Coda in /Users/sebastian/Downloads/coda packaging/Coda-darwin-x64/Electron.app/Contents/MacOS +105ms
electron-packager Renaming Electron Helper to Coda Helper in /Users/sebastian/Downloads/coda packaging/Coda-darwin-x64/Electron.app/Contents/Frameworks/Electron Helper.app/Contents/MacOS +3ms
electron-packager Renaming Electron Helper (Renderer) to Coda Helper (Renderer) in /Users/sebastian/Downloads/coda packaging/Coda-darwin-x64/Electron.app/Contents/Frameworks/Electron Helper (Renderer).app/Contents/MacOS +1ms
electron-packager Renaming Electron Helper (Plugin) to Coda Helper (Plugin) in /Users/sebastian/Downloads/coda packaging/Coda-darwin-x64/Electron.app/Contents/Frameworks/Electron Helper (Plugin).app/Contents/MacOS +0ms
electron-packager Renaming Electron Helper (GPU) to Coda Helper (GPU) in /Users/sebastian/Downloads/coda packaging/Coda-darwin-x64/Electron.app/Contents/Frameworks/Electron Helper (GPU).app/Contents/MacOS +1ms
electron-packager Renaming Electron Helper.app to Coda Helper.app in /Users/sebastian/Downloads/coda packaging/Coda-darwin-x64/Electron.app/Contents/Frameworks +0ms
electron-packager Renaming Electron Helper (Renderer).app to Coda Helper (Renderer).app in /Users/sebastian/Downloads/coda packaging/Coda-darwin-x64/Electron.app/Contents/Frameworks +1ms
electron-packager Renaming Electron Helper (Plugin).app to Coda Helper (Plugin).app in /Users/sebastian/Downloads/coda packaging/Coda-darwin-x64/Electron.app/Contents/Frameworks +1ms
electron-packager Renaming Electron Helper (GPU).app to Coda Helper (GPU).app in /Users/sebastian/Downloads/coda packaging/Coda-darwin-x64/Electron.app/Contents/Frameworks +0ms
Finalizing build...
Copying icons if necessary
No copying necessary on macOS; aborting
App built to /Users/sebastian/Downloads/coda packaging/Coda-darwin-x64`
This will lead to the following error on app-opening:

Not using --verbose leads to the error reported first by @schloram.

When building with electron 8.3.2 the error disappears for me.
The site "dhl.de" works flawlessly.
The site "ebay-kleinanzeigen.de" also starts without the error message. Then the login fails: just white window, nothing happening. This seems to be a different problem.
System info
Nativefier: 9.0.4 (installed via HomeBrew)
OS: macOS Mojave 10.14.6
node: 14.4.0
npm: 6.14.4
Attachments
a) screenshot of error message for dhl.de with electron 9.0.4 (default)
b) screenshot of error message for ebay-kleinanzeigen.de with electron 9.0.4 (default)
c) verbose output when building with 9.0.4 and 8.3.2.
verbose_output.pdf

Thanks for the other hint to fallback to an earlier Electron-version @ronjouch.
As also reported by @MalEbenSo using -e 8.3.2 also succeeds to build here. 👍

I have the same exact problem as @schloram, trying to generate a GitLab app.
I have tried with various Electron versions (from 5 to 10) and none of them worked for me. From 5 to 8 I only have a white screen when launching the app. For version 9 I have the same error dialog as @schloram. For version 10-beta I have an error report window.
Since the error with Electron 9 reports a problem with the image, I have tried passing the icon when calling nativefier, but to no effect.
Before that I've never encountered this problem with nativefier, but I don't know what version I was using before (probably an 8.x version).
Here are the details.
Command
nativefier --name "GitLab" --maximize --single-instance -internal-urls ".+" -e 8.3.2 -i logos/gitlab.png --verbose "https://gitlab.com/"
Context

Nativefier: 9.0.0
Node.js: v14.3.0
Npm: 6.14.4
OS: Mac OSX Mojave 10.14.6

Verbose
URL ".+" lacks a protocol. Will try to parse it as HTTPS: "https://.+". Please pass "http://.+" if this is what you meant.
Running in verbose mode! This will produce a mountain of logs and is recommended only for troubleshooting or if you like Shakespeare.

ATTENTION: Using **old** Electron version 8.3.2 as requested.
It's untested, bugs and horror will happen, you're on your own.
Simply abort & re-run without passing the version flag to default to 9.0.4

Performing async options post-processing.
Inferring user agent for electron 8.3.2 / darwin
Grabbing electron<->chrome versions file from https://atom.io/download/atom-shell/index.json
Got icon from options. Using it, no inferring needed
Got name GitLab from options. No inferring needed
Sanitized filename for GitLab : GitLab
Associated electron v8.3.2 to chrome v80.0.3987.165
Given chrome 80.0.3987.165 on darwin, using user agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.165 Safari/537.36

Preparing Electron app...
Copying electron app from /usr/local/lib/node_modules/nativefier/app to /var/folders/nm/89jj4cls3rsbb4xfbkp99mb00000gn/T/nativefier-16-48-27-app--29562-aeQWvTSHfpTA
Writing app config to /var/folders/nm/89jj4cls3rsbb4xfbkp99mb00000gn/T/nativefier-16-48-27-app--29562-aeQWvTSHfpTA/nativefier.json
No files to inject, skipping copy.
Updating /var/folders/nm/89jj4cls3rsbb4xfbkp99mb00000gn/T/nativefier-16-48-27-app--29562-aeQWvTSHfpTA/package.json 'name' field to gitlab-nativefier-4b2337

Converting icons...
Converting icon logos/gitlab.png to /var/folders/nm/89jj4cls3rsbb4xfbkp99mb00000gn/T/nativefier-16-48-27-iconconv--29562-pkMeZf5hEyl8/icon.icns. Calling: "/usr/local/lib/node_modules/nativefier/icon-scripts/convertToIcns" "logos/gitlab.png" "/var/folders/nm/89jj4cls3rsbb4xfbkp99mb00000gn/T/nativefier-16-48-27-iconconv--29562-pkMeZf5hEyl8/icon.icns"
Conversion succeeded and produced icon at /var/folders/nm/89jj4cls3rsbb4xfbkp99mb00000gn/T/nativefier-16-48-27-iconconv--29562-pkMeZf5hEyl8/icon.icns

Packaging... This will take a few seconds, maybe minutes if the requested Electron isn't cached yet...
  electron-packager Electron Packager 14.2.1
  electron-packager Node v14.3.0
  electron-packager Host Operating system: darwin 18.7.0 (x64) +0ms
  electron-packager Packager Options: {"arch":"x64","asar":false,"darwinDarkModeSupport":false,"dir":"/var/folders/nm/89jj4cls3rsbb4xfbkp99mb00000gn/T/nativefier-16-48-27-app--29562-aeQWvTSHfpTA","electronVersion":"8.3.2","icon":"/var/folders/nm/89jj4cls3rsbb4xfbkp99mb00000gn/T/nativefier-16-48-27-iconconv--29562-pkMeZf5hEyl8/icon.icns","name":"GitLab","out":"https://gitlab.com/","overwrite":true,"platform":"darwin","targetUrl":"https://.+/","tmpdir":false,"win32metadata":{"ProductName":"GitLab","InternalName":"GitLab","FileDescription":"GitLab"}} +0ms
  electron-packager Target Platforms: darwin +0ms
  electron-packager Target Architectures: x64 +0ms
  electron-packager Inferring appVersion from version in /var/folders/nm/89jj4cls3rsbb4xfbkp99mb00000gn/T/nativefier-16-48-27-app--29562-aeQWvTSHfpTA/package.json +0ms
  electron-packager Application name: GitLab +6ms
  electron-packager Target Electron version: 8.3.2 +0ms
  electron-packager Ignored path regular expressions: [ '/\\.git($|/)', '/node_modules/\\.bin($|/)', '\\.o(bj)?$' ] +0ms
  electron-packager Downloading Electron with options {"platform":"darwin","arch":"x64","version":"8.3.2","artifactName":"electron"} +0ms
Packaging app for platform darwin x64 using electron v8.3.2
  electron-packager Creating /Applications/nativefier/https:/gitlab.com/darwin-x64-template +5ms
  electron-packager Extracting /Users/mmmmore/Library/Caches/electron/httpsgithub.comelectronelectronreleasesdownloadv8.3.2electron-v8.3.2-darwin-x64.zip/electron-v8.3.2-darwin-x64.zip to /Applications/nativefier/https:/gitlab.com/darwin-x64-template +0ms
  electron-packager Initializing app in https:/gitlab.com/GitLab-darwin-x64 from /Applications/nativefier/https:/gitlab.com/darwin-x64-template template +0ms
  electron-packager Ignored paths based on the out param: [ '/Applications/nativefier/https:/gitlab.com' ] +1s
  electron-packager Copying icon "/var/folders/nm/89jj4cls3rsbb4xfbkp99mb00000gn/T/nativefier-16-48-27-iconconv--29562-pkMeZf5hEyl8/icon.icns" to app's Resources as "electron.icns" +0ms
  electron-packager Renaming Electron to GitLab in https:/gitlab.com/GitLab-darwin-x64/Electron.app/Contents/MacOS +56ms
  electron-packager Renaming Electron Helper to GitLab Helper in https:/gitlab.com/GitLab-darwin-x64/Electron.app/Contents/Frameworks/Electron Helper.app/Contents/MacOS +0ms
  electron-packager Renaming Electron Helper (Renderer) to GitLab Helper (Renderer) in https:/gitlab.com/GitLab-darwin-x64/Electron.app/Contents/Frameworks/Electron Helper (Renderer).app/Contents/MacOS +1ms
  electron-packager Renaming Electron Helper (Plugin) to GitLab Helper (Plugin) in https:/gitlab.com/GitLab-darwin-x64/Electron.app/Contents/Frameworks/Electron Helper (Plugin).app/Contents/MacOS +0ms
  electron-packager Renaming Electron Helper (GPU) to GitLab Helper (GPU) in https:/gitlab.com/GitLab-darwin-x64/Electron.app/Contents/Frameworks/Electron Helper (GPU).app/Contents/MacOS +0ms
  electron-packager Renaming Electron Helper.app to GitLab Helper.app in https:/gitlab.com/GitLab-darwin-x64/Electron.app/Contents/Frameworks +0ms
  electron-packager Renaming Electron Helper (Renderer).app to GitLab Helper (Renderer).app in https:/gitlab.com/GitLab-darwin-x64/Electron.app/Contents/Frameworks +0ms
  electron-packager Renaming Electron Helper (Plugin).app to GitLab Helper (Plugin).app in https:/gitlab.com/GitLab-darwin-x64/Electron.app/Contents/Frameworks +0ms
  electron-packager Renaming Electron Helper (GPU).app to GitLab Helper (GPU).app in https:/gitlab.com/GitLab-darwin-x64/Electron.app/Contents/Frameworks +0ms

Finalizing build...
Copying icons if necessary
No copying necessary on macOS; aborting
App built to https:/gitlab.com/GitLab-darwin-x64

Thanks for your input @ronjouch!
Curiously, using, --verbose produces a different error message after the app has been built.
...

I get this message when I try to relaunch the app after failing to close the app after the original (icon.png) error message.

It seems electron wants an icon.png in the Resources dir ... I fixed my Gmail app by doing this:
sips -s format png Gmail-darwin-x64/Gmail.app/Contents/Resources/electron.icns --out Gmail-darwin-x64/Gmail.app/Contents/Resources/app/icon.png

(on macOS 10.15.4)

Thanks for the other hint to fallback to an earlier Electron-version @ronjouch.
As also reported by @MalEbenSo using -e 8.3.2 also succeeds to build here. 👍

I can also confirm this works for me.
Passing -e 10.0.0-beta.3 results in the app crashing immediately upon startup with no error message.
Here's the verbose output when I run this without the -e parameter:
❯ nativefier --name "Google Calendar" "https://calendar.google.com" "$HOME/Applications/" --verbose
Running in verbose mode! This will produce a mountain of logs and is recommended only for troubleshooting or if you like Shakespeare.

Performing async options post-processing.
Inferring user agent for electron 9.0.4 / darwin
Grabbing electron<->chrome versions file from https://atom.io/download/atom-shell/index.json
Inferring icon for https://calendar.google.com/ on darwin
Inferring icon from store for https://calendar.google.com/ on darwin
Allowed icon formats when building for darwin: [ '.icns', '.png', '.ico' ]
Got name Google Calendar from options. No inferring needed
Sanitized filename for Google Calendar : Google Calendar
Got 249 icons from gitcloud
Max icon match score: 2
Downloading https://jiahaog.github.io/nativefier-icons/files/google-calendar.png
Got an icon from the page.
Writing 19.1 kb icon to /var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-iconinfer--11318-eAD3qj8pSU6u/icon.png
Associated electron v9.0.4 to chrome v83.0.4103.104
Given chrome 83.0.4103.104 on darwin, using user agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.104 Safari/537.36

Preparing Electron app...
Copying electron app from /usr/local/Cellar/nativefier/9.0.0/libexec/lib/node_modules/nativefier/app to /var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-app--11318-Kx9HD0L4S3BL
Writing app config to /var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-app--11318-Kx9HD0L4S3BL/nativefier.json
No files to inject, skipping copy.
Updating /var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-app--11318-Kx9HD0L4S3BL/package.json 'name' field to google-calendar-nativefier-e22938

Converting icons...
Converting icon /var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-iconinfer--11318-eAD3qj8pSU6u/icon.png to /var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-iconconv--11318-PlKPoczYofvl/icon.icns. Calling: "/usr/local/Cellar/nativefier/9.0.0/libexec/lib/node_modules/nativefier/icon-scripts/convertToIcns" "/var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-iconinfer--11318-eAD3qj8pSU6u/icon.png" "/var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-iconconv--11318-PlKPoczYofvl/icon.icns"
Conversion succeeded and produced icon at /var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-iconconv--11318-PlKPoczYofvl/icon.icns

Packaging... This will take a few seconds, maybe minutes if the requested Electron isn't cached yet...
  electron-packager Electron Packager 14.2.1
  electron-packager Node v14.4.0
  electron-packager Host Operating system: darwin 19.5.0 (x64) +0ms
  electron-packager Packager Options: {"arch":"x64","asar":false,"darwinDarkModeSupport":false,"dir":"/var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-app--11318-Kx9HD0L4S3BL","electronVersion":"9.0.4","icon":"/var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-iconconv--11318-PlKPoczYofvl/icon.icns","name":"Google Calendar","out":"/Users/kris/Applications/","overwrite":true,"platform":"darwin","targetUrl":"https://calendar.google.com/","tmpdir":false,"win32metadata":{"ProductName":"Google Calendar","InternalName":"Google Calendar","FileDescription":"Google Calendar"}} +0ms
  electron-packager Target Platforms: darwin +0ms
  electron-packager Target Architectures: x64 +0ms
  electron-packager Inferring appVersion from version in /var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-app--11318-Kx9HD0L4S3BL/package.json +0ms
  electron-packager Application name: Google Calendar +6ms
  electron-packager Target Electron version: 9.0.4 +0ms
  electron-packager Ignored path regular expressions: [ '/\\.git($|/)', '/node_modules/\\.bin($|/)', '\\.o(bj)?$' ] +0ms
  electron-packager Downloading Electron with options {"platform":"darwin","arch":"x64","version":"9.0.4","artifactName":"electron"} +0ms
Packaging app for platform darwin x64 using electron v9.0.4
  electron-packager Creating /Users/kris/Applications/darwin-x64-template +3ms
  electron-packager Extracting /Users/kris/Library/Caches/electron/httpsgithub.comelectronelectronreleasesdownloadv9.0.4electron-v9.0.4-darwin-x64.zip/electron-v9.0.4-darwin-x64.zip to /Users/kris/Applications/darwin-x64-template +1ms
  electron-packager Initializing app in /Users/kris/Applications/Google Calendar-darwin-x64 from /Users/kris/Applications/darwin-x64-template template +0ms
  electron-packager Ignored paths based on the out param: [ '/Users/kris/Applications' ] +2s
  electron-packager Copying icon "/var/folders/_k/hrxc6w_d4rx84_k6cpd1hzkw0000gn/T/nativefier-14-31-46-iconconv--11318-PlKPoczYofvl/icon.icns" to app's Resources as "electron.icns" +0ms
  electron-packager Renaming Electron to Google Calendar in /Users/kris/Applications/Google Calendar-darwin-x64/Electron.app/Contents/MacOS +72ms
  electron-packager Renaming Electron Helper to Google Calendar Helper in /Users/kris/Applications/Google Calendar-darwin-x64/Electron.app/Contents/Frameworks/Electron Helper.app/Contents/MacOS +0ms
  electron-packager Renaming Electron Helper (Renderer) to Google Calendar Helper (Renderer) in /Users/kris/Applications/Google Calendar-darwin-x64/Electron.app/Contents/Frameworks/Electron Helper (Renderer).app/Contents/MacOS +1ms
  electron-packager Renaming Electron Helper (Plugin) to Google Calendar Helper (Plugin) in /Users/kris/Applications/Google Calendar-darwin-x64/Electron.app/Contents/Frameworks/Electron Helper (Plugin).app/Contents/MacOS +0ms
  electron-packager Renaming Electron Helper (GPU) to Google Calendar Helper (GPU) in /Users/kris/Applications/Google Calendar-darwin-x64/Electron.app/Contents/Frameworks/Electron Helper (GPU).app/Contents/MacOS +0ms
  electron-packager Renaming Electron Helper.app to Google Calendar Helper.app in /Users/kris/Applications/Google Calendar-darwin-x64/Electron.app/Contents/Frameworks +0ms
  electron-packager Renaming Electron Helper (Renderer).app to Google Calendar Helper (Renderer).app in /Users/kris/Applications/Google Calendar-darwin-x64/Electron.app/Contents/Frameworks +0ms
  electron-packager Renaming Electron Helper (Plugin).app to Google Calendar Helper (Plugin).app in /Users/kris/Applications/Google Calendar-darwin-x64/Electron.app/Contents/Frameworks +0ms
  electron-packager Renaming Electron Helper (GPU).app to Google Calendar Helper (GPU).app in /Users/kris/Applications/Google Calendar-darwin-x64/Electron.app/Contents/Frameworks +0ms

Finalizing build...
Copying icons if necessary
No copying necessary on macOS; aborting
App built to /Users/kris/Applications/Google Calendar-darwin-x64

It seems electron wants an icon.png in the Resources dir ... I fixed my Gmail app by doing this:
sips -s format png Gmail-darwin-x64/Gmail.app/Contents/Resources/electron.icns --out Gmail-darwin-x64/Gmail.app/Contents/Resources/app/icon.png

(e.g. generated a .png from the embedded .icns file)

This did the trick! Having an icon.png file in the <MyApp-darwin-x64>/MyApp.app/Contents/Resources/app folder removes the error dialog and the app starts normally.
I've used these commands:
$ nativefier --name "GitLab" --maximize --single-instance --internal-urls --icon logos/gitlab.png "https://gitlab.com/"
$ cp logos/gitlab.png GitLab-darwin-x64/GitLab.app/Contents/Resources/app/icon.png

(since I have the png file already, I don't use sips, I simply copy it where it's needed).

Yep, fixing this was as simple as adding an icon.png file to the path where the error indicated it was missing <name>.app/Contents/Resources/app/!
Command run:
nativefier --name "Asana" "https://app.asana.com" --min-width 750 --min-height 300 --hide-window-frame --single-instance
Error:

Fix:
Used this website to convert the electron.icns file in <name>.app/Contents/Resources/ to a PNG, then renamed that PNG to icon.png and placed it in <name>.app/Contents/Resources/app/. (I assume any PNG would have done the trick.)

@ronjouch Thanks for your reply. -e 8.3.2 seems to work. However -e 10.0.0-beta.3 does not. With this the app doesn't even start and no error message is shown (as described by @kris-anderson).

EDIT also, does the png/ico image reported as un-loadable in your error screenshots (/blah/blah/blah/icon.{ico,png}) actually exist in your filesystem, or not?

I can confirm like some others before that the icon is not there but placing a png file by hand in there after the app is being built works. But this of course should not considered a fix. More a temporary workaround 😊

Any solution for this except using an old Electron version? Placing a icon.png file is not a solution and does not work all the time.
Thank you very much.

Any solution for this except using an old Electron version? Placing a icon.png file is not a solution and does not work all the time.
Thank you very much.

Can you provide reproducible steps that show it doesn't work? This is important because otherwise, the likely solution that will be implemented is adding a .png during the build process. So if that's not working, by your claim, the community and authors would benefit from knowing in which situations it doesn't work so they can find a more universal solution.

When I add it manually the path on a Mac cannot be created, otherwise I do understand somethings wrong.
You won't be able to create a folder name like: App Name.app

When I add it manually the path on a Mac cannot be created, otherwise I do understand somethings wrong.
You won't be able to create a folder name like: App Name.app

Right click on generated electron app
Click on show package content
Navigate to Content > Resources > app
Copy & Paste icon.png file

Copying the icon.png file into the folder doesn't work for 2 of the apps I've tried. Only the Electron fallback is working.

That fixed the issue for me

Using the -e 8.3.2 option in addition to manually copying the icon.png file into AppName.app/Contents/Resources/apps/icon.png solved the issue for me.

This should be fixed in f234473, folks, please try it with a developer build, or wait for the next release.

I'm seeing this too, when is a new release planned?

I'm seeing this too, when is a new release planned?

@simonweil is is released as 9.1.0

This should be fixed in f234473, folks, please try it with a developer build, or wait for the next release.

I can confirm that this works like a charm with version 9.1.0. Good job everybody.

Can confirm too that it's working, thank you so much!


Request help: I want to view all the blogs index in one page

Actual Behaviour
Rensently, when I visit our blog page, I found that it is hard for me to know what blogs we have, for there are only five blogs in menu list. I have to click next button to go to next page

I wonder if we can change our blog index page to a guided page, we can found all the blogs, no matter by name list, keyword list, and so on.
Expected Behaviour
Help me to found a better organized way easily view all blogs, thanks a lot

In fact, more items can be displayed here. You only need to setting them in the configuration file, but the effect is not nice.

Recently, when I visit our blog page, I found that it is hard for me to know what blogs we have, for there are only five blogs in menu list. I have to click next button to go to next page
I wonder if we can change our blog index page to a guided page, we can found all the blogs, no matter by name list, keyword list, and so on.
Help me to found a better organized way easily view all blogs, thanks a lot

So I did some look out and found that the most commonly used strategies are -

Blogs thumbs come in a list from most recent to past ones, and are paginated to display certain amount on one page. Also, they provide feature to look up blogs under different sub categories
On demand load of blogs thumbs, like the read more stories thing on google blog (check in link below)

Check out these examples for some ideas and we can discuss on the ones we like.

https://blog.google/
https://stripe.com/blog
https://github.blog/
https://www.netlify.com/blog/
https://ionicframework.com/blog/

If we want to go complete vanilla then React blog website is best bet, given that I believe React website is also based on docusaurus (but personally I think their site is really confusing to traverse among blogs, when you have tried blog sections like on our website).

Great @1502shivam-singh , thanks for such careful research~
Among those sites listed above, I prefer https://github.blog/

Categorise blog posts to make it easier for users to focus on target areas faster
Articles are in chronological order from new to old, so that users can easily see the latest blog posts
Topping the most popular posts in the current category is also convenient for users to access
Turn the page to view, in line with user browsing habits
Global search, pinpointing

actually, we already have global search, list order from new to old and  paging. We need Categorise, it will be the be the cornerstone of our optimisation.
what do you think?
cc @bzp2010 @KishaniKandasamy @foolwc @yzeng25 @juzhiyuan @moonming @Baoyuantop @guoqqqi @LiteSun @iamayushdas

I prefer https://github.blog/ too. Categorize is a good idea, similar to #470 , we can quickly view the corresponding content by category, so do we still need tags? Or use tags as the first step?

https://github.blog/ +1

github.blog or blog.google LGTM

Among those sites listed above, I prefer https://github.blog/

Categorise blog posts to make it easier for users to focus on target areas faster
Articles are in chronological order from new to old, so that users can easily see the latest blog posts
Topping the most popular posts in the current category is also convenient for users to access
Turn the page to view, in line with user browsing habits
Global search, pinpointing

actually, we already have global search, list order from new to old and paging. We need Categorise, it will be the be the cornerstone of our optimisation.
what do you think?

Seems like a nice way to move forward. Also the layout of github's blog is very clean, so a similar adaptation with some changes will be highly usable and look nice visually too. +1
Something to add, we can also adapt the strategy used by Google to load more stories on the same page. Pagination is good, but it has that context switch, staying on same page while browsing is always better.
So more like a hybrid of both strategies I mean.

I prefer https://github.blog/ too. Categorize is a good idea, similar to #470 , we can quickly view the corresponding content by category, so do we still need tags? Or use tags as the first step?

Tags is nice I believe, more like a step already completed. I believe we would have needed tags anyway for sorting posts.

https://github.blog/ +1

I prefer https://github.blog/ too. Categorize is a good idea, similar to #470 , we can quickly view the corresponding content by category, so do we still need tags? Or use tags as the first step?

Tags is nice I believe, more like a step already completed. I believe we would have needed tags anyway for sorting posts.

Agree with you , we need tags any way, so we can use the tag as the first step,  that is to say finish #470 first, and at the same time, make a simple design refer to github blog for our site, in order that we can have a clearer look and feel. We can take action now😊

Pagination is good, but it has that context switch, staying on same page while browsing is always better

and for this part , browsing is better for view the blogs, and I also perfer this way. But it is not good for Google to generate a snapshot and crawl contents as far as I kown. We need a better user experience, and we also need SEO to get more people to find us through search engines.  looking forward to your opinion on this part, thanks @1502shivam-singh @yzeng25

But it is not good for Google to generate a snapshot and crawl contents as far as I kown. We need a better user experience, and we also need SEO to get more people to find us through search engines.

Hmm, good catch. I just found this question related to this issue. The newer answers around 2015 also seem to highlight this. Might want to check them out. We could go for pagination too if there is any uncertainity, just to be on the safe side.

Hi all, we have finished the first step of update blog page:

add tags for the blog page
pr: feat: add blog tags #538
Effect：

preview: https://deploy-preview-538--apisix.netlify.app
remove the recennt posts index links in the blog page
pr: fix: remove Recent posts index in blog page #549
Effect：

preview: https://deploy-preview-549--apisix.netlify.app
fix some errors in the blog page
mainly fix can not show Thumbnail for China Mobile Cloud in blog list, already merge, see: https://apisix.apache.org/blog/page/2

As of now we have made changes with the help of the native template, and this is our first step, the native template has little room for optimization in terms of ease of use, please help to review, and comment here your feedback, this will become these will be the focus of our next optimization. Thanks a lot.
cc @1502shivam-singh @Baoyuantop @juzhiyuan @Serendipity96 @yzeng25 @moonming @iamayushdas @KishaniKandasamy

It is really lit, thanks for this

As of now we have made changes with the help of the native template, and this is our first step, the native template has little room for optimization in terms of ease of use,

Well technically we can customize this page (any page for that matter), but it would require swizzling the blog related items, these would do -
    yarn swizzle @docusaurus/theme-classic BlogListPage
    yarn swizzle @docusaurus/theme-classic BlogPostItem
    yarn swizzle @docusaurus/theme-classic BlogPostPage
    yarn swizzle @docusaurus/theme-classic BlogTagsListPage
    yarn swizzle @docusaurus/theme-classic BlogTagsPostsPage
    // plus some more to if need to customize the paginator etc.

but it's a step to take once we have some concrete design in place. Maybe sometime later I would experiment and share the output with you all, and based on the responses we could try that.

please help to review, and comment here your feedback, this will become these will be the focus of our next optimization. Thanks a lot.

LGTM, so now we have to move forward with categorization and related, right ?

LGTM, so now we have to move forward with categorization and related, right ?

yes, actually in order to make our blog page have a more clean look quickly, we make a quickly update, and thanks to @Baoyuantop @bzp2010 help, now it has already online, and there is still a lot of room for improvement

Pagination
Improve the tag interaction logic in blog page
Bug: extra '|' shown in the blog list
Add tags for events page
other improvement and better design

welcome to do further design and communication based on your point of interest


JVM crash at boot

Mod Version: DynamicSurroundings-1.7.10-<IP_ADDRESS>
Forge Version: 1.7.10-Forge<IP_ADDRESS>4-1.7.10
JVM crash logs: https://gist.github.com/LemADEC/f754a33c8653bff4655dfc34a4a7b976
...
Stack: [0x0000000002a30000,0x0000000002b30000],  sp=0x0000000002b2c9e0,  free space=1010k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [OpenAL64.dll+0x11066]
C  [OpenAL64.dll+0x1248f]
C  0x0000000002ce7f54

Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j  org.lwjgl.openal.ALC10.nalcCreateContext(JJ)J+0
j  org.lwjgl.openal.ALC10.alcCreateContext(Lorg/lwjgl/openal/ALCdevice;Ljava/nio/IntBuffer;)Lorg/lwjgl/openal/ALCcontext;+8
j  org.lwjgl.openal.AL.init(Ljava/lang/String;IIZZ)V+69
j  org.lwjgl.openal.AL.create(Ljava/lang/String;IIZZ)V+227
j  org.lwjgl.openal.AL.create(Ljava/lang/String;IIZ)V+5
j  org.lwjgl.openal.AL.create()V+6
j  org.blockartistry.mod.DynSurround.client.sound.SoundManager.configureSound()V+18
j  org.blockartistry.mod.DynSurround.proxy.ProxyClient.preInit(Lcpw/mods/fml/common/event/FMLPreInitializationEvent;)V+5
j  org.blockartistry.mod.DynSurround.Module.preInit(Lcpw/mods/fml/common/event/FMLPreInitializationEvent;)V+83
v  ~StubRoutines::call_stub
J 5212  sun.reflect.NativeMethodAccessorImpl.invoke0(Ljava/lang/reflect/Method;Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object; (0 bytes) @ 0x0000000003340f7f [0x0000000003340f00+0x7f]
J 5211 C1 sun.reflect.NativeMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object; (104 bytes) @ 0x0000000003cf1d14 [0x0000000003cf1920+0x3f4]
J 6011 C1 sun.reflect.DelegatingMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object; (10 bytes) @ 0x00000000038cbc8c [0x00000000038cbb80+0x10c]
J 6010 C1 java.lang.reflect.Method.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object; (62 bytes) @ 0x00000000038cc434 [0x00000000038cc040+0x3f4]
j  cpw.mods.fml.common.FMLModContainer.handleModStateEvent(Lcpw/mods/fml/common/event/FMLEvent;)V+68
j  sun.reflect.GeneratedMethodAccessor3.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+40
...

FML logs: https://gist.github.com/LemADEC/6f6b8e467a6a441976b4757e56cecd71
...
[10:08:45] [Client thread/DEBUG] [FML/]: Bar Step: PreInitialization - Dimensional Doors took 0,036s
[10:08:45] [Client thread/TRACE] [DamageIndicatorsMod/DamageIndicatorsMod]: Sending event FMLPreInitializationEvent to mod DamageIndicatorsMod
[10:08:45] [Client thread/TRACE] [DamageIndicatorsMod/DamageIndicatorsMod]: Sent event FMLPreInitializationEvent to mod DamageIndicatorsMod
[10:08:45] [Client thread/DEBUG] [FML/]: Bar Step: PreInitialization - Damage Indicators took 0,014s
[10:08:45] [Client thread/TRACE] [dsurround/dsurround]: Sending event FMLPreInitializationEvent to mod dsurround

Description:
Launching the game results in an hard crash of the JVM.
Issue is intermittent, could be due to bad multi-threading?

Pretty sure it isn't threading related.  Looking at the existing threads the only real active Minecraft thread is "Client" and this is startup.  This is something down in the LWJGL code.  What Dynamic Surroundings is trying to do is create an OpenAL context because it hasn't been created yet.  This context is used to query the underlying sound system to find out how many mono sources (channels) are available for use.  Has this always been happening on/off, or did it just start?

We've updated the pack recently, it wasn't doing it before.

When is the game starting OpenAL if a mod doesn't do it?

@LemADEC Thought this is a bit "stale", I just pushed a <IP_ADDRESS> version for 1.7.10.  The initialization sequence changed (because I replace the underlying SoundManager with my own version).  I haven't been able to repro the issue being reported here, so I am not sure if what I did will help in this situation.

Thanks for the update!
I didn't see the issue since then, we'll try your updated version in our next modpack.

I can confirm the issue is still present with DynamicSurroundings-1.7.10-<IP_ADDRESS>:

Stack: [0x00000000029a0000,0x0000000002aa0000],  sp=0x0000000002a9e440,  free space=1017k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [OpenAL64.dll+0x11066]
C  [OpenAL64.dll+0x1248f]
C  0x0000000002ca7f54

Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j  org.lwjgl.openal.ALC10.nalcCreateContext(JJ)J+0
j  org.lwjgl.openal.ALC10.alcCreateContext(Lorg/lwjgl/openal/ALCdevice;Ljava/nio/IntBuffer;)Lorg/lwjgl/openal/ALCcontext;+8
j  org.lwjgl.openal.AL.init(Ljava/lang/String;IIZZ)V+69
j  org.lwjgl.openal.AL.create(Ljava/lang/String;IIZZ)V+227
j  org.lwjgl.openal.AL.create(Ljava/lang/String;IIZ)V+5
j  org.lwjgl.openal.AL.create()V+6
j  org.blockartistry.mod.DynSurround.client.sound.SoundManagerReplacement.configureSound()V+18
j  org.blockartistry.mod.DynSurround.client.sound.SoundManagerReplacement.<init>(Lnet/minecraft/client/audio/SoundHandler;Lnet/minecraft/client/settings/GameSettings;)V+18
j  net.minecraft.client.audio.SoundHandler.<init>(Lnet/minecraft/client/resources/IResourceManager;Lnet/minecraft/client/settings/GameSettings;)V+27
j  net.minecraft.client.Minecraft.func_71384_a()V+712
j  net.minecraft.client.Minecraft.func_99999_d()V+6
j  net.minecraft.client.main.Main.main([Ljava/lang/String;)V+1012
v  ~StubRoutines::call_stub
j  sun.reflect.NativeMethodAccessorImpl.invoke0(Ljava/lang/reflect/Method;Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+0
j  sun.reflect.NativeMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+100
J 2844 C1 sun.reflect.DelegatingMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object; (10 bytes) @ 0x00000000036794cc [0x00000000036793c0+0x10c]
J 2843 C1 java.lang.reflect.Method.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object; (62 bytes) @ 0x0000000003678ef4 [0x0000000003678b00+0x3f4]
j  net.minecraft.launchwrapper.Launch.launch([Ljava/lang/String;)V+661
j  net.minecraft.launchwrapper.Launch.main([Ljava/lang/String;)V+8
v  ~StubRoutines::call_stub

@LemADEC I am wondering if anyone has had this issue with the latest 1.7.10 release?

We're running with 1.7.10-<IP_ADDRESS> since April 2018. No report since then.

OK.  Going to close the issue out.  If it does come back up let me know.


More detailed length distributions

Have three length distributions instead of only taking the non-paired

Singletons
Merged
Paired (insert size)

no development scheduled, closing for now


UI not updating after moving from hooks_riverpod 0.12.1 to 0.13.1

A StateProvider that was updating UI in hooks_riverpod 0.12.1 no longer does so after updating to 0.13.1
I can't see any breaking changes mentioned in the change log.
Not sure why this stopped working between these versions.
The provider is defined in one class:
final currentTransactionProvider = StateProvider<CurrentTransaction>((ref) {
  final _currentTransaction = CurrentTransaction();
  return _currentTransaction;
});

And used in a HookBuilder:
final currentTransactionController = useProvider(currentTransactionProvider);
A slider is used to update a value in the Provider (this works as expected):
onChanged: (value) {
   final transactionState = currentTransactionController.state;
   transactionState.amount = value?.toInt()?.toUSDCBigInt() ?? BigInt.zero;
   currentTransactionController.state =  transactionState;
},

It is then used to update the slider position:
value: (currentTransactionController.state.amount / BigInt.from(1E6)).toDouble(),
and display the value in a Text:
Text(currentTransactionController.state.amount.dollarString(),
   key: ValueKey<String>(currentTransactionController.state.amount.dollarString()),
),

Expected behavior
Updating the state of the Provider should trigger a rebuild of the HookBuilder and child widgets.

You can look into Freezed, to generate a "copyWith" method

For anyone else that runs into this, here's what I changed to get it working.
Instead of the one Provider before, I used StateNotifierProvider, StateNotifier with an updateAmount method:
final currentTransactionProvider = StateNotifierProvider<CurrentTransactionNotifier>(
        (ref) => CurrentTransactionNotifier());

final currentTransactionAmountProvider = Provider<BigInt>(
    (ref) => ref.watch(currentTransactionProvider.state).amount);

class CurrentTransactionNotifier extends StateNotifier<CurrentTransaction> {
  CurrentTransactionNotifier() : super(CurrentTransaction(BigInt.zero));

  void updateAmount(BigInt newAmount) {
    state = CurrentTransaction(newAmount);
  }
}

I moved the UI code into a ConsumerWidget, and watch the amount:
class CustomSlider extends ConsumerWidget {
  @override
  Widget build(BuildContext context, ScopedReader watch) {
    final BigInt amount = watch(currentTransactionAmountProvider);
    return MyActualSliderWidgetGoesHere();
  }
}

In the Slider I can then use amount for reading, and update like this in the onChanged:
value: (amount / BigInt.from(1E6)).toDouble(),
onChanged: (value) {
   context.read(currentTransactionProvider).updateAmount(value?.toInt()?.toUSDCBigInt() ?? BigInt.zero);
},

I didn't want to use Freezed and have to go through a build for such a simple thing. In my case I only ever need to update the one value, so I simply create a new object with the new value rather than copy, other's might need a normal class copyWith method.
I had trouble using the copy/copyWith functions I found elsewhere, probably due to the way I was constructing my class with a fixed value. I changed this to needing an external value on creation and that made it work.


[opencv3]Add feature option ${FEATURE_OPTIONS} to vcpkg_configure_cmake.

${FEATURE_OPTIONS} should be added at the same time as vcpkg_check_features.
Related: #7922.

wow, awesome I need this

I discussed about it here: https://github.com/microsoft/vcpkg/pull/7658#issuecomment-524544974 (the typo is still in the portfile...)
Where's Victor? 😢


when the job succeed , it will be captured

Closes
Example

Screenshots

Checklist

[ ] References any related issue by including "Closes #" or "Closes ".

If no issue exists and your change is not a small fix, please create an issue first.

[ ] Includes tests or only affects documentation.
[ ] Passes pre-commit checks.

Run pre-commit install && pre-commit run --all locally for formatting and linting.

[ ] Includes screenshots of documentation updates.

Run mkdocs serve view documentation locally.

[ ] Summarizes PR's changes in CHANGELOG.md

Closing this PR because it appears stale. Please reopen and resolve the conflicts if this change is still needed.


add boba l2 rinkeby and mainnet

Hi,
thank you for open sourcing Safe!
https://github.com/gnosis/safe-react/wiki/How-to-configure-the-interface-to-support-a-new-network
mentions:
Backend-devops related:
Add required information to the config-service https://github.com/gnosis/safe-config-service

Are there any more places in this repo I need to add Boba chains (28, 288)?
Cheers
Ino

Hey @InoMurko thank you for reaching out and for your interest in the Safe project.
If you are running the safe-config-service on your side then this Pull Request is not required as you can add this via the admin interface that is exposed by the service.
If you want Gnosis to support the proposed chains, then they first need to be evaluated internally. To start that evaluation please do please reach out to @ennis_gnosis on Telegram.

Closing this PR since no action is required on this service. See https://github.com/gnosis/safe-config-service/pull/305#issuecomment-968838292


word-count: Simplify by removing quotation aspect

In #403 the exercise was extended with a completely new aspect (the removal of single quotations but not apostrophes) which is not mentioned in it's minimalistic description.
Especially in the last months we tried to simplify exercises in a way that they try to tackle at best one problem (or at least not too many different ones). Right now we test splitting on different characters, counting, case normalization and removing some but not all punctuation.
So, I would like to see this exercise simplified just a bit by removing those two quotation test cases.

So basically the options are:

Remove the quotations test cases.
Update the documentation.

Personally, I don't really have an opinion either way, but perhaps other people do?

This extension happened within the last 6 months, are we finding that there is a decrease in completion, a negative change in the discussions about the exercise, a general failure to solve these tests in solutions submitted?

No Change Necessary
Document the requirement (arguably this is already done via the tests as a "Did you also consider that words with apostrophes are single words?")
Remove the extension

I saw very complex implementations because they didn't know regular expressions. So they wrote a lot of if statements and accessed the the single chars of the string after they already did all the splitting and counting.

How about keeping quotations but removing apostrophes? i.e. Change can't to cannot.

Contractions are common enough in documents to warrant having this included as part of the problem.  It can be solved without regular expressions.  It happens that regular expressions happen to be a good tool to extract that apostrophe pattern.  But it isn't the only thing.  Many languages support regular expressions either directly or provided through libraries, but many languages do not.
Indeed, even with those using regular expressions, it seems that there are solutions with pretty complex logic.  I am not sure that is a bad thing.  It lets us talk about the choices for the solutions.
What I would be more concerned about is a decrease in the attempt rate on this exercise.  And then finding out why.

Actually, I quite like the added apostrophe precisely because it makes the exercise just a bit more difficulty. Without this, the exercise would almost be too trivial I feel.

I agree that this change maybe would make it too easy.
So, we have the problems of splitting and counting. Now one way to make this exercise more challenging is to add (or not remove) a totally new problem domain with normalization and complex punctuation removal.
Or, as most languages have some built-in functions to split on whitespace, we could just make the splitting more interesting and also split on other chars like underscore.
word_count('hey,my_spacebar_is_broken.') -> {'hey': 1, 'my': 1, 'spacebar': 1, 'is': 1, 'broken': 1}

I am for not removing....


Update operator version and image spec

Changes
This fixes test failures due to the fact that the CSV version of the operator being tested conflicts with the operator in the OperatorHub index image.

Update the default version to 0.7.1-snapshot so it does not conflict
with the CSV on OperatorHub.
Update default image location to ghcr.io so we can more easily submit
updates to OperatorHub.

/kind cleanup
Submitter Checklist

[ ] Includes tests if functionality changed/was added
[ ] Includes docs if changes are user-facing
[x] Set a kind label on this PR
[x] Release notes block has been filled in, or marked NONE

See the contributor guide
for details on coding conventions, github and prow interactions, and the code review process.
Release Notes
Update default location of the operator image to ghcr.io/shipwright-io/operator/operator.

/lgtm
There's one discussion still open, but the changes on this PR are looking good to me.

/approve
Self-approving, long term we should add additional approvers to this repo.


Support for custom notifications

closes #5071
This PR addresses Add support for custom messages section described in #5071.
(NOTE: The section Move the "update available" notification to the about page is addressed in a different PR in Ghost-Admin repo)
As described in #5071 we wish to send notifications for specific versions of Ghost. These notifications can be dismissed. Once they are dismissed, they are not shown again. For this purpose, UpdateCheck service was upgraded to send responses like so:
{
  "version": "0.5.0",
  "next_check":<PHONE_NUMBER>,
  "messages": [{
    "id": ed9dc38c-73e5-4d72-a741-22b11f6e151a,
    "version": "0.5.x",
    "content": "
Hey there! 0.6 is available, visit Ghost.org to grab your copy now<!/p>"
  ]}
}

In the above example, a blog running on Ghost version 0.5.x would display content a banner on the top. All other Ghost versions ignore messages field.
To accomplish this, a new core property seenNotifications is added to settings table.
If a response from UpdateCheck has messages property, iterate over them and construct  notifications intended for current version. If a custom notification is dismissed, its uuid is added to seenNotification array to prevent showing the same message again.
TODO

[x] Test fixtures. grunt validate fails with "Unable to find setting to update: seenNotifications". However, grunt test:integration/api/api_notifications_spec.js and grunt test:integration/update_check_spec.js pass.

@acburdine Thanks. I think I am done with coding here. If someone can review it ...

@vkandy I'll try to look at it later today and get it merged :)

Couple of quick notes about the commit msg here before merge. It doesn't have a ref to the issue e.g.  [refs|closes] TryGhost/Ghost#5071 and also @vkandy your avatar didn't come through on the commit which suggests something is wrong with your git config/github config.

The icon thing was bugging me as well. But since it was mentioned I went through .gitconfig and realized I had a different global email. The avatar should show on commit messages now (it's definitely me) :)
I've added refs too. Please note that this PR addresses just one section mentioned in #5071

I've been testing this out, and haven't managed to find how to get the custom notifications to display? I also don't see code that handles them and the version they are intended for although perhaps I'm reading it wrong?

Resolved issues with settings test fixtures. Good for review again.


DeepPartial Objects for SuperValidate

Is your feature request related to a problem? Please describe.
Currently SuperValidate accepts Partial<In>, but we have a nested object structure and want to set default values in these sub objects.
Describe the solution you'd like
I know there is no default type for DeepPartial, but it would be nice to use DeepPartial<In> instead of just Partial<In>.
type DeepPartial<T> = T extends object ? {
    [P in keyof T]?: DeepPartial<T[P]>;
} : T;

Additional context
Currently we work around with a type cast like
import { superValidate, InferIn } from 'sveltekit-superform';

superValidate({
  nested: {
    some: 'data'
  } as Partial<InferIn<TypeOfObject>>
});

Good idea, will add to the next release if everything seems to work!

It's a bit unfortunate, but since the default value of an array is an empty array, it won't traverse into arrays in the same way as objects. Changing the behavior would probably break some schemas (unions in arrays especially), and also require a bit of rewrite for the default value mapping, so I'm hesitant to add it to version 2.
I'll put it up on the v3 milestone for the time being, sorry.

Another example of when DeepPartial is useful: https://www.sveltelab.dev/fharhjf6zn96b9u?files=.%2Fsrc%2Froutes%2F%2Bpage.svelte


Add deprecated log for inline_config

Which issue(s) this PR fixes:
ref: https://github.com/fluent/fluentd/issues/2711
What this PR does / why we need it:
add log when inline_config is -. it's good to remove this feature in v1.20.0.
Docs Changes:
no need
Release Note:
no need

it's good to remove this feature in v1.20.0.

v2?

you're right. it's v2.


Changing the baseUrl property doesn't affect existing uploads

Describe the bug
I just set a baseUrl for production. There exist many previously uploaded files (at that point, baseUrl was undefined).
To Reproduce
Steps to reproduce the behavior:

Create strapi instance
Upload image
Set baseUrl to some other value
Upload image

Expected behavior
Api returns both images as being hosted from the new baseUrl.
Actual behavior
Api returns a different baseUrl for each image
Desktop (please complete the following information):
N/A
Smartphone (please complete the following information):
N/A
Additional context
I've considered updating the sql table manually, but I'm not too familiar with sql and modifying a json string via sql sounds like a terrible idea.

So apparently this seems to work:
UPDATE files
SET formats = replace(formats::TEXT, 'https://storage.googleapis.com/CHANGETHIS/', 'https://example.com/')::jsonb;

Adapted from source:
https://stackoverflow.com/a/71221922/5854364
Use at your own risk.
Since there exists a reasonable workaround, I'm closing this.


Dartpad Workshops: Keep code I've written moving from one step to the next

Problem statement:

As a workshop taker
when I've worked on a step for a bit and like my solution
Then I move to the next step
All of the code I've written in the previous step is now gone.

I cannot navigate back to the step to see my solution, the code is always replaced with the contents of snippet.dart. This is quite a bummer in many workshops, where you may want to go back and forth to build upon the code you've written before.
Possible Solution: Start with snippet.dart, then keep contents in localstorage when moving away from step. Display contents kept in localstorage when returning to the step. This would also handle the case of needing to reload at some point.

I have created a PR (#2260) as an example of a possible solution to the problem you have detailed..
The change adds localstorage memory for any changes the user makes for each of the steps of the workshop.
Other details:

once the user edits a steps snippet a 'revert' icon is added next to the run button that allows going back to the original snippet
if the user does revert to the original snippet the revert icon changes to a 'restore last edit' icon allowing you to go back to source as you last edited it (in case the user presses revert button in error they can still get it back, or they can review original snippet and return to their code)
there is a 'Reset' button in the top left that allows the user to clear all saved step code at once - allowing them to start the workshop from scratch.
User can move back and forth thru steps and their code is saved - but they can revert any step as they wish

An example of this can be found here:
https://timmaffett.github.io/worksave/workshops.html?webserver=https://raw.githubusercontent.com/flutter/codelabs/master/dartpad_codelabs/src/example_dart
@brianegan I would be interested if this addresses your problem statement in a satisfactory way ?  Are there any changes that you (or anyone else) would suggest ?

Heya @timmaffett -- this looks great! Thanks so much for the help.
After testing it, it's working almost exactly as I hoped!
After working with it, I realized I failed to specify one use case: some ability to Show & then hide the Solution code. Or, show the Solution code, then restore the code the user has written. I could see it working something like this:

as a workshop taker
when I finish my work
and I want to compare to the proper solution
I should be able to go back and update my code

That would cover all possible use cases for the user: The ability to see both the original snippet, the correct solution, and ability to go back to their code in either case.
Please let me know if that feels out of scope for this work, I'd be happy to create a separate issue if so. I wouldn't want to block what you have b/c it's great!

Thanks for taking a look @brianegan !
I have added the ability to show the solution and return to your code.
When the user presses show solution they are no longer presented with a dialog (as losing your code no longer applies).
When the solution is showing they have the icons available to revert to original snippet or revert to their last edit.
When they return to their last edit there is now a lightbulb icon that is available to quickly toggle back to the solution.  This allows the user to toggle back and forth between solution and their code.
Tell me if you hate the secondary lightbulb/show solution icon.   I am torn but it did seem nice to be able to click back and forth without having to move the mouse all the way to the primary show solution button.
example using your simple workshop
Here is a more link with a more complicated workshop:
https://timmaffett.github.io/worksave/workshops.html?webserver=https://dartpad-workshops-io2021.web.app/getting_started_with_slivers

Good find - It is because they haven't edited yet and I am not handling that correctly.  I will fix this by tomorrow.

Ok @brianegan , I have fixed that case and any case where they view the solution before editing (or resetting to the snippet with no changes).
I would love it for you to give that a try when you can and let me know if it does indeed fix the problem for you.
thanks!

Thanks again, @timmaffett :)
When I click on "Show Solution" before typing any code, the button "Go to last edit" pops up. That totally wors, but I was surprised it wasn't the "Revert to Original" button instead.
A small detail, functionally everything is working well at this point! Really appreciate it.


Cannot resolve aar dependencies

Hello! I am writing android project with Scala and I would like to use coursier with android project, but I have problem when compiling project:
[error] 1 not found
[error]   /Users/rafal/Utils/android-sdk/extras/android/m2repository/com/android/support/support-v4/23.3.0/support-v4-23.3.0.jar
[trace] Stack trace suppressed: run last *:update for the full output.
[error] (*:update) java.lang.Exception: Encountered 1 errors (see above messages)
[error] Total time: 2 s, completed Jun 20, 2016 6:00:12 PM

the problem is, it's not *.jar file it's *.aar depenency:
  23.3.0 ls -l
total 2132
-rw-r--r-- 1 rafal     261 Jun 16 18:16 support-v4-23.3.0-javadoc.jar
-rw-r--r-- 1 rafal      32 Jun 16 18:16 support-v4-23.3.0-javadoc.jar.md5
-rw-r--r-- 1 rafal      40 Jun 16 18:16 support-v4-23.3.0-javadoc.jar.sha1
-rw-r--r-- 1 rafal  911276 Jun 16 18:16 support-v4-23.3.0-sources.jar
-rw-r--r-- 1 rafal      32 Jun 16 18:16 support-v4-23.3.0-sources.jar.md5
-rw-r--r-- 1 rafal      40 Jun 16 18:16 support-v4-23.3.0-sources.jar.sha1
-rw-r--r-- 1 rafal 1226175 Jun 16 18:16 support-v4-23.3.0.aar
-rw-r--r-- 1 rafal      32 Jun 16 18:16 support-v4-23.3.0.aar.md5
-rw-r--r-- 1 rafal      40 Jun 16 18:16 support-v4-23.3.0.aar.sha1
-rw-r--r-- 1 rafal     659 Jun 16 18:16 support-v4-23.3.0.pom
-rw-r--r-- 1 rafal      32 Jun 16 18:16 support-v4-23.3.0.pom.md5
-rw-r--r-- 1 rafal      40 Jun 16 18:16 support-v4-23.3.0.pom.sha1

OS is mac OS X el capitan, coursier is enabled with global plugin
➜  plugins cat build.sbt
addSbtPlugin("io.get-coursier" % "sbt-coursier" % "1.0.0-M12")

It's possible that https://github.com/alexarchambault/coursier/pull/290 fixed that. I don't have an android SDK at hand to test that right now. You could give the current snapshot of coursier (1.0.0-SNAPSHOT) a try though.

Sorry for long reply. I tried  addSbtPlugin("io.get-coursier" % "sbt-coursier" % "1.0.0-M12") once again with sbt 0.13.12 and it's working now. Probably my setup had some problems.
I'm closing issue for now, if I see this problem again, I will give more info.
Thank you.


Direct access for setting custom object mapper

Current method to provide a custom object mapper through code (as described here: https://vladmihalcea.com/hibernate-types-customize-jackson-objectmapper/) is not possible in Spring Boot, as the Hibernate configuration is not reachable (unless writing custom configuration, where we want to let the auto-configuration do the job).
Could there be a simple setter, for example on the ObjectMapperWrapper to directly provide the custom mapper?
That way, we could write this in our Spring configuration class:
Configuration.INSTANCE.objectMapperWrapper.setObjectMapper(customMapper);

It's true that the Spring Boot application.properties is not used, but you can define the hibernate.types.jackson.object.mapper in a hibernate-types.properties file, and everything will work fine in Spring Boot too.
Or, even better. You can add support in the Configuration class to scan the application.properties too.
So, here's what you need to do:

Create a new issue "Add support for loading settings from an application.properties file"
Add support for this feature in the load method. Most likely, you can provide the file name to the propertiesInputStream method call.
Send me a Pull Request so that I can validate and integrate it.

It is not about where to define properties but about using a mapper instance already configured. For example, Spring already provides an instance with some settings and automatically discovers/registers serialization classes annotated with @JsonComponent at runtime.
So, I'm looking for a way to directly inject the instance that was build and configured by Spring.

@fdubuisson The PropertyKey.JACKSON_OBJECT_MAPPER setting could be set at runtime before you bootstrap the EntityManagerFactory to a Supplier that gives the object configured by Spring:
else if (objectMapperPropertyInstance instanceof Supplier) {
	Supplier<ObjectMapper> objectMapperSupplier = (Supplier<ObjectMapper>) objectMapperPropertyInstance;
	objectMapperWrapper = new ObjectMapperWrapper(objectMapperSupplier.get());
}

Now, the current implementation loads the default properties from org.hibernate.cfg.Environment.getProperties(), so you could pass that like this:
System.getProperties().set(PropertyKey.JACKSON_OBJECT_MAPPER, myCustomObjectSupplier);

What can be done is adding a ThreadLocal in the Configuration class, which can allow passing the ObjectMapperWrapper That one could be used to cache the already computed one as, now, the Configuration.getObjectMapperWrapper() always extracts it, so if e have multiple JsonType, the ObjectMapperWrapper is instantiated multiple times.

I really need this option to be implemented can I help?
I could not find a way to do what you suggested above: The PropertyKey.JACKSON_OBJECT_MAPPER setting could be set at runtime before you bootstrap the EntityManagerFactory to a Supplier that gives the object configured by Spring.

@Tom-Ritense At the moment, I don't have too much free time to work on OSS. If your company needs this and is willing to sponsor the development of this feature, then check out my consulting offering.

For now I used the solution proposed in https://stackoverflow.com/questions/66656772/use-jackson-objectmapper-configured-by-spring-boot-in-hibernate works fine. I might create a PR in the future.

Looking forward to your PR then.

Hi, I've just stumbled upon the same problem (want to use spring-provided objectMapper in hibernate-types), although I was trying to handle it from different approach.
I wanted to initialize JavaType with spring-provided objectMapper inside spring @Configuration and somehow register it in hibernate basic type registry (using this guide and this answer as reference) but so far I was unsuccessful (seems that this solution is not compatible with spring-boot-data-jpa).
Still thinking that this approach is most promising, I'll post an update if I succeed.

@RemboL We've implemented this solution in our project to set the ObjectMapper instance configured by Spring. Look at the code example below.
@Component("HibernateObjectMapperSupplier")
public class HibernateObjectMapperSupplier implements ObjectMapperSupplier {
    private static final AtomicReference<ObjectMapper> objectMapper = new AtomicReference<>();

    @Autowired
    private void setObjectMapper(ObjectMapper mapper) {
        objectMapper.set(mapper);
    }

    @Override
    public ObjectMapper get() {
        return objectMapper.get();
    }

    @Component
    static class ObjectMapperDependencyFixer implements BeanFactoryPostProcessor {

        @Override
        public void postProcessBeanFactory(ConfigurableListableBeanFactory beanFactory) {
            final var beanDefinition = beanFactory.getBeanDefinition("entityManagerFactory");
            beanDefinition.setDependsOn(
                Stream.concat(
                    Stream.of(Objects.requireNonNullElse(beanDefinition.getDependsOn(), new String[]{})),
                    Stream.of("HibernateObjectMapperSupplier")
                ).toArray(String[]::new)
            );
        }
    }
}

And now you need to set the property in the application.yml:
spring:
  jpa:
    properties:
      hibernate:
        types:
          jackson:
            object:
              mapper: com.your.company.pckg.HibernateObjectMapperSupplier

That's a dirty hack but it's working. @vladmihalcea mind to add this example to the README?

Fixed.


[Admin] Fix preview styling

The netlify-cms admin preview is actually broken for all the resources.
The issue seems to be a problem with styled-components and netlify-cms
https://github.com/netlify/netlify-cms/issues/793

Closed as we're using react-admin instead netilify-cms

Closed as we're using react-admin instead netilify-cms


New Keyboard Layout

Hi :)
I would like to contribute a new locale (CH_de) to the project. The only instruction i could find to create a new locale was this https://github.com/Nurrl/LocaleKeyboard.js/wiki/How-to-create-a-locale-%3F!.
I downloaded the sample file but im not sure hot to find the right hex/dec values of my keyboard layout for the _asciimap variable and the initAltGr() function.
Can anyone point me in the right direction where or how i can find the right values?

okay i figured it out myself :)

okay i figured it out myself :)

Hey
I would be interested in the locale for CH_de. Could you help me or even give me the file?

@moswed is it possible to tell me how you found the right values? Because I'm trying to create a new locale for Norwegian bokmål (nb_NO)

@Retardur So i figured it out by myself and the way i did it was by looking which characters are wrong and just trial and error to see what it's supposed to be. For example if its writing ! instead of * you just look where it does write * and take the keycode from there. Hope that helps. And btw for AltGR characters you just look up the ASCII decimal codes for the characters that need it and at them to the other AltGR characters

@Chr1s28 thank you

@Retardur Did you make the nb_NO locale im interested

@Chr1s28
Hi,
I would also be interested in the locale for CH_de file. Would it be possible that you could send me the file or help me create one my self?

@Neoministein So it has been a while since i've done anything with the malduino but i found my file and uploaded it. Heres the link:
https://gist.github.com/Chr1s28/4b9cecd902107bdfbe07004dce3edef3

@Chr1s28 Thanks you very much you are amazing!


PEER REVIEW ON URL-SHORTENER API

What does this PR do?
Have creation of api routes for url management
Description of Task to be completed?

Changes Unknown when pulling 5c98578ca524b8cdba043e851efc3ef63fb4432e on develop into ** on master**.

Changes Unknown when pulling 98e7d06fc162a0372baafde50203eef5199f10ca on develop into ** on master**.


[#627] Add option --quiet to pip-compile

With --quiet, the output file is not logged.
Fixes #627.
Changelog-friendly one-liner: Add option --quiet to pip-compile
Contributor checklist

[x] Provided the tests for the changes
[X] Requested (or received) a review from another contributor
[X] Gave a clear one-line description in the PR (that the maintainers can add to CHANGELOG.md afterwards).

pip-tools v3.4.0 released


Architettura fix

Codecov Report

Merging #2 (1c4967b) into develop (85b5509) will increase coverage by 10.73%.
The diff coverage is 62.77%.

@@             Coverage Diff              @@
##           develop       #2       +/-   ##
============================================
+ Coverage    55.19%   65.93%   +10.73%
============================================
  Files           38       64       +26
  Lines         1656     1585       -71
  Branches       202      174       -28
============================================
+ Hits           914     1045      +131
+ Misses         686      506      -180
+ Partials        56       34       -22

Impacted Files
Coverage Δ

...Content/StrategyDimReduction/AlghorithmStrategy.js
40.00% <ø> (ø)

...ts/UI/burgerMenuUI/ModalContent/services/ApiURL.js
100.00% <ø> (ø)

client/src/stores/data/DistanceMatrix.js
100.00% <ø> (ø)

...nt/src/components/UI/graphUI/charts/PlmaChartVM.js
27.94% <27.94%> (ø)

...onents/UI/graphUI/preferences/PlmaPreferencesVM.js
38.46% <38.46%> (ø)

...ient/src/components/UI/graphUI/charts/FfChartVM.js
38.57% <38.57%> (ø)

...s/UI/burgerMenuUI/ModalContent/LoadDataFromDBVM.js
38.80% <38.80%> (ø)

...uUI/ModalContent/StrategyDimReduction/Parameter.js
40.00% <40.00%> (ø)

...mponents/UI/graphUI/preferences/HmPreferencesVM.js
44.44% <44.44%> (ø)

...ent/src/components/UI/graphUI/charts/SpmChartVM.js
48.09% <48.09%> (ø)

... and 90 more

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 85b5509...1c4967b. Read the comment docs.


ocamlPackages.mmap: init at 1.1.0

Motivation for this change
Dependency of recent versions of LWT.
Things done

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

@GrahamcOfBorg build ocamlPackages.mmap


The Copy button is gone

The Copy button is gone, which is a problem for me.
I need to transfer the URL into a private browser window. Clicking Copy let me do this.
Clicking View opens a non-private browser window, which immediately changes the URL, making it impossible to copy the URL.

FWIW: This is what I see now:

I don't know how to get a screenshot from before, but there was a Copy button there.

I wonder... if the recent "Trust" change in vscode is the root cause here?
I never added sites to the "Trusted Domains" config and I see it's still empty, but I did trust the folder I have open...

yeah... nevermind, it's a vscode bug.
untrusted folder that's allowed to use the git blame extension uses trusted domains.

This flew under my radar. I am sorry.
There is a command for copying the URL generated by vscode-gitblame. If you use the command palette it is called Git Blame: Copy tool URL to clipboard and if you want to bind it to a keyboard shortcut it is called gitblame.addToolUrlToClipboard.
I hope you have good URL copying experiences!


IT for failover actor reminder.

Description
IT for failover actor reminder.
Issue reference
We strive to have all PR being opened based on an issue, where the problem or feature have been discussed prior to implementation.
Relates to: https://github.com/dapr/dapr/issues/2554
Checklist
Please make sure you've completed the relevant tasks for this PR, out of the following list:

[ ] Code compiles correctly
[X] Created/updated tests
[ ] Extended the documentation

the reminder fire IT added recently seems to be flaky. A rerun of build passed the test https://github.com/dapr/java-sdk/pull/407/checks?check_run_id=1534796822 when before it was failing.

I can look at it again when it fails.


Add HTTPS support to the dev server

Which also should have some support for create local trusted dev certificates (the hard part).

I think the way to go for the hard part would be along the lines of caddy trust.
As caddy is written in go, it should be straightforward to carve out the logic from there. The PKI handling is even done in a module.
But if you'd ask me, I would rather go the opposite way and completely discontinue "hugo serve".
Along the philosophy: do one thing and do it really well. Hugo + Caddy already work pretty well as a pair for local development with HTTPS "out of the box". The detour via rendering to disk shouldn't hurt much on a modern development environment (SSD) either.
Hugo is one of the best SSGs today (if not the best). Caddy is pretty decent as a dev and production server. So why not try to focus on integrating these two (only the livereload capability would need to be integrated). Caddy could even use configuration from hugo config directly with very little effort.
/cc @jmooring

discontinue "hugo server"

Would this mean that users would have to install caddy?

@jmooring if you go by the principle "cut the logic from caddy and mimic it in hugo" - no.
If you follow the "Unix way" (one tool does one thing) - yes. hugo builds, caddy serves.
The latter was more meant to be "food for thought for strategic direction" of hugo development -- given that there is still a lot to be done (or on the roadmap) for the core functionality of building things.
Of course, deprecating hugo serve could have a huge impact on the current user base, but it could help prioritize / focus on other tasks.
It could be as simple as an official statement: "we will not add functionality to hugo serve, if you need this function (HTTPS) - use hugo along with a separate local proxy. We give guidance / document on how this could be done."

Would this mean that users would have to install caddy?

That's not an option. If we add some server library, it needs to be compiled in.
The hugo server is extremely simple by design and that will not change. The problem with adding e.g. Caddy's "trust component" or whatever is that it opens the Pandora Gate or something for people wanting to pull in more Caddy stuff.
I will have a look at how caddy trust works and if we can borrow some ... library code from that concept. But we obviously need something simple to use on any platform.

or whatever is that it opens the Pandora Gate or something for people wanting to pull in more Caddy stuff.

Exactly and to the point. I'd rather not open this box if I were in your shoes.
So I would recommend to postpone this feature or deliberately not implement it at all.
hugo serve is good enough for 90+% of all use cases (and probably for most users). Those (power) users who need local HTTPS in dev already know their way around it.

No, i actually think hugo server really needs HTTPS; it has been postponed because it has been a hard problem to tackle. Now, in 2023, there may be tools available that would make this doable.

No, i actually think hugo server really needs HTTPS; it has been postponed because it has been a hard problem to tackle. Now, in 2023, there may be tools available that would make this doable.

Sure, your call. :smiley: In that case I would really take a closer look at caddy, because the UX of caddy trust is really good (at least under linux). I would appreciate if it was built in, but still find it dispensable.


Explore different ranking models

This is addressing this open issue: https://github.com/NVIDIA-Merlin/models/issues/242

I left some comments in ReviewNB.


Customizable ring HTTP status page handler

What this PR does:
Exports the ring HTTP status page handler, allowing to pass in a custom template similarly to what I did in https://github.com/grafana/dskit/pull/163 for memberlist.
I strongly recommend checking the commits (and their descriptions) individually to make the review easier.
Which issue(s) this PR fixes:
None
Checklist

[ ] Tests updated
[x] CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX]

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


Rename rust-lang/stdsimd to rust-lang/portable-simd

Please and thank you~
Some of the reasoning is summarized at https://github.com/rust-lang/stdsimd/issues/148
Basically we realized there was a lot of name collision going on and a different name would help.
Other name collisions include e.g. https://crates.io/crates/stdsimd

We're likely happy to rename the repository (I don't see any blockers for that, github generally supports renames pretty well). Going to go ahead and do so now.
However, with regards to crates.io et. al. it's likely we'll not want to publish portable-simd I'd guess -- if the impl is intended to be in std, that's likely to be confusing.

Seems to be solved, closing.


Feature/36/dpi support

Codecov Report

Merging #37 (34369fe) into master (740e9fc) will increase coverage by 0.20%.
The diff coverage is 87.50%.

@@            Coverage Diff             @@
##           master      #37      +/-   ##
==========================================
+ Coverage   80.94%   81.15%   +0.20%
==========================================
  Files           5        5
  Lines         488      504      +16
==========================================
+ Hits          395      409      +14
- Misses         51       54       +3
+ Partials       42       41       -1

Impacted Files
Coverage Δ

img/processor/imagemagick.go
75.84% <50.00%> (-0.31%)
:arrow_down:

img/service.go
89.44% <100.00%> (+0.77%)
: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 740e9fc...34369fe. Read the comment docs.


fix: create unique layout autosave key attribute GENC-266

Review Guidance
📓   Related JIRA
GENC-266
🤔   What does this PR do?

Uses the current date/time to create a unique layout autosave key
This handles this issue

📑   How should this be tested?
npx -y @genesislcap/genx@latest init prtest -x --ref mw/GENC-266-unique-layout-key --routes '[{"name":"home","tiles":[{"title":"Entity manager tile","type":"entity-manager","config":{"resourceName":"ALL_COUNTERPARTYS","title":"Counterparty Management","updateEvent":"EVENT_COUNTERPARTY_MODIFY","deleteEvent":"EVENT_COUNTERPARTY_DELETE","createEvent":"EVENT_COUNTERPARTY_INSERT"}},{"title":"Form tile","type":"smart-form","config":{"resourceName":"EVENT_TRADE_INSERT"}}]},{"name":"page-2","tiles":[{"title":"Grid Tile","type":"grid-pro","config":{"resourceName":"ALL_POSITIONS"}},{"title":"Charts Tile 1","type":"chart","config":{"type":"line","resourceName":"ALL_POSITIONS","xField":"INSTRUMENT_NAME","yField":"VALUE"}},{"title":"Charts Tile 2","type":"chart","config":{"type":"pie","resourceName":"ALL_POSITIONS","xField":"INSTRUMENT_NAME","yField":"VALUE"}},{"title":"Charts Tile 3","type":"chart","config":{"type":"column","resourceName":"ALL_POSITIONS","xField":"INSTRUMENT_ID","yField":"VALUE"}}]}]' --apiHost 'wss://public-foundation.genesislab.global/gwf/'

Observe that the auto-save-key attributes on the generated layouts have the date and time appended
✅   Checklist

[X] I have tested my changes.
[X] I have added tests for my changes.
[ ] I have updated the project documentation to reflect my changes.

Tested locally:
<zero-layout auto-save-key="home_1712220406238">


Parse error: Muliple annotations with line comment

That code can not be parsed:
@Suppress("unused") //
@JsName("daName")
fun myname(){
....

If the both annotations are switched, it works just fine.
--> The exception occurs if:

there are two annotations
there is a line comment between these two annotations

Stack trace:
`
ava.lang.IllegalStateException: Unrecognized modifier: // public API
at kastree.ast.psi.Converter$convertModifiers$1.invoke(Converter.kt:367)
at kastree.ast.psi.Converter$convertModifiers$1.invoke(Converter.kt:16)
at kotlin.sequences.TransformingSequence$iterator$1.next(Sequences.kt:172)
at kotlin.sequences.FilteringSequence$iterator$1.calcNext(Sequences.kt:132)
at kotlin.sequences.FilteringSequence$iterator$1.hasNext(Sequences.kt:156)
at kotlin.sequences.SequencesKt___SequencesKt.toCollection(_Sequences.kt:702)
at kotlin.sequences.SequencesKt___SequencesKt.toMutableList(_Sequences.kt:732)
at kotlin.sequences.SequencesKt___SequencesKt.toList(_Sequences.kt:723)
at kastree.ast.psi.Converter.convertModifiers(Converter.kt:371)
at kastree.ast.psi.Converter.convertModifiers(Converter.kt:350)
at kastree.ast.psi.Converter.convertFunc(Converter.kt:304)
at kastree.ast.psi.Converter.convertDecl(Converter.kt:195)
at kastree.ast.psi.Converter.convertFile(Converter.kt:293)
at kastree.ast.psi.Parser.parseFile(Parser.kt:23)
at kastree.ast.psi.Parser.parseFile$default(Parser.kt:23)

`

I am not really doing much to this library these days (my day job has taken me away fro Kotlin mostly). It appears this might be a bug in the Kotlin PSI libraries, but admittedly I probably use an old version and this may have been fixed in the meantime.

I have changed Kotlin to the latest 1.3.50, this includes the latest PSI libraries, I think, and it still crashes.
The crash is because of the line 367 in Converter.kt. Returning null instead of error("Unrecognized modifier: ${node.text}") ignores "unknown" cases. I do not think this is correct solution because I do not know what exactly what other cases I am breaking...
Unit tests fail for this case because Writer.write(node).trim() will write the original source code without the comments:

    @Test
    fun testCommentBetweenAnnotations() {
        assertParseAndWriteExact("""
            @Annotation1("abc")
            // line comment between annotations crashes parser
            @Annotation2("123")
            fun parse() {}
        """.trimIndent())
    }

    fun assertParseAndWriteExact(code: String) {

        val node = Parser.parseFile(code)
        val identityNode = MutableVisitor.preVisit(node) { v, _ -> v }

        assertEquals(
            code.trim(),
            Writer.write(node).trim(),
            "Parse -> Write for $code, not equal")

        assertEquals(
            code.trim(),
            Writer.write(identityNode).trim(),
            "Parse -> Identity Transform -> Write for $code, failed")
    }

Hi @martinflorek,
maybe my Kotlin parsing library can help you:
https://github.com/kotlinx/ast
It is a generic AST parsing library, Kotlin is currently the only supported language. The library is designed that other languages can be easily added. kotlinx.ast does not use the kotlin compiler for paring, it is using ANTLR (the kotlin variant https://github.com/Strumenta/antlr-kotlin) using the official kotlin grammer (https://kotlinlang.org/docs/reference/grammar.html)
One Component is "Klass", a collection of language independent data classes used to represent and easily access the AST.
Your example code will be parsed fine: https://github.com/kotlinx/ast/commit/d4da88af8bdbcc9d4b5f2a125ee0b985301905e0

MultiAnnotationsWithLineComment.kt.txt contains the source of your example
MultiAnnotationsWithLineComment.raw.txt contains the raw AST
MultiAnnotationsWithLineComment.summary.txt contains the "Klass" Representation you can use:

PackageHeader()
importList
KlassDeclaration(fun parse)
  KlassAnnotation(Annotation1)
    KlassArgument()
      KlassString
        "abc"
  KlassAnnotation(Annotation2)
    KlassArgument()
      KlassString
        "123"

using kotlin code, this is:
listOf(
  PackageHeader(),
  DefaultAstNode("importList"),
  KlassDeclaration(
    keyword = "fun",
    identifier = KlassIdentifier("parse"),
    annotations = listOf(
      KlassAnnotation(KlassIdentifier("Annotation1")),
      KlassAnnotation(KlassIdentifier("Annotation2"))
    )
)

There are some parts missing, for example the importList is not converted into an easy-to-use data class. But I'm already using the library for AST parsing. You can just open the project in IDEA or run
./gradlew clean check publishToMavenLocal if you want to use it locally.
Please let me know if you have any questions, or just open an issue :-)

@drieks I tried it but it complains "Could not find com.strumenta.antlr-kotlin:antlr-kotlin-gradle-plugin:0.0.5". I added the jitpack repo into repositories (maven("https://jitpack.io")), based on their examples for versions > 0.0.4, but it is still cannot find it. Any ides?

@martinflorek : Oh sorry, please try to replace version "0.0.5" of antlr-kotlin with "2e25fd550f" (the latest revision listed here: https://jitpack.io/#com.strumenta/antlr-kotlin when clicking on "Commits")

@drieks there are more and more issues...
> Could not resolve all files for configuration ':common:jvmCompileClasspath'.
   > Could not find com.strumenta.antlr-kotlin:antlr-kotlin-runtime-jvm:0.0.5.
     Searched in the following locations:
       - https://repo.maven.apache.org/maven2/com/strumenta/antlr-kotlin/antlr-kotlin-runtime-jvm/0.0.5/antlr-kotlin-runtime-jvm-0.0.5.module
       - https://repo.maven.apache.org/maven2/com/strumenta/antlr-kotlin/antlr-kotlin-runtime-jvm/0.0.5/antlr-kotlin-runtime-jvm-0.0.5.pom
       - https://jcenter.bintray.com/com/strumenta/antlr-kotlin/antlr-kotlin-runtime-jvm/0.0.5/antlr-kotlin-runtime-jvm-0.0.5.module
       - https://jcenter.bintray.com/com/strumenta/antlr-kotlin/antlr-kotlin-runtime-jvm/0.0.5/antlr-kotlin-runtime-jvm-0.0.5.pom
       - https://jitpack.io/com/strumenta/antlr-kotlin/antlr-kotlin-runtime-jvm/0.0.5/antlr-kotlin-runtime-jvm-0.0.5.module
       - https://jitpack.io/com/strumenta/antlr-kotlin/antlr-kotlin-runtime-jvm/0.0.5/antlr-kotlin-runtime-jvm-0.0.5.pom
     Required by:
         project :common > com.strumenta.antlr-kotlin:antlr-kotlin-runtime:2e25fd550f

Hi @martinflorek,
it seems that I have always used the locally build version of antlr-kotlin.
I fixed the bug in antlr-kotlin that forced the usage of version 0.0.5 (https://github.com/Strumenta/antlr-kotlin/issues/29)
I added kotlinx.ast to jitpack, you can include it now in your project without building it locally:
In settings.gradle.kts add this line: (otherwise, the jars are not resolved):
// Enables KotlinMultiplatform publication and resolving (in dependencies)
enableFeaturePreview("GRADLE_METADATA")

You have to add jitpack to build.gradle.kts:
repositories {
  maven("https://jitpack.io")
}

Now, you can add the dependency to kotlinx.ast:
kotlin {
    jvm()

    sourceSets {
        val commonMain by getting {
            dependencies {
                api("com.github.kotlinx.ast:kotlin:0e92ad018e")
            }
        }
    }
}

This should add kotlinx.ast.kotlin with transitive dependencies to kotlinx.ast.common and antlr-kotlin.
(currently, for multiplatform only common and jvm is supported, but native and js support should be possible without too much work)
If you don't use kotlin-multiplatform, please try to add implementation("com.github.kotlinx.ast:kotlin:0e92ad018e") or implementation("com.github.kotlinx.ast:kotlin-jvm:0e92ad018e").

@drieks it works now, thank you. But it crashes on parsing annotation values with \$ e.g. @Value("\${abc}") :( Which is a much bigger problem, for me, than the line comments.

Hi @martinflorek,
fixed, please try Version 67b2331974.
I added StringComponentEscape for escaped characters in Strings. When I find some time, I will add a test that tries to parse a large kotlin codebase to find such errors. https://github.com/kotlinx/ast/commit/67b23319747afb8479c3b25b3683db8288294798
@Value("\${abc}") will now be parsed as:
KlassAnnotation(Value)
  KlassArgument()
    KlassString
      Escape("\$")
      "{abc}"

@drieks Now the parsing of "escaped" values in annotations work, but I have found another issue. It does not belong here, so I created a new issue in your repo https://github.com/kotlinx/ast/issues/1
@cretz I still prefer your parser, especially its speed, and it handles everything I have thrown at it except for the comments after annotations. Thank you for this library.

Thanks (it's the Kotlin core code that I use, I didn't write the parser)...I apologize as I have left the JVM ecosystem for the time being and don't have time to work on this or any of my other Kotlin libs.