feat: Add strict typing to a lot of packages#720
Merged
Conversation
Add explicit type annotations and `: ()` return types and resolve all strict errors. Inline the EnabledMixin surface since the old solver cannot intersect it, and fix a latent ActiveAction.Value comparison that prevented deactivation cleanup.
Add explicit type annotations and `: ()` return types to MarketplaceServiceCache and resolve all strict errors.
Add explicit type annotations and `: ()` return types to OverriddenProperty and resolve all strict errors.
Add explicit type annotations and `: ()` return types and resolve all strict errors. Add the @quenty/rx dependency required for Observable typing.
Add explicit type annotations and `: ()` return types to RadialImage and resolve all strict errors.
Add explicit type annotations and `: ()` return types across the snackbar service, story, and option utils, and resolve all strict errors.
Add explicit type annotations and `: ()` return types to the Time library and resolve all strict errors.
Record the explicit `: ()` no-return annotation convention, the EnabledMixin/invariant-generic old-solver workarounds, and a warning that omitting --defs=globalTypes.d.lua produces false unknown-global errors on tick/time.
…fixes, selene _self/shadowing) + add selene dimension to eval scorer
…ast Tie :Implement receiver
…minal analyze errors
…hrough selfAny (any) to kill nominal flake
…uau-lsp V1 symlink-nominal flake, unreproducible locally)
…ict escape from PR #720
…operty RogueProperty defines a custom __index/__newindex that errors on unknown keys, so its fields must be assigned before the metatable is applied and its internal reads must use rawget to bypass the metamethod. The --!strict conversion hoisted setmetatable above the constructor's field assignments and rewrote three rawget(self, "_x") reads as self._x, both of which broke it at runtime: every field assignment threw "Bad index", crashing construction of every RogueProperty and RoguePropertyTable. Build the plain table first and apply the metatable last, and restore the rawget reads (keeping the strict-mode casts).
…egressions Add a SKILL.md section and conventions note telling the converter never to rewrite rawget/rawset as self._x or hoist setmetatable in classes with a custom __index/__newindex that errors on unknown keys, and add an eval scorer dimension (raw vs raw_gold) that fails any conversion which drops a raw access. Exercised by the settings-property gold case and validated against the RogueProperty regression.
The eval harness's restore() checked out `main` per package to undo place/convert. On `main` that's correct, but on a feature branch it reverted the branch's own work in the case package. Restore to HEAD (the current branch's committed state) instead — identical on main, non-destructive on a branch.
Scalar array elements are serialized either as attributes on the array container or as child ValueBase instances, depending on how a game wrote them. createDefinitionsFromContainer only enumerated child instances, so attribute-serialized scalar arrays (including freshly initialized defaults) read back empty, and shrinking such an array left stale attribute entries behind. Discover attribute-backed elements during read and clear excess attributes on shrink, preserving both serialization forms.
Add unit and integration specs: RogueProperty/RoguePropertyTable usage (including Color3 and boolean values), the individual modifier implementations (RogueMultiplier/RogueAdditive/RogueSetter surface + math, and RogueModifierBase), modifier ordering/enable/reactiveness, RoguePropertyArrayUtils, and both scalar-array serialization forms. Each integration test builds and tears down its own ServiceBag via setup()/controller:destroy().
Alias the lune type definitions so the nevermore-cli and studio-bridge build-scripts type-check against them.
Owner
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.