diff --git a/.github/workflows/update-sources.yml b/.github/workflows/update-sources.yml index 343a131..bc65815 100644 --- a/.github/workflows/update-sources.yml +++ b/.github/workflows/update-sources.yml @@ -6,6 +6,7 @@ on: permissions: contents: write pull-requests: write + issues: write jobs: check: runs-on: ubuntu-latest diff --git a/research/python/update_sources.py b/research/python/update_sources.py index a744747..b0de7a1 100644 --- a/research/python/update_sources.py +++ b/research/python/update_sources.py @@ -76,7 +76,8 @@ def update_form(src, report): subprocess.run([sys.executable, P("research", "python", "export_raw.py"), src, out], check=True, cwd=HERE) subprocess.run([sys.executable, P("research", "python", "clean.py"), out, P("data", "derived", "runs_clean.csv")], check=True, cwd=HERE) raw_copy = P("data", "raw", "form", "Threshing_Routes_Responses.xlsx") - if os.path.abspath(src) != raw_copy: + if os.path.abspath(src) != raw_copy: # local copy only; data/raw/form/*.xlsx is git-ignored + os.makedirs(os.path.dirname(raw_copy), exist_ok=True) shutil.copyfile(src, raw_copy) new_q = [h for h in headers if h not in current["headers"]] gone_q = [h for h in current["headers"] if h not in headers]