Skip to content

set_value argument name: src or values #6

@visr

Description

@visr

I just noticed in

bmi-python/bmipy/bmi.py

Lines 394 to 407 in 0fcca44

def set_value(self, name: str, values: np.ndarray) -> None:
"""Specify a new value for a model variable.
This is the setter for the model, used to change the model's
current state. It accepts, through *src*, a new value for a
model variable, with the type, size and rank of *src*
dependent on the variable.
Parameters
----------
var_name : str
An input or output variable name, a CSDMS Standard Name.
src : array_like
The new value for the specified variable.

That the argument name values does not match the src in the docstring and the src on the BMI website.

Since in Python these are not strictly positional but can be addressed as keyword arguments as well, I didn't just want to change it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions