Skip to content

Fix play-by-play special teams and LCB output - #48

Closed
tpitzel wants to merge 1 commit into
CalebRose:masterfrom
tpitzel:agent/upstream-fix-pbp-special-teams-and-lcb
Closed

Fix play-by-play special teams and LCB output#48
tpitzel wants to merge 1 commit into
CalebRose:masterfrom
tpitzel:agent/upstream-fix-pbp-special-teams-and-lcb

Conversation

@tpitzel

@tpitzel tpitzel commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

What changed

  • Use the play-by-play ResultYards value directly when narrating punt and kickoff returns in both result and stream output.
  • Normalize the legacy Fcb participant field into Lcb, return Lcb from play-by-play responses, and export the LCB value in NFL play-by-play CSVs.
  • Correct the IsRight field mapping and a right-miss field-goal narration string.

Why

The engine already supplies return distance directly through ResultYards, but the API was reconstructing return yardage from field-position coordinates. That produced narration which disagreed with the numeric play result and ensuing field position. The cornerback participant also existed under both Fcb and Lcb, while the export path continued reading the legacy name.

Impact

New and historical play-by-play responses generated from stored direct-return-yard data will report punt and kickoff returns consistently. LCB participant IDs will also be exposed under the expected field without breaking records that still contain the legacy Fcb value.

Checks

  • go test ./...
  • git diff --check upstream/master...HEAD
  • GitHub Actions completed the Go build successfully. The subsequent Azure registry login failed because deployment secrets are unavailable to the fork pull-request run (blank registry username/password), not because of a source or build failure.

@CalebRose CalebRose left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved. Just to confirm, does the build successfully run locally?

@tpitzel

tpitzel commented Jul 20, 2026

Copy link
Copy Markdown
Contributor Author

Approved. Just to confirm, does the build successfully run locally?

Yes, that's why I was confused that punt returns still were off in this past weekends games because they look right locally. Then I had codex discover that change wasn't in master and fired this pull request off

@tpitzel

tpitzel commented Jul 25, 2026

Copy link
Copy Markdown
Contributor Author

Superseded by #50, rebuilt from current master as a ready-for-review one-file PR containing only the punt and kickoff return-yard narration fix. The unrelated LCB/field-mapping cleanups from this draft are intentionally not included in #50 and can be handled separately.

@tpitzel tpitzel closed this Jul 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants