Package: apt-transport-s3
Version: 2.0.0-1
Severity: normal
Tags: patch

Dear Maintainer,


   * What led up to the situation?
Running "apt update".

   * What exactly did you do (or not do) that was effective (or
     ineffective)?

   * What was the outcome of this action?
Traceback (most recent call last):
  File "/usr/lib/apt/methods/s3", line 598, in <module>
    method = S3_method(config)
  File "/usr/lib/apt/methods/s3", line 385, in __init__
    self.iam.get_credentials()
  File "/usr/lib/apt/methods/s3", line 192, in get_credentials
    data = self.__request_json(urllib.parse.urljoin(self.credentials_metadata,
  File "/usr/lib/python3.8/urllib/parse.py", line 512, in urljoin
    base, url, _coerce_result = _coerce_args(base, url)
  File "/usr/lib/python3.8/urllib/parse.py", line 121, in _coerce_args
    raise TypeError("Cannot mix str and non-str arguments")
TypeError: Cannot mix str and non-str arguments
Hit:1 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal InRelease
Hit:2 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal-updates InRelease
Hit:3 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal-backports InRelease
Hit:4 http://ppa.launchpad.net/ansible/ansible/ubuntu focal InRelease
Hit:5 https://pkg.threatstack.com/v2/Ubuntu focal InRelease
Hit:6 http://security.ubuntu.com/ubuntu focal-security InRelease
Reading package lists... Done
E: Method s3 has died unexpectedly!
E: Sub-process s3 returned an error code (1)
E: Method /usr/lib/apt/methods/s3 did not start correctly
E: Failed to fetch s3://REDACTED-OUT
E: Some index files failed to download. They have been ignored, or old ones
used instead.
   * What outcome did you expect instead?



-- System Information:
Debian Release: bullseye/sid
  APT prefers focal-updates
  APT policy: (500, 'focal-updates'), (500, 'focal-security'), (500, 'focal'), 
(100, 'focal-backports')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 5.8.0-48-generic (SMP w/8 CPU cores)
Kernel taint flags: TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages apt-transport-s3 depends on:
ii  apt                2.0.4
ii  python3            3.8.2-0ubuntu2
pn  python3-configobj  <none>

apt-transport-s3 recommends no packages.

apt-transport-s3 suggests no packages.
--- /usr/lib/apt/methods/s3     2021-04-07 20:55:36.739190710 +0000
+++ s3  2021-04-07 20:52:39.432481416 +0000
@@ -188,7 +188,7 @@
         if data.get("AccessKeyId") is None:
             self.__get_role()
             data = 
self.__request_json(urllib.parse.urljoin(self.credentials_metadata,
-                                                            self.iamrole))
+                                                            str(self.iamrole, 
'utf-8')))
 
         self.access_key = data['AccessKeyId']
         if self.access_key is None or self.access_key == '':

Reply via email to