Jayy001/codexctl

On rM the default downloads folder doesn't exist

multijoy opened this issue · 2 comments

As title - trying to download onto a 3.11 in order to rollback to the 2. series to install Toltec, however fails with "cannot find download folder" and creating the folder in the current directory doesn't see a file downloaded

Cancel my last, it is expecting to see "./Downloads"

What OS are you on? It should not be looking for the folder named Downloads in your local directory, it should be using either the folder specified by the XDG_DOWNLOAD_DIR environment variable, or the folder named Downloads in your home directory if the environment variable is not set.

self.DOWNLOAD_FOLDER = Path(
os.environ["XDG_DOWNLOAD_DIR"]
if (
"XDG_DOWNLOAD_DIR" in os.environ
and os.path.exists(os.environ["XDG_DOWNLOAD_DIR"])
)
else Path.home() / "Downloads"
)

I see you saying that it's "On device", but it's failing because the folder doesn't exist. It would be fair to add extra code to have a better sane default for running on the device, as well as making sure the folder exists.