Skip to content

Commit

Permalink
Merge pull request #11 from p-ortega/hotfix_mup3d
Browse files Browse the repository at this point in the history
avoid defining name for mup3d class
  • Loading branch information
p-ortega authored Nov 29, 2024
2 parents 76bb212 + 1bbd119 commit b320550
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/mf6rtm/mup3d.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,16 @@ def set_packtype(self, packtype):


class Mup3d(object):
def __init__(self, name, solutions, nlay, nrow, ncol):
def __init__(self, name=None, solutions=None, nlay=None, nrow=None, ncol=None):
if solutions is None and isinstance(name, Solutions):
# New style: first argument is solutions
solutions = name
name = None
# Validate required parameters
if solutions is None:
raise ValueError("solutions parameter is required")
if any(param is None for param in [nlay, nrow, ncol]):
raise ValueError("nlay, nrow, and ncol parameters are required")
self.name = name
self.wd = None
self.charge_offset = 0.0
Expand Down

0 comments on commit b320550

Please sign in to comment.