Skip to content

avoid >100% progress #628

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 1 commit into from
Jun 11, 2020
Merged

avoid >100% progress #628

merged 1 commit into from
Jun 11, 2020

Conversation

IonBazan
Copy link
Contributor

@IonBazan IonBazan commented May 30, 2020

Fixes #468
This change skips tracking the progress of downloads where Content-Length header is missing. Curl returns -1 which resulted in wrong progress calculation (total file size was not added to the total bytes to download).

As soon as such file is downloaded, the progress is updated. This means that downloading one big file might cause progress to stuck until the download is done.

Copy link
Member

@nicolas-grekas nicolas-grekas left a comment

Choose a reason for hiding this comment

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

Thanks for having a look, let's see how this goes!

This means that downloading one big file might cause progress to stuck until the download is done.

ACK. We could add some visual spinner but let's keep this simple :)

@nicolas-grekas
Copy link
Member

Thank you @IonBazan.

@nicolas-grekas nicolas-grekas merged commit f850efc into symfony:master Jun 11, 2020
@IonBazan IonBazan deleted the progress-fix branch June 11, 2020 11:23
@stof
Copy link
Member

stof commented Jun 11, 2020

is this something that needs to be applied in composer 2 as well ? I know that they reused part of the curl implementation of Flex, but I don't know whether this bug happens in the code they copied or in the code they did not use.

@nicolas-grekas
Copy link
Member

@stof can you please have a look?
Or maybe @Seldaek knows?

@Seldaek
Copy link
Member

Seldaek commented Jun 11, 2020

We dropped progress support entirely so should be fine but thanks for asking.

tgalopin pushed a commit to tgalopin/flex that referenced this pull request Dec 3, 2020
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.

Percentage of downloaded packages goes beyond 100%
4 participants