gpt4 book ai didi

python-3.x - PyCharm:在 'Gtk' 中找不到引用 '__init__.py'

转载 作者:行者123 更新时间:2023-12-04 10:07:08 25 4
gpt4 key购买 nike

我有一个干净的虚拟环境

conda create --name gtk python=3.8

conda install -c conda-forge pygobject gtk3


当我添加导入时 from gi.repository import Gtk根据 PyGTK3维基。

PyCharm 提示说 Cannot find reference 'Gtk' in '__init__.py'

最佳答案

PyCharm 提供自动修复 'Generate stubs for binary module'这解决了这个问题。

关于python-3.x - PyCharm:在 'Gtk' 中找不到引用 '__init__.py',我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/61528664/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com