File tree 1 file changed +5
-3
lines changed
1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -68,13 +68,15 @@ def is_compatible(self) -> bool:
68
68
"""Whether upgrade is supported from previous versions"""
69
69
assert self .versions_set
70
70
try :
71
- previous_version_strs : dict [str , str ] = json .loads (self ._app_databag ["versions" ])
71
+ previous_version_strs : typing .Dict [str , str ] = json .loads (
72
+ self ._app_databag ["versions" ]
73
+ )
72
74
except KeyError as exception :
73
75
logger .debug ("`versions` missing from peer relation" , exc_info = exception )
74
76
return False
75
77
# TODO charm versioning: remove `.split("+")` (which removes git hash before comparing)
76
78
previous_version_strs ["charm" ] = previous_version_strs ["charm" ].split ("+" )[0 ]
77
- previous_versions : dict [str , poetry_version .Version ] = {
79
+ previous_versions : typing . Dict [str , poetry_version .Version ] = {
78
80
key : poetry_version .Version .parse (value )
79
81
for key , value in previous_version_strs .items ()
80
82
}
@@ -177,7 +179,7 @@ def upgrade_resumed(self) -> bool:
177
179
178
180
@property
179
181
@abc .abstractmethod
180
- def _unit_workload_versions (self ) -> dict [str , str ]:
182
+ def _unit_workload_versions (self ) -> typing . Dict [str , str ]:
181
183
"""{Unit name: unique identifier for unit's workload version}
182
184
183
185
If and only if this version changes, the workload will restart (during upgrade or
You can’t perform that action at this time.
0 commit comments