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

AttributeError: module 'builtins' has no attribute 'loader' #740

Open
shqln opened this issue Dec 6, 2024 · 0 comments
Open

AttributeError: module 'builtins' has no attribute 'loader' #740

shqln opened this issue Dec 6, 2024 · 0 comments

Comments

@shqln
Copy link

shqln commented Dec 6, 2024

Ursina version 7.0.0
Windows version 10.0.19045 Build 19045

Everything was working last week, one day I started encountering this error when I try to start any ursina script

Traceback (most recent call last):
File "c:\Users\Shiqi\Documents\ursina\what.py", line 1, in
from ursina import *
File "C:\Users\Shiqi\miniconda3\envs\ursina\Lib\site-packages\ursina_init_.py", line 30, in
from ursina.boxcast import boxcast
File "C:\Users\Shiqi\miniconda3\envs\ursina\Lib\site-packages\ursina\boxcast.py", line 8, in
_boxcast_box = Entity(model='cube', origin_z=-.5, collider='box', color=color.white33, enabled=False, eternal=True, add_to_scene_entities=False)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Shiqi\miniconda3\envs\ursina\Lib\site-packages\ursina\ursinastuff.py", line 230, in call
obj = type.call(cls, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Shiqi\miniconda3\envs\ursina\Lib\site-packages\ursina\entity.py", line 107, in init
setattr(self, key, kwargs[key])
File "C:\Users\Shiqi\miniconda3\envs\ursina\Lib\site-packages\ursina\entity.py", line 198, in model_setter
m = load_model(value, application.asset_folder)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Shiqi\miniconda3\envs\ursina\Lib\site-packages\ursina\mesh_importer.py", line 55, in load_model
return builtins.loader.loadModel(filename) # type: ignore
^^^^^^^^^^^^^^^
AttributeError: module 'builtins' has no attribute 'loader'

Tried:

  • running the basic ursina example scene
  • running ursina in python's interactive shell
  • reinstalling ursina
  • creating fresh venv with different python versions (3.10, 3.11, 3.12)
  • creating venv in WSL

all yield the same error message.

However, installing ursina 6.1.2 and running the basic example scene works fine.

Does anyone have an idea why this error occurs in the first place when it used to work perfectly fine? I installed ursina relatively recently so I would have most likely had the same 7.0.0 version.

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

1 participant