Web API: closed_at field null even though ticket is closed. #2600

Closed
opened 2025-11-02 04:41:41 -06:00 by GiteaMirror · 1 comment
Owner

Originally created by @jabouchleih on GitHub (Dec 2, 2018).

Description

When closing an issue, the closed_at field in the API request is null even though the issue inside the issue tracker is closed.

Example:
{"id":4321,"url":"https://try.gitea.io/api/v1/repos/rakshith-ravi/test/issues/2","number":2,"user":{"id":9467,"login":"Test","full_name":"","email":"test@noreply.example.org","avatar_url":"https://secure.gravatar.com/avatar/f10679d1743e9ff23ac5dd72d5bf71d8?d=identicon","language":"de-DE","username":"TestJinInQ"},"title":"test","body":"test","labels":[],"milestone":null,"assignee":null,"assignees":null,"state":"closed","comments":0,"created_at":"2018-12-02T15:25:48Z","updated_at":"2018-12-02T15:28:22Z","closed_at":null,"due_date":null,"pull_request":null}

closed_at == null.

Expected:
{"id":4321,"url":"https://try.gitea.io/api/v1/repos/rakshith-ravi/test/issues/2","number":2,"user":{"id":9467,"login":"Test","full_name":"","email":"test@noreply.example.org","avatar_url":"https://secure.gravatar.com/avatar/f10679d1743e9ff23ac5dd72d5bf71d8?d=identicon","language":"de-DE","username":"TestJinInQ"},"title":"test","body":"test","labels":[],"milestone":null,"assignee":null,"assignees":null,"state":"closed","comments":0,"created_at":"2018-12-02T15:25:48Z","updated_at":"2018-12-02T15:28:22Z","closed_at":2018-12-02T15:28:22Z,"due_date":null,"pull_request":null}

closed_at == updated_at == 2018-12-02T15:28:22Z

Originally created by @jabouchleih on GitHub (Dec 2, 2018). <!-- 1. Please speak English, this is the language all of us can speak and write. 2. Please ask questions or configuration/deploy problems on our Discord server (https://discord.gg/NsatcWJ) or forum (https://discourse.gitea.io). 3. Please take a moment to check that your issue doesn't already exist. 4. Please give all relevant information below for bug reports, because incomplete details will be handled as an invalid report. --> - Gitea version (or commit ref): bc42b3a - Git version: 2.11.0 - Operating system: - Database (use `[x]`): - [ ] PostgreSQL - [x] MySQL - [ ] MSSQL - [ ] SQLite - Can you reproduce the bug at https://try.gitea.io: - [x] Yes (provide example URL): https://try.gitea.io/api/v1/repos/rakshith-ravi/test/issues/2 - [ ] No - [ ] Not relevant - Log gist: ## Description When closing an issue, the closed_at field in the API request is null even though the issue inside the issue tracker is closed. **Example:** `{"id":4321,"url":"https://try.gitea.io/api/v1/repos/rakshith-ravi/test/issues/2","number":2,"user":{"id":9467,"login":"Test","full_name":"","email":"test@noreply.example.org","avatar_url":"https://secure.gravatar.com/avatar/f10679d1743e9ff23ac5dd72d5bf71d8?d=identicon","language":"de-DE","username":"TestJinInQ"},"title":"test","body":"test","labels":[],"milestone":null,"assignee":null,"assignees":null,"state":"closed","comments":0,"created_at":"2018-12-02T15:25:48Z","updated_at":"2018-12-02T15:28:22Z","closed_at":null,"due_date":null,"pull_request":null}` `closed_at == null.` **Expected:** `{"id":4321,"url":"https://try.gitea.io/api/v1/repos/rakshith-ravi/test/issues/2","number":2,"user":{"id":9467,"login":"Test","full_name":"","email":"test@noreply.example.org","avatar_url":"https://secure.gravatar.com/avatar/f10679d1743e9ff23ac5dd72d5bf71d8?d=identicon","language":"de-DE","username":"TestJinInQ"},"title":"test","body":"test","labels":[],"milestone":null,"assignee":null,"assignees":null,"state":"closed","comments":0,"created_at":"2018-12-02T15:25:48Z","updated_at":"2018-12-02T15:28:22Z","closed_at":2018-12-02T15:28:22Z,"due_date":null,"pull_request":null}` `closed_at == updated_at == 2018-12-02T15:28:22Z`
GiteaMirror added the type/bug label 2025-11-02 04:41:41 -06:00
Author
Owner

@r-52 commented on GitHub (Dec 2, 2018):

Could I take a look at this one if no is already working on it?

@r-52 commented on GitHub (Dec 2, 2018): Could I take a look at this one if no is already working on it?
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#2600