-
Notifications
You must be signed in to change notification settings - Fork 87
Update Python scripts and enhance dependency management #1412
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
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR improves Python scripts for package management by fixing regex patterns, adding functions to dynamically retrieve package versions from common.vm
and nodejs.vm
, and introducing a new method to update metapackage dependencies.
- Enhanced regex pattern in
update_dependencies
to handle optional whitespace - Added
update_metapackage_dependencies
function for packages with single dependencies - Created dynamic version retrieval functions for
common.vm
andnodejs.vm
packages
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.
File | Description |
---|---|
scripts/utils/update_package.py | Fixed regex pattern and added metapackage dependency update functionality |
scripts/utils/create_package_template.py | Added dynamic version retrieval functions and updated templates to use dynamic versions |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
for line in f: | ||
if "<version>" in line: | ||
return line.split("<version>")[1].split("</version>")[0].strip() | ||
return "0.0.0.20250206" # Default version if version tag is not found |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The hardcoded default version should be a constant or configuration value to avoid magic numbers and ensure consistency across the codebase.
Copilot uses AI. Check for mistakes.
for line in f: | ||
if "<version>" in line: | ||
return line.split("<version>")[1].split("</version>")[0].strip() | ||
return "0.0.0.20250219" # Default version if version tag is not found |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The hardcoded default version should be a constant or configuration value to avoid magic numbers and ensure consistency across the codebase.
Copilot uses AI. Check for mistakes.
Improve Python scripts by fixing issues and adding functions to retrieve package versions from
common.vm
andnodejs.vm
. Introduce a new method to update metapackage dependencies based on the latest available versions.