hcengineering / hcengineering/platform

@hcengineering/* 0.7.423 still missing TypeScript declarations despite PR #10768

Open
#10,881 4 comments 1 reaction 0 assignees View on GitHub
Dominant language
TypeScript
Stars
27.7k
Forks
2.2k
PR merge metrics
No merged PRs in 30d

Description

## Problem

Published tarballs of `@hcengineering/*` packages at version `0.7.423` (published 2026-05-10) still ship without `types/*.d.ts` files, despite PR #10768 having been merged on 2026-04-15.

## Evidence

```bash
$ npm pack @hcengineering/core@0.7.423
$ tar -tzf hcengineering-core-0.7.423.tgz | grep -c "\.d\.ts$"
0 # zero .d.ts files

$ npm pack @hcengineering/core@0.7.19
$ tar -tzf hcengineering-core-0.7.19.tgz | grep -c "\.d\.ts$"
20+ # types/ directory present in older release
```

| Version | Files in tarball | .d.ts files |
|---------|------------------|-------------|
| `@hcengineering/core@0.7.19` | 230 | yes |
| `@hcengineering/core@0.7.423` | 157 | none |

`package.json` in 0.7.423 still declares `"types": "types/index.d.ts"`, but the file is not in the tarball, so TypeScript consumers get `TS7016: Could not find a declaration file for module '@hcengineering/core'`.

## Context

- PR #10768 added the `Emit TypeScript declarations` step (`rush validate`) to `publish-npm.yml` and was merged into `develop` (commit `cc9c8b87`).
- The `gitHead` of 0.7.423 is `a00c0135` (commit "Bump version" on 2026-05-10), which is **426 commits ahead** of the PR #10768 merge commit — so the fix is in the publishing source tree.
- The current `publish-npm.yml` on `develop` still has the `Emit TypeScript declarations` step. So either:
- `rush validate` is silently failing inside that step (no error surfaced); or
- `safe-publish.js` is invoking `npm publish` from a stage where `types/` has been cleaned/not yet generated; or
- The 0.7.423 publish was kicked off through a different path that bypasses the workflow.

Affected packages (all 0.7.411+, sampled):
- `@hcengineering/core`
- `@hcengineering/account-client`
- `@hcengineering/api-client`
- `@hcengineering/tracker`
- `@hcengineering/task`
- `@hcengineering/card`
- `@hcengineering/contact`
- `@hcengineering/calendar`
- `@hcengineering/text`, `@hcengineering/text-markdown`
- (probably all `@hcengineering/*` packages published from this monorepo)

## Impact

Downstream TypeScript consumers (Huly MCP servers, custom integrations, the official `huly-examples` repo) cannot consume any `@hcengineering/*` version newer than `0.7.382` without manually shimming declarations. This blocks adoption of cards processes, associations, automation, user statuses, time service, and every other feature added since 0.7.382.

## Suggested fix

1. Trigger the `publish-npm.yml` workflow again and verify `Emit TypeScript declarations` actually produces `types/index.d.ts` for at least `@hcengineering/core` before `safe-publish.js` runs.
2. If a silent failure is suspected, add `ls -la /types/index.d.ts || (echo "::error::types/ missing" && exit 1)` between validate and publish to fail loudly.
3. Re-publish as `0.7.424` with declarations intact.

Happy to verify the result by re-installing in our consumer project once a new version is up.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.