Skip to content

Fix incorrect parameter names in docstrings#316

Merged
PaulWAyers merged 2 commits into
theochem:masterfrom
eeshsaxena:doc/fix-docstring-param-names
Jul 2, 2026
Merged

Fix incorrect parameter names in docstrings#316
PaulWAyers merged 2 commits into
theochem:masterfrom
eeshsaxena:doc/fix-docstring-param-names

Conversation

@eeshsaxena

Copy link
Copy Markdown
Contributor

Description

Three docstrings documented parameter names that do not match their function signatures:

  • NumericalIntegrand.integrate (src/grid/ngrid.py) documented integrand, but the parameter is integrand_function.
  • _evaluate_coeffs_on_points (src/grid/ode.py) documented coeffs, but the parameter is coeff.
  • deriv3 (src/grid/rtransform.py) documented array, but the parameter is x.

This corrects the documented names to match each signature. Documentation-only change.

Three docstrings documented parameter names that don't match their
signatures:

- NumericalIntegrand.integrate documented 'integrand' but the parameter
  is 'integrand_function'.
- _evaluate_coeffs_on_points documented 'coeffs' but the parameter is
  'coeff'.
- deriv3 documented 'array' but the parameter is 'x'.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR corrects mismatched parameter names in three NumPy-style docstrings so the documented parameter names match their corresponding function signatures.

Changes:

  • Update NumericalIntegrand.integrate docstring parameter name from integrand to integrand_function.
  • Update _evaluate_coeffs_on_points docstring parameter name from coeffs to coeff.
  • Update deriv3 docstring parameter name from array to x.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
src/grid/ngrid.py Renames the documented integrate parameter to integrand_function (but docstring still has a duplicated/incorrect integration_chunk_size section).
src/grid/ode.py Renames the documented _evaluate_coeffs_on_points parameter to coeff.
src/grid/rtransform.py Renames the documented deriv3 parameter to x.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/grid/ngrid.py
Comment on lines +179 to 182
integrand_function : callable
Integrand function to integrate. It must take a list of arguments (one for each domain)
with the same dimension as the grid points used for the corresponding domain and return
a float (e.g. a function of the form f([x1,y1,z1], [x2,y2,z2]) -> float).
The integrate docstring documented integration_chunk_size twice; the
first entry had an incorrect default (1000 vs the signature's 6000) and
appeared out of order. Keep the single correct entry.
@eeshsaxena

Copy link
Copy Markdown
Contributor Author

Good catch on the duplicate integration_chunk_size - I removed the stray first entry (it had the wrong default of 1000 and appeared before non_vectorized); the remaining entry matches the signature's 6000 default and parameter order.

@PaulWAyers PaulWAyers merged commit ca23fd4 into theochem:master Jul 2, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants