-
Notifications
You must be signed in to change notification settings - Fork 288
migrate ts package to esm exports only #2489
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: canary
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for GitHub.
|
🌿 Preview your docs: https://boundary-preview-e71d1a35-e849-4384-8575-8f54a52f6df3.docs.buildwithfern.com |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
🔒 Entelligence AI Vulnerability Scanner ❌ Security analysis failed: Security analysis failed: Command exited with code 1 and error: |
Review Summary🏷️ Draft Comments (8)
🔍 Comments beyond diff scope (4)
|
const props = this.rawProperties() | ||
return Object.keys(props).map((name) => [name, new ClassPropertyViewer()]) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
correctness: ClassViewer.listProperties()
and ClassBuilder.listProperties()
return all properties from the underlying class, not just those in the properties
set, which can cause contract violations and unexpected results.
🤖 AI Agent Prompt for Cursor/Windsurf
📋 Copy this prompt to your AI coding assistant (Cursor, Windsurf, etc.) to get help fixing this issue
In engine/language_client_typescript/typescript_src/type_builder.ts, lines 173-175, the implementation of ClassViewer.listProperties() returns all properties from the underlying class, not just those tracked in the `properties` set. This can violate the class contract and produce unexpected results. Update the method so it only returns properties present in `this.properties` and that exist in the raw properties object.
📝 Committable Code Suggestion
‼️ Ensure you review the code suggestion before committing it to the branch. Make sure it replaces the highlighted code, contains no missing lines, and has no issues with indentation.
const props = this.rawProperties() | |
return Object.keys(props).map((name) => [name, new ClassPropertyViewer()]) | |
} | |
const props = this.rawProperties() | |
return Array.from(this.properties).filter((name) => name in props).map((name) => [name, new ClassPropertyViewer()]) |
🌿 Preview your docs: https://boundary-preview-6ca0bb2e-77ea-4266-81a1-4e651e352f85.docs.buildwithfern.com |
Done mostly by codex. seems to pass the failing imports in typescript-esm now. But need to run the react code still