Skip to content

Commit

Permalink
Merge pull request #1702 from pints-team/rt-notebook-fix-2
Browse files Browse the repository at this point in the history
Rt notebook fix 2
  • Loading branch information
MichaelClerx authored Feb 10, 2025
2 parents dd2f625 + bb70b0b commit 015b1e8
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 207 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1028,7 +1028,7 @@
"metadata": {},
"outputs": [],
"source": [
"pois_intervals.to_csv('pois_rt.csv')"
"#pois_intervals.to_csv('pois_rt.csv')"
]
},
{
Expand Down Expand Up @@ -1844,7 +1844,7 @@
"metadata": {},
"outputs": [],
"source": [
"negbin_intervals.to_csv('negbin_rt.csv')"
"#negbin_intervals.to_csv('negbin_rt.csv')"
]
},
{
Expand Down
101 changes: 0 additions & 101 deletions examples/miscellaneous/negbin_rt.csv

This file was deleted.

101 changes: 0 additions & 101 deletions examples/miscellaneous/pois_rt.csv

This file was deleted.

7 changes: 4 additions & 3 deletions run-tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -432,7 +432,7 @@ def list_notebooks(root, recursive=True, ignore_list=None, notebooks=None):

def test_notebook(path):
"""
Tests a notebook in a subprocess, exists if it doesn't finish.
Tests a notebook in a subprocess, exits if it doesn't finish.
"""
import nbconvert
import pints
Expand All @@ -442,7 +442,7 @@ def test_notebook(path):

# Load notebook, convert to python
e = nbconvert.exporters.PythonExporter()
code, __ = e.from_filename(path)
code, _ = e.from_filename(path)

# Remove coding statement, if present
code = '\n'.join([x for x in code.splitlines() if x[:9] != '# coding'])
Expand All @@ -455,7 +455,8 @@ def test_notebook(path):
cmd = [sys.executable, '-c', code]
try:
p = subprocess.Popen(
cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE, env=env
cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE, env=env,
cwd=os.path.dirname(path)
)
stdout, stderr = p.communicate()
# TODO: Use p.communicate(timeout=3600)
Expand Down

0 comments on commit 015b1e8

Please sign in to comment.