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

_customize_scene() is not called during Android export #96104

Closed
cengiz-pz opened this issue Aug 26, 2024 · 3 comments · Fixed by #98265
Closed

_customize_scene() is not called during Android export #96104

cengiz-pz opened this issue Aug 26, 2024 · 3 comments · Fixed by #98265

Comments

@cengiz-pz
Copy link

Tested versions

Reproducible in 4.3.stable

System information

Android 13 - Godot v4.3.stable - Windows 11 dev environment

Issue description

The documentation states:

Return true [from _begin_customize_scenes() method] if this plugin will customize scenes based on the platform and features used.
When enabled, _get_customization_configuration_hash and _customize_scene will be called and must be implemented.

However, in the attached project, _customize_scene() method is never called.

Interestingly, if the included plugin's aar archive files are removed and replaced with dummy files, then the export mechanism starts calling the _customize_scene() method.

Steps to reproduce

  1. Open attached project in Godot Editor
  2. Install Android export template from Godot's Project menu
  3. Select Android export preset and export debug
  4. Check output tab & notice that _customize_scene() is never called (addons/SharePlugin/ShareExportPlugin.gd)
  5. Remove addons/SharePlugin/bin/debug/SharePlugin-3.0-debug.aar and addons/SharePlugin/bin/release/SharePlugin-3.0-release.aar & replace with dummy files, & notice that export fails, but _customize_scene() method is called.

Minimal reproduction project (MRP)

customize-scenes.zip

@godotengine godotengine deleted a comment Aug 26, 2024
@godotengine godotengine deleted a comment Aug 26, 2024
@godotengine godotengine deleted a comment Aug 26, 2024
@godotengine godotengine locked and limited conversation to collaborators Aug 26, 2024
@godotengine godotengine unlocked this conversation Aug 26, 2024
@syntaxerror247
Copy link
Member

syntaxerror247 commented Oct 16, 2024

@cengiz-pz _customize_scene() is called if a scene is modified before export. Doc link

You can try adding a new child or creating a scene before export.

@Alex2782
Copy link
Member

  1. Check output tab & notice that _customize_scene() is never called

I couldn't reproduce it

image

@Alex2782
Copy link
Member

@cengiz-pz _customize_scene() is called if a scene is modified before export. Doc link

You can try adding a new child or creating a scene before export.

Reproduced in the 2nd attempt, what you wrote, what is in the documentation is correct.

PR: #65135

Uses a cache for the converted files if nothing changes, so this work only happens if a file is modified.

For large projects it makes sense to speed up the export process. Otherwise, editor_description could be adjusted, e.g. write timestamps there to force _customize_scene.

I think no bug and it can be closed?

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

Successfully merging a pull request may close this issue.

5 participants
@Alex2782 @AThousandShips @cengiz-pz @syntaxerror247 and others