GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Copy the api/types/time package to internal client/daemon packages by austinvazquez · Pull Request #50722 · moby/moby

Conversation

@austinvazquez

@austinvazquez austinvazquez commented Aug 13, 2025 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

- What I did
1/2 for #50718

This change copies the api/types/time package into internal packages for the client and daemon. The package does not define any types but provided some utilities for format-handling of timestamps.

- How I did it

- How to verify it

- Human readable description for the release notes

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

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@austinvazquez austinvazquez added area/api API area/daemon Core Engine area/go-sdk labels Aug 13, 2025
@austinvazquez
austinvazquez force-pushed the deconstruct-api-types-time branch from 536025a to 9004cab Compare August 13, 2025 22:06
@thaJeztah

thaJeztah commented Aug 13, 2025

Copy link
Copy Markdown
Member

Git gets a bit confused because it tries to keep history, but has to decide "did it move to daemon/internal or client/internal ?

Perhaps we should have 2 commits in this PR; one that moves it to either daemon or client, and a second commit that creates a copy for the other.

(not sure which one is best to use for the "move" - ideally we'd pick the one where it's most likely to "stay", so that that one can be used to preserve history)

austinvazquez reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@thaJeztah

thaJeztah commented Aug 13, 2025

Copy link
Copy Markdown
Member

Thinking of that; perhaps the daemon/internal would be best for the move, because that would only have a "move" (no duplication in the vendor/ directory). For the client one, it likely would be harder to keep track as it (again) would have to chose "did it move to vendor/xxx or did it move to client/xxx ?)

(hope I make sense!)

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@austinvazquez

austinvazquez commented Aug 13, 2025 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor Author

Yep makes sense. Ironically I had that at first but ended up squashing as I thought there would be a broken commit. Although now I realize client is a module pointing to a point in time of API so it should be fine if I do the daemon first as you said.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@thaJeztah

thaJeztah commented Aug 13, 2025

Copy link
Copy Markdown
Member

Yeah, I don't think there's a "best" option, and of course there's still git history. But I suspect the move to daemon will preserve that history best because it's a literal move.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@austinvazquez
austinvazquez force-pushed the deconstruct-api-types-time branch 2 times, most recently from eb6d49d to 4f1e1be Compare August 14, 2025 12:43
@thompson-shaun
thompson-shaun requested a review from Copilot August 14, 2025 12:45
Copilot AI reviewed Aug 14, 2025
View reviewed changes

Copilot AI left a comment

Copy link
Copy Markdown

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 copies the api/types/time package into internal packages for both the client and daemon components. The purpose is to remove the external dependency on the shared API types package by creating internal copies of timestamp utility functions.

Key changes:

  • Created internal timestamp packages for both client and daemon with identical functionality
  • Updated all import references from github.com/moby/moby/api/types/time to the new internal package paths
  • Changed package names from time to timestamp to avoid naming conflicts

Reviewed Changes

Copilot reviewed 19 out of 25 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
daemon/internal/timestamp/timestamp.go New internal timestamp utilities package for daemon
daemon/internal/timestamp/timestamp_test.go Test file for daemon timestamp package
client/internal/timestamp/timestamp.go New internal timestamp utilities package for client
client/internal/timestamp/timestamp_test.go Test file for client timestamp package
Multiple daemon files Updated imports to use new internal timestamp package
Multiple client files Updated imports to use new internal timestamp package

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread daemon/cluster/executor/container/adapter.go Resolved

Uh oh!

There was an error while loading. Please reload this page.

@austinvazquez
austinvazquez marked this pull request as ready for review August 14, 2025 12:54
austinvazquez added 2 commits August 14, 2025 07:56
@austinvazquez
Move the api/types/time package to internal daemon package
812aa46
Signed-off-by: Austin Vazquez <[email protected]>
@austinvazquez
Copy the daemon/internal/timestamp package to internal client package
aa80ad2
This change copies the daemon/internal/timestamp package (previously api/types/time) to an internal client package and updates the client usage for GetTimestamp functionality.

Signed-off-by: Austin Vazquez <[email protected]>
@austinvazquez
austinvazquez force-pushed the deconstruct-api-types-time branch from 4f1e1be to aa80ad2 Compare August 14, 2025 13:27
thaJeztah
thaJeztah approved these changes Aug 14, 2025
View reviewed changes

@thaJeztah thaJeztah left a comment

Copy link
Copy Markdown
Member

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.

LGTM, thanks!

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@austinvazquez austinvazquez mentioned this pull request Aug 14, 2025
deconstruct api/types/time, move internal to daemon and client #50718
Open
@thaJeztah thaJeztah added release-blocker PRs we want to block a release on status/2-code-review labels Aug 14, 2025
@thaJeztah thaJeztah added this to the 29.0.0 milestone Aug 14, 2025
vvoland
vvoland approved these changes Aug 14, 2025
View reviewed changes
@austinvazquez
austinvazquez merged commit 823f61a into moby:master Aug 14, 2025
@austinvazquez
austinvazquez deleted the deconstruct-api-types-time branch August 14, 2025 15:03
This was referenced Sep 5, 2025
Prepare release notes for api/v1.52.0-beta.0 #50904
Merged
Prepare release notes for client/v0.1.0-beta.0 #50913
Merged
@dmcgowan dmcgowan mentioned this pull request Sep 24, 2025
Prepare release notes for api/v1.52.0-rc.0 #51030
Closed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

Copilot code review Copilot
Copilot review effort
Applies to this pull request for everyone.Learn more about Copilot code review.
Copilot left review comments
@thaJeztah thaJeztah thaJeztah approved these changes
@vvoland vvoland vvoland approved these changes

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

area/api API area/daemon Core Engine area/go-sdk release-blocker PRs we want to block a release on status/2-code-review

Projects

None yet

Milestone

29.0.0

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

4 participants

@austinvazquez @thaJeztah @vvoland
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.