错误信息:
Color management: using fallback mode for management
Color management: Error could not find role data role.
BLT_lang_init: 'locale' data path for translations not found, continuing
Color management: scene view "Filmic" not found, setting default "Standard".
blf_load_font_default: 'fonts' data path not found for 'droidsans.ttf', will not be able to display text
blf_load_font_default: 'fonts' data path not found for 'bmonofont-i18n.ttf', will not be able to display text
blf_load_font_default: 'fonts' data path not found for 'bmonofont-i18n.ttf', will not be able to display text
bpy: couldn't find 'scripts/modules', blender probably wont start.
Freestyle: couldn't find 'scripts/freestyle/modules', Freestyle won't work properly.
ModuleNotFoundError: No module named 'bpy_types'
ModuleNotFoundError: No module named 'bpy_types'
ERROR (bpy.rna): /Blender/blender/source/blender/python/intern/bpy_rna.c:7236 pyrna_srna_ExternalType: failed to find 'bpy_types' module
ModuleNotFoundError: No module named 'bpy_types'
ModuleNotFoundError: No module named 'bpy_types'
ERROR (bpy.rna): /Blender/blender/source/blender/python/intern/bpy_rna.c:7236 pyrna_srna_ExternalType: failed to find 'bpy_types' module
ModuleNotFoundError: No module named 'bpy_types'
ERROR (bpy.rna): /Blender/blender/source/blender/python/intern/bpy_rna.c:7236 pyrna_srna_ExternalType: failed to find 'bpy_types' module
ModuleNotFoundError: No module named 'bpy_types'
ERROR (bpy.rna): /Blender/blender/source/blender/python/intern/bpy_rna.c:7236 pyrna_srna_ExternalType: failed to find 'bpy_types' module
ModuleNotFoundError: No module named 'bpy_types'
ERROR (bpy.rna): /Blender/blender/source/blender/python/intern/bpy_rna.c:7236 pyrna_srna_ExternalType: failed to find 'bpy_types' module
ModuleNotFoundError: No module named 'bpy_types'
ERROR (bpy.rna): /Blender/blender/source/blender/python/intern/bpy_rna.c:7236 pyrna_srna_ExternalType: failed to find 'bpy_types' module
ModuleNotFoundError: No module named 'bpy_types'
ERROR (bpy.rna): /Blender/blender/source/blender/python/intern/bpy_rna.c:7236 pyrna_srna_ExternalType: failed to find 'bpy_types' module
F1025 14:42:28.139618 2423870 utilities.cc:346] Check failed: !IsGoogleLoggingInitialized() You called InitGoogleLogging() twice!
问题原因:包的位置错了。
根据网上别的回答,应该把2.91(这个根据版本号来的,是哪个版本就叫什么名字)这个文件夹移动到可执行python文件的同一目录下,即env/Scrips文件夹下,但是不知道是系统还是版本不一样我没有这个文件夹,而且本来就在一个目录下,但还是报上面那个错。
后面在github看到这个解决方案:
py -m pip install -U pip future-fstrings wheel
pip install -i https://test.pypi.org/simple/ bpy==2.82.post0 && bpy_post_install
* bpy==2.82.post0(这里后面跟你的版本号,我是2.91所以是bpy==2.91a0)
原解决方案地址:https://github.com/TylerGubala/blenderpy/issues/13
运行后好了
运行完后会输出:
Found Blender scripts directory at ……/anaconda3/envs/py37/bin/2.91
Moving ……/anaconda3/envs/py37/bin/2.91 to ……/anaconda3/envs/py37/lib/python3.7/site-packages
所以,根据这个提示来看,直接把2.91移动到site-packages里应该就可以了