Skip to content

Conversation

@thaJeztah
Copy link
Member

These were deprecated in 6c400a9 (docker 19.03), but the "Deprecated:" comments were missing a newline before them.

While most IDEs will detect such comments as "deprecated", pkg.go.dev and linters will ignore them, which may result in users not being aware of them being deprecated.

This patch;

  • Fixes the "Deprecated:" comments.
  • Changes the var aliases to functions, which is slightly more boilerplating, but makes sure the functions are documented as "function", instead of shown in the "variables" section on pkg.go.dev.
  • Adds some punctuation and adds "doc links", which allows readers to navigate to related content on pkg.go.dev.

Before this patch:

https://pkg.go.dev/github.com/docker/[email protected]+incompatible/cli/command#InStream

Screenshot 2023-04-01 at 17 46 10

With this patch:

Screenshot 2023-04-01 at 18 11 12

Screenshot 2023-04-01 at 18 15 04

Screenshot 2023-04-01 at 18 33 25

- What I did

- How I did it

- How to verify it

- Description for the changelog

- A picture of a cute animal (not mandatory but encouraged)

These were deprecated in 6c400a9 (docker 19.03),
but the "Deprecated:" comments were missing a newline before them.

While most IDEs will detect such comments as "deprecated", pkg.go.dev and linters
will ignore them, which may result in users not being aware of them being deprecated.

This patch;

- Fixes the "Deprecated:" comments.
- Changes the var aliases to functions, which is slightly more boilerplating,
  but makes sure the functions are documented as "function", instead of shown
  in the "variables" section on pkg.go.dev.
- Adds some punctuation and adds "doc links", which allows readers to navigate
  to related content on pkg.go.dev.

Signed-off-by: Sebastiaan van Stijn <[email protected]>
(cherry picked from commit 817897f)
Signed-off-by: Sebastiaan van Stijn <[email protected]>
@codecov-commenter
Copy link

Codecov Report

Merging #4154 (6efc4ea) into 23.0 (3e7cbfd) will decrease coverage by 0.01%.
The diff coverage is 0.00%.

Additional details and impacted files
@@            Coverage Diff             @@
##             23.0    #4154      +/-   ##
==========================================
- Coverage   59.14%   59.13%   -0.01%     
==========================================
  Files         287      288       +1     
  Lines       24741    24745       +4     
==========================================
  Hits        14634    14634              
- Misses       9221     9225       +4     
  Partials      886      886              

@thaJeztah thaJeztah marked this pull request as ready for review April 3, 2023 09:19
@thaJeztah thaJeztah modified the milestones: 23.0.3, 23.0.4 Apr 4, 2023
@thaJeztah
Copy link
Member Author

@rumpl @vvoland ptal

@thaJeztah thaJeztah merged commit 06ab599 into docker:23.0 Apr 5, 2023
@thaJeztah thaJeztah deleted the 23.0_backport_fix_deprecation_message branch April 5, 2023 15:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants