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

edk2_invocable.py: catch invalid arguments #753

Merged
merged 2 commits into from
Feb 20, 2024

Conversation

Javagedes
Copy link
Contributor

@Javagedes Javagedes commented Feb 15, 2024

  1. updates edk2_invocable.py to catch any unexpected argument that start with either a "-" or "/" rather than just "-". This is due to the fact that "/" is a common argument prefix for executables.
  2. Changes the RuntimeError exception to a print statement and an exit command as this is an expected possible user error and a print of the backtrace is unnecessary.

@Javagedes Javagedes added the enhancement New feature or request label Feb 15, 2024
@Javagedes Javagedes requested review from makubacki and apop5 February 15, 2024 22:29
Copy link

codecov bot commented Feb 15, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (bf643b0) 78.75% compared to head (83181f5) 78.75%.
Report is 15 commits behind head on master.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #753   +/-   ##
=======================================
  Coverage   78.75%   78.75%           
=======================================
  Files          49       49           
  Lines        4909     4910    +1     
=======================================
+ Hits         3866     3867    +1     
  Misses       1043     1043           
Files Coverage Δ
edk2toolext/edk2_invocable.py 75.54% <100.00%> (+0.13%) ⬆️

updates edk2_invocable.py to catch any unexpected argument that start
with either a "-" or "/" rather than just "-". This is due to the fact
that "/" is a common argument prefix for executables.
@Javagedes Javagedes force-pushed the invalid-param-bugfix branch from 67da131 to 83181f5 Compare February 20, 2024 20:26
@Javagedes Javagedes added this to the 0.27.3 milestone Feb 20, 2024
@Javagedes Javagedes merged commit 4538a1b into tianocore:master Feb 20, 2024
25 checks passed
@Javagedes Javagedes deleted the invalid-param-bugfix branch February 20, 2024 21:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants