feat: [sc-29033] drop Package.resolved#348
Conversation
Summary of ChangesHello @supersonicbyte, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request streamlines the dependency management process by removing the Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request removes the Package.resolved file to facilitate CI testing across multiple Swift versions. While testing against newer dependencies is a good goal, removing this file sacrifices reproducible builds, which can lead to unexpected build failures and inconsistencies between developer environments and CI. I've added a comment suggesting an alternative approach that maintains build reproducibility while still allowing for testing against updated dependencies.
I am having trouble creating individual review comments. Click here to see my feedback.
Package.resolved (1-68)
Removing Package.resolved will lead to non-reproducible builds. While the goal of testing against multiple Swift versions and newer dependencies is valid, this approach can introduce instability. Every time a developer or CI runs swift build on a clean checkout, it might fetch different versions of dependencies, potentially causing unexpected build failures or behavior changes.
I also noticed that Benchmarks/Package.resolved is not being removed. For consistency, you should decide on a single strategy for all Package.resolved files in the repository.
A better approach to achieve your goal without sacrificing reproducibility is to:
- Keep
Package.resolvedin your source control. This ensures all developers and CI jobs use the exact same dependency versions, guaranteeing reproducible builds. - Create a separate, scheduled CI job (e.g., nightly or weekly) that runs
swift package updateto get the latest versions of dependencies. - This job would then run your full test suite against these new versions.
- If the tests pass, the job could automatically create a pull request with the updated
Package.resolvedfile for review and merging.
This strategy provides the best of both worlds: stable, reproducible builds for day-to-day development and a controlled process for testing and integrating dependency updates.
|
Pull request had an unknown failure |
Description
We are dropping
Package.resolvedin favor of running CI jobs across multiple swift versions.How Has This Been Tested?
Please describe the tests that you ran to verify your changes.
Minimal checklist:
DocCcode-level documentation for any public interfaces exported by the package