Skip to content

FE-726: generate ds-helpers styled-system before publishing#8732

Merged
lunelson merged 9 commits into
mainfrom
ln/fe-726-ds-helpers-tarball
May 20, 2026
Merged

FE-726: generate ds-helpers styled-system before publishing#8732
lunelson merged 9 commits into
mainfrom
ln/fe-726-ds-helpers-tarball

Conversation

@lunelson
Copy link
Copy Markdown
Contributor

@lunelson lunelson commented May 19, 2026

🌟 What is the purpose of this PR?

Ensure the generated Panda styled-system/ files are present in the @hashintel/ds-helpers npm tarball when the package is packed/published, without committing that generated output to git.

This fixes the broken @hashintel/ds-helpers@0.2.0 package shape reported in FE-726, where the published tarball included export paths pointing at styled-system/ but omitted the generated directory itself.

🔗 Related links

🚫 Blocked by

  • Not blocked

🔍 What does this change?

  • Adds a prepack script to @hashintel/ds-helpers so packaging runs Turbo codegen before npm assembles the tarball.
  • Adds a no-op codegen script for @hashintel/ds-helpers, making it addressable in the Turbo graph.
  • Adds libs/@hashintel/ds-helpers/turbo.json so ds-helpers#codegen depends on @hashintel/ds-components#codegen, which is the source-owned generator that writes ../ds-helpers/styled-system.
  • Overrides ds-helpers#build locally to avoid a Turbo dependency cycle while preserving styled-system/ as generated, gitignored output.
  • Adds a patch changeset for @hashintel/ds-helpers.

Pre-Merge Checklist 🚀

🚢 Has this modified a publishable library?

This PR:

  • modifies an npm-publishable library and I have added a changeset file(s)

📜 Does this require a change to the docs?

The changes in this PR:

  • are internal and do not require a docs change

🕸️ Does this require a change to the Turbo Graph?

The changes in this PR:

  • affected the execution graph, and the turbo.json's have been updated to reflect this

⚠️ Known issues

The already-published @hashintel/ds-helpers@0.2.0 tarball cannot be changed in place; this will publish a patched package version with the generated files included.

🐾 Next steps

After merge, publish the changeset release for @hashintel/ds-helpers so consumers can upgrade to the fixed package version.

🛡 What tests cover this?

  • Manual package verification with npm pack --dry-run --json from libs/@hashintel/ds-helpers, after deleting local styled-system/.
  • Manual Turbo verification with turbo run codegen --filter @hashintel/ds-helpers.

❓ How to test this?

  1. Remove any local generated output: rm -rf libs/@hashintel/ds-helpers/styled-system
  2. Run: cd libs/@hashintel/ds-helpers && npm pack --dry-run --json
  3. Confirm prepack runs turbo run codegen --filter @hashintel/ds-helpers.
  4. Confirm the pack output includes styled-system/ files, e.g. styled-system/css/index.mjs and styled-system/tokens/index.mjs.

📹 Demo

N/A — packaging fix only.

@vercel
Copy link
Copy Markdown

vercel Bot commented May 19, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
hash Ready Ready Preview, Comment May 20, 2026 8:23am
hashdotdesign-tokens Ready Ready Preview, Comment May 20, 2026 8:23am
petrinaut Ready Ready Preview May 20, 2026 8:23am

@github-actions github-actions Bot added area/infra Relates to version control, CI, CD or IaC (area) area/libs Relates to first-party libraries/crates/packages (area) type/eng > frontend Owned by the @frontend team area/apps > hash.design Affects the `hash.design` design site (app) labels May 19, 2026
Copy link
Copy Markdown
Contributor Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

@lunelson lunelson changed the title FE-726: ensure that ds-helpers is generated by ds-components, before it is published FE-726: generate ds-helpers styled-system before publishing May 19, 2026
@lunelson lunelson marked this pull request as ready for review May 19, 2026 17:20
@cursor
Copy link
Copy Markdown

cursor Bot commented May 19, 2026

PR Summary

Medium Risk
Adjusts Turbo task dependencies and npm packaging hooks for @hashintel/ds-helpers, which could affect build/publish behavior and caching if misconfigured. No runtime logic changes, but a bad graph edge could reintroduce cycles or ship missing artifacts.

Overview
Ensures @hashintel/ds-helpers publishes its generated styled-system/** output without committing it to git by running Turbo codegen during npm pack/npm publish.

Adds a local turbo.json that makes ds-helpers#codegen depend on @hashintel/ds-components#codegen (and overrides build deps to avoid a Turbo cycle), plus a prepack hook and no-op codegen script in package.json to materialize styled-system/** before packing. Includes a patch changeset and clarifies the package boundary rules in AGENTS.md.

Reviewed by Cursor Bugbot for commit 4fa497b. Bugbot is set up for automated code reviews on this repo. Configure here.

@lunelson lunelson requested a review from indietyp May 19, 2026 17:21
@augmentcode
Copy link
Copy Markdown

augmentcode Bot commented May 19, 2026

🤖 Augment PR Summary

Summary: Ensures the published @hashintel/ds-helpers tarball includes the Panda-generated styled-system/ output by running codegen during prepack.

Changes: Adds a no-op codegen script plus a package-local turbo.json task graph (and a patch changeset) so packing triggers generation without committing the output.

🤖 Was this summary useful? React with 👍 or 👎

Copy link
Copy Markdown

@augmentcode augmentcode Bot left a comment

Choose a reason for hiding this comment

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

Review completed. 2 suggestions posted.

Fix All in Augment

Comment augment review to trigger a new review at any time.

Comment thread libs/@hashintel/ds-helpers/turbo.json
Comment thread libs/@hashintel/ds-helpers/package.json
Comment thread libs/@hashintel/ds-helpers/turbo.json Outdated
Comment thread libs/@hashintel/ds-helpers/package.json Outdated
Copy link
Copy Markdown

@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 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 54853b1. Configure here.

Comment thread libs/@hashintel/ds-helpers/turbo.json
@lunelson lunelson force-pushed the ln/fe-726-ds-helpers-tarball branch from 569349d to bca3f59 Compare May 20, 2026 07:26
Comment thread libs/@hashintel/ds-helpers/package.json Outdated
@lunelson lunelson added this pull request to the merge queue May 20, 2026
Merged via the queue into main with commit c0c9498 May 20, 2026
47 checks passed
@lunelson lunelson deleted the ln/fe-726-ds-helpers-tarball branch May 20, 2026 12:47
@hashdotai hashdotai mentioned this pull request May 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/apps > hash.design Affects the `hash.design` design site (app) area/infra Relates to version control, CI, CD or IaC (area) area/libs Relates to first-party libraries/crates/packages (area) type/eng > frontend Owned by the @frontend team

Development

Successfully merging this pull request may close these issues.

FE-726: @hashintel/ds-helpers@0.2.0 published tarball is missing the entire styled-system/ directory

2 participants