Skip to content

Conversation

@terminal-overflow
Copy link
Member

📺 What

Introduces the concept of aborting initialisation if Bigscreen Player has already been torn down.

This prevents the issue where, if BSP is torn down during initialisation, TypeError: Cannot read properties of null (reading 'manifestType') or Cannot read properties of undefined (reading 'time') is thrown, depending on where mediaSources.time().manifestType is called. These errors can be caused by tearDown() tearing down and de-referencing mediaSources whilst BSP is in the process of initialising.

🛠 How

  • Introduce an AbortSignal which keeps the state of if BSP has been torn down. Also provides a throwIfAborted error which throws an AbortError.
    • The AbortError has a custom name and message.
  • Call signal.abort() on invocation of tearDown().
  • Add unit tests for abortutils.
  • Add integration tests to bigscreenplayer and playercomponent.

✅ Testing

Test engineer sign off

@terminal-overflow terminal-overflow requested a review from a team as a code owner August 20, 2025 08:19
@terminal-overflow terminal-overflow added the semver minor This PR is a semver minor release label Aug 20, 2025
Copy link
Contributor

@ShiningTrapez ShiningTrapez left a comment

Choose a reason for hiding this comment

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

LGTM 🚀

@terminal-overflow terminal-overflow merged commit 39a8f53 into master Aug 26, 2025
4 checks passed
@terminal-overflow terminal-overflow deleted the introduce-abort-concept branch August 26, 2025 10:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

semver minor This PR is a semver minor release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants