diff --git a/CHANGELOG.md b/CHANGELOG.md index 631dff1..06994bf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Fixed `Gamma` parameter on the Exp-sine-squared kernel, for which `juliet` was actually fitting log(`Gamma`) and not `Gamma`, as pointed out in #118. - Fixed bug on binning with given errorbars pointed out in #117. +### Added +- Exception if user tries to fit `a_p1` and `rho` (covering issue #116). + + ## [2.2.5] - 2024-03-01 ### Fixed - Bug of multi-instrument fits not updating posteriors by @Jayshil (PR #112). diff --git a/juliet/fit.py b/juliet/fit.py index df1c6df..c3859cf 100644 --- a/juliet/fit.py +++ b/juliet/fit.py @@ -1717,8 +1717,15 @@ def __init__(self, data, sampler = 'multinest', n_live_points = 500, nwalkers = # To run dynesty, we do it a little bit different depending if we are doing multithreading or not: if self.nthreads is None: - # As with the other samplers, first extract list of possible args: - args = vars(DynestySampler).keys() + # As with the other samplers, first extract list of possible args (try-except for back-compatibility with prior dynesty versions): + try: + + args = vars(DynestySampler)['__init__'].__code__.co_varnames + + except: + + args = vars(DynestySampler).keys() + d_args = {} # Define some standard ones (for back-compatibility with previous juliet versions): @@ -1753,8 +1760,16 @@ def __init__(self, data, sampler = 'multinest', n_live_points = 500, nwalkers = else: - # Before running the whole multithread magic, match kwargs with functional arguments: - args = vars(DynestySampler).keys() + # Before running the whole multithread magic, match kwargs with functional arguments (try-except + # for back-compatibility with prior dynesty versions): + try: + + args = vars(DynestySampler)['__init__'].__code__.co_varnames + + except: + + args = vars(DynestySampler).keys() + d_args = {} # Define some standard ones (for back-compatibility with previous juliet versions):