Skip to content

feat(deathData): PHX-272: Create FSM death certificate#9165

Merged
NavarroEmilioLuis merged 44 commits intomainfrom
feature/phx-272-create-new-death-certificate-for-fsm
Mar 19, 2026
Merged

feat(deathData): PHX-272: Create FSM death certificate#9165
NavarroEmilioLuis merged 44 commits intomainfrom
feature/phx-272-create-new-death-certificate-for-fsm

Conversation

@NavarroEmilioLuis
Copy link
Copy Markdown
Contributor

@NavarroEmilioLuis NavarroEmilioLuis commented Feb 13, 2026

Changes

Alright, some changes!

Deploys

  • Deploy to Tamanu Internal

Note

Medium Risk
Adds a new JSONB extra_data column and threads it through API + form + PDF generation; mistakes could silently drop or mis-shape certificate data. Also includes unresolved merge-conflict markers in FSMBirthNotificationCertificate.jsx, which is a release-blocking build risk.

Overview
Adds FSM-specific death certificate support behind the fsmCrvsCertificates.enableFSMStyle setting, including a new FSMDeathCertificatePrintout (2-page, landscape) and wiring the print modal to pass printedBy.

Extends death data persistence with a new JSONB patient_death_data.extra_data column (PatientDeathData.extraData), updates the patient death API (GET/POST) and validation schema to accept/return extraData, and adds FSM_FIELDS constants plus form changes to collect FSM-only fields and nest them into extraData on submit.

Refactors the death form into reusable optional-page components (DeathFormOptionalPages.jsx), adds an FSM-only questions page (including hierarchy-based place-of-death selectors), and updates HierarchyFields to optionally render without its container.

Includes an unrelated change that introduces merge conflict markers in FSMBirthNotificationCertificate.jsx that must be resolved.

Written by Cursor Bugbot for commit eea684d. Configure here.

@gemini-code-assist
Copy link
Copy Markdown
Contributor

Summary of Changes

Hello @NavarroEmilioLuis, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request implements the functionality for generating Federated States of Micronesia (FSM) death certificates. It involves significant changes across the application stack, from database schema modifications to accommodate new FSM-specific data points, to updates in the API for handling this data, and a complete overhaul of the death form's optional sections to support FSM-specific questions and a new FSM-styled printout. The changes ensure that the system can accurately capture and present death information according to FSM requirements, activated by a feature flag.

Highlights

  • FSM Death Certificate Implementation: Introduced a new Federated States of Micronesia (FSM) specific death certificate, including new data fields, a dedicated printout component, and conditional rendering logic based on a feature flag.
  • Database Schema Update: Added an extra_data JSONB column to the patient_death_data table to store FSM-specific death certificate information, ensuring flexibility for future data requirements.
  • Death Form Refactoring: Refactored the Death Form in the web application to modularize optional sections (Manner of Death, Pregnancy, Infant details) into separate components, improving maintainability and supporting FSM-specific question sets.
  • API and Validation Updates: Modified the patient death data API routes and validation schemas to correctly handle the new extraData field, allowing for persistence and retrieval of FSM-specific information.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Changelog
  • packages/constants/src/deaths.ts
    • Added FSM_FIELDS constant, defining an array of FSM-specific death data fields.
  • packages/constants/src/index.ts
    • Exported the binary.ts module from the constants index.
  • packages/database/src/migrations/1770952177082-addExtraDataFieldToPatientDeathData.ts
    • Added a new migration to introduce an extra_data JSONB column to the patient_death_data table.
  • packages/database/src/models/PatientDeathData.ts
    • Updated the PatientDeathData model to include the new extraData field as a JSONB type.
  • packages/facility-server/app/routes/apiv1/patient/patientDeath.js
    • Removed commented-out TBD fields related to death certificate data.
    • Included autopsyRequested, mannerOfDeathDescription, externalCauseLocation, externalCauseDate, externalCauseNotes, and extraData in the GET response for patient death data.
    • Added extraData to the POST request body for creating/updating patient death data.
  • packages/facility-server/app/routes/apiv1/patient/patientDeathValidationSchema.js
    • Added extraData as an optional object field to the patient death full schema for validation.
  • packages/shared/src/utils/patientCertificates/DeathCertificatePrintout.jsx
    • Imported FSMDeathCertificatePrintout component.
    • Modified the DeathCertificatePrintoutComponent to conditionally render FSMDeathCertificatePrintout based on the fsmCrvsCertificates.enableFSMStyle setting.
  • packages/shared/src/utils/patientCertificates/FSMDeathCertificatePrintout.jsx
    • Added a new component FSMDeathCertificatePrintout for rendering the FSM-specific death certificate, including detailed styling and data mapping.
  • packages/web/app/components/Field/HierarchyFields.jsx
    • Updated HierarchyFields component to accept a removeContainer prop, allowing it to render without its default container.
  • packages/web/app/components/PatientPrinting/modals/DeathCertificateModal.jsx
    • Imported useAuth hook to access current user information.
    • Passed the currentUser?.displayName as printedBy to the DeathCertificatePrintout component.
  • packages/web/app/constants/binary.js
    • Renamed and moved the file to packages/constants/src/binary.ts.
  • packages/web/app/constants/index.js
    • Removed the export for binary.js as it was moved to a shared constants package.
  • packages/web/app/forms/DeathForm.jsx
    • Refactored imports to use new optional page components and constants from @tamanu/constants.
    • Removed Subheading styled component.
    • Introduced canBePregnantFSM helper function for FSM-specific pregnancy criteria.
    • Added transformData function to nest FSM-specific fields into an extraData object before submission.
    • Integrated useSettings to check for FSM style enablement.
    • Conditionally rendered FSMSpecificQuestions, FSMMannerOfDeathPage, FSMPregnancyPage, MannerOfDeathPage, PregnancyPage, and InfantPage components based on FSM style and patient data.
    • Used useMemo to cache field definitions for optional pages.
  • packages/web/app/forms/DeathFormOptionalPages.jsx
    • Added a new file to encapsulate optional pages for the Death Form, including FSMSpecificQuestions, MannerOfDeathPage, InfantPage, PregnancyPage, FSMMannerOfDeathPage, and FSMPregnancyPage.
    • Defined FSM-specific marital status options and death location hierarchy fields.
    • Provided functions (getMannerOfDeathPageFields, getInfantPageFields, getPregnancyPageFields, getFSMMannerOfDeathPageFields, getFSMPregnancyPageFields) to return field configurations for each optional page.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

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 introduces a new FSM death certificate, including a new database field, model updates, API changes, a new printout component, and a significant refactoring of the death form to support different certificate styles. The changes are well-structured, especially the refactoring of the DeathForm into smaller, conditional pages.

I've found one issue in the new FSMDeathCertificatePrintout.jsx component where incorrect data is being displayed for the manner of death. My review includes a specific comment with a suggestion to fix this.

@NavarroEmilioLuis NavarroEmilioLuis force-pushed the feature/phx-272-create-new-death-certificate-for-fsm branch from 86d3357 to eea684d Compare February 13, 2026 04:06
@NavarroEmilioLuis NavarroEmilioLuis changed the base branch from main-base-2026-02-11 to feature/phx-271-update-birth-certificate February 13, 2026 04:06
@NavarroEmilioLuis
Copy link
Copy Markdown
Contributor Author

bugbot run

Copy link
Copy Markdown
Contributor

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

This is the final PR Bugbot will review for you during this billing cycle

Your free Bugbot reviews will reset on March 28

Details

You are on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle.

To receive Bugbot reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial.

Comment thread packages/shared/src/utils/patientCertificates/FSMDeathCertificatePrintout.jsx Outdated
Comment thread packages/shared/src/utils/patientCertificates/FSMDeathCertificatePrintout.jsx Outdated
return entry ? entry.label : '';
};

const FSM_DATE_FORMAT = 'MM/dd/yyyy';
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Do we want to fix date format here? Or just use formatShort?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

FSM wants this specific day format, notice it's months first!

Comment thread packages/facility-server/app/routes/apiv1/patient/patientDeath.js Outdated
Copy link
Copy Markdown
Contributor

@dannash100 dannash100 left a comment

Choose a reason for hiding this comment

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

Just that comment re that promise all, otherwise looking good

Base automatically changed from feature/phx-271-update-birth-certificate to main February 23, 2026 15:07
@NavarroEmilioLuis NavarroEmilioLuis force-pushed the feature/phx-272-create-new-death-certificate-for-fsm branch from 6995ca4 to fa8d470 Compare February 23, 2026 15:30
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Feb 23, 2026

Android builds 📱

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Feb 23, 2026

🍹 up on tamanu-on-k8s/bes/tamanu-on-k8s/feature-phx-272-create-new-death-certificate-for-fsm

Pulumi report
   Updating (feature-phx-272-create-new-death-certificate-for-fsm)

View Live: https://app.pulumi.com/bes/tamanu-on-k8s/feature-phx-272-create-new-death-certificate-for-fsm/updates/5

Downloading plugin random-4.19.0: starting
Downloading plugin random-4.19.0: done
Installing plugin random-4.19.0: starting
Installing plugin random-4.19.0: done

@ Updating....
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running 
@ Updating.....
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running read pulumi:pulumi:StackReference bes/k8s-core/tamanu-internal-main
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running read kubernetes:core/v1:Namespace tamanu-feature-phx-272-create-new-death-certificate-for-fsm
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running read pulumi:pulumi:StackReference bes/k8s-core/tamanu-internal-main
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running read pulumi:pulumi:StackReference bes/core/tamanu-internal
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Using tailscale proxy https://k8s-operator-tamanu-internal-main.tail53aef.ts.net
@ Updating....
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running read pulumi:pulumi:StackReference bes/core/tamanu-internal
@ Updating......
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running read kubernetes:core/v1:Namespace tamanu-feature-phx-272-create-new-death-certificate-for-fsm
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Waiting for central-db...
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Waiting for facility-1-db...
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Waiting for facility-2-db...
~  kubernetes:apps/v1:Deployment facility-1-web updating (0s) [diff: ~spec]
~  kubernetes:apps/v1:Deployment facility-2-web updating (0s) [diff: ~spec]
~  kubernetes:apps/v1:Deployment central-web updating (0s) [diff: ~spec]
~  kubernetes:apps/v1:Deployment patient-portal-web updating (0s) [diff: ~spec]
@ Updating....
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running read kubernetes:core/v1:ConfigMap actual-provisioning
++ kubernetes:batch/v1:Job central-migrator creating replacement (0s) [diff: ~spec]
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Secret facility-2-db-superuser not found or not ready: Error: HTTP-Code: 404
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Message: Unknown API Status Code!
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Body: "{\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"secrets \\\"facility-2-db-superuser\\\" not found\",\"reason\":\"NotFound\",\"details\":{\"name\":\"facility-2-db-superuser\",\"kind\":\"secrets\"},\"code\":404}
"
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Headers: {"audit-id":"20404304-9609-461c-be30-a32026bc387a","cache-control":"no-cache, private","connection":"close","content-length":"220","content-type":"application/json","date":"Tue, 10 Mar 2026 04:09:03 GMT","x-kubernetes-pf-flowschema-uid":"3fb296fc-e46b-45d1-9306-057e37ddd229","x-kubernetes-pf-prioritylevel-uid":"feccf24d-a074-4fa8-aa6f-db82477fc2f5"}
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Secret central-db-superuser not found or not ready: Error: HTTP-Code: 404
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Message: Unknown API Status Code!
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Body: "{\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"secrets \\\"central-db-superuser\\\" not found\",\"reason\":\"NotFound\",\"details\":{\"name\":\"central-db-superuser\",\"kind\":\"secrets\"},\"code\":404}
"
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Headers: {"audit-id":"c0093e01-432b-4a68-80ef-6c1630cde37c","cache-control":"no-cache, private","connection":"close","content-length":"214","content-type":"application/json","date":"Tue, 10 Mar 2026 04:09:03 GMT","x-kubernetes-pf-flowschema-uid":"3fb296fc-e46b-45d1-9306-057e37ddd229","x-kubernetes-pf-prioritylevel-uid":"feccf24d-a074-4fa8-aa6f-db82477fc2f5"}
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Secret facility-1-db-superuser not found or not ready: Error: HTTP-Code: 404
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Message: Unknown API Status Code!
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Body: "{\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"secrets \\\"facility-1-db-superuser\\\" not found\",\"reason\":\"NotFound\",\"details\":{\"name\":\"facility-1-db-superuser\",\"kind\":\"secrets\"},\"code\":404}
"
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running Headers: {"audit-id":"d9c9d66b-f954-4427-94b4-191f34646323","cache-control":"no-cache, private","connection":"close","content-length":"220","content-type":"application/json","date":"Tue, 10 Mar 2026 04:09:03 GMT","x-kubernetes-pf-flowschema-uid":"3fb296fc-e46b-45d1-9306-057e37ddd229","x-kubernetes-pf-prioritylevel-uid":"feccf24d-a074-4fa8-aa6f-db82477fc2f5"}
@ Updating....
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm running read kubernetes:core/v1:ConfigMap actual-provisioning
++ kubernetes:batch/v1:Job central-migrator creating replacement (0s) [diff: ~spec]; 
@ Updating....
++ kubernetes:batch/v1:Job facility-2-migrator creating replacement (0s) [diff: ~spec]
++ kubernetes:batch/v1:Job facility-1-migrator creating replacement (0s) [diff: ~spec]
++ kubernetes:batch/v1:Job central-migrator creating replacement (2s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/central-migrator-bc71dcc2" to start
++ kubernetes:batch/v1:Job central-migrator creating replacement (2s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/central-migrator-bc71dcc2" to succeed (Active: 1 | Succeeded: 0 | Failed: 0)
++ kubernetes:batch/v1:Job facility-2-migrator creating replacement (0s) [diff: ~spec]; 
++ kubernetes:batch/v1:Job facility-2-migrator creating replacement (0s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-2-migrator-db49c58e" to start
++ kubernetes:batch/v1:Job facility-2-migrator creating replacement (0s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-2-migrator-db49c58e" to succeed (Active: 1 | Succeeded: 0 | Failed: 0)
@ Updating....
++ kubernetes:batch/v1:Job facility-1-migrator creating replacement (0s) [diff: ~spec]; 
++ kubernetes:batch/v1:Job facility-1-migrator creating replacement (0s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-1-migrator-87ee6f83" to start
++ kubernetes:batch/v1:Job facility-1-migrator creating replacement (0s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-1-migrator-87ee6f83" to succeed (Active: 1 | Succeeded: 0 | Failed: 0)
~  kubernetes:apps/v1:Deployment patient-portal-web updating (3s) [diff: ~spec]; Waiting for app ReplicaSet to be available (0/1 Pods available)
~  kubernetes:apps/v1:Deployment facility-1-web updating (3s) [diff: ~spec]; Waiting for app ReplicaSet to be available (0/1 Pods available)
~  kubernetes:apps/v1:Deployment facility-2-web updating (3s) [diff: ~spec]; Waiting for app ReplicaSet to be available (0/1 Pods available)
~  kubernetes:apps/v1:Deployment central-web updating (3s) [diff: ~spec]; Waiting for app ReplicaSet to be available (0/1 Pods available)
@ Updating.............
~  kubernetes:apps/v1:Deployment patient-portal-web updating (13s) [diff: ~spec]; warning: [Pod tamanu-feature-phx-272-create-new-death-certificate-for-fsm/patient-portal-web-42424b7e-6dc8d4d454-r9gz9]: containers with unready status: [http]
~  kubernetes:apps/v1:Deployment facility-1-web updating (13s) [diff: ~spec]; warning: [Pod tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-1-web-7d48f981-5bf8c8f4cf-5797l]: containers with unready status: [http]
~  kubernetes:apps/v1:Deployment facility-2-web updating (13s) [diff: ~spec]; warning: [Pod tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-2-web-e9288652-599d8cd8b6-jm6cc]: containers with unready status: [http]
~  kubernetes:apps/v1:Deployment central-web updating (13s) [diff: ~spec]; warning: [Pod tamanu-feature-phx-272-create-new-death-certificate-for-fsm/central-web-890e387e-6d96d59ff7-5hcn2]: containers with unready status: [http]
~  kubernetes:apps/v1:Deployment facility-2-web updating (14s) [diff: ~spec]; Waiting for app ReplicaSet to be available (1/2 Pods available)
@ Updating....
~  kubernetes:apps/v1:Deployment central-web updating (14s) [diff: ~spec]; Waiting for app ReplicaSet to be available (1/2 Pods available)
~  kubernetes:apps/v1:Deployment facility-1-web updating (14s) [diff: ~spec]; Waiting for app ReplicaSet to be available (1/2 Pods available)
@ Updating....
~  kubernetes:apps/v1:Deployment patient-portal-web updating (15s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment patient-portal-web updating (15s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment patient-portal-web updated (15s) [diff: ~spec]; 
@ Updating..........
++ kubernetes:batch/v1:Job facility-2-migrator creating replacement (20s) [diff: ~spec]; warning: [Pod tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-2-migrator-db49c58e-777bf]: Container "migrator" completed with exit code 0
@ Updating....
~  kubernetes:apps/v1:Deployment central-web updating (23s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment central-web updating (23s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment central-web updated (23s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-1-web updating (23s) [diff: ~spec]; warning: [Pod tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-1-web-7d48f981-5bf8c8f4cf-w6xbm]: containers with unready status: [http]
~  kubernetes:apps/v1:Deployment facility-2-web updating (23s) [diff: ~spec]; warning: [Pod tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-2-web-e9288652-599d8cd8b6-mtq8f]: containers with unready status: [http]
@ Updating....
~  kubernetes:apps/v1:Deployment facility-2-web updating (24s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment facility-2-web updating (24s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-2-web updated (24s) [diff: ~spec]; 
++ kubernetes:batch/v1:Job facility-2-migrator creating replacement (22s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-2-migrator-db49c58e" to succeed (Active: 0 | Succeeded: 0 | Failed: 0)
++ kubernetes:batch/v1:Job facility-2-migrator creating replacement (22s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-2-migrator-db49c58e" to succeed (Active: 0 | Succeeded: 1 | Failed: 0)
++ kubernetes:batch/v1:Job facility-2-migrator creating replacement (22s) [diff: ~spec]; 
++ kubernetes:batch/v1:Job facility-2-migrator created replacement (22s) [diff: ~spec]; 
+- kubernetes:batch/v1:Job facility-2-migrator replacing (0s) [diff: ~spec]; 
+- kubernetes:batch/v1:Job facility-2-migrator replaced (0.00s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-2-tasks updating (0s) [diff: ~spec]
~  kubernetes:apps/v1:Deployment facility-2-sync updating (0s) [diff: ~spec]
~  kubernetes:apps/v1:Deployment facility-2-api updating (0s) [diff: ~spec]
~  kubernetes:apps/v1:Deployment facility-1-web updating (25s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment facility-1-web updating (25s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-1-web updated (25s) [diff: ~spec]; 
@ Updating.....
~  kubernetes:apps/v1:Deployment facility-2-tasks updating (1s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment facility-2-tasks updating (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-2-tasks updated (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-2-sync updating (1s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment facility-2-sync updating (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-2-sync updated (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-2-api updating (1s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment facility-2-api updating (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-2-api updated (1s) [diff: ~spec]; 
@ Updating................
++ kubernetes:batch/v1:Job facility-1-migrator creating replacement (37s) [diff: ~spec]; warning: [Pod tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-1-migrator-87ee6f83-bpjcj]: Container "migrator" completed with exit code 0
++ kubernetes:batch/v1:Job central-migrator creating replacement (39s) [diff: ~spec]; warning: [Pod tamanu-feature-phx-272-create-new-death-certificate-for-fsm/central-migrator-bc71dcc2-xf24v]: Container "migrator" completed with exit code 0
@ Updating.....
++ kubernetes:batch/v1:Job facility-1-migrator creating replacement (39s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-1-migrator-87ee6f83" to succeed (Active: 0 | Succeeded: 0 | Failed: 0)
++ kubernetes:batch/v1:Job central-migrator creating replacement (41s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/central-migrator-bc71dcc2" to succeed (Active: 0 | Succeeded: 0 | Failed: 0)
++ kubernetes:batch/v1:Job facility-1-migrator creating replacement (39s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/facility-1-migrator-87ee6f83" to succeed (Active: 0 | Succeeded: 1 | Failed: 0)
++ kubernetes:batch/v1:Job facility-1-migrator creating replacement (39s) [diff: ~spec]; 
++ kubernetes:batch/v1:Job facility-1-migrator created replacement (39s) [diff: ~spec]; 
++ kubernetes:batch/v1:Job central-migrator creating replacement (41s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/central-migrator-bc71dcc2" to succeed (Active: 0 | Succeeded: 1 | Failed: 0)
++ kubernetes:batch/v1:Job central-migrator creating replacement (41s) [diff: ~spec]; 
++ kubernetes:batch/v1:Job central-migrator created replacement (41s) [diff: ~spec]; 
+- kubernetes:batch/v1:Job facility-1-migrator replacing (0s) [diff: ~spec]; 
+- kubernetes:batch/v1:Job facility-1-migrator replaced (0.00s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-1-tasks updating (0s) [diff: ~spec]
~  kubernetes:apps/v1:Deployment facility-1-api updating (0s) [diff: ~spec]
~  kubernetes:apps/v1:Deployment facility-1-sync updating (0s) [diff: ~spec]
@ Updating....
+- kubernetes:batch/v1:Job central-migrator replacing (0s) [diff: ~spec]; 
+- kubernetes:batch/v1:Job central-migrator replaced (0.00s) [diff: ~spec]; 
++ kubernetes:batch/v1:Job central-provisioner creating replacement (0s) [diff: ~spec]
@ Updating....
++ kubernetes:batch/v1:Job central-provisioner creating replacement (0s) [diff: ~spec]; 
++ kubernetes:batch/v1:Job central-provisioner creating replacement (0s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/central-provisioner-6ecbb0a3" to start
++ kubernetes:batch/v1:Job central-provisioner creating replacement (1s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/central-provisioner-6ecbb0a3" to succeed (Active: 1 | Succeeded: 0 | Failed: 0)
~  kubernetes:apps/v1:Deployment facility-1-tasks updating (1s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment facility-1-tasks updating (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-1-tasks updated (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-1-api updating (1s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment facility-1-api updating (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-1-api updated (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-1-sync updating (1s) [diff: ~spec]; warning: Replicas scaled to 0 for Deployment "facility-1-sync"
~  kubernetes:apps/v1:Deployment facility-1-sync updating (1s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment facility-1-sync updating (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment facility-1-sync updated (1s) [diff: ~spec]; 
@ Updating.........
++ kubernetes:batch/v1:Job central-provisioner creating replacement (7s) [diff: ~spec]; warning: [Pod tamanu-feature-phx-272-create-new-death-certificate-for-fsm/central-provisioner-6ecbb0a3-mnbj6]: Container "provisioner" completed with exit code 0
@ Updating.....
++ kubernetes:batch/v1:Job central-provisioner creating replacement (9s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/central-provisioner-6ecbb0a3" to succeed (Active: 0 | Succeeded: 0 | Failed: 0)
++ kubernetes:batch/v1:Job central-provisioner creating replacement (9s) [diff: ~spec]; Waiting for Job "tamanu-feature-phx-272-create-new-death-certificate-for-fsm/central-provisioner-6ecbb0a3" to succeed (Active: 0 | Succeeded: 1 | Failed: 0)
++ kubernetes:batch/v1:Job central-provisioner creating replacement (9s) [diff: ~spec]; 
++ kubernetes:batch/v1:Job central-provisioner created replacement (9s) [diff: ~spec]; 
+- kubernetes:batch/v1:Job central-provisioner replacing (0s) [diff: ~spec]; 
+- kubernetes:batch/v1:Job central-provisioner replaced (0.00s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment central-fhir-refresh updating (0s) [diff: ~spec]
~  kubernetes:apps/v1:Deployment central-fhir-resolver updating (0s) [diff: ~spec]
~  kubernetes:apps/v1:Deployment central-tasks updating (0s) [diff: ~spec]
~  kubernetes:apps/v1:Deployment central-api updating (0s) [diff: ~spec]
@ Updating.....
~  kubernetes:apps/v1:Deployment central-fhir-refresh updating (1s) [diff: ~spec]; Waiting for app ReplicaSet to be available (0/1 Pods available)
~  kubernetes:apps/v1:Deployment central-fhir-resolver updating (1s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment central-fhir-resolver updating (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment central-fhir-resolver updated (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment central-tasks updating (1s) [diff: ~spec]; warning: Replicas scaled to 0 for Deployment "central-tasks-a74c156d"
~  kubernetes:apps/v1:Deployment central-tasks updating (1s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment central-tasks updating (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment central-tasks updated (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment central-api updating (1s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment central-api updating (1s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment central-api updated (1s) [diff: ~spec]; 
@ Updating.....
~  kubernetes:apps/v1:Deployment central-fhir-refresh updating (3s) [diff: ~spec]; Deployment initialization complete
~  kubernetes:apps/v1:Deployment central-fhir-refresh updating (3s) [diff: ~spec]; 
~  kubernetes:apps/v1:Deployment central-fhir-refresh updated (3s) [diff: ~spec]; 
-- kubernetes:batch/v1:Job central-provisioner deleting original (0s) [diff: ~spec]; 
@ Updating....
-- kubernetes:batch/v1:Job central-provisioner deleting original (0s) [diff: ~spec]; 
-- kubernetes:batch/v1:Job central-provisioner deleted original (0.61s) [diff: ~spec]; 
-- kubernetes:batch/v1:Job facility-1-migrator deleting original (0s) [diff: ~spec]; 
-- kubernetes:batch/v1:Job facility-2-migrator deleting original (0s) [diff: ~spec]; 
-- kubernetes:batch/v1:Job central-migrator deleting original (0s) [diff: ~spec]; 
@ Updating....
-- kubernetes:batch/v1:Job facility-1-migrator deleting original (0s) [diff: ~spec]; 
-- kubernetes:batch/v1:Job facility-1-migrator deleted original (0.86s) [diff: ~spec]; 
-- kubernetes:batch/v1:Job facility-2-migrator deleting original (1s) [diff: ~spec]; 
-- kubernetes:batch/v1:Job facility-2-migrator deleted original (1s) [diff: ~spec]; 
-- kubernetes:batch/v1:Job central-migrator deleting original (1s) [diff: ~spec]; 
-- kubernetes:batch/v1:Job central-migrator deleted original (1s) [diff: ~spec]; 
@ Updating....
   pulumi:pulumi:Stack tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm  16 messages
Diagnostics:
 pulumi:pulumi:Stack (tamanu-on-k8s-feature-phx-272-create-new-death-certificate-for-fsm):
   Waiting for central-db...
   Waiting for facility-1-db...
   Waiting for facility-2-db...

   Using tailscale proxy https://k8s-operator-tamanu-internal-main.tail53aef.ts.net

   Secret facility-2-db-superuser not found or not ready: Error: HTTP-Code: 404
   Message: Unknown API Status Code!
   Body: "{\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"secrets \\\"facility-2-db-superuser\\\" not found\",\"reason\":\"NotFound\",\"details\":{\"name\":\"facility-2-db-superuser\",\"kind\":\"secrets\"},\"code\":404}
"
   Headers: {"audit-id":"20404304-9609-461c-be30-a32026bc387a","cache-control":"no-cache, private","connection":"close","content-length":"220","content-type":"application/json","date":"Tue, 10 Mar 2026 04:09:03 GMT","x-kubernetes-pf-flowschema-uid":"3fb296fc-e46b-45d1-9306-057e37ddd229","x-kubernetes-pf-prioritylevel-uid":"feccf24d-a074-4fa8-aa6f-db82477fc2f5"}
   Secret central-db-superuser not found or not ready: Error: HTTP-Code: 404
   Message: Unknown API Status Code!
   Body: "{\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"secrets \\\"central-db-superuser\\\" not found\",\"reason\":\"NotFound\",\"details\":{\"name\":\"central-db-superuser\",\"kind\":\"secrets\"},\"code\":404}
"
   Headers: {"audit-id":"c0093e01-432b-4a68-80ef-6c1630cde37c","cache-control":"no-cache, private","connection":"close","content-length":"214","content-type":"application/json","date":"Tue, 10 Mar 2026 04:09:03 GMT","x-kubernetes-pf-flowschema-uid":"3fb296fc-e46b-45d1-9306-057e37ddd229","x-kubernetes-pf-prioritylevel-uid":"feccf24d-a074-4fa8-aa6f-db82477fc2f5"}
   Secret facility-1-db-superuser not found or not ready: Error: HTTP-Code: 404
   Message: Unknown API Status Code!
   Body: "{\"kind\":\"Status\",\"apiVersion\":\"v1\",\"metadata\":{},\"status\":\"Failure\",\"message\":\"secrets \\\"facility-1-db-superuser\\\" not found\",\"reason\":\"NotFound\",\"details\":{\"name\":\"facility-1-db-superuser\",\"kind\":\"secrets\"},\"code\":404}
"
   Headers: {"audit-id":"d9c9d66b-f954-4427-94b4-191f34646323","cache-control":"no-cache, private","connection":"close","content-length":"220","content-type":"application/json","date":"Tue, 10 Mar 2026 04:09:03 GMT","x-kubernetes-pf-flowschema-uid":"3fb296fc-e46b-45d1-9306-057e37ddd229","x-kubernetes-pf-prioritylevel-uid":"feccf24d-a074-4fa8-aa6f-db82477fc2f5"}

   [Pulumi Neo] Would you like help with these diagnostics?
   https://app.pulumi.com/bes/tamanu-on-k8s/feature-phx-272-create-new-death-certificate-for-fsm/updates/5?explainFailure

Outputs:
   urls: {
       Central      : "https://central.feature-phx-272-create-new-death-certificate-for-fsm.cd.tamanu.app"
       Facility- 1  : "https://facility-1.feature-phx-272-create-new-death-certificate-for-fsm.cd.tamanu.app"
       Facility- 2  : "https://facility-2.feature-phx-272-create-new-death-certificate-for-fsm.cd.tamanu.app"
       PatientPortal: "https://portal.feature-phx-272-create-new-death-certificate-for-fsm.cd.tamanu.app"
   }

Resources:
   ~ 14 updated
   +-4 replaced
   18 changes. 49 unchanged

Duration: 1m6s

   

Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

@dannash100 dannash100 left a comment

Choose a reason for hiding this comment

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

beautiful

@NavarroEmilioLuis NavarroEmilioLuis merged commit f6590b4 into main Mar 19, 2026
147 of 150 checks passed
@NavarroEmilioLuis NavarroEmilioLuis deleted the feature/phx-272-create-new-death-certificate-for-fsm branch March 19, 2026 00:52
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.

2 participants