mirror of
https://github.com/clearml/clearml
synced 2025-06-26 18:16:07 +00:00
Fix parsing pipeline component arguments with comma slices in python 3.9
This commit is contained in:
@@ -753,7 +753,11 @@ if __name__ == '__main__':
|
||||
# type: (str) -> str
|
||||
try:
|
||||
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:
|
||||
return function_source
|
||||
|
||||
|
||||
Reference in New Issue
Block a user