mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 06:05:58 -04:00
Remove try/except block around CDLL
This commit is contained in:
parent
d0676c7a85
commit
745b0b2d83
1 changed files with 8 additions and 13 deletions
|
|
@ -28,16 +28,11 @@ else:
|
|||
# Open shared library
|
||||
_filename = pkg_resources.resource_filename(
|
||||
__name__, '_libopenmc.{}'.format(_suffix))
|
||||
try:
|
||||
_dll = CDLL(_filename)
|
||||
except OSError:
|
||||
warn("OpenMC shared library is not available from the Python API. This "
|
||||
"means you will not be able to use openmc.capi to make in-memory "
|
||||
"calls to OpenMC.")
|
||||
else:
|
||||
from .error import *
|
||||
from .core import *
|
||||
from .nuclide import *
|
||||
from .material import *
|
||||
from .cell import *
|
||||
from .tally import *
|
||||
_dll = CDLL(_filename)
|
||||
|
||||
from .error import *
|
||||
from .core import *
|
||||
from .nuclide import *
|
||||
from .material import *
|
||||
from .cell import *
|
||||
from .tally import *
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue