ci: ignore SC2317 only for functestlib shell library#470
Merged
Conversation
Runner/utils contains sourced helper libraries whose functions are called indirectly by suite run.sh files. When these libraries are linted as standalone shell files, ShellCheck can report SC2317 even though the functions are reachable from tests. Update the ShellCheck workflow to use a per-file lint policy: - ignore SC2317 for sourced utility libraries - keep SC2317 enabled for standalone scripts and suite run.sh files Library mode applies only to: - Runner/utils/functestlib.sh - Runner/utils/lib_*.sh - Runner/utils/*_common.sh This keeps unreachable-code detection enabled for normal test scripts while avoiding false failures for shared sourced libraries. Signed-off-by: Srikanth Muppandam <smuppand@qti.qualcomm.com>
bhargav0610
approved these changes
Jun 3, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Update the ShellCheck workflow to handle
SC2317only forRunner/utils/[functestlib.sh](http://functestlib.sh/).[functestlib.sh](http://functestlib.sh/)is a sourced helper library used by many suite[run.sh](http://run.sh/)tests. Some helper functions are invoked indirectly, so ShellCheck can reportSC2317when the library is linted as a standalone shell file.All other shell files remain under the existing strict ShellCheck policy.Update the ShellCheck workflow to handle
SC2317only forRunner/utils/[functestlib.sh](http://functestlib.sh/).[functestlib.sh](http://functestlib.sh/)is a sourced helper library used by many suite[run.sh](http://run.sh/)tests. Some helper functions are invoked indirectly, so ShellCheck can reportSC2317when the library is linted as a standalone shell file.All other shell files remain under the existing strict ShellCheck policy.