Home Website Youtube GitHub

Adding an empty folder is causing unique naming warnings

Hi, I am new to scripting with mGear. I am trying to create a custom module to get myself more familiar with the code. I created an custom_module folder and put the path in my maya.env

MGEAR_SHIFTER_COMPONENT_PATH =C:\Users\myName\tools\mgear\custom_modules

I created an empty folder named “tail_testMod” under my “custom_module” folder as a start and before even putting any code in there mGear gives me the following warning:

Warning: Custom component name: init.pyc, already in default components. Names should be unique. This component is not loaded

I am confused as to why mGear throw this warning?

I think this should be considered a bug.

In mgear/shifter/guide_manager_component.py
In GuideManagerComponent.get_component_list() it tries to load all component directories using shifter.getComponentDirectories().

If that fails, that is just the warning it prints. But that warning is a bit misleading. It definitely doesn’t mean what it says.

Anyway, once you have the component files set up, it won’t give that warning any more. You can ignore it for now.

Actually, this might have already been fixed here? remove warning mistake when listing components · mgear-dev/shifter@2825b31 · GitHub

But I haven’t tested. I tested in mGear 3.7.11

@chrislesage if is not fixed. Please feel free to open a ticket on github and add it to the project mgear 4.x.
Thanks!

1 Like