← Back to team overview

group.of.nepali.translators team mailing list archive

[Bug 1771914] Re: release-upgrade-motd can't update message via apt proxy

 

Targetting this to xenial so we can verify that this regression won't
happen there when fixing bug 1744318.


** Also affects: update-manager (Ubuntu Xenial)
   Importance: Undecided
       Status: New

-- 
You received this bug notification because you are a member of नेपाली
भाषा समायोजकहरुको समूह, which is subscribed to Xenial.
Matching subscriptions: Ubuntu 16.04 Bugs
https://bugs.launchpad.net/bugs/1771914

Title:
  release-upgrade-motd can't update message via apt proxy

Status in update-manager package in Ubuntu:
  Fix Released
Status in update-manager source package in Xenial:
  New
Status in update-manager source package in Bionic:
  Fix Released

Bug description:
  [Impact]
  apt proxy settings are not applied to https urls, and thus the release-upgrade-motd script fails, and upgrades from bionic to new versions won't be detected either, if you need to use a proxy. This is a regression from the 1:18.04.6 upload which switched changelogs.ubuntu.com from http to https.

  [Test case]
  Set acquire::http::proxy to a non-existing host, e.g. http://invalid.invalid/, and check that the tool fails.

  Do the same with acquire::https::proxy.

  (Kind of a reverse check, since I don't have a proxy setup to test
  against. If there's an actual proxy and otherwise, no internet, it can
  be verified by setting the actual proxy and checking that it works
  with it).

  [Regression potential]
  The fix changes the API of init_proxy() in UpdateManager/Core/utils.py to make it return a dict with 'http' and 'https' members rather than just a string. It seems the return value is only used by the test case, though, so that should be fine.

  Apart from that, it also allows https proxies now, since we're doing
  https anyway, which means that a proxy setting ignored before now is
  not. The same applies to the the new proxy variables used - they were
  not used before, so things might fail that used to work - like you
  specify an invalid https proxy but don't actually need one. Low risk,
  though.

  [Original bug report]
  I have configured apt proxy in apt.conf.d and apt update and apt install can work correctly. However, when I logged in system everyday, in the login message, it says:

  Failed to connect to https://changelogs.ubuntu.com/meta-release-lts.
  Check your Internet connection or proxy settings

  After further investigation, I found the the issue is caused in
  package python3-update-manager:

  python3-update-manager: /usr/lib/python3/dist-
  packages/UpdateManager/Core/utils.py

  In the init_proxy function of the python script, it only set a http
  proxy by below code:

  proxy_support = ProxyHandler({"http": proxy})

  after changing the line to add https proxy, it can work:

  proxy_support = ProxyHandler({"http": proxy, "https":proxy})

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/update-manager/+bug/1771914/+subscriptions