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

Use http scheme instead of zim in our internal links. #917

Closed
mgautierfr opened this issue Jan 3, 2023 · 6 comments
Closed

Use http scheme instead of zim in our internal links. #917

mgautierfr opened this issue Jan 3, 2023 · 6 comments
Assignees
Milestone

Comments

@mgautierfr
Copy link
Member

kiwix-desktop use a specific scheme zim:// in the webview to reference content provided by our urlschemhandler. This allow a well defined separation between http content which link to actual online content (which should be catch/blocked/opened with web browser) and our internal content which need a url.

However, few features (as service worker #487 or Phet zim file #915) need a http:// scheme.

We should rethink how we build our internal urls and use http scheme all the time. (Use a specific host to reference internal content ?)

@kelson42
Copy link
Collaborator

kelson42 commented Jan 3, 2023

@mgautierfr We have custom protocol handler on Android. We should keep it here, bit implement it in a way it works. I strongly oppose to launch a http daemon.

@mgautierfr
Copy link
Member Author

I don't want to launch a http daemon. I want to change the scheme of the url from zim:// to http://. Simply because a lot of technologies in the web word expect http:// and using zim:// breaks things.

@kelson42
Copy link
Collaborator

kelson42 commented Jan 4, 2023

AFAIK nothing expects here the http:// scheme (we have no URL of that type in ZIM files to access local content) and it would be abusing the HTTP protocol to provide ZIM access using it. For example, in #915, the URL failing is zim://fbd2f790-5d36-fccc-df2d-c22f94be3a69.zim/-/en.json. We need a zim:// protocol working properly.

@mgautierfr
Copy link
Member Author

In #915, I understand that Fetch API cannot load zim://fbd2f790-5d36-fccc-df2d-c22f94be3a69.zim/-/en.json. URL scheme "zim" is not supported. means that the js content of the libzim itself refuse to load things using the zim scheme. It is not us refusing the request.

@kelson42 kelson42 added enhancement Qt Qt related labels Jan 5, 2023
@kelson42
Copy link
Collaborator

kelson42 commented Apr 16, 2023

@mgautierfr After reading this I was somehow under the impression, the problem has been fixed recently. Reading #915 seems to confirm this as well.

If this is confirmed, this ticket is not the way to follow. We should be able to fix #487 simply after kiwix/kiwix-build#594 is implemented, using a custom protocol.

@kelson42 kelson42 added this to the 2.4.0 milestone Apr 16, 2023
@kelson42 kelson42 modified the milestones: 2.4.0, 2.5.0 Aug 6, 2023
@kelson42
Copy link
Collaborator

Considering that both#487 and 915 have been closed, this issue has lost its justification

@kelson42 kelson42 closed this as not planned Won't fix, can't repro, duplicate, stale May 14, 2024
@kelson42 kelson42 modified the milestones: 2.5.0, 2.4.0 May 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants