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

Replace empty collection comparisons w/ a more idiomatic unary operator #70

Merged
merged 5 commits into from
Jun 3, 2022
Merged

Replace empty collection comparisons w/ a more idiomatic unary operator #70

merged 5 commits into from
Jun 3, 2022

Conversation

ThibFrgsGmz
Copy link
Contributor

Originating Project/Creator @ThibFrgsGmz
Affected Component fbuild
Affected Architectures(s) (void )
Related Issue(s) (void)
Has Unit Tests (y/n) n
Builds Without Errors (y/n) y
Unit Tests Pass (y/n) see CI results
Documentation Included (y/n) n

Change Description

This PR aims to replace the comparison of empty collections with a more idiomatic unary operator.

Rationale

This refactoring follows the PEP 8 programming recommendations, in particular the following recommendation: For sequences, (strings, lists, tuples), use the fact that empty sequences are false in the context of comparisons.

Testing/Review Recommendations

(void)

Future Work

(void)

@lgtm-com
Copy link

lgtm-com bot commented May 22, 2022

This pull request introduces 1 alert when merging 225ba2e into 2b81916 - view on LGTM.com

new alerts:

  • 1 for Syntax error

src/fprime/fbuild/settings.py Show resolved Hide resolved
src/fprime/fbuild/interaction.py Outdated Show resolved Hide resolved
src/fprime/fbuild/cmake.py Outdated Show resolved Hide resolved
@LeStarch LeStarch closed this May 31, 2022
@LeStarch LeStarch reopened this May 31, 2022
@LeStarch LeStarch merged commit 9c5efe5 into nasa:devel Jun 3, 2022
@ThibFrgsGmz ThibFrgsGmz deleted the feat/simplify-empty-collection-comparison branch July 20, 2022 21:27
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.

None yet

2 participants