Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(api): replace single quotes with double quotes #14269

Merged
merged 5 commits into from
Jan 3, 2024

Conversation

erictleung
Copy link
Contributor

@erictleung erictleung commented Dec 31, 2023

Overview

Replaced single quotes with double quotes in tutorial docs, both v1 and v2 docs.

This also changes some example protocols, located in api/docs/v2/example_protocols/, which are Python files.

And a minor change, this also changes some random non-standard single quotes at the beginning of api/docs/v2/tutorial.rst to regular single quotes.

Test Plan

N/A

Changelog

  • Replaced single quotes with double quotes in v1 docs
  • Replaced single quotes with double quotes in v2 docs
  • Replaced single quotes with double quotes in v2 example protocols

Review requests

Risk assessment

Low

@erictleung erictleung requested a review from a team as a code owner December 31, 2023 06:59
@SyntaxColoring
Copy link
Contributor

Thanks for the consistency cleanup!

@ecormany Thoughts on this? In the Python community in general, I don't think there's a strong convention for whether to use single- or double-quotes in API docs. h11 uses double, requests uses single...

The Black formatter, which we use, prefers double-quotes, so I'd probably prefer switching everything to that.

@ecormany
Copy link
Contributor

ecormany commented Jan 2, 2024

Thanks for opening this PR, Eric! I agree with Max that our standard should be double quotes. We don't 100% adhere to Black (our code blocks use shorter line lengths and we tend to get rid of trailing commas in docs), but the fewer manual changes we have to make to Black-formatted code, the better.

That said, the branch name still states the goal: make-quotes-consistent. Eric, I'll leave it up to you if you want to keep this PR open to standardize in the opposite direction, or to close it.

@erictleung
Copy link
Contributor Author

@SyntaxColoring @ecormany thanks for considering my PR! Happy to keep this open and ensure the docs have double quotes. I'll tag y'all again once I have an update.

@erictleung erictleung marked this pull request as draft January 2, 2024 17:03
@SyntaxColoring SyntaxColoring added api Affects the `api` project docs labels Jan 2, 2024
Copy link

codecov bot commented Jan 3, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (13e2c40) 68.06% compared to head (111d786) 68.06%.
Report is 2 commits behind head on edge.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             edge   #14269   +/-   ##
=======================================
  Coverage   68.06%   68.06%           
=======================================
  Files        2508     2508           
  Lines       71333    71333           
  Branches     9060     9060           
=======================================
  Hits        48556    48556           
  Misses      20674    20674           
  Partials     2103     2103           
Flag Coverage Δ
g-code-testing 96.44% <ø> (ø)
notify-server 89.13% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

@erictleung erictleung changed the title docs(api): replace double quotes with single quotes docs(api): replace single quotes with double quotes Jan 3, 2024
@erictleung
Copy link
Contributor Author

@SyntaxColoring @ecormany updates made. I went ahead and changed both v1 and v2 docs for thoroughness. I've updated the main PR body message as well to summarize all the changes. Thanks for reviewing!

@erictleung erictleung marked this pull request as ready for review January 3, 2024 17:34
Copy link
Contributor

@ecormany ecormany left a comment

Choose a reason for hiding this comment

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

Thanks again for this, Eric. Above and beyond, going back to the v1 docs! (Those are effectively archived, but there's no prohibition against changing them, so we'll accept your edits.)

In reviewing, I tested:

  • All modified .py protocol files pass opentrons_simulate.
  • Built v2 documentation locally and visually inspected.

There are a couple remaining improvements that can wait until follow-up PRs. For example, the images on the Tutorial page contain code with single quotes. I don't think there's any possibility for confusion until I get a chance to update those (I have the source files for those images). And the docstrings that compose the API Reference also have some single quotes. I've ticketed both of those internally for a rainy day ☔

@ecormany ecormany merged commit e9f782d into Opentrons:edge Jan 3, 2024
24 checks passed
@erictleung erictleung deleted the make-quotes-consistent branch January 3, 2024 23:53
@ecormany
Copy link
Contributor

ecormany commented Jan 4, 2024

@erictleung just so you know, even though these changes are merged, they won't go live until the next time we do a documentation deploy. I expect there will be one sometime this month.

@erictleung
Copy link
Contributor Author

@ecormany awesome, I appreciate the heads up! Looking forward to it

@ecormany
Copy link
Contributor

ecormany commented Jan 8, 2024

This is now deployed as part of the [email protected]_1 tag.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Affects the `api` project docs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants