You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
classCashier(UP.Actor):
a_queue=UP.ResourceState[UP.SelfMonitoringStore]()
defq_help(self) ->None:
self.a_queue._record() # <- type hinter fails
The type hinting will think a_queue is of type Store or Container and complain about using _record() (which you may want to do if you're doing things to items directly).
Typing
ResourceState
and setting the default are most commonly going to be duplicated. This is similar forState
values and thevalid_type
argument.This looks more complicated:
than this:
Any changes made here would have to allow for union types that would still require a single default value.
The text was updated successfully, but these errors were encountered: