Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

chore: require kwargs forutils.copy_dict()#1871

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
nejch merged 1 commit intomainfromjlvillal/copy_dict
Feb 3, 2022
Merged

Conversation

JohnVillalovos
Copy link
Member

@JohnVillalovosJohnVillalovos commentedFeb 2, 2022
edited
Loading

The non-keyword arguments were a tiny bit confusing as the destination was
first and the source was second.

Change the order and require key-word only arguments to ensure we
don't silently break anyone.

@codecov-commenter
Copy link

codecov-commenter commentedFeb 2, 2022
edited
Loading

Codecov Report

Merging#1871 (7cf35b2) intomain (64d01ef) willnot change coverage.
The diff coverage is100.00%.

@@           Coverage Diff           @@##             main    #1871   +/-   ##=======================================  Coverage   92.51%   92.51%           =======================================  Files          78       78             Lines        4878     4878           =======================================  Hits         4513     4513             Misses        365      365
FlagCoverage Δ
cli_func_v481.59% <75.00%> (ø)
py_func_v480.42% <100.00%> (ø)
unit83.37% <75.00%> (ø)

Flags with carried forward coverage won't be shown.Click here to find out more.

Impacted FilesCoverage Δ
gitlab/client.py90.55% <100.00%> (ø)
gitlab/utils.py87.09% <100.00%> (ø)

@nejch
Copy link
Member

Non-keyword arguments are a tiny bit confusing as the destination is first and the source is second.

Should we switch them everywhere? If someone uses this undocumented function outside the library I would be slightly confused :D

@JohnVillalovos
Copy link
MemberAuthor

Non-keyword arguments are a tiny bit confusing as the destination is first and the source is second.

Should we switch them everywhere? If someone uses this undocumented function outside the library I would be slightly confused :D

Sorry I don't understand? Switch what everywhere?

Maybe my description should have been:

The non-keyword argument order inutils.copy_dict() is confusing as the destination is first and the source is second.

@nejch
Copy link
Member

I understand, but since we're already making a breaking change by introducing required keyword arguments, we can also switch them to be src first, dest, second - both in the definition and when they're called. Would that make sense?

@JohnVillalovos
Copy link
MemberAuthor

I guess I don't think of it as a breaking change. But maybe that means we need to define what is considered a breaking change.

What part of the API do we consider covered for it be a breaking change? We probably need to document that. I don't think an internal utility library function is part of our API.

@nejch
Copy link
Member

I guess I don't think of it as a breaking change. But maybe that means we need to define what is considered a breaking change.

What part of the API do we consider covered for it be a breaking change? We probably need to document that. I don't think an internal utility library function is part of our API.

Sorry, I wasn't super clear there, I didn't mean something user-facing or to add to the changelog, just that the way the function can be used now has changed. So if we're already doing that, we can also correct the order and switch the args :)

JohnVillalovos reacted with thumbs up emoji

@JohnVillalovos
Copy link
MemberAuthor

Sorry, I wasn't super clear there, I didn't mean something user-facing or to add to the changelog, just that the way the function can be used now has changed. So if we're already doing that, we can also correct the order and switch the args :)

Ah! That makes total sense to me 👍

The non-keyword arguments were a tiny bit confusing as the destination wasfirst and the source was second.Change the order and require key-word only arguments to ensure wedon't silently break anyone.
@nejchnejch merged commit2adf31d intomainFeb 3, 2022
@nejchnejch deleted the jlvillal/copy_dict branchFebruary 3, 2022 22:16
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@JohnVillalovos@codecov-commenter@nejch

[8]ページ先頭

©2009-2025 Movatter.jp