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] Rework tools update (only) #695

merged 4 commits into from Apr 2, 2019


None yet
2 participants
Copy link

commented Mar 27, 2019

The problem

Many issues related to sources.list management these days ... Current code miserably crashes with "FetchFailedException" which doesn't tell anything about what's wrong.


Rework tools_update to use apt update directly instead of apt's python lib which is madness

Also properly shows warning/errors message occuring during the command, and detect the issue (and dump the sources.list lines to help bebugging)

PR Status


How to test

Run yunohost tools update in various conditions (e.g. voluntary break the sources.list)


  • Principle agreement 0/2 :
  • Quick review 0/1 :
  • Simple test 0/1 :
  • Deep review 0/1 :

This comment has been minimized.

Copy link
Member Author

commented Mar 27, 2019

Note that this contains commits from #692

The motivation of this PR is that it should be smaller and less touchy as it doesn't affect tools_upgrade which is more complicated.

Ideally I'd like to include this in 3.5.x to avoid doing so much more boring support about FetchFailedException

@alexAubin alexAubin added this to the 3.5.x milestone Mar 27, 2019

@alexAubin alexAubin merged commit 507c427 into stretch-unstable Apr 2, 2019

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
continuous-integration/travis-ci/push The Travis CI build passed

@alexAubin alexAubin deleted the rework_tools_update_only branch Apr 2, 2019

# Also keep track of wether or not we encountered a warning...
warnings = []
def is_legit_warning(m):
legit_warning = m.rstrip() and "apt does not have a stable CLI interface" not in m.rstrip()

This comment has been minimized.

Copy link

Psycojoker Apr 8, 2019


Shouldn't we use "apt-get" instead of "apt"? iirc apt is designed to be runed interactively not for scripting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.