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

bcrypt 4.0.0 test failure on 32bit arch

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

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
35/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
停滞
技术栈
python

调研方向

Reproduce the failure with the 32-bit Mageia or Fedora Mock build, then inspect bcrypt/init.py around kdf and tests/test_bcrypt.py at test_kdf. Run the reported tox py310 test environment and compare behavior on a 32-bit system. Done means the test suite completes without a segmentation fault on the affected architecture.

由索引模型根据 Issue 内容生成。

描述

Tests fails due to a segfault on 32bit Mageia Cauldron, the development version of the distro. I can reproduce the issue also with Fedora 36 bcrypt mock build. Mock is a tool for a reproducible build of RPM packages.

+ /usr/bin/python3 -m tox --current-env -q --recreate -e py310
============================= test session starts ==============================
platform linux -- Python 3.10.6, pytest-7.1.3, pluggy-1.0.0
cachedir: .tox/py310/.pytest_cache
rootdir: /builddir/build/BUILD/bcrypt-4.0.0
collected 150 items

tests/test_bcrypt.py ................................................... [ 34%]
........................................................................ [ 82%]
..Fatal Python error: Segmentation fault

Current thread 0xf7938700 (most recent call first):
  File "/builddir/build/BUILDROOT/python-bcrypt-4.0.0-1.mga9.i386/usr/lib/python3.10/site-packages/bcrypt/__init__.py", line 127 in kdf
  File "/builddir/build/BUILD/bcrypt-4.0.0/tests/test_bcrypt.py", line 443 in test_kdf
  File "/usr/lib/python3.10/site-packages/_pytest/python.py", line 192 in pytest_pyfunc_call
  File "/usr/lib/python3.10/site-packages/pluggy/_callers.py", line 39 in _multicall
  File "/usr/lib/python3.10/site-packages/pluggy/_manager.py", line 80 in _hookexec
  File "/usr/lib/python3.10/site-packages/pluggy/_hooks.py", line 265 in __call__
  File "/usr/lib/python3.10/site-packages/_pytest/python.py", line 1761 in runtest
  File "/usr/lib/python3.10/site-packages/_pytest/runner.py", line 166 in pytest_runtest_call
  File "/usr/lib/python3.10/site-packages/pluggy/_callers.py", line 39 in _multicall
  File "/usr/lib/python3.10/site-packages/pluggy/_manager.py", line 80 in _hookexec
  File "/usr/lib/python3.10/site-packages/pluggy/_hooks.py", line 265 in __call__
  File "/usr/lib/python3.10/site-packages/_pytest/runner.py", line 259 in <lambda>
  File "/usr/lib/python3.10/site-packages/_pytest/runner.py", line 338 in from_call
  File "/usr/lib/python3.10/site-packages/_pytest/runner.py", line 258 in call_runtest_hook
  File "/usr/lib/python3.10/site-packages/_pytest/runner.py", line 219 in call_and_report
  File "/usr/lib/python3.10/site-packages/_pytest/runner.py", line 130 in runtestprotocol
  File "/usr/lib/python3.10/site-packages/_pytest/runner.py", line 111 in pytest_runtest_protocol
  File "/usr/lib/python3.10/site-packages/pluggy/_callers.py", line 39 in _multicall
  File "/usr/lib/python3.10/site-packages/pluggy/_manager.py", line 80 in _hookexec
  File "/usr/lib/python3.10/site-packages/pluggy/_hooks.py", line 265 in __call__
  File "/usr/lib/python3.10/site-packages/_pytest/main.py", line 347 in pytest_runtestloop
  File "/usr/lib/python3.10/site-packages/pluggy/_callers.py", line 39 in _multicall
  File "/usr/lib/python3.10/site-packages/pluggy/_manager.py", line 80 in _hookexec
  File "/usr/lib/python3.10/site-packages/pluggy/_hooks.py", line 265 in __call__
  File "/usr/lib/python3.10/site-packages/_pytest/main.py", line 322 in _main
  File "/usr/lib/python3.10/site-packages/_pytest/main.py", line 268 in wrap_session
  File "/usr/lib/python3.10/site-packages/_pytest/main.py", line 315 in pytest_cmdline_main
  File "/usr/lib/python3.10/site-packages/pluggy/_callers.py", line 39 in _multicall
  File "/usr/lib/python3.10/site-packages/pluggy/_manager.py", line 80 in _hookexec
  File "/usr/lib/python3.10/site-packages/pluggy/_hooks.py", line 265 in __call__
  File "/usr/lib/python3.10/site-packages/_pytest/config/__init__.py", line 164 in main
  File "/usr/lib/python3.10/site-packages/_pytest/config/__init__.py", line 187 in console_main
  File "/usr/lib/python3.10/site-packages/pytest/__main__.py", line 5 in <module>
  File "/usr/lib/python3.10/site-packages/coverage/execfile.py", line 199 in run
  File "/usr/lib/python3.10/site-packages/coverage/cmdline.py", line 830 in do_run
  File "/usr/lib/python3.10/site-packages/coverage/cmdline.py", line 659 in command_line
  File "/usr/lib/python3.10/site-packages/coverage/cmdline.py", line 943 in main
  File "/usr/bin/coverage", line 8 in <module>
ERROR: InvocationError for command /usr/bin/coverage run -m pytest --strict-markers (exited with code -11 (SIGSEGV)) (exited with code -11)
___________________________________ summary ____________________________________
ERROR:   py310: commands failed

Full build logs available in Fedora COPR, mageia-cauldron-i586 builder-live.log.gz.

主要语言
Python
星标
1.5k
派生
216
平均合并
6 小时 15 分钟
30 天内合并 PR
8

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

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

pyca/bcrypt 的其他 Issue

查看 pyca/bcrypt 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

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