gdrapp / hass-addons

MIT License
2 stars 23 forks source link

No module names boto3 #5

Open garethbradley opened 3 years ago

garethbradley commented 3 years ago

Hi,

I'm super motivated to get this working. I'm not sure how it's not a core feature of HASS. So, thanks for putting in the effort :)

Having an issue when running it though - logs suggest boto3 isn't installed:

Traceback (most recent call last):
  File "/usr/bin/amazon-s3-backup/amazon-s3-backup.py", line 12, in <module>
    from s3bucket import S3Bucket, S3BucketError
  File "/usr/bin/amazon-s3-backup/s3bucket.py", line 3, in <module>
    import boto3
ModuleNotFoundError: No module named 'boto3'

Config looks correct to me, so not sure if there's a step I missed in the installation?

johntdyer commented 2 years ago

same error

AdrienBigot commented 2 years ago

Hello,

Same problem for me. Python boto3 lib is missing in dependencies.

[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 00-banner.sh: executing... 
-----------------------------------------------------------
 Add-on: Amazon S3 Backup
 Automatically backup Home Assistant snapshots to Amazon S3
-----------------------------------------------------------
 Add-on version: 1.1
 You are running the latest version of this add-on.
 System: Home Assistant OS 6.2  (amd64 / qemux86-64)
 Home Assistant Core: 2021.8.8
 Home Assistant Supervisor: 2021.06.8
-----------------------------------------------------------
 Please, share the above information when looking for help
 or support in, e.g., GitHub, forums or the Discord chat.
-----------------------------------------------------------
[cont-init.d] 00-banner.sh: exited 0.
[cont-init.d] 01-log-level.sh: executing... 
Log level is set to DEBUG
[cont-init.d] 01-log-level.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[16:02:34] INFO: Starting Amazon S3 Backup...
Traceback (most recent call last):
  File "/usr/bin/amazon-s3-backup/amazon-s3-backup.py", line 12, in <module>
    from s3bucket import S3Bucket, S3BucketError
  File "/usr/bin/amazon-s3-backup/s3bucket.py", line 3, in <module>
    import boto3
ModuleNotFoundError: No module named 'boto3'
[cont-finish.d] executing container finish scripts...
[cont-finish.d] 99-message.sh: executing... 
[cont-finish.d] 99-message.sh: exited 0.
[cont-finish.d] done.
[s6-finish] waiting for services.
[s6-finish] sending all processes the TERM signal.
[s6-finish] sending all processes the KILL signal and exiting.
stuartornum commented 2 years ago

I forked this repo and got it working, simple fix in the Dockerfile, just remove Line 11 and add RUN pip3 install boto3 on line 14

https://github.com/stuartornum/hass-addons

ScottG489 commented 2 years ago

@gdrapp Could we get this fixed in this repo? Seems straightforward. Happy to create a PR if you're reviewing them.