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

Bug: error when trying to load fbx of .blend file inside Blender, if it was published by the Tray Publisher #6017

Open
2 tasks done
alainxi opened this issue Dec 6, 2023 · 4 comments

Comments

@alainxi
Copy link

alainxi commented Dec 6, 2023

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior:

If you use the WindowsTray-->Ayon-->Publisher to publish an fbx or a .blend file, then you cannot load it from inside Blender (menu Ayon-->Load).

It only bugs if the publish was done using the Tray publisher (I tried both fbx and blend files).
If I publish from inside Blender, then there is no load error and no popup appears.

Expected Behavior:

We should be able to load in Blender, fbx and .blend scenes that where publish by the Tray publisher.

Version

3.17.7-nightly.5

What platform you are running OpenPype on?

Windows

Steps To Reproduce:

Using the WindowsTray-->Ayon-->Publisher, publish an fbx file (or a .blend file).
Select an asset and a Modeling task, and choose the "Model" publish type.
The publish works all right, no errors.

From inside Blender, use the menu Ayon-->Load
Then select the product you just published, and click on RightMouseButton-->Load FBX (fbx)

An error popup will display this : "Error : No asset group found"
error

Are there any labels you wish to add?

  • I have added the relevant labels to the bug report.

Relevant log output:

Traceback (most recent call last):

  File "C:\Users\Alain\AppData\Local\Ynput\AYON\addons\openpype_3.17.7\openpype\hosts\blender\api\ops.py", line 113, in execute
    result = callback(*args, **kwargs)

  File "C:\Users\Alain\AppData\Local\Ynput\AYON\addons\openpype_3.17.7\openpype\hosts\blender\api\plugin.py", line 476, in _load
    nodes = self.process_asset(

  File "C:\Users\Alain\AppData\Local\Ynput\AYON\addons\openpype_3.17.7\openpype\hosts\blender\plugins\load\load_fbx.py", line 150, in process_asset
    objects = self._process(libpath, asset_group, group_name, None)

  File "C:\Users\Alain\AppData\Local\Ynput\AYON\addons\openpype_3.17.7\openpype\hosts\blender\plugins\load\load_fbx.py", line 71, in _process
    assert container, "No asset group found"

AssertionError: No asset group found



Also, checking the Blender output window,  this appears when clicking on  RightMouseButton-->Load FBX (fbx)  :

Initialising WM_OT_avalon_loader...
execute_in_main_thread
Executing process in main thread
Running callback: <bound method AssetLoader._load of []>
FBX version: 7400
Done

Additional context:

The problem is the same on Blender 3.3 and Blender 4.

The "No asset group found" problem is detected by several load kinds (blend, blendscene, fbx, animation) :

assert container, "No asset group found"

assert container, "No asset group found"

assert container, "No asset group found"

assert container, "No asset group found"

Looking at the load code, it seems the imported file (fbx, .blend, etc...) must contain an empty, or else it raises a "No asset group found" exception.
As we will use the WindowsTray-->Ayon-->Publisher to publish fbx of blend files that are purchased or provided by our clients, their content does not automatically contain an empty, but it should still be possible to load it inside Blender using Ayon's Load menu.

[cuID:OP-7547]

@LiborBatek
Copy link
Member

I guess that assets originating from Tray Publisher not working at all. So not just FBX but any other like for ie Pointcache or Model etc.

They do not have present any nodes with neccessary metadata present ATM ??

@LiborBatek
Copy link
Member

@simonebarbieri @iLLiCiTiT I think that this not being supported at all and might need solution in the future, not simply possible feature wise ATM

@BigRoy
Copy link
Collaborator

BigRoy commented Feb 26, 2024

Shouldn't an alembic gone through tray publisher as abc be loaded with this loader: https://github.com/ynput/OpenPype/blob/3cf3c93fa608d12262b9f84fd88ed13c54f29046/openpype/hosts/blender/plugins/load/load_abc.py

All that seems to expect is that there's at least one top node that it'll use as 'container'. No?

For your FBX case isn't the issue that it's just not able to find anything that Blender loads as an empty, like a group? Are you FBX'es flat direct meshes maybe?

@alainxi
Copy link
Author

alainxi commented Feb 26, 2024

Yes, the use case is to have the pipeline ingest fbx files that were produced elsewhere (provided by the client, purchased on the web, etc...), so most of the time it has a random structure.
I just tested, it works all right if I parent the mesh below an empty, and export as fbx.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants