Skip to content

Commit 811d1c2

Browse files
committed
bug: fix windows "/" separator 2
1 parent 644660f commit 811d1c2

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

rocketsled/utils.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ def serialize(fun):
103103
(str) The full function path as a string.
104104
105105
"""
106+
mod_sep = "."
106107
mod_path = fun.__module__
107108
name = fun.__name__
108109
if mod_path == "__main__":
@@ -115,9 +116,9 @@ def serialize(fun):
115116

116117
for _ in range(5):
117118
try:
118-
full_import_path = all_pkgs[-1] + "." + full_import_path
119+
full_import_path = all_pkgs[-1] + mod_sep + full_import_path
119120
all_pkgs = all_pkgs[:-1]
120-
fun_path = full_import_path + "." + name
121+
fun_path = full_import_path + mod_sep + name
121122
deserialize(fun_path)
122123
return fun_path
123124
except ImportError:

0 commit comments

Comments
 (0)