Skip to content

Fix department name in department history response#107

Open
lahiruudayakumara wants to merge 2 commits into
LDFLK:mainfrom
lahiruudayakumara:fix-department-history-department-name
Open

Fix department name in department history response#107
lahiruudayakumara wants to merge 2 commits into
LDFLK:mainfrom
lahiruudayakumara:fix-department-history-department-name

Conversation

@lahiruudayakumara
Copy link
Copy Markdown

Summary

  • add department_name to the department history timeline response
  • prevent renamed departments from collapsing into a single timeline entry incorrectly
  • update the API contract and service tests
  • clean up async error-path tests so the full suite runs without unawaited coroutine warnings

Fixes #106

Add department_name to the department history timeline response and keep renamed departments separate during timeline collapsing.

Update the API contract and service tests for the response change, and adjust async error-path tests to avoid unawaited coroutine warnings while running the suite.

Fixes LDFLK#106
@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Apr 23, 2026

CLA assistant check
All committers have signed the CLA.

Copy link
Copy Markdown
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 adds department_name to the organization API contract and updates the department_history_timeline service to include department names and source IDs in the response. The logic for collapsing timeline entries was updated to account for these new fields, and several tests were adjusted to verify the changes. Review feedback suggests completing the API examples in the contract and using pre-formatted period strings in the service implementation to ensure consistency and simplify consumer usage.

Comment thread gi_service/contract/rest/organisation_api_contract.yaml
Comment thread src/services/organisation_service.py
Comment thread src/services/organisation_service.py
@sehansi-9
Copy link
Copy Markdown
Contributor

hi @lahiruudayakumara
pls address the bot comments

Keep internal gap records structurally consistent by setting minister_name for placeholder entries and clarify why the timeline uses raw timestamps until the final response formatting step.

Validated with the full test suite.

Refs LDFLK#106
Copy link
Copy Markdown
Author

@lahiruudayakumara lahiruudayakumara left a comment

Choose a reason for hiding this comment

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

fix: add minister_name field to gap timeline entries for consistent response structure

Refs #106

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] [DEPARTMENT HISTORY] Missing department name in repsonse

3 participants