Skip to content

Renaming time stamp field in API responses#2979

Open
jpodivin wants to merge 1 commit intopackit:mainfrom
jpodivin:timestamps/api
Open

Renaming time stamp field in API responses#2979
jpodivin wants to merge 1 commit intopackit:mainfrom
jpodivin:timestamps/api

Conversation

@jpodivin
Copy link
Contributor

@jpodivin jpodivin commented Feb 4, 2026

I don't think it's necessary, nor wise, to merge this immediately. Since it is change to API and could break integration.

But it would be good to have the PR ready when the time comes.

RELEASE NOTES BEGIN

The build_submitted_time of responses from following API endpoints has been renamed to submitted_time.

  • copr-builds
  • copr-builds/int:id
  • koji-builds
  • koji-builds/int:id
  • srpm-builds
  • srpm-builds/int:id

RELEASE NOTES END

Signed-off-by: Jiri Podivin <jpodivin@redhat.com>
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request consistently renames the build_submitted_time field to submitted_time across multiple API endpoints (copr-builds, koji-builds, srpm-builds) to improve API consistency. The changes are also reflected in the test suite. I've suggested one improvement to make the API even more consistent by renaming other related fields.

"status": build.status,
"chroot": build.target,
"build_submitted_time": optional_timestamp(build.submitted_time),
"submitted_time": optional_timestamp(build.submitted_time),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

For consistency, it would be beneficial to also rename build_start_time and build_finished_time to start_time and finished_time respectively. This change would align them with the renaming of build_submitted_time and make the API more uniform. This should be applied to the other detail endpoints in koji_builds.py and srpm_builds.py as well. If you apply this change, please also update the release notes accordingly.

@centosinfra-prod-github-app
Copy link
Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

1 participant