Skip to content

Commit dc1565e

Browse files
committedDec 12, 2020
fix issue RudoRoemer#8 (crash when pdbfile is given as a relative path) by converting the pdbfile argument to the full path

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed
 

‎cleanpdb.py

+4
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,10 @@ def parsing_args(sys_args):
6363

6464
# actually do the parsing for all system args other than 0 (which is the python script name) and return the structure generated
6565
args = parser.parse_args(sys_args[1:])
66+
67+
#ensure pdbfile has the full path
68+
args.pdbfile[0] = os.path.abspath(args.pdbfile[0])
69+
6670
return args
6771

6872

‎pdb2movie.py

+4
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,10 @@ def parsing_args(sys_args):
7070
# actually do the parsing for all system args other than 0
7171
# (which is the python script name) and return the structure generated
7272
args = parser.parse_args(sys_args[1:])
73+
74+
#ensure pdbfile has the full path
75+
args.pdbfile[0] = os.path.abspath(args.pdbfile[0])
76+
7377
return args
7478

7579
# no specific function is defined here, since this is our main program!

0 commit comments

Comments
 (0)
Please sign in to comment.