Skip to content

fix(types): show the warning about older types once per SDK version - #92

Open
m1ga wants to merge 2 commits into
mainfrom
fix/types-warning-once
Open

m1ga wants to merge 2 commits into
mainfrom
fix/types-warning-once

Conversation

@m1ga

@m1ga m1ga commented Nov 22, 2026

Copy link
Copy Markdown

Until types are updated:

The server replaces a project each time its tiapp.xml changes. Each replacement resolved the types again and showed the same warning again. A workspace with several projects on one SDK also showed it once per project.

The service now remembers each warning message that it showed. It shows a message one time for the life of the server. The message names the SDK, so a different SDK version still gets its own warning. The server still writes the message to the log each time.

The server replaces a project each time its tiapp.xml changes. Each
replacement resolved the types again and showed the same warning again.
A workspace with several projects on one SDK also showed it once per
project.

The service now remembers each warning message that it showed. It shows
a message one time for the life of the server. The message names the
SDK, so a different SDK version still gets its own warning. The server
still writes the message to the log each time.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@m1ga
m1ga requested a review from ewanharris November 22, 2026 18:43
Comment thread CHANGELOG.md Resolved
Comment thread src/server/service.ts
private diagnosed = new Set<string>();
/** The projects already told their types are too old to warn from, so it is said once */
private explained = new Set<string>();
/** The warnings already shown, so a project opened again does not interrupt with the same one */

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This will just persist in memory right, not on disk? So it would stil warn every open?

@m1ga m1ga Nov 24, 2026 •

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

only for that session, didn't want to write it somewhere as it is hopefully just a short term fix. Another option was to disable the warning completely for now

release-please writes the changelog after #91 merges, so the entry is not
needed here.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@m1ga

m1ga commented Nov 25, 2026

Copy link
Copy Markdown
Author

The types are finally merged. I still think this is a valid improvement as we'll have to deal with it the next time the SDK updates 😄 This will reduce the warnings to one session

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.

2 participants