Skip to content

feat(ci): add StackBlitz templates for e2e apps#540

Open
ryanbas21 wants to merge 1 commit into
mainfrom
feat/stackblitz-templates
Open

feat(ci): add StackBlitz templates for e2e apps#540
ryanbas21 wants to merge 1 commit into
mainfrom
feat/stackblitz-templates

Conversation

@ryanbas21

@ryanbas21 ryanbas21 commented Feb 26, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Adds --template './e2e/*-app' to pkg-pr-new so PR comments include interactive StackBlitz links for all e2e apps (davinci, journey, oidc, device-client, protect)
  • Switches to --pnpm flag for correct pnpm pack behavior in the monorepo
  • Keeps --packageManager=pnpm so PR comments show pnpm add install commands

Test plan

  • Verify the PR CI comment includes StackBlitz "Open in StackBlitz" links for each e2e app
  • Confirm the StackBlitz instances resolve snapshot package versions correctly
  • Verify pnpm pack is used (check CI logs for pack output)

Summary by CodeRabbit

  • Chores
    • Updated CI/CD publishing configuration to include the correct E2E template during the publish step, while preserving the existing package selection globs and keeping pnpm publish behavior unchanged.

@changeset-bot

changeset-bot Bot commented Feb 26, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 83bde57

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@coderabbitai

coderabbitai Bot commented Feb 26, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The CI workflow publish step now includes an additional --template './e2e/*-app' argument in the pnpm pkg-pr-new publish command, while keeping the existing package globs and pnpm publish flags.

Changes

CI Publish Command

Layer / File(s) Summary
Publish command arguments
.github/workflows/ci.yml
The CI publish step adds --template './e2e/*-app' to pnpm pkg-pr-new publish and retains the existing package globs and pnpm flags.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

Poem

🐰 I hopped through CI with a template in sight,
The publish step twinkled and ran just right.
E2E apps joined the prance and the play,
While pnpm kept bouncing along on its way.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title is concise and accurately summarizes the main CI change for StackBlitz templates in e2e apps.
Description check ✅ Passed The description covers the change and test plan, but it misses the Jira ticket section and the template's exact headings.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/stackblitz-templates

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@nx-cloud

nx-cloud Bot commented Feb 26, 2026

Copy link
Copy Markdown
Contributor

View your CI Pipeline Execution ↗ for commit 83bde57

Command Status Duration Result
nx run-many -t build --no-agents ✅ Succeeded <1s View ↗
nx affected -t build lint test typecheck e2e-ci ✅ Succeeded 7m 10s View ↗

💡 Verify your cache is correct by running tasks in a sandbox. Read docs ↗


☁️ Nx Cloud last updated this comment at 2026-06-27 00:13:19 UTC

@pkg-pr-new

pkg-pr-new Bot commented Feb 26, 2026

Copy link
Copy Markdown
More templates

@forgerock/davinci-client

pnpm add https://pkg.pr.new/@forgerock/davinci-client@540

@forgerock/device-client

pnpm add https://pkg.pr.new/@forgerock/device-client@540

@forgerock/journey-client

pnpm add https://pkg.pr.new/@forgerock/journey-client@540

@forgerock/oidc-client

pnpm add https://pkg.pr.new/@forgerock/oidc-client@540

@forgerock/protect

pnpm add https://pkg.pr.new/@forgerock/protect@540

@forgerock/sdk-types

pnpm add https://pkg.pr.new/@forgerock/sdk-types@540

@forgerock/sdk-utilities

pnpm add https://pkg.pr.new/@forgerock/sdk-utilities@540

@forgerock/iframe-manager

pnpm add https://pkg.pr.new/@forgerock/iframe-manager@540

@forgerock/sdk-logger

pnpm add https://pkg.pr.new/@forgerock/sdk-logger@540

@forgerock/sdk-oidc

pnpm add https://pkg.pr.new/@forgerock/sdk-oidc@540

@forgerock/sdk-request-middleware

pnpm add https://pkg.pr.new/@forgerock/sdk-request-middleware@540

@forgerock/storage

pnpm add https://pkg.pr.new/@forgerock/storage@540

commit: 83bde57

@github-actions

github-actions Bot commented Feb 26, 2026

Copy link
Copy Markdown
Contributor

Deployed 9ba6385 to https://ForgeRock.github.io/ping-javascript-sdk/pr-540/9ba63852044f6d4573a2a6837c32ceae72145d75 branch gh-pages in ForgeRock/ping-javascript-sdk

@github-actions

github-actions Bot commented Feb 26, 2026

Copy link
Copy Markdown
Contributor

📦 Bundle Size Analysis

📦 Bundle Size Analysis

🆕 New Packages

🆕 @forgerock/oidc-client - 35.3 KB (new)
🆕 @forgerock/sdk-types - 9.1 KB (new)
🆕 @forgerock/davinci-client - 54.4 KB (new)
🆕 @forgerock/sdk-utilities - 18.6 KB (new)
🆕 @forgerock/device-client - 0.0 KB (new)
🆕 @forgerock/device-client - 10.0 KB (new)
🆕 @forgerock/journey-client - 0.0 KB (new)
🆕 @forgerock/journey-client - 92.6 KB (new)
🆕 @forgerock/protect - 144.6 KB (new)
🆕 @forgerock/iframe-manager - 3.2 KB (new)
🆕 @forgerock/sdk-logger - 1.6 KB (new)
🆕 @forgerock/storage - 1.5 KB (new)
🆕 @forgerock/sdk-request-middleware - 4.6 KB (new)
🆕 @forgerock/sdk-oidc - 5.7 KB (new)


14 packages analyzed • Baseline from latest main build

Legend

🆕 New package
🔺 Size increased
🔻 Size decreased
➖ No change

ℹ️ How bundle sizes are calculated
  • Current Size: Total gzipped size of all files in the package's dist directory
  • Baseline: Comparison against the latest build from the main branch
  • Files included: All build outputs except source maps and TypeScript build cache
  • Exclusions: .map, .tsbuildinfo, and .d.ts.map files

🔄 Updated automatically on each push to this PR

@codecov-commenter

codecov-commenter commented Feb 27, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 23.13%. Comparing base (eafe277) to head (83bde57).
⚠️ Report is 41 commits behind head on main.

❌ Your project status has failed because the head coverage (23.13%) is below the target coverage (40.00%). You can increase the head coverage or adjust the target coverage.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #540      +/-   ##
==========================================
+ Coverage   18.07%   23.13%   +5.06%     
==========================================
  Files         155      161       +6     
  Lines       24398    25602    +1204     
  Branches     1203     1614     +411     
==========================================
+ Hits         4410     5924    +1514     
+ Misses      19988    19678     -310     

see 16 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ancheetah

Copy link
Copy Markdown
Collaborator

How are the templates useful? Is the idea so that we can copy paste the package.json into our e2e locally so we can run the test suites? Also, the templates generated by Stackblitz don't seem to boot up the application in the browser. There might be some error I'm not seeing.

@ryanbas21 ryanbas21 force-pushed the feat/stackblitz-templates branch from 5615d50 to f528f61 Compare May 12, 2026 20:01

@nx-cloud nx-cloud Bot left a comment

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.

Important

At least one additional CI pipeline execution has run since the conclusion below was written and it may no longer be applicable.

Nx Cloud has identified a possible root cause for your failed CI:

We determined these e2e failures are unrelated to this PR's changes, which only affect CI publishing configuration. The same failures are reproducible in branch 576, confirming a pre-existing issue with the external PingAM/ForgeRock OAuth2 service returning invalid_request errors for all authentication flows. The affected projects (@forgerock/protect-suites, @forgerock/oidc-suites) were not touched by this PR.

No code changes were suggested for this issue.

Trigger a rerun:

Rerun CI

Nx Cloud View detailed reasoning on Nx Cloud ↗


🎓 Learn more about Self-Healing CI on nx.dev

@ryanbas21 ryanbas21 force-pushed the feat/stackblitz-templates branch from f528f61 to 33d5a85 Compare May 19, 2026 21:12
@ryanbas21 ryanbas21 force-pushed the feat/stackblitz-templates branch 3 times, most recently from 60a7d52 to 0ee0434 Compare June 17, 2026 16:05
@ryanbas21 ryanbas21 force-pushed the feat/stackblitz-templates branch 5 times, most recently from 536df86 to b2e51c6 Compare June 26, 2026 20:13
Adds --template flag to pkg-pr-new so PR comments include
interactive StackBlitz links for all e2e apps. Also switches
to --pnpm for correct packing in the monorepo.
@ryanbas21 ryanbas21 force-pushed the feat/stackblitz-templates branch from b2e51c6 to 83bde57 Compare June 27, 2026 00:04

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/ci.yml:
- Line 49: The pkg-pr-new publish step is advertising e2e app templates that are
not yet standalone. Update the ci workflow’s publish command so the `--template`
selection only includes apps that can boot independently, or add a preflight in
the publish flow to skip/reject templates that still rely on workspace/catalog
resolution or `pnpm nx` monorepo scripts.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: c42b6b85-a905-4435-89ab-12a7d7af110c

📥 Commits

Reviewing files that changed from the base of the PR and between b2e51c6 and 83bde57.

📒 Files selected for processing (1)
  • .github/workflows/ci.yml

Comment thread .github/workflows/ci.yml
run: pnpm nx run-many -t build --no-agents

- run: pnpm pkg-pr-new publish './packages/*' './packages/sdk-effects/*' --pnpm --packageManager=pnpm
- run: pnpm pkg-pr-new publish './packages/*' './packages/sdk-effects/*' --template './e2e/*-app' --pnpm --packageManager=pnpm

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🗄️ Data Integrity & Integration | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

fd -p package.json e2e | while read -r pkg; do
  echo "== $pkg =="
  echo "-- package links --"
  jq -r '
    ((.dependencies // {}) + (.devDependencies // {}) + (.peerDependencies // {}))
    | to_entries[]
    | select(.value | test("^(workspace:|file:|link:|catalog:)"))
    | "  \(.key): \(.value)"
  ' "$pkg" || true

  echo "-- scripts --"
  jq -r '
    (.scripts // {})
    | to_entries[]
    | "  \(.key): \(.value)"
  ' "$pkg"
  echo
done

echo "Potential monorepo-only references:"
rg -n --glob 'e2e/*-app/package.json' '"(workspace:|file:|link:|catalog:)|(\.\./)|(\bnx\b)|(\bpnpm -r\b)|(\bturbo\b)' .

Repository: ForgeRock/ping-javascript-sdk

Length of output: 5319


Don't publish the e2e/*-app templates yet

Line 49 now advertises apps that still depend on workspace/catalog resolution and pnpm nx scripts, so pkg-pr-new will keep publishing templates that can't boot in isolation. Gate --template to standalone apps, or add a preflight that rejects monorepo-only deps/scripts before publishing.

🧰 Tools
🪛 zizmor (1.26.1)

[info] 49-49: prefer trusted publishing for authentication (use-trusted-publishing): this command

(use-trusted-publishing)

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/ci.yml at line 49, The pkg-pr-new publish step is
advertising e2e app templates that are not yet standalone. Update the ci
workflow’s publish command so the `--template` selection only includes apps that
can boot independently, or add a preflight in the publish flow to skip/reject
templates that still rely on workspace/catalog resolution or `pnpm nx` monorepo
scripts.

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

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants