Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

missing bl_info dict #52

Closed
hannesdelbeke opened this issue Nov 10, 2022 · 7 comments
Closed

missing bl_info dict #52

hannesdelbeke opened this issue Nov 10, 2022 · 7 comments
Labels
bug Something isn't working

Comments

@hannesdelbeke
Copy link
Collaborator

Has anyone else had problems with the latest bqt version?
Using 3.3LTS and the addon no longer has the bl_info dict which causes an error on start up

slack chatlog: Shea Richardson

I had to do some fix ups to get it functional for 3.3 LTS
main one was this:
https://tech-artists.slack.com/archives/C0F73KP2N/p1666962461134569
Has anyone else had problems with the latest bqt version?
Using 3.3LTS and the addon no longer has the bl_info dict which causes an error on start up
could have been related to how we load auto-load our plugins
it caused an infinite loop if it did not exist

reported by Shea Richardson
who will make a PR 🙏

@munkybutt
Copy link

munkybutt commented Nov 10, 2022

Further info related to the error:
It occurs when enabling the addon programmatically using:
addon_utils.enable:

Traceback (most recent call last):
  File ".../blender/python/startup/startup.py", line 124, in _auto_enable_addons
    auto_enable_addons(addons_root_path)
  File ".../blender/python/startup/startup.py", line 87, in auto_enable_addons
    bpy.ops.wm.save_userpref()
  File "C:/Program Files/Blender Foundation/Blender 3.3/3.3/scripts/modules/bpy/ops.py", line 97, in __call__
    import bpy
  File "C:/Program Files/Blender Foundation/Blender 3.3/3.3/python/lib/site-packages/shiboken2/files.dir/shibokensupport/__feature__.py", line 142, in _import
    return original_import(name, *args, **kwargs)
  File "C:/Program Files/Blender Foundation/Blender 3.3/3.3/scripts/modules/bpy/__init__.py", line 61, in <module>
    main()
  File "C:/Program Files/Blender Foundation/Blender 3.3/3.3/scripts/modules/bpy/__init__.py", line 58, in main
    utils.load_scripts()
  File "C:/Program Files/Blender Foundation/Blender 3.3/3.3/scripts/modules/bpy/utils/__init__.py", line 301, in load_scripts
    _initialize()
  File "C:/Program Files/Blender Foundation/Blender 3.3/3.3/scripts/modules/addon_utils.py", line 29, in _initialize
    enable(addon.module)
  File "C:/Program Files/Blender Foundation/Blender 3.3/3.3/scripts/modules/addon_utils.py", line 355, in enable
    if mod.bl_info.get("blender", (0, 0, 0)) < (2, 80, 0):
AttributeError: module 'bqt' has no attribute 'bl_info'

The fix is to re-add the bl_info dict to bqt __init__.py file:

bl_info = {
    "name": "Qt for Blender",
    "author": "Tech-Artists.org",
    "version": (0, 2),
    "blender": (2, 80, 3),
    "description": "Qt for Blender",
    "warning": "",
    "wiki_url": "",
}

@hannesdelbeke
Copy link
Collaborator Author

awesome, look forward to the PR next week

@hannesdelbeke
Copy link
Collaborator Author

any chance you have this fix still lying around anywhere? @munkybutt

@hannesdelbeke
Copy link
Collaborator Author

if it's only the bl info, i can do this myself

@munkybutt
Copy link

Hey bud - yeah it is just the top level dict called bl_info that is required

@hannesdelbeke
Copy link
Collaborator Author

hannesdelbeke commented Mar 15, 2023

1ec8e4e added bl_info to the bqt/__init__.py .
The startup in dist doesn't has bl_info added, but i plan to delete this file, see #61

@hannesdelbeke
Copy link
Collaborator Author

removed the leftover empty addon, finsihing the cleanup. closing this.

@hannesdelbeke hannesdelbeke added the bug Something isn't working label Jun 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants