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

TypeError: stat: path should be string, bytes, os.PathLike or integer, not NoneType #12

Closed
Volkor3-16 opened this issue Apr 4, 2022 · 2 comments

Comments

@Volkor3-16
Copy link

Running CATS dev build (the one with integration), but I don't think that's relevant.
I tried both the latest commit on master, and the release, and got the same error.
Happy to help out with debugging if needed :)

Python: Traceback (most recent call last):
  File "C:\Program Files\Blender Foundation\Blender 3.0\3.0\scripts\startup\bl_operators\userpref.py", line 458, in execute
    mod = addon_utils.enable(self.module, default_set=True, handle_error=err_cb)
  File "C:\Program Files\Blender Foundation\Blender 3.0\3.0\scripts\modules\addon_utils.py", line 305, in enable
    if mod and os.path.exists(mod.__file__):
  File "C:\Program Files\Blender Foundation\Blender 3.0\3.0\python\lib\genericpath.py", line 19, in exists
    os.stat(path)
TypeError: stat: path should be string, bytes, os.PathLike or integer, not NoneType

location: <unknown location>:-1
@Volkor3-16
Copy link
Author

Volkor3-16 commented Apr 18, 2022

Same error on Blender LTS 2.93.8

@triazo
Copy link
Owner

triazo commented Apr 30, 2022

Figured I'd comment since I've figured out what's going on here, I haven't figured out the best fix yet but there's probably a few ways I can do it and I'll try to get that up asap so I can release 0.3 and work on redoing stuff for ik2 and lock all mode.

So the cats integration uses a submodule, when you the whole repo as a zip (as all installations of the cats dev are) that submodule isn't populated and is just left as an empty folder, which is picked up by blender python as an empty module. When immersive scaler is installed later, python continues to use the old module until either the list is refreshed or blender is restarted. I basically need to force blender to reload the module list at some point.

Workaround for now is to install, restart blender, then enable.

triazo added a commit to triazo/cats-blender-plugin that referenced this issue May 19, 2022
The submodule had the same name as the actual module when
installed, which was causing issues when installing immersive
scaler after installing cats dev. See triazo/immersive_scaler#12
feilen pushed a commit to absolute-quantum/cats-blender-plugin that referenced this issue Jun 11, 2022
The submodule had the same name as the actual module when
installed, which was causing issues when installing immersive
scaler after installing cats dev. See triazo/immersive_scaler#12
@triazo triazo closed this as completed Aug 31, 2022
AraHaan pushed a commit to AraHaan/cats-blender-plugin that referenced this issue Jan 9, 2024
…um#465)

The submodule had the same name as the actual module when
installed, which was causing issues when installing immersive
scaler after installing cats dev. See triazo/immersive_scaler#12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants