Bug: Argentina preprocess doesn´t skip based on variable
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 52/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Stale
- Tech stack
- python
- Domain
- data-engineering
Research direction
Open preprocess_flow.py and inspect the loop around lines 188-194. Compare the date-selection pattern in aggregate_products_flow.py and insert_products_flow.py, then verify that dates after LAST_PREPROCESS_SUCCESS_DATE are considered while already processed dates remain skipped.
Written by the indexing model from the issue text.
Description
Problem
preprocess_flow.py processes ALL available dates instead of respecting LAST_PREPROCESS_SUCCESS_DATE like other Argentina flows do.
Current behavior (line 188-194):
for date in self.raw_provider.list_available_keys():
if self.processed_provider.exists(date):
continue
await self.process_date(date)
Expected behavior: Filter dates by LAST_PREPROCESS_SUCCESS_DATE first, then check if already processed.
Solution
Add date filtering before the loop:
last_preprocess_date = await variables.Variable.aget(
ArgentinaFlowVariableNames.LAST_PREPROCESS_SUCCESS_DATE,
default=ArgentinaFlowVariableNames.DEFAULT_DATE
)
dates_to_process = [d for d in self.raw_provider.list_available_keys() if d > last_preprocess_date]
This matches the pattern already used in aggregate_products_flow.py and insert_products_flow.py.
- Dominant language
- Python
- Stars
- 0
- Forks
- 3
- Avg merge
- 2h 9m
- Merged PRs (30d)
- 1
Getting set up
- Ships a Dockerfile or Docker Compose file
- No pull request template
- No contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from trufnetwork/adapters
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
trufnetwork/adapters#213 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
trufnetwork/adapters#202 ·
-
Difficulty 5/5 Over a week Newbie friendliness 15/100
trufnetwork/adapters#151 · 1 comment ·
-
Difficulty 4/5 3-5 days Newbie friendliness 20/100
trufnetwork/adapters#72 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 20/100
trufnetwork/adapters#71 ·
All issues in trufnetwork/adapters
Similar issues
-
bug server
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
sportsdataverse/sportsdataverse-py#641 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
googleapis/google-cloud-python#18532 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day