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

Non-zero return code for launchpad (and possibly debian) #49

Open
mariuszskon opened this issue Jun 22, 2021 · 0 comments · May be fixed by #50
Open

Non-zero return code for launchpad (and possibly debian) #49

mariuszskon opened this issue Jun 22, 2021 · 0 comments · May be fixed by #50

Comments

@mariuszskon
Copy link

If at least one download fails for launchpad, the return code is non-zero. This does not happen for other categories like rpm. This inconsistency breaks automated scripts which use the return code unless if all errors are ignored which is probably not a good idea.

$ ./get launchpad
Will download or update for:
	* launchpad ; Requirements are met
Downloading/updating launchpad
Launchpad: Series impish
...
Getting launchpad-ubuntu-glibc-hoary
  -> Location: https://launchpad.net/ubuntu/+source/glibc/2.3.2.ds1-20ubuntu14/+build/95476/+files/libc6_2.3.2.ds1-20ubuntu14_i386.deb
  -> ID: libc6_2.3.2.ds1-20ubuntu14_i386
  -> Downloading package
Failed to download package from https://launchpad.net/ubuntu/+source/glibc/2.3.2.ds1-20ubuntu14/+build/95476/+files/libc6_2.3.2.ds1-20ubuntu14_i386.deb
Getting launchpad-ubuntu-glibc-hoary
  -> Location: https://launchpad.net/ubuntu/+source/glibc/2.3.2.ds1-20ubuntu15/+build/179595/+files/libc6_2.3.2.ds1-20ubuntu15_i386.deb
  -> ID: libc6_2.3.2.ds1-20ubuntu15_i386
  -> Already have this version, 'rm /home/mariusz/.libc-database/db/libc6_2.3.2.ds1-20ubuntu15_i386.*' to force
Launchpad: Series warty
Getting launchpad-ubuntu-glibc-warty
  -> Location: https://launchpad.net/ubuntu/+source/glibc/2.3.2.ds1-13ubuntu2.2/+build/73022/+files/libc6_2.3.2.ds1-13ubuntu2.2_i386.deb
  -> ID: libc6_2.3.2.ds1-13ubuntu2.2_i386
  -> Already have this version, 'rm /home/mariusz/.libc-database/db/libc6_2.3.2.ds1-13ubuntu2.2_i386.*' to force
Getting launchpad-ubuntu-glibc-warty
  -> Location: https://launchpad.net/ubuntu/+source/glibc/2.3.2.ds1-13ubuntu2.3/+build/179681/+files/libc6_2.3.2.ds1-13ubuntu2.3_i386.deb
  -> ID: libc6_2.3.2.ds1-13ubuntu2.3_i386
  -> Already have this version, 'rm /home/mariusz/.libc-database/db/libc6_2.3.2.ds1-13ubuntu2.3_i386.*' to force
Getting launchpad-ubuntu-glibc-warty
  -> Location: https://launchpad.net/ubuntu/+source/glibc/2.3.2.ds1-13ubuntu2/+build/57040/+files/libc6_2.3.2.ds1-13ubuntu2_i386.deb
  -> ID: libc6_2.3.2.ds1-13ubuntu2_i386
  -> Already have this version, 'rm /home/mariusz/.libc-database/db/libc6_2.3.2.ds1-13ubuntu2_i386.*' to force
$ echo $?
1

This seems to be because some of the get_all_* functions have a sleep .1 after each download, but launchpad and debian do not.

@mariuszskon mariuszskon linked a pull request Jun 22, 2021 that will close this issue
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 a pull request may close this issue.

1 participant