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

Restarting the project sometimes make the package not work anymore [USDU-461] #402

Open
SoftwareMechanic opened this issue Jul 21, 2023 · 8 comments

Comments

@SoftwareMechanic
Copy link

SoftwareMechanic commented Jul 21, 2023

Hello!

Sometimes closing and reopening a Unity project make the package just not working anymore (maybe something saved in cache?), I can not import anymore USD files in Unity and whenever I try to open a stage reading a file from script I get errors:

  • ApplicationException: USD ERROR: Cannot determine file format for @C:/folder/output.usd:SDF_FORMAT_ARGS:target=usd@
  • ApplicationException: USD ERROR: Failed to open layer @C:/path/to/output.usd@
  • NullReferenceException: Null stage

so in the end I can not open and read USD file anymore

  • Asset Packages/com.unity.formats.usd/Runtime/Scripts/Tests/TestData/Materials has no meta file, but it's in an immutable folder. The asset will be ignored.
  • Asset Packages/com.unity.formats.usd/Runtime/Scripts/Tests/TestData/Materials has no meta file, but it's in an immutable folder. The asset will be ignored.

and a lot of similar logs all related to Materials

The files are correctly rendered in USD View and others tool.
Before I faced this issue, I was working easily with the same files, both from editor menu (Import) and from script.

you can see that issue #401 has been created by me, I was just reporting issue post-import, but now I can not even import the same file:
https://github.com/Unity-Technologies/usd-unity-sdk/files/12135108/usd_files.zip

Unity Version: 2022.3 (I faced same issue with .0 and .5f1)

In the projects I am testing this, there is also the NVIDIA Omniverse package installed, do you think this could cause conflicts?

I hope this can help you to improve this package :)

@SoftwareMechanic
Copy link
Author

SoftwareMechanic commented Jul 22, 2023

OK,
I found that removing and reinstalling the packaged doesn't work.
But I found that deleting the Library folder and reopening the project the package works again

@vickycl
Copy link
Collaborator

vickycl commented Jul 24, 2023

Hi @Baruchware, this is super interesting, thank you for reporting. A few follow up questions so we can investigate:

  • How are you installing the package? Which version?
  • You say 'Before I faced this issue...', is this something you have only started facing recently? Perhaps with a package upgrade?
  • In my local checkout of the package and in the GitHub repo I don't see a 'Materials' folder in that TestData folder, so that sounds super weird. Is this something you have added by any chance?

The NVIDIA Omniverse Connector is an intriguing point. It is something we haven't tested for compatibility with our package, so I will make a note to test this. In the meantime, it would be really interesting if you could test removing/ disabling that package and see if your issue arises again?

@vickycl vickycl changed the title Restarting the project sometimes make the package not work anymore Restarting the project sometimes make the package not work anymore [USDU-461] Jul 24, 2023
@SoftwareMechanic
Copy link
Author

Hello and thank you for the answer !

I am using the last package version (the only one I tried) 3.0.0 - exp4
sadly I started using your package very recently so I can not compare this with experience of other versions,
for the Materials folder I didn't added nothing, maybe it is just a remnant of tests made by developers ( I don't think this is creating the issue, but I wanted to share this info with you because I am not sure)

For the NVIDIA Omniverse Connector I will test a new project without it, and let you know ☺️

@vickycl
Copy link
Collaborator

vickycl commented Jul 25, 2023

Thank you for your answers, I will update our ticket. Please let us know whether or not you still see the issue without the Nvidia package :)

@SoftwareMechanic
Copy link
Author

SoftwareMechanic commented Jul 26, 2023

Hello @vickycl,
I found that restarting a project multiple times (without the NVIDIA Omniverse connector installed in the project) it seems to works fine 😊

So maybe the issue is a sort of conflict between those 2 packages (maybe because of references to 'pxr' namespace?)

I am trying to use both because they have a very nice import which supports URP and HDRP, but considering this, I will wait for you to implement those pipelines.
Also because I don't want to be forced to use the Omniverse Connector.

in the issue #401 we are already discussing about the usage of the branch which should support URP.

thank you!

EDIT: just a side note:
if you want/need to use both (usd unity sdk and Omniverse connector) for each session of Unity (every time you open Unity3D) you have to reinstall both

@codethegame18
Copy link

@vickycl @Baruchware
I work on the NVIDIA Omniverse Unity Connector team, and we test compatibility with the Unity USD SDK (latest exp.4) package alongside the connector to ensure both packages work together.

Could you please provide more context on your operations that caused the incompatibility error reported above?

@vickycl
Copy link
Collaborator

vickycl commented Aug 14, 2023

Hi @codethegame18! Great to meet you, and I'm really happy to hear it's something being actively tested. I don't have the reproduction case that @Baruchware has mentioned, but if you are able to get to the bottom of it I would be glad to hear it and help out from our side. I (perhaps prematurely) added a disclaimer to the docs that the packages aren't compatible, so I will remove that before we release the new version of the package.
(Edit: Accidentally closed the ticket, sorry!)

@vickycl vickycl closed this as completed Aug 14, 2023
@vickycl vickycl reopened this Aug 14, 2023
@AnisAbDev
Copy link

Hey, any update about this issue ?

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