Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Use new Python 3.12 f-string syntax

オープン
#126 コメント 4 件 リアクション 0 件 担当者 1 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@ashprit-x がすでに取り組んでいます。

2024年7月5日 から。

評価

この issue はまだ評価されていません。

説明

good first issue

Now that we have updated this project to use Python 3.12 (#124), all multi-line f-strings should be updated to use the new syntax.

For example:

my_var: str = (
    f"""This is a {
        random.choice("good", "amazing", "wonderful")
    }. My next random number will be provided below in due course: {
        random.choice(
            999_999_999_999_999,
            420,
            10,
            0
        )
        if random.randint(0, 101) == 69
        else random.random()
    }"""
)

Would be changed to:

my_var: str = (
    f"This is a {random.choice("good", "amazing", "wonderful")}. "
    "My next random number will be provided below in due course: "
    f"{
        random.choice(
            999_999_999_999_999,
            420,
            10,
            0
        )
        if random.randint(0, 101) == 69
        else random.random()
    }"
)

(I am aware that this example can be simplified on to a single line without the line-length being exceeded, however this is just an example. Use the shown changes to help when the changed lines do exceed the maximum allowed line-length.)

主要言語
Python
スター
1
フォーク
11
平均マージ
2日 11時間
マージ済み PR(30日)
4

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

CSSUoB/TeX-Bot-Py-V2 のほかの issue

CSSUoB/TeX-Bot-Py-V2 の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。