Skip to content

Fix typos, grammar errors, and capitalization inconsistencies in docstrings#7989

Open
Hadar01 wants to merge 3 commits intoquantumlib:mainfrom
Hadar01:fix-typos-docstrings
Open

Fix typos, grammar errors, and capitalization inconsistencies in docstrings#7989
Hadar01 wants to merge 3 commits intoquantumlib:mainfrom
Hadar01:fix-typos-docstrings

Conversation

@Hadar01
Copy link
Copy Markdown

@Hadar01 Hadar01 commented Mar 30, 2026

Fix documentation issues in cirq-core/cirq/:

1.Typos: "denity" → "density", "derteines" → "determines"
2.Grammar: "is approximately" → "is approximately", "i.a." → "i.e."
3.Capitalization: "hermitian" → "Hermitian" consistently across all files
4.Punctuation: "operation ." → "operation."
5.Possessive: "who's" → "whose"
6.Variable name in docstring: "qid_state" → "qid_shape"

No behavioral changes.

…r messages

- Fix 'denity' typo in states.py (L149)

- Capitalize 'hermitian' to 'Hermitian' in error message for consistency (states.py L1018)

- Remove extra space before period in channels.py docstring (L288)

- Fix 'is a approximately' grammar in predicates.py (L30)

- Fix 'dertemines' typo in predicates.py (L274)

- Fix 'i.a.' to 'i.e.' in transformations.py (L261)

- Update corresponding test assertions for Hermitian capitalization
@Hadar01 Hadar01 requested review from a team and vtomole as code owners March 30, 2026 11:36
@Hadar01 Hadar01 requested a review from maffoo March 30, 2026 11:36
@google-cla
Copy link
Copy Markdown

google-cla bot commented Mar 30, 2026

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@github-actions github-actions bot added the size: S 10< lines changed <50 label Mar 30, 2026
@mhucka mhucka self-assigned this Mar 30, 2026
@mhucka
Copy link
Copy Markdown
Contributor

mhucka commented Mar 30, 2026

@Hadar01 Thank you for this contribution. When you get a chance, can you please follow up on the contributor license agreement (CLA) per the comment by the CLA bot?

@mhucka
Copy link
Copy Markdown
Contributor

mhucka commented Mar 30, 2026

@Hadar01 There are at least a couple of other places in the code where "hermitian" is not capitalized in strings, but I don't see those cases included in this PR. This makes me think that the PR is incomplete. Can you please double-check that the capitalization changes are consistent across all the files?

@codecov
Copy link
Copy Markdown

codecov bot commented Mar 30, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.63%. Comparing base (9888067) to head (0791f57).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7989      +/-   ##
==========================================
- Coverage   99.63%   99.63%   -0.01%     
==========================================
  Files        1110     1110              
  Lines       99685    99685              
==========================================
- Hits        99318    99317       -1     
- Misses        367      368       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@pavoljuhas
Copy link
Copy Markdown
Collaborator

Additional issues found (not included to keep PR small): ...

Yes, please include them here.

@Hadar01 - please edit the description to remove the unnecessary LLM fluff.

The Changes section should have only the kind of typos listed, the files and line numbers are obvious from the diff. Also please remove the Testing section. This PR does not change any tests (apart from error messages) - so that section does not convey anything.

The PR description will become a commit message when merged, so it is desirable for it to be informative, brief and relevant.

@Hadar01
Copy link
Copy Markdown
Author

Hadar01 commented Mar 30, 2026

@mhucka Good catch, thanks! I've searched the full codebase and added the remaining cases in the second commit. Could you check if I'm still missing any?

@Hadar01
Copy link
Copy Markdown
Author

Hadar01 commented Mar 30, 2026

@mhucka @pavoljuhas Done ,updated the description and included the additional fixes (who's → whose, qid_state → qid_shape) in the third commit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size: S 10< lines changed <50

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants