model-card-toolkit
model-card-toolkit copied to clipboard
Prefer single quote strings model-card-toolkit
Currently, model-card-toolkit uses both single quotes and double quotes for strings. Update the codebase to use single quote strings so that we have consistent style across the project.
Update yapf lint tooling to prefer single quote strings (if possible).
Thank you @codesue for linking the yapf
issue. The issue is open for 3+ years and the consensus is
use black to change the quote and then use yapf to make it format the way you want.
Should we use black
before yapf
?
black
prefers double quote strings over single quote strings. https://github.com/psf/black/issues/118
I prefer single quote strings and they're consistent with a lot of other tensorflow org projects, but I wouldn't be a blocker if others prefer double quote strings and if there's tooling to format the code so I don't have to think about it.
black
refuses to support 2-space indents, though, so I wonder if it'll be more trouble than it's worth. https://github.com/psf/black/issues/378