Skip to content

Commit d02c4cb

Browse files
committed
Fixes potential trailing space in path problems.
- Closes #17
1 parent 1ea53d8 commit d02c4cb

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

__init__.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ def check_for_ptvsd():
7070

7171
#check in path just in case PYTHONPATH happens to be set
7272
for path in sys.path:
73+
path = path.rstrip("/")
7374
if os.path.exists(path+"/ptvsd"):
7475
return path
7576
if os.path.exists(path+"/site-packages/ptvsd"):
@@ -167,7 +168,7 @@ class DebugServerStart(bpy.types.Operator):
167168
def execute(self, context):
168169
#get ptvsd and import if exists
169170
prefs = bpy.context.preferences.addons[__name__].preferences
170-
ptvsd_path = prefs.path
171+
ptvsd_path = prefs.path.rstrip("/")
171172
ptvsd_port = prefs.port
172173

173174
#actually check ptvsd is still available

0 commit comments

Comments
 (0)