-
-
Notifications
You must be signed in to change notification settings - Fork 16.3k
microsoft-edge: fix file picker and substituteInPlace
#219170
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/ms-edge-crash-when-trying-to-load-open-save-dialogs/25621/6 |
I see you, @JonaEnz and @puffnfresh are also working on |
The |
Thank you for your review @JonaEnz. I've implemented your suggestion (well spotted by the way) and confirmed that the substitutions now work. The substitutions are to functions such as At the same time, I also confirmed that the |
This fixes Microsoft Edge crashing if someone tries to open or save a file via the file picker. For example, to debug the functionality, I went to: ``` https://drive.google.com -> New -> File upload ``` This used to crash with the following error: ``` [...] (microsoft-edge:22536): GLib-GIO-ERROR **: 11:11:46.555: No GSettings schemas are installed on the system [0302/111146.559740:ERROR:elf_dynamic_array_reader.h(64)] tag not found [0302/111146.559913:ERROR:process_memory_range.cc(75)] read out of range [0302/111146.568118:ERROR:watson_metadata.cc(170)] unexpected header Trace/breakpoint trap (core dumped) ``` This PR fixes this error by explicitly making `gsettings-schemas` from `gtk` available to `microsoft-edge` via `XDG_DATA_DIRS`. Furthermore, this PR fixes some broken `subsituteInPlace` commands. Thanks to Jona Enzinger (`@JonaEnz`) who noticed that `--replace "''${XDG...` should be written as `--replace "\''${XDG...`.
substituteInPlace
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/prs-ready-for-review/3032/1900 |
It is not broken, it just needs to be escaped properly. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Whats with this dangling symlink?
▶ ls -lah result/bin/microsoft-edge-stable
lrwxrwxrwx root root 36 B Thu Jan 1 01:00:01 1970 result/bin/microsoft-edge-stable ⇒ /opt/microsoft/msedge/microsoft-edge
Yes. Didn't we fix that? |
I have no idea. I considered it out of scope for this PR. |
Successfully uploaded and downloaded an image to Bing image search with this PR using the file picker. Result of 2 packages failed to build:
1 package built:
|
Description of changes
This fixes Microsoft Edge crashing if someone tries to open or save a file via the file picker. For example, to debug the functionality, I went to:
Also, I've removed the
substituteInPlace
for thexdg-settings
file because it appears that they don't substitute anything. Maybe another argument for a--fail-on-no-subst
flag (https://discourse.nixos.org/t/when-to-use-substituteinplace-functions-vs-a-patch/11073/11).Things done
sandbox = true
set innix.conf
? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)