Skip to content
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

IR waves become very thin and barely visible in Studio #67

Closed
Tracked by #707
Nancy-Salpepi opened this issue Aug 17, 2021 · 5 comments
Closed
Tracked by #707

IR waves become very thin and barely visible in Studio #67

Nancy-Salpepi opened this issue Aug 17, 2021 · 5 comments
Labels
type:bug Something isn't working

Comments

@Nancy-Salpepi
Copy link

Nancy-Salpepi commented Aug 17, 2021

Test device
MacBook Air (M1 chip)

Operating System
11.4

Browser
Safari 14.1.1

Problem description
phetsims/qa#690

When the sim is launched in studio, the IR waves suddenly become thin and barely visible. Once that occurs, the temperature drops to -28 degrees Celsius and even if the amount of greenhouse gases is increased, temperature remains there.

Steps to reproduce

  1. In studio, click the "start sunlight" button.
  2. Once the IR waves begin to radiate from the surface, launch the sim.

Visuals

Screen Shot 2021-08-17 at 9 23 29 AM

https://drive.google.com/file/d/1l4UMTvyoKSrfjOPV2T-dNS1doTAnNqAO/view?usp=sharing

Console:

Uncaught TypeError: q.toStateObject is not a function
at Object.toStateObject (greenhouse-effect_all_phet-io.html?postMessageOnError&phetioEmitStates=false&phetioEmitStatesInterval=1&phetioEmitHighFrequencyEvents=true:861)
at u.toStateObject (greenhouse-effect_all_phet-io.html?postMessageOnError&phetioEmitStates=false&phetioEmitStatesInterval=1&phetioEmitHighFrequencyEvents=true:861)
at xw.toStateObject (greenhouse-effect_all_phet-io.html?postMessageOnError&phetioEmitStates=false&phetioEmitStatesInterval=1&phetioEmitHighFrequencyEvents=true:861)
at Object.toStateObject (greenhouse-effect_all_phet-io.html?postMessageOnError&phetioEmitStates=false&phetioEmitStatesInterval=1&phetioEmitHighFrequencyEvents=true:861)
at toStateObject (greenhouse-effect_all_phet-io.html?postMessageOnError&phetioEmitStates=false&phetioEmitStatesInterval=1&phetioEmitHighFrequencyEvents=true:861)
at Array.map ()
at Object.toStateObject (greenhouse-effect_all_phet-io.html?postMessageOnError&phetioEmitStates=false&phetioEmitStatesInterval=1&phetioEmitHighFrequencyEvents=true:861)
at u.toStateObject (greenhouse-effect_all_phet-io.html?postMessageOnError&phetioEmitStates=false&phetioEmitStatesInterval=1&phetioEmitHighFrequencyEvents=true:861)
at ST.toStateObject (greenhouse-effect_all_phet-io.html?postMessageOnError&phetioEmitStates=false&phetioEmitStatesInterval=1&phetioEmitHighFrequencyEvents=true:861)
at ST.toStateObject (greenhouse-effect_all_phet-io.html?postMessageOnError&phetioEmitStates=false&phetioEmitStatesInterval=1&phetioEmitHighFrequencyEvents=true:861)

@Nancy-Salpepi Nancy-Salpepi added the type:bug Something isn't working label Aug 17, 2021
@Nancy-Salpepi
Copy link
Author

This issue is also seen in the State wrapper when the "set state rate" value=0 and the "set state now" button is utilized OR the Launch button is used.

@jbphet
Copy link
Contributor

jbphet commented Aug 26, 2021

This problem was happening because when state was set, the list of energy packets in LayersModel was being overwritten, so the reference held by the sunEnergySource was no longer valid, which means it was supplying energy to nowhere and the main model was no longer getting any energy. Hence, the temperature of the Earth dropped rapidly and the IR waves became thin.

I've addressed this by making the applyState method in LayersModel repopulate the list of energy packets rather than overwriting it, and this appears to resolve the problem.

@Nancy-Salpepi - Can you please re-test this on master an verify that it is fixed?

@Nancy-Salpepi
Copy link
Author

Issue is fixed in both Studio and State wrappers

@Nancy-Salpepi Nancy-Salpepi removed their assignment Aug 27, 2021
@jbphet
Copy link
Contributor

jbphet commented Aug 30, 2021

Cool. I'll unassign for now and have this verified in the next round of QA testing.

@Nancy-Salpepi
Copy link
Author

I've spent ample time in the Studio Wrapper during this round of testing and this issue has not occurred.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants