Skip to content
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

Clicking on external links and map markers in Wikivoyage articles crashes the Electron app (blocked by CSP) [workaround below] #633

Closed
Jaifroid opened this issue Aug 6, 2024 · 2 comments
Assignees
Labels
bug upstream Should be worked on in kiwix-js
Milestone

Comments

@Jaifroid
Copy link
Member

Jaifroid commented Aug 6, 2024

EDIT this issue is caused by a faulty script upstream in mwOffliner - openzim/mwoffliner#2075

This is a regression probably introduced when dealing with custom protocols. Clicking on a map marker will attempt to navigate in-app to the Open Street Maps or OS Maps app (according to Config setting), and this is of course blocked by the CSP, causing the app to enter a completely unresponsive state (it has to be restarted to continue using it).

Workaround: use Ctrl-click on a map marker to ensure a new window is opened with a map centred on the marker's location. There is no current touchscreen solution for this in the Electron app. However, the mobile (UWP WinRT) version is unaffected by the bug.

Although I was sure that I had included geo: and bingmaps: protocols for special handling, it's not working in the Electron app. W10M is unaffected.

@Jaifroid Jaifroid added this to the Release 3.4.0 milestone Aug 6, 2024
@Jaifroid Jaifroid self-assigned this Aug 6, 2024
@Jaifroid Jaifroid changed the title Clicking on map markers in Wikivoyage articles crashes the Electron app (blocked by CSP) [workaround below] Clicking on external links and map markers in Wikivoyage articles crashes the Electron app (blocked by CSP) [workaround below] Aug 8, 2024
@Jaifroid Jaifroid added upstream Should be worked on in kiwix-js and removed regression labels Aug 8, 2024
@Jaifroid
Copy link
Member Author

Jaifroid commented Aug 8, 2024

I'll need to work around this issue at least for the PWA, which will fix the UWP app that relies on it. I may need to release an updated Electron app, as the issue is more widespread than I thought, though it can be dealt with using the Ctrl-click workaround. Unfortunately that won't work on mobile.

@Jaifroid
Copy link
Member Author

So, this issue is fixed in the PWA and in the latest base app release. Given the workarounds, I don't think it's crucial to reissue the Wikivoyage app, so closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug upstream Should be worked on in kiwix-js
Projects
None yet
Development

No branches or pull requests

1 participant