sphinx-doc / sphinx-doc/sphinx

docs: Avoid unclear use of "attribute"

Open Beginner friendly
#8,358 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

type:bug type:docs
Dominant language
Python
Stars
8k
Forks
2.6k
PR merge metrics
No merged PRs in 30d

Description

The documentation of the missing-reference event says that the pending_xref node has "attributes reftype, reftarget...". However, these are not Python instance attributes - they are accessed with node["reftype"], not node.reftype.

I suggest referring to these fields as "items" rather than "attributes" to match the syntax used for accessing them. (I'm not sure if this is a general problem throughout the docs or if it's just here on missing-reference). Also, there's a typo here - the word "attributes" is repeated both before and after the list of names.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open the linked missing-reference event documentation and inspect the sentence describing the pending_xref node fields. Change the wording so the listed fields are called items rather than attributes, remove the repeated “attributes” typo, and verify the rendered documentation conveys the intended terminology.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
documentation
Issue type
Documentation
Difficulty
1/5
Estimated time
Under an hour
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
78/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.