Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Flake8 F824 for global variable scoping

未关闭
#357 0 条评论 0 个 reaction 已指派 1 人 在 GitHub 查看

维护者通常 1 天内回复

@cpswan 已经在做这个了。

开始于 2025年4月25日。

评估

这个 Issue 还没有评估数据。

描述

bug
Describe the bug

#355 introduced Flake8 7.2.0, which added a new variable scoping check. at_client currently fails that test throwing an F824 error:

./at_client/atclient.py:348:13: F824 `global should_be_running_lock` is unused: name is never assigned in scope
            global should_be_running_lock
            ^
./at_client/atclient.py:371:13: F824 `global should_be_running_lock` is unused: name is never assigned in scope
            global should_be_running_lock
            ^
./at_client/connections/atmonitorconnection.py:37:9: F824 `global should_be_running_lock` is unused: name is never assigned in scope
        global should_be_running_lock
        ^
./examples/repl.py:93:17: F824 `global shared_queue` is unused: name is never assigned in scope
                global shared_queue
                ^
4     F824 `global should_be_running_lock` is unused: name is never assigned in scope
4

https://github.com/atsign-foundation/at_python/pull/355/commits/d7f839491e35269f2ec0121bb5200117e6d44157 put in place a workaround, and this ticket is to track its eventual removal.

Steps to reproduce

Run flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics --exclude .venv,.git without --ignore=F824

Expected behavior

Lints pass clean

主要语言
Python
星标
0
派生
4
平均合并
6 小时 25 分钟
30 天内合并 PR
11

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

atsign-foundation/at_python 的其他 Issue

查看 atsign-foundation/at_python 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。