mirror of
https://github.com/clearml/clearml
synced 2025-05-23 13:34:04 +00:00
Fix backward compatibility when using datetime filtering for GetAllRequest in models.py and tasks.py
This commit is contained in:
parent
6f1c208726
commit
fc8435e26b
@ -2242,11 +2242,11 @@ class GetAllRequest(Request):
|
|||||||
},
|
},
|
||||||
"last_update": {
|
"last_update": {
|
||||||
"description": (
|
"description": (
|
||||||
"List of last_update constraint strings (utcformat, epoch) with an optional prefix "
|
"List of last_update constraint strings, or a single string (utcformat, epoch) with an optional prefix "
|
||||||
"modifier (>, >=, <, <=)"
|
"modifier (>, >=, <, <=)"
|
||||||
),
|
),
|
||||||
"items": {"pattern": "^(>=|>|<=|<)?.*$", "type": "string"},
|
"items": {"pattern": "^(>=|>|<=|<)?.*$", "type": "string"},
|
||||||
"type": ["array", "null"],
|
"type": ["string", "array", "null"],
|
||||||
},
|
},
|
||||||
"name": {
|
"name": {
|
||||||
"description": "Get only models whose name matches this pattern (python regular expression syntax)",
|
"description": "Get only models whose name matches this pattern (python regular expression syntax)",
|
||||||
@ -2621,9 +2621,11 @@ class GetAllRequest(Request):
|
|||||||
self._property_last_update = None
|
self._property_last_update = None
|
||||||
return
|
return
|
||||||
|
|
||||||
self.assert_isinstance(value, "last_update", (list, tuple))
|
self.assert_isinstance(value, "last_update", (str, list, tuple))
|
||||||
|
|
||||||
|
if not isinstance(value, six.string_types):
|
||||||
|
self.assert_isinstance(value, "last_update", six.string_types, is_array=True)
|
||||||
|
|
||||||
self.assert_isinstance(value, "last_update", six.string_types, is_array=True)
|
|
||||||
self._property_last_update = value
|
self._property_last_update = value
|
||||||
|
|
||||||
@schema_property("_all_")
|
@schema_property("_all_")
|
||||||
|
@ -8218,11 +8218,11 @@ class GetAllRequest(Request):
|
|||||||
},
|
},
|
||||||
"status_changed": {
|
"status_changed": {
|
||||||
"description": (
|
"description": (
|
||||||
"List of status changed constraint strings (utcformat, epoch) with an optional prefix modifier "
|
"List of status changed constraint strings, or a single string (utcformat, epoch) with an optional prefix modifier "
|
||||||
"(>, >=, <, <=)"
|
"(>, >=, <, <=)"
|
||||||
),
|
),
|
||||||
"items": {"pattern": "^(>=|>|<=|<)?.*$", "type": "string"},
|
"items": {"pattern": "^(>=|>|<=|<)?.*$", "type": "string"},
|
||||||
"type": ["array", "null"],
|
"type": ["string", "array", "null"],
|
||||||
},
|
},
|
||||||
"system_tags": {
|
"system_tags": {
|
||||||
"description": "List of task system tags. Use '-' prefix to exclude system tags",
|
"description": "List of task system tags. Use '-' prefix to exclude system tags",
|
||||||
@ -8502,9 +8502,11 @@ class GetAllRequest(Request):
|
|||||||
self._property_status_changed = None
|
self._property_status_changed = None
|
||||||
return
|
return
|
||||||
|
|
||||||
self.assert_isinstance(value, "status_changed", (list, tuple))
|
self.assert_isinstance(value, "status_changed", (str, list, tuple))
|
||||||
|
|
||||||
|
if not isinstance(value, six.string_types):
|
||||||
|
self.assert_isinstance(value, "status_changed", six.string_types, is_array=True)
|
||||||
|
|
||||||
self.assert_isinstance(value, "status_changed", six.string_types, is_array=True)
|
|
||||||
self._property_status_changed = value
|
self._property_status_changed = value
|
||||||
|
|
||||||
@schema_property("search_text")
|
@schema_property("search_text")
|
||||||
|
Loading…
Reference in New Issue
Block a user