mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 21:04:40 +01:00
bugfix/environment_crashing_on_floats
This commit is contained in:
parent
f263eabe82
commit
b567af166d
1 changed files with 8 additions and 7 deletions
|
|
@ -271,20 +271,21 @@ class MayaSubmitDeadline(pyblish.api.InstancePlugin):
|
|||
for key in environment:
|
||||
clean_path = ""
|
||||
self.log.debug("key: {}".format(key))
|
||||
to_process = environment[key]
|
||||
self.log.debug("value: {}".format(environment[key]))
|
||||
to_process = str(environment[key])
|
||||
if key == "PYPE_STUDIO_CORE_MOUNT":
|
||||
clean_path = environment[key]
|
||||
elif "://" in environment[key]:
|
||||
clean_path = environment[key]
|
||||
elif os.pathsep not in to_process:
|
||||
clean_path = to_process
|
||||
elif "://" in to_process:
|
||||
clean_path = to_process
|
||||
elif os.pathsep not in str(to_process):
|
||||
try:
|
||||
path = environment[key]
|
||||
path = to_process
|
||||
path.decode('UTF-8', 'strict')
|
||||
clean_path = os.path.normpath(path)
|
||||
except UnicodeDecodeError:
|
||||
print('path contains non UTF characters')
|
||||
else:
|
||||
for path in environment[key].split(os.pathsep):
|
||||
for path in to_process.split(os.pathsep):
|
||||
try:
|
||||
path.decode('UTF-8', 'strict')
|
||||
clean_path += os.path.normpath(path) + os.pathsep
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue