Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
72 commits
Select commit Hold shift + click to select a range
c854b5b
Update Ansible
korlaxxalrok Dec 8, 2021
c3227c4
Add `hosp_claims` automation rig
korlaxxalrok Dec 8, 2021
9d30a69
Merge branch 'main' into productionize-claims_hosp
korlaxxalrok Dec 9, 2021
17c35f7
Merge branch 'main' into productionize-claims_hosp
korlaxxalrok Dec 9, 2021
095f792
Re-add new secrets after fixing merge conflict with main
korlaxxalrok Dec 9, 2021
b70e0bb
Register template and template-secrets in case we have both
korlaxxalrok Dec 9, 2021
ab1c2b8
Update claims_hosp/HospClaims/automate/update_json.py
korlaxxalrok Dec 10, 2021
4193038
Remove unused lines
korlaxxalrok May 3, 2022
17b85d5
Update claims_hosp/HospClaims/automate/update_json.py
korlaxxalrok May 3, 2022
a631d77
In light of #1419 being merged, we can change to 70 dates
korlaxxalrok May 3, 2022
d6dff50
Merge branch 'productionize-claims_hosp' of github.com:cmu-delphi/cov…
korlaxxalrok May 3, 2022
126f6e1
Remove unused line
korlaxxalrok May 3, 2022
d9b087f
add scripts and modification required for pulling data
Jun 6, 2022
0e59cd1
rm downloaded files at the end
Jun 6, 2022
c927e00
add logger info for it
Jun 6, 2022
c69cc2f
fixed errors in pulling
Jun 6, 2022
40411f8
add unit tests
Jun 6, 2022
b753b7e
change the path to test.log
Jun 7, 2022
edf8e3f
fixed an error
Jun 7, 2022
2d4400b
change the format of geo_id at hrr level from float to str
Jun 7, 2022
a7f9146
fix hrr geo id type
Jun 7, 2022
a2fcfcb
add unit tests
Jun 7, 2022
40fa62d
change back. Geo ids for hrr are still float numbers
Jun 7, 2022
78e3c4f
fix linting
Jun 7, 2022
af7184b
initial commit to turn QIDs in translation files into item names
nmdefries Jun 7, 2022
ee3e362
report qids in codebook
nmdefries Jun 7, 2022
93fdafa
remove unused code
Jun 9, 2022
0034a41
Merge branch 'main' into ndefries/translation-files-qids
nmdefries Jun 9, 2022
de29f3a
remove initial translation file line with survey ID
nmdefries Jun 9, 2022
27f62e0
make csvs excel compatible
nmdefries Jun 9, 2022
26561d7
new script to combine eu translation files
nmdefries Jun 9, 2022
3be1ef0
drop some unnecessary fields + output format changes
nmdefries Jun 10, 2022
4ed1502
Merge pull request #1641 from cmu-delphi/bot/sync-prod-main
krivard Jun 13, 2022
42d7217
Use os.remove to clean raw files
jingjtang Jun 14, 2022
a011ffa
Use mock for the logger in unit tests
jingjtang Jun 14, 2022
06875d7
include filename with errors
Jun 14, 2022
cdd0583
delete commented-out code
Jun 14, 2022
4f86e1e
Update logger info with variables
jingjtang Jun 14, 2022
747d580
Remove continue but check file links with .csv.gz
Jun 14, 2022
c0482c3
fix the error in switching to Mock in unittest.mock
Jun 14, 2022
ce1f45e
remove unused variables
Jun 14, 2022
2546cea
remove unused messages
Jun 14, 2022
cc8a6ad
save name with "v" instead of "wave"
nmdefries Jun 14, 2022
c0c6900
alphabetize item descriptions
nmdefries Jun 14, 2022
c00a72f
fill in TODOs
nmdefries Jun 14, 2022
aaf34ae
remove duplicates
nmdefries Jun 14, 2022
7adf66f
add too-few-public-methods back to message control for linting
Jun 14, 2022
c6b9ce4
Merge pull request #1631 from cmu-delphi/ndefries/translation-files-qids
krivard Jun 14, 2022
c33e1c5
Merge pull request #1642 from cmu-delphi/ndefries/fill-UMD-TODOs
krivard Jun 14, 2022
0c39be0
add logger info for files to download
Jun 15, 2022
c77c811
Update logger info for the latest claims file
jingjtang Jun 15, 2022
0be164c
update the function for renmaing the raw drops
Jun 15, 2022
2c9b21d
remove agg function
Jun 15, 2022
080ad45
update import info for the modification function
Jun 15, 2022
819b043
add j2 file for claims_hosp params
Jun 15, 2022
cfb682c
Manually merge vault changes
krivard Jun 15, 2022
a8c2a6e
Merge branch 'main' into productionize-claims_hosp
krivard Jun 15, 2022
6f4976c
Update logger info
jingjtang Jun 16, 2022
1c83ffd
add min_max_dates, csv_export_count, etc to logger info
Jun 16, 2022
50c93fb
update the unit test for modification of the raw files
Jun 17, 2022
300397f
fix the error in the unit test
Jun 17, 2022
76b4db0
rename the parameter for test_mode check
Jun 21, 2022
aef9511
Remove try/except from get_timestamp by converting to re
krivard Jun 22, 2022
170f2e3
Update expected file count for inpatient-only
krivard Jun 24, 2022
d1ffb14
Merge pull request #1644 from cmu-delphi/krivard/pch-no-general-except
krivard Jun 24, 2022
74cb9e1
Merge pull request #1408 from cmu-delphi/productionize-claims_hosp
krivard Jun 30, 2022
bbeba31
Rename with underscore
korlaxxalrok Jun 30, 2022
3590e64
Merge pull request #1651 from cmu-delphi/fix-ansible-template
korlaxxalrok Jun 30, 2022
8bb95a2
Update Sircal to silence fb-survey alerts
neul3 Jul 1, 2022
34e3087
Updated Dev Params
neul3 Jul 5, 2022
eb21217
Merge pull request #1652 from cmu-delphi/neul3/sir_complainsalot-para…
krivard Jul 5, 2022
f160459
chore: bump covidcast-indicators to 0.3.17
Jul 5, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[bumpversion]
current_version = 0.3.16
current_version = 0.3.17
commit = True
message = chore: bump covidcast-indicators to {new_version}
tag = False
12 changes: 12 additions & 0 deletions ansible/ansible-deploy-staging.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@
local_action: stat path="templates/{{ indicator }}-params-prod.json.j2"
register: template

- name: Check to see if we have a secrets template to send.
local_action: stat path="templates/{{ indicator }}-secrets-prod.py.j2"
register: template_secrets

- name: Set production params file.
copy:
src: files/{{ indicator }}-params-prod.json
Expand All @@ -42,3 +46,11 @@
owner: "{{ runtime_user }}"
group: "{{ runtime_user }}"
when: template.stat.exists

- name: Set production secrets template.
template:
src: templates/{{ indicator }}-secrets-prod.py.j2
dest: "{{ indicators_runtime_dir }}/{{ indicator }}/secrets.py"
owner: "{{ runtime_user }}"
group: "{{ runtime_user }}"
when: template_secrets.stat.exists
12 changes: 12 additions & 0 deletions ansible/ansible-deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@
local_action: stat path="templates/{{ indicator }}-params-prod.json.j2"
register: template

- name: Check to see if we have a secrets template to send.
local_action: stat path="templates/{{ indicator }}-secrets-prod.py.j2"
register: template_secrets

- name: Set production params file.
copy:
src: files/{{ indicator }}-params-prod.json
Expand All @@ -42,3 +46,11 @@
owner: "{{ runtime_user }}"
group: "{{ runtime_user }}"
when: template.stat.exists

- name: Set production secrets template.
template:
src: templates/{{ indicator }}-secrets-prod.py.j2
dest: "{{ indicators_runtime_dir }}/{{ indicator }}/secrets.py"
owner: "{{ runtime_user }}"
group: "{{ runtime_user }}"
when: template_secrets.stat.exists
43 changes: 43 additions & 0 deletions ansible/templates/claims_hosp-params-prod.py.j2
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
"common": {
"export_dir": "./receiving",
"log_exceptions": false
},
"indicator": {
"input_dir": "./retrieve_files",
"start_date": "2020-02-01",
"end_date": null,
"drop_date": null,
"n_backfill_days": 70,
"n_waiting_days": 3,
"write_se": false,
"obfuscated_prefix": "foo_obfuscated",
"parallel": false,
"geos": ["state", "msa", "hrr", "county"],
"weekday": [true, false],
"ftp_credentials": {
"host": "{{ claims_hosp_ftp_host }}",
"user": "{{ claims_hosp_ftp_user }}",
"pass": "{{ claims_hosp_ftp_password }}",
"port": 2222
}
},
"validation": {
"common": {
"data_source": "hospital-admissions",
"span_length": 14,
"min_expected_lag": {"all": "3"},
"max_expected_lag": {"all": "4"},
"dry_run": true,
"suppressed_errors": []
},
"static": {
"minimum_sample_size": 5,
"missing_se_allowed": true,
"missing_sample_size_allowed": true
},
"dynamic": {
"ref_window_size": 7
}
}
}
11 changes: 11 additions & 0 deletions ansible/templates/claims_hosp-secrets-prod.py.j2
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
class claims:
HOST = 'ftp.delphi.cmu.edu'
USER = {{ claims_hosp_ftp_user }}
PASS = {{ claims_hosp_ftp_password }}
PORT = 2222


class covidcast:
HOST = "delphi.midas.cs.cmu.edu"
USER = {{ claims_hosp_midas_user }}
PASS = {{ claims_hosp_midas_password }}
94 changes: 0 additions & 94 deletions ansible/templates/sir_complainsalot-params-prod.json.j2
Original file line number Diff line number Diff line change
Expand Up @@ -43,100 +43,6 @@
"maintainers": ["U01AP8GSWG3","U01069KCRS7"],
"retired-signals": ["completely_home_prop", "full_time_work_prop", "part_time_work_prop", "median_home_dwell_time", "completely_home_prop_7dav", "full_time_work_prop_7dav", "part_time_work_prop_7dav", "median_home_dwell_time_7dav"]
},
"fb-survey": {
"max_age": 3,
"maintainers": ["U01069KCRS7"],
"retired-signals": [
"smoothed_anxious_5d", "smoothed_wanxious_5d",
"smoothed_depressed_5d", "smoothed_wdepressed_5d",
"smoothed_felt_isolated_5d", "smoothed_wfelt_isolated_5d",
"smoothed_large_event_1d", "smoothed_wlarge_event_1d",
"smoothed_restaurant_1d", "smoothed_wrestaurant_1d",
"smoothed_shop_1d", "smoothed_wshop_1d",
"smoothed_spent_time_1d", "smoothed_wspent_time_1d",
"smoothed_travel_outside_state_5d", "smoothed_wtravel_outside_state_5d",
"smoothed_work_outside_home_1d", "smoothed_wwork_outside_home_1d",
"smoothed_wearing_mask", "smoothed_wwearing_mask",
"smoothed_vaccine_likely_local_health", "smoothed_wvaccine_likely_local_health",
"smoothed_others_masked", "smoothed_wothers_masked",
"smoothed_wanted_test_14d", "smoothed_wwanted_test_14d",
"smoothed_covid_vaccinated_or_accept", "smoothed_wcovid_vaccinated_or_accept",
"smoothed_accept_covid_vaccine", "smoothed_waccept_covid_vaccine",
"smoothed_hesitancy_reason_allergic", "smoothed_whesitancy_reason_allergic",
"smoothed_hesitancy_reason_not_recommended", "smoothed_whesitancy_reason_not_recommended",
"smoothed_hesitancy_reason_distrust_vaccines", "smoothed_whesitancy_reason_distrust_vaccines",
"smoothed_hesitancy_reason_health_condition", "smoothed_whesitancy_reason_health_condition",
"smoothed_hesitancy_reason_pregnant", "smoothed_whesitancy_reason_pregnant",
"smoothed_vaccine_likely_friends", "smoothed_wvaccine_likely_friends",
"smoothed_vaccine_likely_who", "smoothed_wvaccine_likely_who",
"smoothed_vaccine_likely_govt_health", "smoothed_wvaccine_likely_govt_health",
"smoothed_vaccine_likely_politicians", "smoothed_wvaccine_likely_politicians",
"smoothed_vaccine_likely_doctors", "smoothed_wvaccine_likely_doctors",
"smoothed_felt_isolated_7d", "smoothed_wfelt_isolated_7d",
"smoothed_worried_become_ill", "smoothed_wworried_become_ill",
"smoothed_received_2_vaccine_doses", "smoothed_wreceived_2_vaccine_doses",
"smoothed_hesitancy_reason_dislike_vaccines", "smoothed_whesitancy_reason_dislike_vaccines",
"smoothed_inperson_school_fulltime", "smoothed_winperson_school_fulltime",
"smoothed_inperson_school_parttime", "smoothed_winperson_school_parttime",
"smoothed_vaccinate_children", "smoothed_wvaccinate_children",
["smoothed_vaccine_barrier_appointment_time_tried", "msa", "county", "state"], ["smoothed_wvaccine_barrier_appointment_time_tried", "msa", "county", "state"],
["smoothed_vaccine_barrier_childcare_tried", "msa", "county", "state"], ["smoothed_wvaccine_barrier_childcare_tried", "msa", "county", "state"],
["smoothed_vaccine_barrier_document_tried", "msa", "county", "state"], ["smoothed_wvaccine_barrier_document_tried", "msa", "county", "state"],
["smoothed_vaccine_barrier_eligible_tried", "msa", "county", "state"], ["smoothed_wvaccine_barrier_eligible_tried", "msa", "county", "state"],
["smoothed_vaccine_barrier_language_tried", "msa", "county", "state"], ["smoothed_wvaccine_barrier_language_tried", "msa", "county", "state"],
["smoothed_vaccine_barrier_no_appointments_tried", "msa", "county", "state"], ["smoothed_wvaccine_barrier_no_appointments_tried", "msa", "county", "state"],
["smoothed_vaccine_barrier_none_tried", "msa", "county", "state"], ["smoothed_wvaccine_barrier_none_tried", "msa", "county", "state"],
["smoothed_vaccine_barrier_technical_difficulties_tried", "msa", "county", "state"], ["smoothed_wvaccine_barrier_technical_difficulties_tried", "msa", "county", "state"],
["smoothed_vaccine_barrier_technology_access_tried", "msa", "county", "state"], ["smoothed_wvaccine_barrier_technology_access_tried", "msa", "county", "state"],
["smoothed_vaccine_barrier_time_tried", "msa", "county", "state"], ["smoothed_wvaccine_barrier_time_tried", "msa", "county", "state"],
["smoothed_vaccine_barrier_travel_tried", "msa", "county", "state"], ["smoothed_wvaccine_barrier_travel_tried", "msa", "county", "state"],
["smoothed_vaccine_barrier_type_tried", "msa", "county", "state"], ["smoothed_wvaccine_barrier_type_tried", "msa", "county", "state"],
["smoothed_try_vaccinate_1m", "hrr"], ["smoothed_wtry_vaccinate_1m", "hrr"],
["smoothed_try_vaccinate_1m", "msa"], ["smoothed_wtry_vaccinate_1m", "msa"],
["smoothed_dontneed_reason_dont_spend_time", "hrr"], ["smoothed_wdontneed_reason_dont_spend_time", "hrr", "msa"],
["smoothed_dontneed_reason_had_covid", "hrr"], ["smoothed_wdontneed_reason_had_covid", "hrr", "msa"],
["smoothed_dontneed_reason_not_beneficial", "hrr"], ["smoothed_wdontneed_reason_not_beneficial", "hrr", "msa"],
["smoothed_dontneed_reason_not_high_risk", "hrr"], ["smoothed_wdontneed_reason_not_high_risk", "hrr", "msa"],
["smoothed_dontneed_reason_not_serious", "hrr"], ["smoothed_wdontneed_reason_not_serious", "hrr", "msa"],
["smoothed_dontneed_reason_other", "hrr"], ["smoothed_wdontneed_reason_other", "hrr", "msa"],
["smoothed_dontneed_reason_precautions", "hrr"], ["smoothed_wdontneed_reason_precautions", "hrr", "msa"],
"smoothed_screening_tested_positive_14d", "smoothed_wscreening_tested_positive_14d",
"smoothed_travel_outside_state_7d", "smoothed_wtravel_outside_state_7d",
"smoothed_belief_vaccinated_mask_unnecessary", "smoothed_wbelief_vaccinated_mask_unnecessary",
"smoothed_belief_children_immune", "smoothed_wbelief_children_immune",
"smoothed_received_2_vaccine_doses", "smoothed_wreceived_2_vaccine_doses",
"smoothed_vaccine_barrier_eligible", "smoothed_wvaccine_barrier_eligible",
"smoothed_vaccine_barrier_no_appointments", "smoothed_wvaccine_barrier_no_appointments",
"smoothed_vaccine_barrier_appointment_time", "smoothed_wvaccine_barrier_appointment_time",
"smoothed_vaccine_barrier_technical_difficulties", "smoothed_wvaccine_barrier_technical_difficulties",
"smoothed_vaccine_barrier_document", "smoothed_wvaccine_barrier_document",
"smoothed_vaccine_barrier_technology_access", "smoothed_wvaccine_barrier_technology_access",
"smoothed_vaccine_barrier_travel", "smoothed_wvaccine_barrier_travel",
"smoothed_vaccine_barrier_language", "smoothed_wvaccine_barrier_language",
"smoothed_vaccine_barrier_childcare", "smoothed_wvaccine_barrier_childcare",
"smoothed_vaccine_barrier_time", "smoothed_wvaccine_barrier_time",
"smoothed_vaccine_barrier_type", "smoothed_wvaccine_barrier_type",
"smoothed_vaccine_barrier_none", "smoothed_wvaccine_barrier_none",
"smoothed_vaccine_barrier_appointment_location", "smoothed_wvaccine_barrier_appointment_location",
"smoothed_vaccine_barrier_other", "smoothed_wvaccine_barrier_other",
"smoothed_vaccine_barrier_eligible_has", "smoothed_wvaccine_barrier_eligible_has",
"smoothed_vaccine_barrier_no_appointments_has", "smoothed_wvaccine_barrier_no_appointments_has",
"smoothed_vaccine_barrier_appointment_time_has", "smoothed_wvaccine_barrier_appointment_time_has",
"smoothed_vaccine_barrier_technical_difficulties_has", "smoothed_wvaccine_barrier_technical_difficulties_has",
"smoothed_vaccine_barrier_document_has", "smoothed_wvaccine_barrier_document_has",
"smoothed_vaccine_barrier_technology_access_has", "smoothed_wvaccine_barrier_technology_access_has",
"smoothed_vaccine_barrier_travel_has", "smoothed_wvaccine_barrier_travel_has",
"smoothed_vaccine_barrier_language_has", "smoothed_wvaccine_barrier_language_has",
"smoothed_vaccine_barrier_childcare_has", "smoothed_wvaccine_barrier_childcare_has",
"smoothed_vaccine_barrier_time_has", "smoothed_wvaccine_barrier_time_has",
"smoothed_vaccine_barrier_type_has", "smoothed_wvaccine_barrier_type_has",
"smoothed_vaccine_barrier_none_has", "smoothed_wvaccine_barrier_none_has",
"smoothed_vaccine_barrier_appointment_location_has", "smoothed_wvaccine_barrier_appointment_location_has",
"smoothed_vaccine_barrier_other_has", "smoothed_wvaccine_barrier_other_has",
["smoothed_vaccine_barrier_appointment_location_tried", "county", "state"], ["smoothed_wvaccine_barrier_appointment_location_tried", "county", "state"],
["smoothed_vaccine_barrier_other_tried", "county", "state"], ["smoothed_wvaccine_barrier_other_tried", "county", "state"]
]
},
"quidel": {
"max_age":6,
"maintainers": ["U01AP8GSWG3","U01069KCRS7"],
Expand Down
5 changes: 5 additions & 0 deletions ansible/vars.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,11 @@ changehc_sftp_host: "{{ vault_changehc_sftp_host }}"
changehc_sftp_port: "{{ vault_changehc_sftp_port }}"
changehc_sftp_user: "{{ vault_changehc_sftp_user }}"
changehc_sftp_password: "{{ vault_changehc_sftp_password }}"
# claims_hosp
claims_hosp_ftp_user: "{{ vault_claims_hosp_ftp_user }}"
claims_hosp_ftp_password: "{{ vault_claims_hosp_ftp_password }}"
claims_hosp_midas_user: "{{ vault_claims_hosp_midas_user }}"
claims_hosp_midas_password: "{{ vault_claims_hosp_midas_password }}"
# NCHS
nchs_mortality_token: "{{ vault_nchs_mortality_token }}"
# SirCAL
Expand Down
Loading