You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, Hello! I ran into a snag last night while learning/migrating to Docker, in case anyone else runs into this/has ran into this, I wanted to provide my insight:
I was running into an issue where testing the app on my local produced no issues, nor have I ran into any issues in the past while running a Flask version on a Raspberry Pi Zero. However, when the container built, I kept getting a "KeyError: dps" randomly when setting the brightness of a particular bulb as such:
I was able to remedy this by throwing in "time.sleep(0.1)"; I'm strongly under the impression the bulb does not have enough time to react between script commands and times out. All my bulbs are 3.3, and like I said, until I threw it into docker I wasn't having the issues and inside the docker, it was never consistently failing. I finally hail mary'd and added these, and it works all day now!
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi, Hello! I ran into a snag last night while learning/migrating to Docker, in case anyone else runs into this/has ran into this, I wanted to provide my insight:
Docker 3.10-slim-bullseye
fastapi==0.86.0
tinytuya==1.7.2
uvicorn==0.19.0
I was running into an issue where testing the app on my local produced no issues, nor have I ran into any issues in the past while running a Flask version on a Raspberry Pi Zero. However, when the container built, I kept getting a "KeyError: dps" randomly when setting the brightness of a particular bulb as such:
I was able to remedy this by throwing in "time.sleep(0.1)"; I'm strongly under the impression the bulb does not have enough time to react between script commands and times out. All my bulbs are 3.3, and like I said, until I threw it into docker I wasn't having the issues and inside the docker, it was never consistently failing. I finally hail mary'd and added these, and it works all day now!
Beta Was this translation helpful? Give feedback.
All reactions