Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .changeset/breezy-actors-sell.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
'@forgerock/storage': minor
---

feat: Update storage package

- Updated ESLint configurations for consistent code style and linting rules.
- Ensured compatibility with `verbatimModuleSyntax` by correcting type-only imports and module exports.
7 changes: 7 additions & 0 deletions .changeset/bright-lights-yawn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
'@forgerock/sdk-utilities': minor
---

feat: Update SDK utilities

- Inlined `REQUESTED_WITH` and `X_REQUESTED_PLATFORM` constants with literal types for better tree-shaking and type narrowing.
8 changes: 8 additions & 0 deletions .changeset/good-games-accept.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
'@forgerock/iframe-manager': minor
---

feat: Update iframe-manager

- Updated ESLint configurations for consistent code style and linting rules.
- Ensured compatibility with `verbatimModuleSyntax` by correcting type-only imports and module exports.
11 changes: 11 additions & 0 deletions .changeset/kind-guests-sneeze.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
'@forgerock/journey-client': minor
---

feat: Implement new journey client

- Implemented a new `journey()` factory function for creating stateful client instances.
- Integrated Redux Toolkit and RTK Query for robust state management and API interactions.
- Refactored `resume` logic to correctly persist and retrieve plain `Step` payloads, resolving prototype loss issues during serialization.
- Improved error handling and type safety within the client.
- Updated internal callback handling and device profiling integration.
11 changes: 11 additions & 0 deletions .changeset/orange-peaches-warn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
'@forgerock/journey-client': minor
---

feat(journey-client): Add WebAuthn, QR Code, and Recovery Code support

- Introduces new utility modules (`FRWebAuthn`, `FRQRCode`, `FRRecoveryCodes`) to handle advanced authentication methods within authentication journeys.
- Adds comprehensive parsing and handling for WebAuthn registration and authentication steps, including a fix for a type error where `TextOutputCallback` was being incorrectly inferred as `TextInputCallback`.
- Implements support for displaying QR codes (for both OTP and Push) and for displaying and using recovery codes.
- Includes extensive unit tests for the new callback types and utility modules to ensure correctness.
- Updates documentation to reflect the new capabilities and architectural changes.
8 changes: 8 additions & 0 deletions .changeset/tender-schools-scream.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
'@forgerock/sdk-types': minor
---

feat: Update SDK types

- Updated ESLint configurations for consistent code style and linting rules.
- Ensured compatibility with `verbatimModuleSyntax` by correcting type-only imports and module exports.
8 changes: 8 additions & 0 deletions .changeset/wild-items-stop.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
'@forgerock/sdk-logger': minor
---

feat: Update SDK logger

- Updated ESLint configurations for consistent code style and linting rules.
- Ensured compatibility with `verbatimModuleSyntax` by correcting type-only imports and module exports.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ jobs:

- uses: codecov/codecov-action@v5
with:
files: ./packages/**/coverage/*.xml
directory: ./packages/
token: ${{ secrets.CODECOV_TOKEN }}

- uses: actions/upload-artifact@v4
Expand Down
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -79,3 +79,7 @@ packages/davinci-client/src/lib/mock-data/*.d.ts.map
test-output
.cursor/rules/nx-rules.mdc
.github/instructions/nx.instructions.md

# Gemini local knowledge base files
GEMINI.md
**/GEMINI.md
2 changes: 1 addition & 1 deletion .whitesource
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"enableScan": true,
"scanPullRequests": true,
"incrementalScan": false,
"baseBranches": ["integration"]
"baseBranches": ["main"]
},
"checkRunSettingsSAST": {
"checkRunConclusionLevel": "failure",
Expand Down
91 changes: 0 additions & 91 deletions CLAUDE.md

This file was deleted.

69 changes: 43 additions & 26 deletions codecov.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,36 @@
# A more comprehensive Codecov configuration
codecov:
require_ci_to_pass: false
# Require CI to pass before Codecov processes reports. This ensures that
# coverage is only measured on successful builds.
require_ci_to_pass: true
notify:
wait_for_ci: false
# Wait for CI to finish before sending notifications.
wait_for_ci: true

coverage:
# Set a higher default target for project and patch coverage.
# This encourages a better testing culture.
status:
project:
default:
target: 40%
threshold: 1%
target: 70%
threshold: 2% # Allow for a small drop in coverage
patch:
default:
target: 40%
threshold: 1%
target: 80% # New code should be well-tested
threshold: 0% # Do not allow new code to decrease coverage

parsers:
v1:
include_full_missed_files: true

# Configure how coverage is displayed.
range: '70...100'
round: down
precision: 2

# Ignore files that are not relevant for code coverage.
# This keeps the coverage report clean and focused on the source code.
ignore:
- '**/dist/**/*'
- '**/*.mock*'
Expand All @@ -35,33 +48,37 @@ ignore:
- '**/*.md'
- '**/LICENSE'
- '**/*.json'
- 'e2e/**/*' # E2E tests are not unit tests
- 'tools/**/*' # Tooling scripts
- 'scripts/**/*' # Other scripts

# Configure the comment that Codecov posts on pull requests.
comment:
layout: 'header, diff, files'
layout: 'header, diff, components, files'
behavior: default
require_changes: false
require_base: false
require_head: true
hide_project_coverage: false

bundle_analysis:
status: 'informational'
require_changes: false # Post a comment even if there are no coverage changes
require_head: true # Only post a comment if there is a coverage report for the head commit

flag_management:
component_management:
default_rules:
# Carry forward coverage from previous commits for all components.
carryforward: true
statuses:
- type: project
target: 40%
- type: patch
target: 40%
individual_flags:
- name: package-*
individual_components:
Comment on lines +62 to +66
Copy link

Choose a reason for hiding this comment

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

⚠️ Potential issue

🧩 Analysis chain

carryforward under component_management is likely ignored; move carryforward to flags or drop it.

Docs show component_management supports paths/flag_regexes/statuses; carryforward is a Flags concept. If you need carryforward, configure it under flag_management and upload with flags, or remove here.

Suggested removal:

 component_management:
   default_rules:
-    # Carry forward coverage from previous commits for all components.
-    carryforward: true

If you do want carryforward, introduce flags:

flag_management:
  default_rules:
    carryforward: true
    statuses:
      - type: project
        target: auto
        threshold: 2%
      - type: patch
        target: 90%
        threshold: 1%

Refs: Components don’t require upload-time flags and their statuses mirror flag rules but don’t accept flags; carryforward is documented with flags. (docs.codecov.com)

Run a quick YAML validation:


🏁 Script executed:

#!/bin/bash
# Validate current codecov.yml against Codecov API
curl -sS https://api.codecov.io/validate \
  -H "Content-Type: text/plain" \
  --data-binary @codecov.yml | jq .

Length of output: 56


🏁 Script executed:

#!/bin/bash
set -euo pipefail
echo "---- codecov.yml (first 240 lines) ----"
if [ ! -f codecov.yml ]; then
  echo "codecov.yml not found"
  exit 0
fi
nl -ba codecov.yml | sed -n '1,240p'

echo
echo "---- occurrences of 'carryforward' ----"
rg -n "carryforward" -S || true

echo
echo "---- occurrences of 'component_management' ----"
rg -n "component_management" -S || true

echo
echo "---- show component_management context (if present) ----"
cm_line=$(rg -n "component_management" -S | head -n1 | cut -d: -f1 || true)
if [ -n "$cm_line" ]; then
  echo "component_management appears at line: $cm_line"
  nl -ba codecov.yml | sed -n "$((cm_line-3)),$((cm_line+40))p"
fi

Length of output: 80


🏁 Script executed:

#!/bin/bash
set -euo pipefail

if [ ! -f codecov.yml ]; then
  echo "codecov.yml not found"
  exit 0
fi

echo "---- codecov.yml (first 240 lines with numbers) ----"
awk '{printf "%5d: %s\n", NR, $0}' codecov.yml | sed -n '1,240p' || true

echo
echo "---- search for 'carryforward' and 'component_management' (with context) ----"
if command -v rg >/dev/null 2>&1; then
  rg -n -C3 -S "carryforward|component_management" codecov.yml || true
else
  grep -n -C3 -E "carryforward|component_management" codecov.yml || true
fi

echo
echo "---- component_management block (first match, +200 lines) ----"
if command -v rg >/dev/null 2>&1; then
  cm_match=$(rg -n "^\s*component_management\s*:" -S codecov.yml | head -n1 || true)
else
  cm_match=$(grep -n "^\s*component_management\s*:" codecov.yml | head -n1 || true)
fi

if [ -n "${cm_match:-}" ]; then
  line=$(echo "$cm_match" | cut -d: -f1)
  start=$((line-3)); if [ "$start" -lt 1 ]; then start=1; fi
  end=$((line+200))
  awk "NR>=$start && NR<=$end {printf \"%5d: %s\n\", NR, \$0}" codecov.yml || true
fi

Length of output: 5205


Move/remove carryforward from component_management — it's ignored there.

carryforward is a Flags/flag_management feature; component_management.default_rules accepts paths/flag_regexes/statuses and does not support carryforward. (docs.codecov.com)

Action: remove this key or move it to flag_management.default_rules (or per-flag under flags). Location: codecov.yml lines 62–65.

🤖 Prompt for AI Agents
In codecov.yml around lines 62 to 66, the component_management.default_rules
block contains a carryforward key which is invalid there; remove the
carryforward entry from component_management.default_rules and either place it
under flag_management.default_rules or under individual flag entries in flags
(or omit it entirely) so that carryforward is defined in the
Flags/flag_management section where Codecov supports it.

# This rule applies to all components that start with "package-".
# It is expected that the CI script uploads coverage reports with components
# like "package-davinci-client", "package-oidc-client", etc.
# This makes the configuration future-proof for new packages.
- component_id: package-*
paths:
- packages/*/
carryforward: true
- packages/ # Only consider files in the packages directory for these components
statuses:
- type: project
target: 40%
target: 80% # Higher target for packages
threshold: 2%
- type: patch
target: 40%
target: 90% # New code in packages should be very well-tested
threshold: 0%

# Enable bundle analysis to track the size of the published packages.
bundle_analysis:
status: 'informational'
Empty file removed e2e/mock-api-v2/GEMINI.md
Empty file.
3 changes: 3 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ export default [
ignores: [
'**/dist',
'**/docs',
'**/node_modules',
'**/coverage',
'**/tmp',
'**/vite.config.*.timestamp*',
'**/vitest.config.*.timestamp*',
'**/out-tsc',
Expand Down
24 changes: 13 additions & 11 deletions nx.json
Original file line number Diff line number Diff line change
Expand Up @@ -133,24 +133,26 @@
"watchDepsTargetName": "vite:watch-deps"
},
"include": ["packages/**/**/*", "e2e/**/**/*", "tools/**/**/*"]
},
{
"plugin": "@nx/js/typescript",
"include": ["packages/journey-client/**"],
"options": {
"typecheck": {
"targetName": "typecheck"
},
"build": {
"targetName": "build",
"configName": "tsconfig.lib.json"
}
}
}
],
"parallel": 1,
"workspaceLayout": {
"appsDir": "",
"libsDir": ""
},
"generators": {
"@nx/js:library": {
"outDir": "{projectRoot}/dist",
"unitTestRunner": "vitest"
},
"@nx/web:application": {
"style": "css",
"unitTestRunner": "none",
"e2eTestRunner": "playwright"
}
},
"useDaemonProcess": true,
"useInferencePlugins": true,
"defaultBase": "main",
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"ci:release": "pnpm publish -r --no-git-checks && changeset tag",
"ci:version": "changeset version && pnpm install --no-frozen-lockfile && pnpm nx format:write --uncommitted",
"circular-dep-check": "madge --circular .",
"clean": "shx rm -rf ./{coverage,dist,docs,node_modules,tmp}/ ./{packages,e2e}/*/{dist,node_modules}/ && git clean -fX -e \"!.env*,nx-cloud.env\"",
"clean": "shx rm -rf ./{coverage,dist,docs,node_modules,tmp}/ ./{packages,e2e}/*/{dist,node_modules}/ && git clean -fX -e \"!.env*,nx-cloud.env\" -e \"!**/GEMINI.md\"",
"commit": "git cz",
"commitlint": "commitlint --edit",
"create-package": "nx g @nx/js:library",
Expand Down
8 changes: 2 additions & 6 deletions packages/davinci-client/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,14 +46,10 @@ export default defineConfig({
'**/vitest.{workspace,projects}.[jt]s?(on)',
'**/.{eslint,mocha,prettier}rc.{?(c|m)js,yml}',
],
reporter: [
['text', { skipEmpty: true }],
['html', { skipEmpty: true }],
['json', { skipEmpty: true }],
],
reporter: ['text', 'html', 'json'],
enabled: Boolean(process.env['CI']),
reportsDirectory: './coverage',
provider: 'v8',
provider: 'v8' as const,
},
},
});
Binary file modified packages/device-client/vite.config.ts
Binary file not shown.
Loading
Loading