From 850b16e14c4c6c5e34c07bd9515162d12f930261 Mon Sep 17 00:00:00 2001 From: Birk Johansson Date: Thu, 23 Jan 2025 15:30:49 +0100 Subject: [PATCH 01/11] fix(maintenance): update deprecated reference to deprecated softDeletedTrackedEntityInstanceRemoval --- cypress/integration/maintenance/index.js | 2 +- src/i18n-keys.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cypress/integration/maintenance/index.js b/cypress/integration/maintenance/index.js index 025ea4d0..8962f08c 100644 --- a/cypress/integration/maintenance/index.js +++ b/cypress/integration/maintenance/index.js @@ -16,7 +16,7 @@ Before(() => { 'softDeletedDataValueRemoval', 'softDeletedEventRemoval', 'softDeletedEnrollmentRemoval', - 'softDeletedTrackedEntityInstanceRemoval', + 'softDeletedTrackedEntityRemoval', 'periodPruning', 'expiredInvitationsClear', 'sqlViewsDrop', diff --git a/src/i18n-keys.js b/src/i18n-keys.js index 1f547cd7..609a6a24 100644 --- a/src/i18n-keys.js +++ b/src/i18n-keys.js @@ -32,7 +32,7 @@ export const i18nKeys = { softDeletedEnrollmentRemoval: i18n.t( 'Permanently remove soft deleted enrollments' ), - softDeletedTrackedEntityInstanceRemoval: i18n.t( + softDeletedTrackedEntityRemoval: i18n.t( 'Permanently remove soft deleted tracked entity instances' ), periodPruning: i18n.t('Prune periods'), From 39e5e70360b7149c0567ffcbb1d4735f8ea908a2 Mon Sep 17 00:00:00 2001 From: Thomas Zemp Date: Tue, 31 Mar 2026 06:16:10 -0600 Subject: [PATCH 02/11] fix: update workflows --- .github/workflows/dhis2-preview-pr.yml | 8 +++--- .github/workflows/dhis2-verify-app.yml | 30 +++++++++++----------- .github/workflows/dhis2-verify-commits.yml | 14 +++++++--- 3 files changed, 29 insertions(+), 23 deletions(-) diff --git a/.github/workflows/dhis2-preview-pr.yml b/.github/workflows/dhis2-preview-pr.yml index 22150d6f..2caad7b4 100644 --- a/.github/workflows/dhis2-preview-pr.yml +++ b/.github/workflows/dhis2-preview-pr.yml @@ -21,12 +21,12 @@ jobs: runs-on: ubuntu-latest if: "!github.event.push.repository.fork && github.actor != 'dependabot[bot]'" steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v1 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: - node-version: 12.x + node-version: 20.x + cache: yarn - - uses: c-hive/gha-yarn-cache@v1 - run: yarn install --frozen-lockfile - name: Build diff --git a/.github/workflows/dhis2-verify-app.yml b/.github/workflows/dhis2-verify-app.yml index de3ec799..6b4cabdb 100644 --- a/.github/workflows/dhis2-verify-app.yml +++ b/.github/workflows/dhis2-verify-app.yml @@ -19,10 +19,10 @@ jobs: if: "!contains(github.event.head_commit.message, '[skip ci]')" steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v1 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: - node-version: 12.x + node-version: 20.x - uses: actions/cache@v4 id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) @@ -39,10 +39,10 @@ jobs: needs: install if: "!contains(github.event.head_commit.message, '[skip ci]')" steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v1 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: - node-version: 12.x + node-version: 20.x - uses: actions/cache@v4 id: yarn-cache @@ -66,10 +66,10 @@ jobs: needs: install if: "!contains(github.event.head_commit.message, '[skip ci]')" steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v1 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: - node-version: 12.x + node-version: 20.x - uses: actions/cache@v4 id: yarn-cache @@ -88,13 +88,13 @@ jobs: needs: [build, lint] if: "!contains(github.event.head_commit.message, '[skip ci]')" steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: token: ${{env.GH_TOKEN}} - - uses: actions/setup-node@v1 + - uses: actions/setup-node@v4 with: - node-version: 12.x + node-version: 20.x - uses: actions/download-artifact@v4 with: @@ -110,13 +110,13 @@ jobs: needs: [publish] if: "github.event_name == 'push' && !contains(github.event.head_commit.message, '[skip ci]')" steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: token: ${{env.GH_TOKEN}} - - uses: actions/setup-node@v1 + - uses: actions/setup-node@v4 with: - node-version: 12.x + node-version: 20.x - name: Publish release to GitHub run: npx @dhis2/cli-utils release diff --git a/.github/workflows/dhis2-verify-commits.yml b/.github/workflows/dhis2-verify-commits.yml index ae7831b5..7ffdda3a 100644 --- a/.github/workflows/dhis2-verify-commits.yml +++ b/.github/workflows/dhis2-verify-commits.yml @@ -8,8 +8,11 @@ jobs: lint-pr-title: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - uses: c-hive/gha-yarn-cache@v1 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: 20.x + cache: yarn - run: yarn install --frozen-lockfile - id: commitlint run: echo ::set-output name=config_path::$(node -e "process.stdout.write(require('@dhis2/cli-style').config.commitlint)") @@ -20,10 +23,13 @@ jobs: lint-commits: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: fetch-depth: 0 - - uses: c-hive/gha-yarn-cache@v1 + - uses: actions/setup-node@v4 + with: + node-version: 20.x + cache: yarn - run: yarn install --frozen-lockfile - id: commitlint run: echo ::set-output name=config_path::$(node -e "process.stdout.write(require('@dhis2/cli-style').config.commitlint)") From ff51e440757d164fd64b0f7ef1f7f46843fc63cc Mon Sep 17 00:00:00 2001 From: Thomas Zemp Date: Tue, 31 Mar 2026 06:30:39 -0600 Subject: [PATCH 03/11] fix: try to resolve postcss --- package.json | 4 ++++ yarn.lock | 24 ++++++++++++++++++++++++ 2 files changed, 28 insertions(+) diff --git a/package.json b/package.json index 0162ea6d..50d89f54 100644 --- a/package.json +++ b/package.json @@ -35,7 +35,11 @@ "@dhis2/d2-i18n": "^1.1.0", "@dhis2/prop-types": "^2.0.3", "@dhis2/ui": "^7.1.1", + "postcss": "8.4.31", "prop-types": "^15.6.0", "react-router-dom": "^5.0.0" + }, + "resolutions": { + "postcss": "8.4.31" } } diff --git a/yarn.lock b/yarn.lock index df2a886f..45022c2d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -12114,6 +12114,11 @@ nanoid@^3.1.20: resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.1.20.tgz#badc263c6b1dcf14b71efaa85f6ab4c1d6cfc788" integrity sha512-a1cQNyczgKbLX9jwbS/+d7W8fX/RfgYR7lVWwWOGIPNgK2m0MWvrGF6/m4kk6U3QcFMnZf3RIhL0v2Jgh/0Uxw== +nanoid@^3.3.6: + version "3.3.11" + resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.11.tgz#4f4f112cefbe303202f2199838128936266d185b" + integrity sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w== + nanomatch@^1.2.9: version "1.2.13" resolved "https://registry.yarnpkg.com/nanomatch/-/nanomatch-1.2.13.tgz#b87a8aa4fc0de8fe6be88895b38983ff265bd119" @@ -12959,6 +12964,11 @@ perfy@^1.1.5: resolved "https://registry.yarnpkg.com/perfy/-/perfy-1.1.5.tgz#0d629f870a34a3eb1866d3db485d2b3faef29e4b" integrity sha512-/ieVBpMaPTJf83YTUl2TImsSwMEJ23qGP2w27pE6aX+NrB/ZRGqOnQZpl7J719yFwd+ebDiHguPNFeMSamyK7w== +picocolors@^1.0.0: + version "1.1.1" + resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.1.1.tgz#3d321af3eab939b083c8f929a1d12cda81c26b6b" + integrity sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA== + picomatch@^2.0.4, picomatch@^2.2.1, picomatch@^2.2.2, picomatch@^2.2.3: version "2.3.0" resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.0.tgz#f1f061de8f6a4bf022892e2d128234fb98302972" @@ -13700,6 +13710,15 @@ postcss@7.0.21: source-map "^0.6.1" supports-color "^6.1.0" +postcss@8.4.31: + version "8.4.31" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.31.tgz#92b451050a9f914da6755af352bdc0192508656d" + integrity sha512-PS08Iboia9mts/2ygV3eLpY5ghnUcfLV/EXTOW1E2qYxJKGGBUtNjN76FYHnMs36RmARn41bC0AZmn+rR0OVpQ== + dependencies: + nanoid "^3.3.6" + picocolors "^1.0.0" + source-map-js "^1.0.2" + postcss@^7, postcss@^7.0.0, postcss@^7.0.1, postcss@^7.0.14, postcss@^7.0.17, postcss@^7.0.2, postcss@^7.0.26, postcss@^7.0.27, postcss@^7.0.32, postcss@^7.0.5, postcss@^7.0.6: version "7.0.35" resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.35.tgz#d2be00b998f7f211d8a276974079f2e92b970e24" @@ -15323,6 +15342,11 @@ source-map-explorer@^2.1.0: temp "^0.9.4" yargs "^16.2.0" +source-map-js@^1.0.2: + version "1.2.1" + resolved "https://registry.yarnpkg.com/source-map-js/-/source-map-js-1.2.1.tgz#1ce5650fddd87abc099eda37dcff024c2667ae46" + integrity sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA== + source-map-resolve@^0.5.0, source-map-resolve@^0.5.2: version "0.5.3" resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.3.tgz#190866bece7553e1f8f267a2ee82c606b5509a1a" From fddc98181ed21a2dc729113d13f93b33654585f8 Mon Sep 17 00:00:00 2001 From: Thomas Zemp Date: Tue, 31 Mar 2026 06:40:03 -0600 Subject: [PATCH 04/11] fix: use lower node version --- .github/workflows/dhis2-preview-pr.yml | 2 +- .github/workflows/dhis2-verify-app.yml | 10 +++++----- .github/workflows/dhis2-verify-commits.yml | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/dhis2-preview-pr.yml b/.github/workflows/dhis2-preview-pr.yml index 2caad7b4..04d315ff 100644 --- a/.github/workflows/dhis2-preview-pr.yml +++ b/.github/workflows/dhis2-preview-pr.yml @@ -24,7 +24,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: - node-version: 20.x + node-version: 16 cache: yarn - run: yarn install --frozen-lockfile diff --git a/.github/workflows/dhis2-verify-app.yml b/.github/workflows/dhis2-verify-app.yml index 6b4cabdb..c21b2146 100644 --- a/.github/workflows/dhis2-verify-app.yml +++ b/.github/workflows/dhis2-verify-app.yml @@ -22,7 +22,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: - node-version: 20.x + node-version: 16 - uses: actions/cache@v4 id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) @@ -42,7 +42,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: - node-version: 20.x + node-version: 16 - uses: actions/cache@v4 id: yarn-cache @@ -69,7 +69,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: - node-version: 20.x + node-version: 16 - uses: actions/cache@v4 id: yarn-cache @@ -94,7 +94,7 @@ jobs: - uses: actions/setup-node@v4 with: - node-version: 20.x + node-version: 16 - uses: actions/download-artifact@v4 with: @@ -116,7 +116,7 @@ jobs: - uses: actions/setup-node@v4 with: - node-version: 20.x + node-version: 16 - name: Publish release to GitHub run: npx @dhis2/cli-utils release diff --git a/.github/workflows/dhis2-verify-commits.yml b/.github/workflows/dhis2-verify-commits.yml index 7ffdda3a..de82dd3b 100644 --- a/.github/workflows/dhis2-verify-commits.yml +++ b/.github/workflows/dhis2-verify-commits.yml @@ -11,7 +11,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: - node-version: 20.x + node-version: 16 cache: yarn - run: yarn install --frozen-lockfile - id: commitlint @@ -28,7 +28,7 @@ jobs: fetch-depth: 0 - uses: actions/setup-node@v4 with: - node-version: 20.x + node-version: 16 cache: yarn - run: yarn install --frozen-lockfile - id: commitlint From 10fe960228eb11e891f6f2a71fa20990bdd32ec1 Mon Sep 17 00:00:00 2001 From: Thomas Zemp Date: Tue, 31 Mar 2026 06:43:50 -0600 Subject: [PATCH 05/11] fix: remove postcss resolution --- package.json | 4 ---- yarn.lock | 34 +--------------------------------- 2 files changed, 1 insertion(+), 37 deletions(-) diff --git a/package.json b/package.json index 50d89f54..0162ea6d 100644 --- a/package.json +++ b/package.json @@ -35,11 +35,7 @@ "@dhis2/d2-i18n": "^1.1.0", "@dhis2/prop-types": "^2.0.3", "@dhis2/ui": "^7.1.1", - "postcss": "8.4.31", "prop-types": "^15.6.0", "react-router-dom": "^5.0.0" - }, - "resolutions": { - "postcss": "8.4.31" } } diff --git a/yarn.lock b/yarn.lock index 45022c2d..188a5dc1 100644 --- a/yarn.lock +++ b/yarn.lock @@ -12109,11 +12109,6 @@ nano-time@1.0.0: dependencies: big-integer "^1.6.16" -nanoid@^3.1.20: - version "3.1.20" - resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.1.20.tgz#badc263c6b1dcf14b71efaa85f6ab4c1d6cfc788" - integrity sha512-a1cQNyczgKbLX9jwbS/+d7W8fX/RfgYR7lVWwWOGIPNgK2m0MWvrGF6/m4kk6U3QcFMnZf3RIhL0v2Jgh/0Uxw== - nanoid@^3.3.6: version "3.3.11" resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.11.tgz#4f4f112cefbe303202f2199838128936266d185b" @@ -13701,16 +13696,7 @@ postcss-values-parser@^2.0.0, postcss-values-parser@^2.0.1: indexes-of "^1.0.1" uniq "^1.0.1" -postcss@7.0.21: - version "7.0.21" - resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.21.tgz#06bb07824c19c2021c5d056d5b10c35b989f7e17" - integrity sha512-uIFtJElxJo29QC753JzhidoAhvp/e/Exezkdhfmt8AymWT6/5B7W1WmponYWkHk2eg6sONyTch0A3nkMPun3SQ== - dependencies: - chalk "^2.4.2" - source-map "^0.6.1" - supports-color "^6.1.0" - -postcss@8.4.31: +postcss@7.0.21, postcss@8.4.31, postcss@^7, postcss@^7.0.0, postcss@^7.0.1, postcss@^7.0.14, postcss@^7.0.17, postcss@^7.0.2, postcss@^7.0.26, postcss@^7.0.27, postcss@^7.0.32, postcss@^7.0.5, postcss@^7.0.6, postcss@^8.1.0: version "8.4.31" resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.31.tgz#92b451050a9f914da6755af352bdc0192508656d" integrity sha512-PS08Iboia9mts/2ygV3eLpY5ghnUcfLV/EXTOW1E2qYxJKGGBUtNjN76FYHnMs36RmARn41bC0AZmn+rR0OVpQ== @@ -13719,24 +13705,6 @@ postcss@8.4.31: picocolors "^1.0.0" source-map-js "^1.0.2" -postcss@^7, postcss@^7.0.0, postcss@^7.0.1, postcss@^7.0.14, postcss@^7.0.17, postcss@^7.0.2, postcss@^7.0.26, postcss@^7.0.27, postcss@^7.0.32, postcss@^7.0.5, postcss@^7.0.6: - version "7.0.35" - resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.35.tgz#d2be00b998f7f211d8a276974079f2e92b970e24" - integrity sha512-3QT8bBJeX/S5zKTTjTCIjRF3If4avAT6kqxcASlTWEtAFCb9NH0OUxNDfgZSWdP5fJnBYCMEWkIFfWeugjzYMg== - dependencies: - chalk "^2.4.2" - source-map "^0.6.1" - supports-color "^6.1.0" - -postcss@^8.1.0: - version "8.2.6" - resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.2.6.tgz#5d69a974543b45f87e464bc4c3e392a97d6be9fe" - integrity sha512-xpB8qYxgPuly166AGlpRjUdEYtmOWx2iCwGmrv4vqZL9YPVviDVPZPRXxnXr6xPZOdxQ9lp3ZBFCRgWJ7LE3Sg== - dependencies: - colorette "^1.2.1" - nanoid "^3.1.20" - source-map "^0.6.1" - prelude-ls@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.2.1.tgz#debc6489d7a6e6b0e7611888cec880337d316396" From 26437879623f5859728cc3803e44389f45e77f18 Mon Sep 17 00:00:00 2001 From: Thomas Zemp Date: Tue, 31 Mar 2026 06:50:21 -0600 Subject: [PATCH 06/11] fix: node 18 --- .github/workflows/dhis2-preview-pr.yml | 4 +++- .github/workflows/dhis2-verify-app.yml | 12 +++++++----- .github/workflows/dhis2-verify-commits.yml | 6 ++++-- 3 files changed, 14 insertions(+), 8 deletions(-) diff --git a/.github/workflows/dhis2-preview-pr.yml b/.github/workflows/dhis2-preview-pr.yml index 04d315ff..8b89e2a4 100644 --- a/.github/workflows/dhis2-preview-pr.yml +++ b/.github/workflows/dhis2-preview-pr.yml @@ -1,4 +1,6 @@ name: 'dhis2: pr preview' +env: + NODE_OPTIONS: --openssl-legacy-provider # Requirements: # @@ -24,7 +26,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 18 cache: yarn - run: yarn install --frozen-lockfile diff --git a/.github/workflows/dhis2-verify-app.yml b/.github/workflows/dhis2-verify-app.yml index c21b2146..cb35d57f 100644 --- a/.github/workflows/dhis2-verify-app.yml +++ b/.github/workflows/dhis2-verify-app.yml @@ -1,4 +1,6 @@ name: 'dhis2: verify (app)' +env: + NODE_OPTIONS: --openssl-legacy-provider on: push: @@ -22,7 +24,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 18 - uses: actions/cache@v4 id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) @@ -42,7 +44,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 18 - uses: actions/cache@v4 id: yarn-cache @@ -69,7 +71,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 18 - uses: actions/cache@v4 id: yarn-cache @@ -94,7 +96,7 @@ jobs: - uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 18 - uses: actions/download-artifact@v4 with: @@ -116,7 +118,7 @@ jobs: - uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 18 - name: Publish release to GitHub run: npx @dhis2/cli-utils release diff --git a/.github/workflows/dhis2-verify-commits.yml b/.github/workflows/dhis2-verify-commits.yml index de82dd3b..c565e5e9 100644 --- a/.github/workflows/dhis2-verify-commits.yml +++ b/.github/workflows/dhis2-verify-commits.yml @@ -1,4 +1,6 @@ name: 'dhis2: verify (commits)' +env: + NODE_OPTIONS: --openssl-legacy-provider on: pull_request: @@ -11,7 +13,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 18 cache: yarn - run: yarn install --frozen-lockfile - id: commitlint @@ -28,7 +30,7 @@ jobs: fetch-depth: 0 - uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 18 cache: yarn - run: yarn install --frozen-lockfile - id: commitlint From 9055e3db6754169c144baa61dc9576a6f194e9c9 Mon Sep 17 00:00:00 2001 From: Thomas Zemp Date: Tue, 31 Mar 2026 06:55:11 -0600 Subject: [PATCH 07/11] fix: rearrange --- .github/workflows/dhis2-preview-pr.yml | 5 +++-- .github/workflows/dhis2-verify-app.yml | 3 +-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/dhis2-preview-pr.yml b/.github/workflows/dhis2-preview-pr.yml index 8b89e2a4..48f7e09d 100644 --- a/.github/workflows/dhis2-preview-pr.yml +++ b/.github/workflows/dhis2-preview-pr.yml @@ -1,6 +1,4 @@ name: 'dhis2: pr preview' -env: - NODE_OPTIONS: --openssl-legacy-provider # Requirements: # @@ -33,6 +31,8 @@ jobs: - name: Build run: yarn d2-app-scripts build --standalone + env: + NODE_OPTIONS: --openssl-legacy-provider - name: Deploy id: netlify-deploy @@ -51,3 +51,4 @@ jobs: NETLIFY_AUTH_TOKEN: ${{ secrets.DHIS2_BOT_NETLIFY_TOKEN }} # repo secret NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }} + NODE_OPTIONS: --openssl-legacy-provider diff --git a/.github/workflows/dhis2-verify-app.yml b/.github/workflows/dhis2-verify-app.yml index cb35d57f..b46bbad4 100644 --- a/.github/workflows/dhis2-verify-app.yml +++ b/.github/workflows/dhis2-verify-app.yml @@ -1,6 +1,4 @@ name: 'dhis2: verify (app)' -env: - NODE_OPTIONS: --openssl-legacy-provider on: push: @@ -14,6 +12,7 @@ env: GH_TOKEN: ${{secrets.DHIS2_BOT_GITHUB_TOKEN}} CI: true D2_VERBOSE: true + NODE_OPTIONS: --openssl-legacy-provider jobs: install: From 2c5fec57d8ed031b7c2bf61534825f07fa9784e0 Mon Sep 17 00:00:00 2001 From: Thomas Zemp Date: Tue, 31 Mar 2026 07:06:04 -0600 Subject: [PATCH 08/11] fix: revert --- .github/workflows/dhis2-preview-pr.yml | 1 - .github/workflows/dhis2-verify-app.yml | 1 - .github/workflows/dhis2-verify-commits.yml | 2 -- 3 files changed, 4 deletions(-) diff --git a/.github/workflows/dhis2-preview-pr.yml b/.github/workflows/dhis2-preview-pr.yml index 48f7e09d..8f6cf252 100644 --- a/.github/workflows/dhis2-preview-pr.yml +++ b/.github/workflows/dhis2-preview-pr.yml @@ -51,4 +51,3 @@ jobs: NETLIFY_AUTH_TOKEN: ${{ secrets.DHIS2_BOT_NETLIFY_TOKEN }} # repo secret NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }} - NODE_OPTIONS: --openssl-legacy-provider diff --git a/.github/workflows/dhis2-verify-app.yml b/.github/workflows/dhis2-verify-app.yml index b46bbad4..f6c78204 100644 --- a/.github/workflows/dhis2-verify-app.yml +++ b/.github/workflows/dhis2-verify-app.yml @@ -12,7 +12,6 @@ env: GH_TOKEN: ${{secrets.DHIS2_BOT_GITHUB_TOKEN}} CI: true D2_VERBOSE: true - NODE_OPTIONS: --openssl-legacy-provider jobs: install: diff --git a/.github/workflows/dhis2-verify-commits.yml b/.github/workflows/dhis2-verify-commits.yml index c565e5e9..8dc7bd06 100644 --- a/.github/workflows/dhis2-verify-commits.yml +++ b/.github/workflows/dhis2-verify-commits.yml @@ -1,6 +1,4 @@ name: 'dhis2: verify (commits)' -env: - NODE_OPTIONS: --openssl-legacy-provider on: pull_request: From 20ef015e0a3c1bfee1a6a9f4855d52b427207295 Mon Sep 17 00:00:00 2001 From: Thomas Zemp Date: Tue, 31 Mar 2026 07:13:48 -0600 Subject: [PATCH 09/11] fix: try again --- .github/workflows/dhis2-verify-app.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/dhis2-verify-app.yml b/.github/workflows/dhis2-verify-app.yml index f6c78204..b46bbad4 100644 --- a/.github/workflows/dhis2-verify-app.yml +++ b/.github/workflows/dhis2-verify-app.yml @@ -12,6 +12,7 @@ env: GH_TOKEN: ${{secrets.DHIS2_BOT_GITHUB_TOKEN}} CI: true D2_VERBOSE: true + NODE_OPTIONS: --openssl-legacy-provider jobs: install: From ffa85bb95a8bccb0acb8962b8c24ac201855fa97 Mon Sep 17 00:00:00 2001 From: Thomas Zemp Date: Tue, 31 Mar 2026 07:26:01 -0600 Subject: [PATCH 10/11] fix: try with master worfklows --- .github/workflows/comment-and-close.yml | 13 +-- .github/workflows/deploy-pr.yml | 14 +++ .github/workflows/deploy-production.yml | 17 +++ .github/workflows/dhis2-preview-pr.yml | 53 --------- .github/workflows/dhis2-verify-app.yml | 123 --------------------- .github/workflows/dhis2-verify-commits.yml | 38 ------- .github/workflows/lint-pr-title.yml | 13 +++ .github/workflows/test-and-release.yml | 22 ++++ 8 files changed, 72 insertions(+), 221 deletions(-) create mode 100644 .github/workflows/deploy-pr.yml create mode 100644 .github/workflows/deploy-production.yml delete mode 100644 .github/workflows/dhis2-preview-pr.yml delete mode 100644 .github/workflows/dhis2-verify-app.yml delete mode 100644 .github/workflows/dhis2-verify-commits.yml create mode 100644 .github/workflows/lint-pr-title.yml create mode 100644 .github/workflows/test-and-release.yml diff --git a/.github/workflows/comment-and-close.yml b/.github/workflows/comment-and-close.yml index 6aa782a0..a8ddd038 100644 --- a/.github/workflows/comment-and-close.yml +++ b/.github/workflows/comment-and-close.yml @@ -1,13 +1,12 @@ +name: comment-and-close + on: issues: types: [opened] jobs: comment-and-close: - runs-on: ubuntu-latest - steps: - - uses: vardevs/candc@v1 - with: - close-comment: 'If you would like to file a bug report or feature request, please refer to our issue tracker: https://jira.dhis2.org' - exempt-users: dhis2-bot,dependabot,kodiakhq - github-token: ${{secrets.DHIS2_BOT_GITHUB_TOKEN}} + uses: dhis2/workflows-platform/.github/workflows/comment-and-close.yml@v1 + if: '!contains(fromJson(''["dhis2-bot", "kodiakhq", "dependabot"]''), github.event.issue.sender.login)' + with: + issue_number: ${{ github.event.issue.number }} diff --git a/.github/workflows/deploy-pr.yml b/.github/workflows/deploy-pr.yml new file mode 100644 index 00000000..fc915d19 --- /dev/null +++ b/.github/workflows/deploy-pr.yml @@ -0,0 +1,14 @@ +name: deploy-pr + +on: + pull_request: + +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref }} + cancel-in-progress: true + +jobs: + deploy: + uses: dhis2/workflows-platform/.github/workflows/deploy-pr.yml@v1 + if: '!github.event.pull_request.head.repo.fork' + secrets: inherit diff --git a/.github/workflows/deploy-production.yml b/.github/workflows/deploy-production.yml new file mode 100644 index 00000000..9575c2ed --- /dev/null +++ b/.github/workflows/deploy-production.yml @@ -0,0 +1,17 @@ +name: deploy-production + +on: + push: + branches: + - master + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + deploy: + uses: dhis2/workflows-platform/.github/workflows/deploy-production.yml@v1 + secrets: inherit + with: + branch: master diff --git a/.github/workflows/dhis2-preview-pr.yml b/.github/workflows/dhis2-preview-pr.yml deleted file mode 100644 index 8f6cf252..00000000 --- a/.github/workflows/dhis2-preview-pr.yml +++ /dev/null @@ -1,53 +0,0 @@ -name: 'dhis2: pr preview' - -# Requirements: -# -# - Org secrets: -# DHIS2_BOT_NETLIFY_TOKEN -# DHIS2_BOT_GITHUB_TOKEN -# - Repo secrets: -# NETLIFY_SITE_ID -# - Customize the 'jobs.build.steps.netlify-deploy.publish-dir' property - -on: - pull_request: - -concurrency: - group: ${{ github.workflow}}-${{ github.ref }} - cancel-in-progress: true - -jobs: - preview: - runs-on: ubuntu-latest - if: "!github.event.push.repository.fork && github.actor != 'dependabot[bot]'" - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-node@v4 - with: - node-version: 18 - cache: yarn - - - run: yarn install --frozen-lockfile - - - name: Build - run: yarn d2-app-scripts build --standalone - env: - NODE_OPTIONS: --openssl-legacy-provider - - - name: Deploy - id: netlify-deploy - uses: nwtgck/actions-netlify@v1.1 - timeout-minutes: 1 - with: - github-token: ${{ secrets.DHIS2_BOT_GITHUB_TOKEN }} - deploy-message: ${{ github.event.pull_request.title }} - enable-pull-request-comment: true - enable-commit-comment: false - alias: pr-${{ github.event.number }} - # customize according to project needs - publish-dir: 'build/app' - env: - # org secret - NETLIFY_AUTH_TOKEN: ${{ secrets.DHIS2_BOT_NETLIFY_TOKEN }} - # repo secret - NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }} diff --git a/.github/workflows/dhis2-verify-app.yml b/.github/workflows/dhis2-verify-app.yml deleted file mode 100644 index b46bbad4..00000000 --- a/.github/workflows/dhis2-verify-app.yml +++ /dev/null @@ -1,123 +0,0 @@ -name: 'dhis2: verify (app)' - -on: - push: - branches: - -env: - GIT_AUTHOR_NAME: '@dhis2-bot' - GIT_AUTHOR_EMAIL: 'apps@dhis2.org' - GIT_COMMITTER_NAME: '@dhis2-bot' - GIT_COMMITTER_EMAIL: 'apps@dhis2.org' - GH_TOKEN: ${{secrets.DHIS2_BOT_GITHUB_TOKEN}} - CI: true - D2_VERBOSE: true - NODE_OPTIONS: --openssl-legacy-provider - -jobs: - install: - runs-on: ubuntu-latest - if: "!contains(github.event.head_commit.message, '[skip ci]')" - - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-node@v4 - with: - node-version: 18 - - - uses: actions/cache@v4 - id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) - with: - path: '**/node_modules' - key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} - - - name: Install - if: steps.yarn-cache.outputs.cache-hit != 'true' - run: yarn install --frozen-lockfile - - build: - runs-on: ubuntu-latest - needs: install - if: "!contains(github.event.head_commit.message, '[skip ci]')" - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-node@v4 - with: - node-version: 18 - - - uses: actions/cache@v4 - id: yarn-cache - with: - path: '**/node_modules' - key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} - - - name: Build - run: yarn build - - - uses: actions/upload-artifact@v4 - with: - name: app-build - path: | - **/build - !**/node_modules - retention-days: 1 - - lint: - runs-on: ubuntu-latest - needs: install - if: "!contains(github.event.head_commit.message, '[skip ci]')" - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-node@v4 - with: - node-version: 18 - - - uses: actions/cache@v4 - id: yarn-cache - with: - path: '**/node_modules' - key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} - - - name: Build - run: yarn build - - - name: Lint - run: yarn lint - - publish: - runs-on: ubuntu-latest - needs: [build, lint] - if: "!contains(github.event.head_commit.message, '[skip ci]')" - steps: - - uses: actions/checkout@v4 - with: - token: ${{env.GH_TOKEN}} - - - uses: actions/setup-node@v4 - with: - node-version: 18 - - - uses: actions/download-artifact@v4 - with: - name: app-build - - - uses: dhis2/deploy-build@master - with: - build-dir: build/app - github-token: ${{ env.GH_TOKEN }} - - release: - runs-on: ubuntu-latest - needs: [publish] - if: "github.event_name == 'push' && !contains(github.event.head_commit.message, '[skip ci]')" - steps: - - uses: actions/checkout@v4 - with: - token: ${{env.GH_TOKEN}} - - - uses: actions/setup-node@v4 - with: - node-version: 18 - - - name: Publish release to GitHub - run: npx @dhis2/cli-utils release diff --git a/.github/workflows/dhis2-verify-commits.yml b/.github/workflows/dhis2-verify-commits.yml deleted file mode 100644 index 8dc7bd06..00000000 --- a/.github/workflows/dhis2-verify-commits.yml +++ /dev/null @@ -1,38 +0,0 @@ -name: 'dhis2: verify (commits)' - -on: - pull_request: - types: ['opened', 'edited', 'reopened', 'synchronize'] - -jobs: - lint-pr-title: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-node@v4 - with: - node-version: 18 - cache: yarn - - run: yarn install --frozen-lockfile - - id: commitlint - run: echo ::set-output name=config_path::$(node -e "process.stdout.write(require('@dhis2/cli-style').config.commitlint)") - - uses: JulienKode/pull-request-name-linter-action@v0.5.0 - with: - configuration-path: ${{ steps.commitlint.outputs.config_path }} - - lint-commits: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - uses: actions/setup-node@v4 - with: - node-version: 18 - cache: yarn - - run: yarn install --frozen-lockfile - - id: commitlint - run: echo ::set-output name=config_path::$(node -e "process.stdout.write(require('@dhis2/cli-style').config.commitlint)") - - uses: wagoid/commitlint-github-action@v4 - with: - configFile: ${{ steps.commitlint.outputs.config_path }} diff --git a/.github/workflows/lint-pr-title.yml b/.github/workflows/lint-pr-title.yml new file mode 100644 index 00000000..eb59072b --- /dev/null +++ b/.github/workflows/lint-pr-title.yml @@ -0,0 +1,13 @@ +name: lint-pr-title + +on: + pull_request: + types: ['opened', 'edited', 'reopened', 'synchronize'] + +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref }} + cancel-in-progress: true + +jobs: + lint-pr-title: + uses: dhis2/workflows-platform/.github/workflows/lint-pr-title.yml@v1 diff --git a/.github/workflows/test-and-release.yml b/.github/workflows/test-and-release.yml new file mode 100644 index 00000000..f9b8cf80 --- /dev/null +++ b/.github/workflows/test-and-release.yml @@ -0,0 +1,22 @@ +name: test-and-release + +on: push + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + # Cancel previous runs if not on a release branch + cancel-in-progress: ${{ !contains(fromJSON('["refs/heads/master", "refs/heads/main"]'), github.ref) }} + +jobs: + lint-commits: + uses: dhis2/workflows-platform/.github/workflows/lint-commits.yml@v1 + lint: + uses: dhis2/workflows-platform/.github/workflows/lint.yml@v1 + test: + uses: dhis2/workflows-platform/.github/workflows/test.yml@v1 + release: + needs: [lint-commits, lint, test] + uses: dhis2/workflows-platform/.github/workflows/release.yml@v1 + # Skips forks and dependabot PRs + if: '!github.event.push.repository.fork' + secrets: inherit From df2b39fab736933c596eda4d100bebec42e1021f Mon Sep 17 00:00:00 2001 From: Thomas Zemp Date: Tue, 31 Mar 2026 07:45:54 -0600 Subject: [PATCH 11/11] fix: ai attempt --- .github/workflows/deploy-pr.yml | 29 ++++++++++++++++++++++-- .github/workflows/test-and-release.yml | 31 ++++++++++++++++++++++++-- yarn.lock | 24 +++++++++++++++++++- 3 files changed, 79 insertions(+), 5 deletions(-) diff --git a/.github/workflows/deploy-pr.yml b/.github/workflows/deploy-pr.yml index fc915d19..e9d6112b 100644 --- a/.github/workflows/deploy-pr.yml +++ b/.github/workflows/deploy-pr.yml @@ -9,6 +9,31 @@ concurrency: jobs: deploy: - uses: dhis2/workflows-platform/.github/workflows/deploy-pr.yml@v1 + runs-on: ubuntu-latest if: '!github.event.pull_request.head.repo.fork' - secrets: inherit + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: 20 + cache: yarn + - run: yarn install --frozen-lockfile + - run: yarn d2-app-scripts build --standalone + env: + NODE_OPTIONS: --openssl-legacy-provider + - id: netlify-deploy + uses: nwtgck/actions-netlify@v3 + timeout-minutes: 1 + with: + github-token: ${{ secrets.DHIS2_BOT_GITHUB_TOKEN }} + github-deployment-environment: netlify + github-deployment-description: PR Preview on Netlify + deploy-message: ${{ github.event.pull_request.title }} + enable-pull-request-comment: true + enable-commit-comment: true + enable-commit-status: true + alias: pr-${{ github.event.number }} + publish-dir: build/app + env: + NETLIFY_AUTH_TOKEN: ${{ secrets.DHIS2_BOT_NETLIFY_TOKEN }} + NETLIFY_SITE_ID: ${{ secrets.NETLIFY_SITE_ID }} diff --git a/.github/workflows/test-and-release.yml b/.github/workflows/test-and-release.yml index f9b8cf80..7fd10bae 100644 --- a/.github/workflows/test-and-release.yml +++ b/.github/workflows/test-and-release.yml @@ -16,7 +16,34 @@ jobs: uses: dhis2/workflows-platform/.github/workflows/test.yml@v1 release: needs: [lint-commits, lint, test] - uses: dhis2/workflows-platform/.github/workflows/release.yml@v1 + runs-on: ubuntu-latest # Skips forks and dependabot PRs if: '!github.event.push.repository.fork' - secrets: inherit + env: + GIT_AUTHOR_NAME: '@dhis2-bot' + GIT_AUTHOR_EMAIL: apps@dhis2.org + GIT_COMMITTER_NAME: '@dhis2-bot' + GIT_COMMITTER_EMAIL: apps@dhis2.org + steps: + - uses: actions/checkout@v4 + with: + token: ${{ secrets.DHIS2_BOT_GITHUB_TOKEN }} + - uses: actions/setup-node@v4 + with: + node-version: 20 + cache: yarn + - run: yarn install --frozen-lockfile + - run: yarn d2-app-scripts build + env: + NODE_OPTIONS: --openssl-legacy-provider + - uses: dhis2/action-semantic-release@master + with: + publish-apphub: true + publish-github: true + apphub-channel: stable + github-token: ${{ secrets.DHIS2_BOT_GITHUB_TOKEN }} + apphub-token: ${{ secrets.DHIS2_BOT_APPHUB_TOKEN }} + - uses: dhis2/deploy-build@master + with: + build-dir: build/app + github-token: ${{ secrets.DHIS2_BOT_GITHUB_TOKEN }} diff --git a/yarn.lock b/yarn.lock index 188a5dc1..296047fa 100644 --- a/yarn.lock +++ b/yarn.lock @@ -12959,6 +12959,11 @@ perfy@^1.1.5: resolved "https://registry.yarnpkg.com/perfy/-/perfy-1.1.5.tgz#0d629f870a34a3eb1866d3db485d2b3faef29e4b" integrity sha512-/ieVBpMaPTJf83YTUl2TImsSwMEJ23qGP2w27pE6aX+NrB/ZRGqOnQZpl7J719yFwd+ebDiHguPNFeMSamyK7w== +picocolors@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-0.2.1.tgz#570670f793646851d1ba135996962abad587859f" + integrity sha512-cMlDqaLEqfSaW8Z7N5Jw+lyIW869EzT73/F5lhtY9cLGoVxSXznfgfXMO0Z5K0o0Q2TkTXq+0KFsdnSe3jDViA== + picocolors@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.1.1.tgz#3d321af3eab939b083c8f929a1d12cda81c26b6b" @@ -13696,7 +13701,24 @@ postcss-values-parser@^2.0.0, postcss-values-parser@^2.0.1: indexes-of "^1.0.1" uniq "^1.0.1" -postcss@7.0.21, postcss@8.4.31, postcss@^7, postcss@^7.0.0, postcss@^7.0.1, postcss@^7.0.14, postcss@^7.0.17, postcss@^7.0.2, postcss@^7.0.26, postcss@^7.0.27, postcss@^7.0.32, postcss@^7.0.5, postcss@^7.0.6, postcss@^8.1.0: +postcss@7.0.21: + version "7.0.21" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.21.tgz#06bb07824c19c2021c5d056d5b10c35b989f7e17" + integrity sha512-uIFtJElxJo29QC753JzhidoAhvp/e/Exezkdhfmt8AymWT6/5B7W1WmponYWkHk2eg6sONyTch0A3nkMPun3SQ== + dependencies: + chalk "^2.4.2" + source-map "^0.6.1" + supports-color "^6.1.0" + +postcss@^7, postcss@^7.0.0, postcss@^7.0.1, postcss@^7.0.14, postcss@^7.0.17, postcss@^7.0.2, postcss@^7.0.26, postcss@^7.0.27, postcss@^7.0.32, postcss@^7.0.5, postcss@^7.0.6: + version "7.0.39" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.39.tgz#9624375d965630e2e1f2c02a935c82a59cb48309" + integrity sha512-yioayjNbHn6z1/Bywyb2Y4s3yvDAeXGOyxqD+LnVOinq6Mdmd++SW2wUNVzavyyHxd6+DxzWGIuosg6P1Rj8uA== + dependencies: + picocolors "^0.2.1" + source-map "^0.6.1" + +postcss@^8.1.0: version "8.4.31" resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.31.tgz#92b451050a9f914da6755af352bdc0192508656d" integrity sha512-PS08Iboia9mts/2ygV3eLpY5ghnUcfLV/EXTOW1E2qYxJKGGBUtNjN76FYHnMs36RmARn41bC0AZmn+rR0OVpQ==