Repository navigation
bug fix when parameter model_dir is wrongly provided - #619
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Note Other AI code review bot(s) detectedCodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review. ✨ Finishing touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
PR Compliance Guide 🔍Below is a summary of compliance checks for this PR:
Compliance status legend🟢 - Fully Compliant🟡 - Partial Compliant 🔴 - Not Compliant ⚪ - Requires Further Human Verification 🏷️ - Compliance label |
||||||||||||||||||||||||
PR Code Suggestions ✨Explore these optional code suggestions:
|
|||||||||
There was a problem hiding this comment.
Pull request overview
This PR fixes parameter validation for ms2features_model_dir to prevent invalid values (empty strings, boolean true, or whitespace) from being passed to the ms2rescore command. The fix replaces a simple ternary operator with comprehensive validation logic that checks for null, boolean true, empty strings, and whitespace before constructing the command argument.
Key Changes
- Enhanced parameter validation with explicit null and boolean true checks
- Added string trimming and empty string detection to handle edge cases
- Included detailed comments explaining the validation logic
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
User description
PR checklist
nf-core pipelines lint).nextflow run . -profile test,docker --outdir <OUTDIR>).nextflow run . -profile debug,test,docker --outdir <OUTDIR>).docs/usage.mdis updated.docs/output.mdis updated.CHANGELOG.mdis updated.README.mdis updated (including new tool citations and authors/contributors).PR Type
Bug fix
Description
Fix parameter validation for
ms2features_model_dirto handle edge casesPrevent passing invalid values (empty strings, boolean true, whitespace)
Add robust null and type checking before constructing command argument
Diagram Walkthrough
File Walkthrough
main.nf
Enhance ms2features_model_dir parameter validationmodules/local/utils/msrescore_features/main.nf
validation logic
parameter values
cases