Skip to content

Conversation

@x15sr71
Copy link

@x15sr71 x15sr71 commented Jan 9, 2026

In raising this pull request, I confirm the following (please check boxes):

  • I have read and understood the contributors guide.
  • I have checked that another pull request for this purpose does not exist.
  • I have considered, and confirmed that this submission will be valuable to others.
  • I accept that this submission may not be used, and the pull request closed at the will of the maintainer.
  • I give this submission freely, and claim no ownership to its content.

My familiarity with the project is as follows (check one):

  • I have never used the project.
  • I have used the project briefly.
  • I have used the project extensively, but have not contributed previously.
  • I am an active contributor to the project.

Summary

Add regression test coverage for ATSC XMLTV output generation (--xmltv=1) using the ATSC broadcast sample I uploaded to the platform.

This test exercises

  • ATSC PSI/SI table parsing (VCT, ETT, EIT)
  • XMLTV format generation from broadcast EPG data
  • Exit code validation (expected_rc=5) with OutputType.null

Technical Details

Sample Selection

Sample 187 (ch29FullTS.ts) – newly added ATSC broadcast sample specifically for XMLTV testing with parameters: --xmltv=1 --out=null:

  • SHA256: 6b10f8aef895469ec9cb89ecd0c2463eb2442052c32da9d81c6a6f5cec9137b8

  • Size: 300.52 MB | Duration: 2m 10s
    ATSC PSI/SI Tables:

  • Virtual Channel Table (VCT) - channels 5.1-5.5 (KPIX-TV, StartTV, etc.)

  • Extended Text Table (ETT) - program titles/descriptions

  • Event Information Table (EIT) - multi-day EPG scheduling

  • EIA-608/708 captions across 5 video PIDs

I reviewed the TS samples currently available on the platform and did not find any that appear to contain the ATSC PSI/SI tables (VCT, EIT, ETT) needed to exercise the ATSC XMLTV generation paths introduced and extended in recent XMLTV fixes. For this reason, I recently added an ATSC broadcast sample to the Sample Platform and use it here to provide regression coverage for the relevant XMLTV code paths.

Sample PSI/SI Tables EIA-608/708 Suitable for XMLTV?
Korean 708 None 708 No PSI tables
Japan Show None None No PSI tables
Short TS None None No PSI tables
VLC broken None 608/708 No PSI tables
Long ATSC None 608/708 No PSI tables

Database Deployment Strategy

Following @canihavesomecoffee review WebVTT PR:

Deployment strategy:

  • Production instances: Registers an ATSC XMLTV regression using sample 187 via Alembic migration.
  • Fresh installs / CI: No XMLTV regression is registered; only existing lightweight samples are used to avoid foreign-key issues and keep setup and tests fast.
Environment Sample Used Mechanism Purpose
Production sample 187 Alembic migration Real ATSC XMLTV validation
Fresh install samples 1-2 install/sample_db.py Bootstrap without FK errors
CI Tests samples 1-2 tests/base.py fixtures Fast smoke tests

Test characteristics

  • OutputType.null: Exit-code–only validation (no golden file)
  • ignore_parse_errors = true: Robust to content differences
  • expected_rc = 5: ATSC XMLTV processing return code
  • Idempotent: Migration checks for existing regression test before inserting (no-op on re-run)

Related Work

@sonarqubecloud
Copy link

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.

1 participant