Closed tomdotorg closed 1 year ago
Thanks @tomdotorg. I'm confused though - the json folder should be created at install because of the weewx_data.json template file that exists in that folder. The install script should also create this folder too. Found here: https://github.com/poblabs/weewx-belchertown/blob/master/install.py#L213
Do you have more info on why this folder was missing for you?
I run weewx in a Docker container (mitct02/weewx) and the way that works is by running the install in the Dockerfile (image, not container) and then overwriting the weewx home directory with a local one the user maintains. Empty directories (which this one should be) are not copied by Docker. All this change does is ensure that the directory exists before trying to download the file.
I (and the others who use this image) currently force create the directory in my Dockerfile, but I thought by putting this check into the Belchertown code, we can simplify the Dockerfiles a bit.
-- Tom Mitchell @.*** Real Time Beverly, MA Weather http://weather.tom.org
"The whole problem with the world is that fools and fanatics are always so certain of themselves, and wiser people so full of doubts."
On Fri, Mar 17, 2023 at 12:29 PM Pat @.***> wrote:
Thanks @tomdotorg https://github.com/tomdotorg. I'm confused though - the json folder should be created at install because of the weewx_data.json template file that exists in that folder. The install script should also create this folder too. Found here: https://github.com/poblabs/weewx-belchertown/blob/master/install.py#L213
Do you have more info on why this folder was missing for you?
— Reply to this email directly, view it on GitHub https://github.com/poblabs/weewx-belchertown/pull/871#issuecomment-1474096121, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAM2ESZWPQNNMSJWNKBV53W4SGPVANCNFSM6AAAAAAV6XKU3A . You are receiving this because you were mentioned.Message ID: @.***>
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
NOTE: this change is not tested. I am not a skilled frontend developer and do not know how to test locally.
This change seeks to fix the error on the first report run where if the directory in which the forecast file goes does not exist, an error is reported and the cycle fails. Subsequent ones do succeed.