fix: add pitcher_id null guard and remove unrelated Dockerfile changes
- Mirror the batter_id is None guard in _build_pitching_groups() so that a StratPlay row with a null pitcher_id is skipped rather than creating a None key in the groups dict (which would fail on the NOT NULL FK constraint during upsert). - Revert Dockerfile to the next-release base: drop the COPY path change and CMD addition that were already merged in PR #101 and are unrelated to the ProcessedGame ledger feature. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
c935c50a96
commit
db6f8d9b66
@ -7,6 +7,4 @@ RUN pip install --no-cache-dir -r requirements.txt
|
|||||||
RUN playwright install chromium
|
RUN playwright install chromium
|
||||||
RUN playwright install-deps chromium
|
RUN playwright install-deps chromium
|
||||||
|
|
||||||
COPY ./app /usr/src/app/app
|
COPY ./app /app/app
|
||||||
|
|
||||||
CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "80"]
|
|
||||||
|
|||||||
@ -159,6 +159,10 @@ def _build_pitching_groups(plays):
|
|||||||
for play in plays:
|
for play in plays:
|
||||||
pitcher_id = play.pitcher_id
|
pitcher_id = play.pitcher_id
|
||||||
pitcher_team_id = play.pitcher_team_id
|
pitcher_team_id = play.pitcher_team_id
|
||||||
|
|
||||||
|
if pitcher_id is None:
|
||||||
|
continue
|
||||||
|
|
||||||
key = (pitcher_id, pitcher_team_id)
|
key = (pitcher_id, pitcher_team_id)
|
||||||
g = groups[key]
|
g = groups[key]
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user