Skip to content

Commit

Permalink
Reduce default extract size to last 30 days
Browse files Browse the repository at this point in the history
Change default start_date for download_pmhc_mds function to 30 days
before the current date.
  • Loading branch information
daviewales committed Dec 6, 2023
1 parent 595eb46 commit 8de8311
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/pmhclib/pmhc.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import shutil
import time
from dataclasses import dataclass
from datetime import datetime, date
from datetime import datetime, date, timedelta
from enum import Enum, unique
from getpass import getpass
from pathlib import Path
Expand Down Expand Up @@ -314,16 +314,16 @@ def is_upload_processing(self) -> bool:
def download_pmhc_mds(
self,
output_directory: Path = Path("."),
start_date: date = date(2016, 1, 1),
start_date: date = date.today() - timedelta(days=30),
end_date: date = date.today(),
organisation_path: Optional[str] = None,
specification: PMHCSpecification = PMHCSpecification.ALL,
without_associated_dates: bool = True,
matched_episodes: bool = True,
) -> Path:
"""Extract PMHC MDS Data within the date range. If no date range
is given, `start_date` defaults to `2016-01-01` and `end_date`
defaults to the current date.
is given, `start_date` defaults to 30 days before the current
date and `end_date` defaults to the current date.
:param output_directory: directory to save download
:param start_date: start date for extract
Expand Down

0 comments on commit 8de8311

Please sign in to comment.