Hi, I’m having trouble with addons tests and it’s essential I need to run them.
I don’t build blender and I’m unsure of what exactly to do to run the load tests.
I’m on Windows and I get my builds from buildbot nearly daily.
LazyDodo has been trying to help yet I’m still failing to run the tests.
I’m not an expert on console use and really… which console am I supposed to use?
Windows? Python? Blender?
Do I need to cd to blender.exe folder location? how?
Sorry but I really need some help with an exact process so I can run these tests in nightly builds.
Would it possible for someone to make me a .cmd to run the tests. If I drop the test files into blender directory then run a .cmd, this should be enough. I have tried this myself but didn’t get it working. To me that would be optimal, then I could drop the .cmd and test files into eash build I download and run easily.
It would greatly help me with Addons Development and help to stop the Developer complaints that I’ve broken the tests with errors in addons code.
Sorry to ask for the hand holding on this but it’s important I know the exact steps to run the tests and indeed which tests I should be regularly running.
Thanks.
The tests are so tightly integrated into the build system, it is really hard to pry most of them lose, it is really really recommended to run the unit tests with your own local build of blender, however since that is currently not an option for you, i’m gonna try my best to get you up and running with the setup you have (but i can’t recommend this for other users/developers)
The test most often breaking in the addons section (and currently broken) is the script_load_addons
test. Which can be relatively easy be run on a buildbot build.
-
grab the bl_load_addons.py script and save it next to blender.exe
-
In the blender folder there should already be a blender_debug_log.cmd
make a copy of it, and rename it to blender_addons_test.cmd
-
Right click on it, and click edit and replace the contents with
blender.exe --background -noaudio --factory-startup --python bl_load_addons.py > blender.log 2>&1
and save it.
- now double click on it and after a few seconds the black console screen will go away and it should have created a
blender.log
with the results in it.
Which currently should have this error
Blender 2.80 (sub 74) (hash 9d28b8ae3f69 built Tue 07/16/2019 11:20 PM)
found bundled python: e:\builds\build_soc-2019-outliner\bin\2.80\python
Error: KeyMapItem 'WM_OT_call_menu_pie' cannot be removed from 'Window'
Traceback (most recent call last):
File "e:\builds\build_soc-2019-outliner\bin\2.80\scripts\modules\addon_utils.py", line 437, in disable
mod.unregister()
File "e:\builds\build_soc-2019-outliner\bin\2.80\scripts\addons\space_view3d_pie_menus\__init__.py", line 263, in unregister
unregister_submodule(mod)
File "e:\builds\build_soc-2019-outliner\bin\2.80\scripts\addons\space_view3d_pie_menus\__init__.py", line 113, in unregister_submodule
mod.unregister()
File "e:\builds\build_soc-2019-outliner\bin\2.80\scripts\addons\space_view3d_pie_menus\pie_editor_switch_menu.py", line 164, in unregister
km.keymap_items.remove(kmi)
RuntimeError: Error: KeyMapItem 'WM_OT_call_menu_pie' cannot be removed from 'Window'
Traceback (most recent call last):
File "e:\builds\build_soc-2019-outliner\bin\2.80\scripts\modules\addon_utils.py", line 384, in enable
mod.register()
File "e:\builds\build_soc-2019-outliner\bin\2.80\scripts\addons\space_view3d_pie_menus\__init__.py", line 249, in register
bpy.utils.register_class(cls)
ValueError: register_class(...): already registered as a subclass
Traceback (most recent call last):
File "e:\builds\build_soc-2019-outliner\bin\bl_load_addons.py", line 147, in <module>
main()
File "e:\builds\build_soc-2019-outliner\bin\bl_load_addons.py", line 138, in main
reload_addons(do_reload=False, do_reverse=False)
File "e:\builds\build_soc-2019-outliner\bin\bl_load_addons.py", line 114, in reload_addons
assert(mod_name in addons)
AssertionError
1 Like