nibcq.errors.SwitchConfigurationError

exception nibcq.errors.SwitchConfigurationError(message: str = 'The switch configuration is invalid or incompatible with the test requirements.')

Bases: BCQError

Exception raised when there is an issue with the switch configuration.

This error occurs when the switch settings are invalid or incompatible with the test requirements.

Parameters:

message (str, optional) – Custom error message. Defaults to a standard message.

Examples

The following are examples of how this error can be raised:

  • General configuration issue

    >>> raise SwitchConfigurationError(
    >>>     "The switch configuration is invalid or
    >>>     incompatible with the test requirements."
    >>> )
    
  • Invalid DUT channel names

    >>> raise SwitchConfigurationError(
    >>>     f"The following DUT channel names are invalid: {invalid_dut_channels}.
    >>>     Allowed: ch0-ch63."
    >>> )
    
  • Invalid sense/source channel names

    >>> raise SwitchConfigurationError(
    >>>     f"The following sense/source channel names
    >>>     are invalid: {invalid_sense_channels}."
    >>> )
    
  • Invalid channel pairs

    >>> raise SwitchConfigurationError(
    >>>     f"The following channel pairs are invalid: {invalid_channel_pairs}."
    >>> )