Compare commits

...

2 Commits

Author SHA1 Message Date
Alejandro Moreo Fernandez 6e83bbef67 log the underlying ImportError when bayesian deps fail to import
Swallowing the exception made it impossible to tell which of
jax/numpyro/stan actually failed in CI.
2026-07-17 17:06:33 +02:00
Alejandro Moreo Fernandez 48a5240a6e import fix 2026-07-17 16:53:27 +02:00
3 changed files with 3 additions and 4 deletions

View File

@ -3,7 +3,7 @@
import numpy as np
from sklearn.metrics import f1_score
import quapy as qp
from functional import AitchisonDistance
from quapy.functional import AitchisonDistance
def from_name(err_name):

View File

@ -35,7 +35,8 @@ try:
import stan.common
DEPENDENCIES_INSTALLED = True
except ImportError:
except ImportError as e:
logging.getLogger(__name__).warning(f'Bayesian dependencies failed to import: {e!r}')
jax = None
jnp = None
jrandom = None

View File

@ -8,8 +8,6 @@ from contextlib import ExitStack
from abc import ABCMeta, abstractmethod
from quapy.data import LabelledCollection
import quapy.functional as F
from os.path import exists
from glob import glob
from collections.abc import Iterable
from numbers import Number