Skip to content

Prevent not running _setup but running _update from happening in static models #687

@dalonsoa

Description

@dalonsoa

@davidorme , @sallymatson I think that in total we have 4 cases, with one of them ill-defined:

Static _setup _update Comments
No Yes Yes Normal run
Yes Yes Once Update once and freeze
Yes No Once Ill defined. Setup is skipped but update is expected to run once
Yes No No Use fix data

The third one is the problem. As the code is now, it is allowed: you just provide all the variables that need to be populated by init but none of those that need to be populated by update. As a result, the _setup method is not run and none of the internals that the _update method will need are there.

If this is not a use case, then we need to fix the code to prevent that from happening.

Originally posted by @dalonsoa in #682 (comment)

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions