Skip to content

test: range requests of deserialized files #213

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

Merged
merged 9 commits into from
May 28, 2025

Conversation

lidel
Copy link
Member

@lidel lidel commented Jun 9, 2024

This is WIP port of HTTP Range tests described in #154 (comment)

  • fix HTTP 500: cannot detect content-type: failed to fetch all nodes returned right now by boxo/gateway (or create better fixture that does not clash with content-type sniffing logic)
  • port test fror range AFTER missing block as well
  • include test for negative from (suffix range, for reading tail of the file)
  • include test for explicit Accept-Ranges: bytes hint on non-range deserialized response

Aims to close #154

Copy link
Contributor

github-actions bot commented Jun 9, 2024

Results against Kubo master:
(check the action's summary for the full results)

Summary

Tests Failures Errors Skipped
1320 3 0 0

Copy link
Contributor

github-actions bot commented Jun 9, 2024

Results against Kubo latest:
(check the action's summary for the full results)

Summary

Tests Failures Errors Skipped
1320 3 0 0

@lidel lidel force-pushed the feat/advanced-unixfs-range-requests branch 3 times, most recently from 41e2a08 to b7a423f Compare May 27, 2025 20:27
@lidel lidel force-pushed the feat/advanced-unixfs-range-requests branch from b7a423f to 789cfac Compare May 27, 2025 20:51
makes test more representative of seeking inside of a partially
available file
Copy link
Contributor

github-actions bot commented May 27, 2025

Results against Kubo fix/range-suffix:
(check the action's summary for the full results)

Summary

Tests Failures Errors Skipped
1320 0 0 0

lidel added 2 commits May 28, 2025 01:34
content-type is not hard requirement, and implementations may have
easier or harder time with coming up with the right one.

if the content type info is not part of DAG metadata, and needs to me
sniffed (majority of content in 2025), then this internal sniffing may
produce different results in different file x library permutations.

in practice, it does not matter, browsers will stream videos just fine.

lets focus on Content-Range and body being correct - if we need to test
Content-Type, let's move it to a different test suite
@lidel lidel force-pushed the feat/advanced-unixfs-range-requests branch from f2719c6 to ad744bc Compare May 28, 2025 00:28
@lidel lidel changed the title wip: http range with file-3k-and-3-blocks-missing-block.car test: range requests of deserialized files May 28, 2025
@lidel lidel marked this pull request as ready for review May 28, 2025 02:26
Copy link
Contributor

v0.8.0

Changed

  • Comprehensive tests for HTTP Range Requests over deserialized UnixFS files have been added. The --specs path-gateway now requires support for at least single-range requests. Deserialized range-requests can be skipped with --skip 'TestGatewayUnixFSFileRanges' #213
  • Updated dependencies #236 & #239

@lidel
Copy link
Member Author

lidel commented May 28, 2025

Because this adds new tests that will start failing in Kubo until fix from ipfs/boxo#922 lands, I'm shipping this. as v0.8, allowing exiting implementations to stay on v0.7 until they pass these new tests. (cc @SgtPooki for visibility)

Let's continue in ipfs/boxo#922

@lidel lidel merged commit bb4780c into main May 28, 2025
10 of 11 checks passed
@lidel lidel deleted the feat/advanced-unixfs-range-requests branch May 28, 2025 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add tests for HTTP Range requests
1 participant