Skip to content

fix(runtime): export core interface declarations - #11

Merged
Upd4ting merged 2 commits into
mainfrom
fix/export-core-declarations
Aug 24, 2026
Merged

fix(runtime): export core interface declarations#11
Upd4ting merged 2 commits into
mainfrom
fix/export-core-declarations

Conversation

@Upd4ting

@Upd4ting Upd4ting commented Aug 21, 2026

Copy link
Copy Markdown
Member

Summary

  • re-export the module and runtime declarations from the package root
  • keep root and subpath imports bound to the same canonical proxy instances
  • cover source and packed-package discovery contracts

Root cause

Core provider routing discovers proxy identities from each canonical interface package root. @antelopejs/interface-core@0.0.11 exposed GetRuntimeInfo, RegisterDevServer, and the module lifecycle declarations only through subpaths, so consumers received no routes for those proxies even though the Core providers were registered.

The root aggregate is safe because it exports the existing canonical declarations; it does not create duplicate proxies. The subpath modules import their constructors from the already-initialized root and the cycle is covered by both source and packed-consumer tests.

Validation

  • pnpm install --frozen-lockfile
  • pnpm lint
  • pnpm build
  • source interface suite with published Core 1.4.7: 73 passing
  • pnpm test:package
  • git diff --check

Recommended next release: 0.0.12. No merge or publication is performed by this PR.

Greptile Summary

The PR exposes module and runtime declarations from the package root while preserving canonical proxy instances.

  • Moves InterfaceFunction into the cycle-free proxy module.
  • Re-exports module and runtime declarations from the root entrypoint.
  • Adds source and packed-package coverage for both CommonJS import orders.

Confidence Score: 5/5

The PR appears safe to merge.

No blocking failure remains; the previously reported import-order cycle is removed by direct proxy-module imports and both loading orders are covered.

Important Files Changed

Filename Overview
src/index.ts Re-exports the canonical module and runtime declarations without retaining the former cyclic constructor dependency.
src/proxies.ts Becomes the cycle-free owner of the existing InterfaceFunction implementation.
src/modules.ts Imports proxy primitives directly, removing the root-entrypoint initialization cycle.
src/runtime.ts Imports InterfaceFunction directly from the proxy module, avoiding root re-entry.
src/tests/root-declarations.test.ts Verifies declaration identity and completeness in fresh CommonJS processes under both import orders.
test/package-consumer.mjs Extends packed-package contracts to verify root exports, proxy identity, and both consumer import orders.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart LR
  Root[src/index.ts] --> Modules[src/modules.ts]
  Root --> Runtime[src/runtime.ts]
  Root --> Proxies[src/proxies.ts]
  Modules --> Proxies
  Runtime --> Proxies
Loading

Reviews (2): Last reviewed commit: "fix(runtime): remove declaration import ..." | Re-trigger Greptile

Copy link
Copy Markdown
Member Author

@greptile review

Comment thread src/index.ts

Copy link
Copy Markdown
Member Author

@greptile review

@Upd4ting
Upd4ting merged commit 8e98b8a into main Aug 24, 2026
3 checks passed
@Upd4ting
Upd4ting deleted the fix/export-core-declarations branch August 24, 2026 18:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant