Zum Inhalt der Seite gehen


aws-cli 1.37 abend with "TypeError: argument of type 'NoneType' is not iterable"


After a recent software package update of my VPS, aws-cli version 1.37 was installed.
This version broke my regular backup to s3 task since aws s3 cp ... abended now with the following error

TypeError: argument of type 'NoneType' is not iterable

I searched the net and found some appropriate bug reports:
SignatureDoesNotMatch when putting file #9236
Content-MD5 header is not set anymore for PutBucketLifecycleConfiguration operation #3415

Both issues were already closed and announced to be fixed in an upcoming version.

But upgrading to the next version didn't solve my problem.
So I decided to revert back to a recent working version, which turned out to be not as easy on Archlinux.


  1. First I deinstalled every target and conflicting package version to avoid later file conflicts.
    sudo yay -R aws-cli python-botocore python-rsa python-docutils
  2. Then i installed missing python build requirements
    sudo yay -S git python-pip python-virtualenv
  3. Checking out the source code
    cd /usr/src/build/
    git clone https://github.com/aws/aws-cli.git
    cd aws-cli/
    git checkout 1.36.34
  4. Building the former version of aws-cli in a venv
    virtualenv venv
    . venv/bin/activate
    pip install --upgrade pip
    pip install -r requirements.txt
    pip install -e .
  5. Installing aws-cli and dependent packages system-wide using pip
    deactivate
    sudo pip install --break-system-packages [--dry-run] .


I hope this short guide helps some people having the same issue.

🔥 But keep in mind, that installing python packages system-wide via pip is strongly discouraged as it may break your system.
🥳 However I didn't experience any such problems.

This website uses only neccessary cookies. If you continue browsing this website, you agree to the usage of cookies.