-
Notifications
You must be signed in to change notification settings - Fork 1k
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
reviewing lockfiles for 2.0 #11135
reviewing lockfiles for 2.0 #11135
Conversation
what's the summary of the review? discussion is pretty long, it's hard to extract the final resolution |
It is a draft, it will be posted on the Tribe repo when ready, and most likely submitted to the mailing list |
conans/cli/commands/export.py
Outdated
add_lockfile_args(parser) | ||
parser.add_argument("-l", "--lockfile", action=OnceArgument, | ||
help="Path to a lockfile.") | ||
parser.add_argument("--lockfile-no-strict", action="store_true", |
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.
--lockfile-partial
?
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.
It could be a complete lockfile, but you changed one requires = xxx
in your recipe and use against the lockfile, want to "lock whatever you can, but if there is something you cannot lock, then evaluate it as normal". I am not sure -lockfile-partial
would be closer to that than no-strict
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.
"lock whatever you can, but if there is something you cannot lock, then evaluate it as normal"
So it applies the lockfile partially. Honestly, the strict
might mean anything.
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.
Good for me. @czoido @franramirez688 ? --lockfile-partial
better naming than --lockfile-no-strict
?
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.
I have to say I don't love --lockfile-partial
either... maybe we need more ideas.
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.
I have used --lockfile-partial
I agree it is slightly better than --lockfile-strict
in the meaning.
If anyone else got other ideas, they are welcome.
Review from Tribe proposal conan-io/tribe#34:
--lockfile=conan.lock
, automatically by commands that implement this argumentconan lock create
will also default to output "conan.lock", even without--lockfile-out
argument--lockfile-out
will allow to save a lockfile as a result, even if a lockfile was not provided as input--lockfile-no-strict
(arg name not great, we can try to think a better one) will allow non-lockedrequires
to not fail--clean
argument that was existing only forconan lock create
has been renamed to--lockfile-clean
, because it now can be used by the other commands that save a--lockfile-out
.Second round of review:
conan.lock
is assumed by default besides theconanfile
, not in thecwd
--lockfile-no-strict
=>--lockfile-partial
, it seems a bit more aligned with the actual behavior