Skip to content

Commit

Permalink
Update try/except statement
Browse files Browse the repository at this point in the history
Changed line 846 to make the try/except statement more broad
except TypeError:
to except:
  • Loading branch information
CayenneMatt committed Apr 17, 2024
1 parent dd0c7b7 commit 736b9ec
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions holodeck/host_relations.py
Original file line number Diff line number Diff line change
Expand Up @@ -843,9 +843,7 @@ def mbh_from_mbulge(self, mbulge, redz, scatter):
# NOTE: this will work for (N,) ==> (N,) or (N,) ==> (N,X)
try:
redz = np.broadcast_to(redz, mbulge.T.shape).T
except TypeError:
redz = redz
except ValueError:
except:
redz = redz
zmamp = self._mamp * (1.0 + redz)**self._zplaw
mbh = _log10_relation(mbulge, zmamp, self._mplaw, scatter_dex, x0=self._mref)
Expand Down

0 comments on commit 736b9ec

Please sign in to comment.