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

fix: parquet over http #2565

Merged
merged 3 commits into from
Feb 2, 2024
Merged

Conversation

universalmind303
Copy link
Contributor

@universalmind303 universalmind303 commented Feb 2, 2024

reqwest's content_length method apparantly doesnt check for the casing of "Content-Length". This seems like a bug in reqwest to me.

seanmonstar/reqwest#843

#[tokio::main]
async fn main() {
    let client = reqwest::Client::new();
    let head_res = client.head("https://clickhouse-public-datasets.s3.eu-central-1.amazonaws.com/hits_compatible/athena/hits.parquet").send().await.unwrap();
    let content_length = head_res.content_length();
    assert_eq!(content_length, Some(14779976446))
}

closes #2561

Copy link
Collaborator

@tychoish tychoish left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

regression testable?

@universalmind303
Copy link
Contributor Author

regression testable?

maybe?? Without relying on other apis like the one mentioned in the issue, We'd have to spin up some infra for hosting some public files.

@universalmind303 universalmind303 merged commit bbe15fb into main Feb 2, 2024
22 checks passed
@universalmind303 universalmind303 deleted the universalmind303/content-length-fix branch February 2, 2024 14:59
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.

Does not work with a Parquet file on an HTTPs server
2 participants