Skip to content

Commit 9dc7532

Browse files
committed
fixed bug in checking dependencies to see if they have been modified while pythontex is running (closes #136)
1 parent 19ad7e9 commit 9dc7532

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed

pythontex/pythontex.dtx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,7 @@
168168
% \item Added support for Perl 6 with the \texttt{perlsix} and \texttt{psix} families of commands and environments (\#104). There is currently no utilities class or equivalent.
169169
% \item Under Windows, capitalization of script paths in \texttt{stderr} is now preserved.
170170
% \item Fixed a bug that prevented the \texttt{sub} environment from working with \texttt{depythontex} (\#155).
171+
% \item Fixed a bug in checking mtime of dependencies to see if they have been modified while \texttt{pythontex} is running. The check failed for dependencies that do not exist or were deleted before \texttt{pythontex} can read them (\#136)
171172
% \end{itemize}
172173
% \end{changelog}
173174
%

pythontex/pythontex2.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1424,7 +1424,7 @@ def do_multiprocessing(data, temp_data, old_data, engine_dict):
14241424
unresolved_sessions = []
14251425
for key in dependencies:
14261426
for dep, val in dependencies[key].items():
1427-
if val[0] > start_time:
1427+
if val[0] is None or val[0] > start_time:
14281428
unresolved_dependencies = True
14291429
dependencies[key][dep] = (None, None)
14301430
unresolved_sessions.append(key.replace('#', ':'))

pythontex/pythontex3.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1424,7 +1424,7 @@ def do_multiprocessing(data, temp_data, old_data, engine_dict):
14241424
unresolved_sessions = []
14251425
for key in dependencies:
14261426
for dep, val in dependencies[key].items():
1427-
if val[0] > start_time:
1427+
if val[0] is None or val[0] > start_time:
14281428
unresolved_dependencies = True
14291429
dependencies[key][dep] = (None, None)
14301430
unresolved_sessions.append(key.replace('#', ':'))

0 commit comments

Comments
 (0)