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

fix: trying to access addressable settings while editor is compiling #66

Conversation

Ale1
Copy link
Contributor

@Ale1 Ale1 commented Aug 10, 2023

Its documented limitation of AddressableAssetSettingsDefaultObject.Settings will return null if being accessed while Editor is compiling or updating. This provides a workaround to remove the null Settings error.

@starikcetin
Copy link
Owner

starikcetin commented Aug 11, 2023

This works for AddressablesChangeListener. However, the generator also has the same problem, but the solution there won't be as simple. I want to figure out a solution there and merge the two together with this PR.

@Ale1
Copy link
Contributor Author

Ale1 commented Aug 12, 2023

I've updated this patch and used the same work-around for the SceneAssetProcessor (which is the other culprit of calling SceneDataMapsGenerator.Run() too soon).

Though in the long-run, maybe it makes more sense for the ScenDataMapsGenerator to delay itself instead of relying on its gentlemen callers to be polite with the timing. :-)

@starikcetin
Copy link
Owner

Yeah, what worries me is batchmode builds, because if quit flag is given, delays may misbehave. We need some rigorous testing there.

@starikcetin starikcetin changed the base branch from entities-subscene-support to main November 12, 2023 10:22
@starikcetin starikcetin changed the base branch from main to entities-subscene-support November 12, 2023 10:23
@starikcetin
Copy link
Owner

May be superseded by #87.

@starikcetin
Copy link
Owner

Superseded by #87.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Opening project with addressable + sceneReference package for first time can lead to init race condition
2 participants