lipoja / URLExtract

URLExtract is python class for collecting (extracting) URLs from given text based on locating TLD.
MIT License
245 stars 61 forks source link

Issue #25 - Fall back to temp rather than home #26

Closed keyz182 closed 5 years ago

keyz182 commented 6 years ago

As stated in #25, fall back to a temp directory rather than home.

Do you think it needs another check to ensure the temp dir is writeable? If so, what do we do if it fails? Throw an exception up, just use the file in-memory and re-download each time?

lipoja commented 6 years ago

I've googled a bit and it looks like /tmp can be unavailable for the user. So I would suggest to check also the temp dir if it is writable. And if not throw exception as you suggested.

lipoja commented 5 years ago

This patch is no longer needed because I used appdirs for getting cache dir with fallback to global temp directory.

Thank you for your work!