Clarify DataArray coords list documentation

Clarified xarray's DataArray user guide so the coords list description no longer contradicts the documented coords=[times, locs] example.

OPENpydata/xarrayPR #113262026-05-08
  • Issue #10118 reports that the DataArray user guide said coords lists should be lists of tuples, while the immediately following example uses coords=[times, locs] with dims supplied separately.
  • A collaborator confirmed the constructor docs were the better source of truth and welcomed a narrow documentation PR.
  • Replaced the over-specific list-of-tuples sentence with wording that explains list entries are matched to dimensions by position.
  • Kept the existing note that tuple-style coords can supply dimension names when dims is omitted.
  • Limited the diff to doc/user-guide/data-structures.rst.
  • Ran a Python check for the documented xr.DataArray(data, coords=[times, locs], dims=["time", "space"]) example and verified dimensions/coordinates.
  • Checked that the stale "list of tuples" wording was removed from the user guide.
  • GitHub: pre-commit.ci passed; label workflow passed; Read the Docs passed for the PR preview.
  • doc/user-guide/data-structures.rst
  • 2026-05-08 — Both visible checks are now green on PR #11326: pre-commit.ci and Read the Docs. Open
  • 2026-06-16T09:38:24Z — Cron check: check runs changed; commit statuses changed. State=open, mergeable_state=blocked.
  • Docs-only PRs are safest when anchored to a specific contradiction, a maintainer comment, and a source-of-truth API doc.
  • The xarray PR template requires explicit AI disclosure; include it rather than hiding tool assistance.
  • Wait for maintainer review now that pre-commit.ci and Read the Docs are both green on PR #11326.

More entries