mirror of
https://github.com/asadbek064/hyparquet.git
synced 2025-12-30 08:56:37 +00:00
* Support endpoints that don't support range requests in asyncBufferFromUrl Before this commit asyncBufferFromUrl assumes that the body of whatever successful response it gets is equivalent to the range it requested. If the origin server does not support HTTP range requests then this assumption is usually wrong and will lead to parsing failures. This commit changes asyncBufferFromUrl to change its behaviour slightly based on the status code in the response: - if 200 then we got the whole parquet file as the response. Save it and use the resulting ArrayBuffer to serve all future slice calls. - if 206 then we got a range response and we can just return that. I have also included some test cases to ensure that such responses are handled correctly and also tweaked other existing mocks to also include the relevant status code. * Fix all lint warnings * replace switch with if-else |
||
|---|---|---|
| .. | ||
| files | ||
| assemble.test.js | ||
| asyncbuffer.test.js | ||
| column.test.js | ||
| convert.test.js | ||
| encoding.test.js | ||
| helpers.js | ||
| indexes.test.js | ||
| metadata.test.js | ||
| package.test.js | ||
| plain.test.js | ||
| query.test.js | ||
| read.test.js | ||
| readFiles.test.js | ||
| schema.test.js | ||
| schemaTree.test.js | ||
| snappy.test.js | ||
| thrift.test.js | ||
| utils.test.js | ||