-
Notifications
You must be signed in to change notification settings - Fork 8
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
deps: latest @helia/verified-fetch & http range support testing #122
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #122 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 1 1
Lines 35 35
Branches 5 5
=========================================
Hits 35 35
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
TypeError: Failed to execute 'put' on 'Cache': Partial response (status code 206) is unsupported
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
i think i got it. byte range is returning invalid byte string. i’ve been testing with bafybeid2sc4k5ynx5yo7wg23fzw2ni4xxuxi7kdq5q3lyurkvglh5wrwmi and hardcoding headers.. and got it fixed with the below if (headers['content-range'] === 'bytes 0-83216545/83216545') {
headers['content-range'] = 'bytes 0-83216544/83216545'
} |
http://helia-sw-gateway.localhost/ipfs/bafybeid2sc4k5ynx5yo7wg23fzw2ni4xxuxi7kdq5q3lyurkvglh5wrwmi is working in brave with the latest from ipfs/helia-verified-fetch#24 |
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.
self review
one issue that comes up when loading large videos (https://bafybeidsp6fva53dexzjycntiucts57ftecajcn5omzfgjx57pqfy3kwbq.ipfs.sw.sgtpooki.com/) is that the request seems to take a while to return. I believe we're waiting for the full content to be loaded, when instead, we should return quickly with minimal data.. I thought we would see a second request from the browser when it sees the content type, but the browser is waiting until the entire first response is done before it sends any additional requests. We can't cancel/abort the original request until the browser tells us to do so, because someone may want the entire content. Opened #131 for this |
Are you referring to the |
Btw, after the initial loading of https://bafybeidsp6fva53dexzjycntiucts57ftecajcn5omzfgjx57pqfy3kwbq.ipfs.sw.sgtpooki.com/ I'm getting a 502 that is coming from the service worker. If I attempt to load the config page I also get a 502: https://bafybeidsp6fva53dexzjycntiucts57ftecajcn5omzfgjx57pqfy3kwbq.ipfs.sw.sgtpooki.com/#ipfs-sw-config |
Yea, the first time verified fetch is called for the content, it loads
Which service worker is registered? When i load https://bafybeidsp6fva53dexzjycntiucts57ftecajcn5omzfgjx57pqfy3kwbq.ipfs.sw.sgtpooki.com/#ipfs-sw-config, and reload, it continues displaying the config page for me, so i think you may have an old SW registered? |
Found DoH bug, filled ipfs/helia#474 (not a blocker, just fyi) |
FYI: merging this in order to continue improvements moving forward. will work on #134 next |
Title
This PR is WIP utilizing the latest release of
@helia/verified-fetch
with the http range header support.Description
This PR updates the service-worker-gateway to support range requests. The
@helia/verified-fetch
package has been updated to the latest release, which includes support for the range header.Notes & open questions
PR is ready for review. things are working.
PR is in draft mode while I test these things out, but for now, the only commit is updating the packages and resolving the conflicts.TODO:
file-3k-and-3-blocks-missing-block.car
from https://github.com/ipfs/gateway-conformance/blob/ed74b532fc7662732ec87d92c49435668369db66/tests/trustless_gateway_car_test.go#L445Progress updates:
2024-03-16 00:32 UTC
bafybeidsp6fva53dexzjycntiucts57ftecajcn5omzfgjx57pqfy3kwbq
bafkreiezuss4xkt5gu256vjccx7vocoksxk77vwmdrpwoumfbbxcy2zowq
Change checklist