Skip to content

Commit

Permalink
Merge pull request #289 from NASA-IMPACT/fix-cache_dir
Browse files Browse the repository at this point in the history
Fix cache dir
  • Loading branch information
xhagrg authored May 28, 2024
2 parents 7c3683d + 7fa67eb commit 2771414
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pyQuARC/code/url_validator.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import os
import requests

from urlextract import URLExtract
Expand Down Expand Up @@ -54,7 +55,7 @@ def status_code_from_request(url):
validity = True

# extract URLs from text
extractor = URLExtract(cache_dir="/tmp")
extractor = URLExtract(cache_dir=os.environ.get("CACHE_DIR"))
urls = extractor.find_urls(text_with_urls)
urls.extend(UrlValidator._extract_http_texts(text_with_urls))

Expand Down

0 comments on commit 2771414

Please sign in to comment.