mirror of
https://github.com/clearml/clearml
synced 2025-06-26 18:16:07 +00:00
Fix python 2.7 support
This commit is contained in:
@@ -2206,7 +2206,8 @@ class Task(IdObjectBase, AccessMixin, SetupUploadMixin):
|
||||
|
||||
# make sure we have str as values:
|
||||
for key in requirements.keys():
|
||||
if requirements[key] and not isinstance(requirements[key], str):
|
||||
# fix python2 support (str/unicode)
|
||||
if requirements[key] and not isinstance(requirements[key], six.string_types):
|
||||
requirements[key] = '\n'.join(requirements[key])
|
||||
|
||||
# protection, Old API might not support it
|
||||
|
||||
Reference in New Issue
Block a user