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
Check for undefined globalObjectType in getPropertyOfObjectType #47183
Conversation
This can happen during symbol merging when initialising the checker, because global types aren't set until after symbols are merged. May stop the crashes in #47179, #47181, #47180. Does not address the underlying problem of needing to resolve aliases, and therefore names, during symbol merging when initialising the checker.
@typescript-bot pack this |
Hey @sandersn, I've packed this into an installable tgz. You can install it for testing by referencing it in your
and then running There is also a playground for this build and an npm module you can use via |
I manually patched it into |
Yes! This fixes the crash in tsdjs/tsd#137. FYI @sandersn if you're looking for a repro. The |
I switched to |
@JoshuaKGoldberg do you remember what you did to get that crash? |
Oh sorry I wasn't clear @DanielRosenwasser -- the real issue report is tsdjs/tsd#136. git clone https://github.com/League-of-Foundry-Developers/foundry-vtt-types
cd foundry-vtt-types
git checkout 6cd18412b0ab71584951d4fb1f2a08482aba495d
npm i
npm run test Note that it uses |
We're going with the fix at #47348 |
It might be worth sorting through the initialisation problems that this PR partly fixes, though. |
This can happen during symbol merging when initialising the checker, because global types aren't set until after symbols are merged.
May stop the crashes in #47179, #47181, #47180.
Does not address the underlying problem of needing to resolve aliases, and therefore names, during symbol merging when initialising the checker.
I created this PR so it would be easier for others to see if this is actually fixes their crashes.