Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow invalid tone #77

Merged
merged 7 commits into from
Aug 29, 2021
Merged

Allow invalid tone #77

merged 7 commits into from
Aug 29, 2021

Conversation

masenf
Copy link
Collaborator

@masenf masenf commented Aug 29, 2021

Address #76 by allowing the user to specify REQUIRE_VALID_TONE=0 in the environment when generating the codeplug files.

masenf added 7 commits August 29, 2021 09:55
conversion function to retrieve a boolean
value from an environment variable.
environment variable REQUIRE_VALID_TONE specifies
whether tones are strictly checked for valid
entries.

in some situations, the user may want to pass
tones through that are not recognized by all
supported targets.
if REQUIRE_VALID_TONE is False, then simply
log a warning instead of raising an exception.
Log a warning if the user allows invalid tones
by setting REQUIRE_VALID_TONE=0 in the env.

This will help during troubleshooting to
understand why codeplug files may not be valid.
Extend existing test_analog_weird_values
to run with and without REQUIRE_VALID_TONES.

If valid tones are not required, then assert
that the channels were created with invalid
tones.
Parametrize test_getenv_bool with various
allowed, unknown, and default values.
Avoid issues where the value specified in the
CSV uses a different case than expected.
@masenf masenf merged commit 7807632 into mycodeplug:main Aug 29, 2021
@masenf masenf deleted the allow-invalid-tone branch August 29, 2021 17:05
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