mirror of
https://github.com/clearml/clearml
synced 2025-04-22 07:15:57 +00:00
Fix parsing pipeline component arguments with comma slices in python 3.9
This commit is contained in:
parent
6fb98d9e8c
commit
09a4d85c0c
@ -753,7 +753,11 @@ if __name__ == '__main__':
|
|||||||
# type: (str) -> str
|
# type: (str) -> str
|
||||||
try:
|
try:
|
||||||
import ast
|
import ast
|
||||||
from ...utilities.lowlevel.astor_unparse import unparse
|
try:
|
||||||
|
# available in Python3.9+
|
||||||
|
from ast import unparse
|
||||||
|
except ImportError:
|
||||||
|
from ...utilities.lowlevel.astor_unparse import unparse
|
||||||
except ImportError:
|
except ImportError:
|
||||||
return function_source
|
return function_source
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user