-
Notifications
You must be signed in to change notification settings - Fork 16
Description
Follow these steps:
(1) in GravityAndOrbitsScene.ts, add a line like:
this.tandem.runSomething();(2) run tsc -b in gravity-and-orbits, it should fail
(3) Then in PhetioObject.js, comment out this.tandem=DEFAULTS.tandem
(4) run tsc -b in gravity and orbits, it should succeed since tandem now has any type.
(5) restore PhetioObject.js
(6) run tsc -b in gravity and orbits, it should fail like it did in step (2) since all of the code is exactly the same, but it succeeds for unknown reasons. Inspecting chipper/dist/PhetioObject.d.ts, it does have the correct type. So it seems that GravityAndOrbitsScene is not getting triggered to recompile. Also, surprisingly, tsc succeeds even as tsc -b fails.
~/apache-document-root/main/gravity-and-orbits$ tsc
js/common/GravityAndOrbitsScene.ts:119:17 - error TS2339: Property 'runSomething' does not exist on type 'Tandem'.
119 this.tandem.runSomething();
~~~~~~~~~~~~
Found 1 error.
~/apache-document-root/main/gravity-and-orbits$ tsc -b
~/apache-document-root/main/gravity-and-orbits$
Running tsc -b --clean && tsc -b for each of the 3 compiles correctly shows the missing method. Therefore, it seems there is stale/bad intermediate data from the incremental or project build.