Skip to content

Commit 91c7e82

Browse files
python 2.7 compatibility
1 parent 08a16ed commit 91c7e82

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

pymultinest_demo.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
from pymultinest.solve import solve
66
import os
77
try: os.mkdir('chains')
8-
except FileExistsError: pass
8+
except OSError: pass
99

1010
# probability function, taken from the eggbox problem.
1111

pymultinest_demo_minimal.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import pymultinest
33
import math, os
44
try: os.mkdir('chains')
5-
except FileExistsError: pass
5+
except OSError: pass
66

77
# This "old" api may be a little bit faster and suitable for likelihoods
88
# written in C (via ctypes).

pymultinest_demo_old.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import threading, subprocess
66
from sys import platform
77
try: os.mkdir('chains')
8-
except FileExistsError: pass
8+
except OSError: pass
99

1010
def show(filepath):
1111
""" open the output (pdf) file for the user """

0 commit comments

Comments
 (0)