Category: Python

  • Upload an Image to S3 Using Post and a Presigned Url

    Hi everyone, Today I’ve been converting my “PUT” upload to S3 to a “POST”. The main motivator for this was to restrict the file size of uploads using a signed policy. Unfortunately this was a pretty tedious process and the error responses from S3 were very vague. Thankfully it’s working now and here’s what I…

  • 4: /codebuild/output/tmp/script.sh: pip: not found – Node.js and CodeStar

    Hi everyone, I ran into the following CodeBuild error after upgrading my build environment from the default nodejs8.10 to nodejs10.14: 4: /codebuild/output/tmp/script.sh: pip: not found This one was a little confusing, but thankfully fairly easy to fix. In your buildspec.yml file update the pip steps to reference pip3 instead of pip: // Original commands: #…

  • AttributeError: module ‘serial’ has no attribute ‘SerialException’ – Python 3.5

    Hi everyone, A quick fix for an error I ran into while updating to Pyhton 3.5.2: AttributeError: module ‘serial’ has no attribute ‘SerialException’ I needed to add pyserial: pi@raspberrypi:~/Desktop/piscripts/get-commands $ sudo pip3.5 install pyserial Collecting pyserial Downloading pyserial-3.4-py2.py3-none-any.whl (193kB) 100% |████████████████████████████████| 194kB 530kB/s Installing collected packages: pyserial Successfully installed pyserial-3.4 Thanks to the following link:…

Create a website or blog at WordPress.com