refactor: convert string formatting to F-strings #29969

pull iw4p wants to merge 1 commits into bitcoin:master from iw4p:enhancement/f-string-formatting changing 1 files +11 −16
  1. iw4p commented at 12:23 pm on April 26, 2024: none
    All instances of string formatting have been converted to F-strings for increased readability and performance. Before that some of strings use .format and others use f-strings.
  2. DrahtBot commented at 12:23 pm on April 26, 2024: contributor

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    Code Coverage

    For detailed information about the code coverage, see the test coverage report.

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    Concept NACK stickies-v

    If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.

    Conflicts

    Reviewers, this pull request conflicts with the following ones:

    • #29971 (refactor: refactored platform assignment into get_platform function by iw4p)

    If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

  3. DrahtBot added the label Refactoring on Apr 26, 2024
  4. brunoerg commented at 1:39 pm on April 26, 2024: contributor
    If this is just a refactor, why the fix: on the commit message (8c600f7f78d5aaf3577f6257b648727d72e32a06)?
  5. iw4p force-pushed on Apr 26, 2024
  6. iw4p commented at 2:28 pm on April 26, 2024: none

    If this is just a refactor, why the fix: on the commit message (8c600f7)?

    Usually the most prefixes are fix and feat, but sometimes some repos and projects use other keywords like chore, ref, etc. reference. By the way I modified the commit message prefix.

  7. fanquake commented at 2:31 pm on April 26, 2024: member
    You should read our developer notes for an overview of what is relevant to our project. ref doesn’t mean anything here. You could probably use refactor:.
  8. refactor: convert string formatting to F-strings 36855f2fd9
  9. iw4p force-pushed on Apr 26, 2024
  10. iw4p commented at 2:37 pm on April 26, 2024: none
    Sorry, I’m a newbie. I read this and only saw this tagging for PR title. Now I changed it to refactor.
  11. stickies-v commented at 11:07 am on April 30, 2024: contributor
    Concept NACK. Thank you for looking into this, and I support increased f-string usage, but imo this should be done organically whenever these lines are touched for other reasons (or with a scripted-diff across the code base, and enforcing it with linter, should there be support to do that). In its current form, this is not worth the review time imo.
  12. iw4p commented at 11:15 am on April 30, 2024: none
    Hi, Thank you. I touched this file to optimize it like using built-in python request library instead of curl and decreasing the request numbers, and one more PR. That’s why I decided to go for converting strings to f-string.
  13. glozow commented at 11:25 am on April 30, 2024: member
    Thanks for your interest in contributing! CONTRIBUTING.md and developer-notes.md contain good resources for beginners. As we have 300+ pulls open right now, closing this test refactor to focus review attention on the others (see https://github.com/bitcoin/bitcoin/blob/master/CONTRIBUTING.md#refactoring)
  14. glozow closed this on Apr 30, 2024


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-12-26 12:12 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me