Skip to content

Conversation

cpsievert
Copy link
Collaborator

Closes #400
Closes #404

This PR does 2 things:

  1. Throws a warning when a reactive read (e.g., input.val()) results in a SilentException. This most commonly occurs when attempting to read an input that doesn't exist in the UI. Since this behavior is sometimes desirable (mainly for dynamic UI reasons), the warning can be suppressed via input.val(warn_if_missing=False).
  2. Adds a default parameter to reactive reads (e.g., input.val(default=None)). When provided, and the read produces a MISSING value, the default value is returned instead of raising a SilentException.

@cpsievert cpsievert requested a review from Copilot October 16, 2025 14:46
Copilot

This comment was marked as resolved.

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.

Accessing an empty reactive Value raises a SilentException If an nonexistent input is accessed in an output, no error is printed

1 participant