Bundle android error (#4236)

#1

I have a .script in defold project, but this script is not the defold script, just has the same file extension.When I build android bundle,It throw error:
image
I’m sure this script is not used by any defold components.Like gui, gameobject
It is just part of an external tool.

0 Likes

#2

Try to move those scripts outside the asset folder.

0 Likes

#3

Looks similar to this issue https://github.com/defold/editor2-issues/issues/1262

0 Likes

#4

I found a new build error when I make android bundle:
image
The Defold editor version I’m using is 1.2.157

0 Likes

#5

HI @gerrykwok7!
Sorry to hear you have trouble bundling.

I cannot see any thing related to that in our cloud build logs, so I’m guessing it’s something from within bob.jar.
One thing to test is to remove extensions one by one and see which one is creating trouble.

1 Like

#6

I have a project that was build error in defold 1.2.157 and success in defold 1.2.147, but the project is too large to upload.(53MB zipped).The detail of two version of defold is:
image image

0 Likes

#7

There is currently a problem bundling for Android on Windows with the latest Defold version:

Can you try with 1.2.156?

0 Likes

#8

image
1.2.156 still produce this error:
image

0 Likes

#9

My sample project is too large to upload to forum, How can I send my sample project to Defold team for debugging?

0 Likes

#10

Perhaps make a copy of your folder, remove all the big assets (e.g. keeping only main collection and it’s needed assets)? Make sure it still produces the same error.

Then you can zip it (without the ./build ang .git/ folders) and share here or with any of us privately.

0 Likes

#11

My sample project is an empty project(with only main collection) with 3 native extensions

0 Likes

#12

My sample project is too large to upload to forum

My sample project is an empty project(with only main collection) with 3 native extensions

Ok, so the extensions are too large to share? They’re not on git hub or similar?
How large is “large”?

0 Likes

#13

135MB, and 53MB when zipped, but the project is all-platform, it also include win32、ios、mac library

0 Likes

#14

emptytest.zip (1.9 MB)
This is my sample project that produce this error, I strip the library of win32、ios、mac platform

0 Likes

#15

I try this project in Defold 1.2.152 and it build successfully. And I havn’t download defold 1.2.153, 1.2.154,1.2.155

0 Likes

#16

Does this issue being solving?

0 Likes

#17

After running bob.jar, (1.2.156) you’ll get an error like this:

Exception in thread "main" com.dynamo.bob.CompileExceptionError: Format specifier '%s'
	at com.dynamo.bob.Project.build(Project.java:445)
	at com.dynamo.bob.Bob.main(Bob.java:557)
Caused by: java.util.MissingFormatArgumentException: Format specifier '%s'
	at java.util.Formatter.format(Formatter.java:2519)
	at java.util.Formatter.format(Formatter.java:2455)
	at java.lang.String.format(String.java:2940)
	at com.dynamo.bob.pipeline.ExtenderUtil.getPlatformSettingsFromExtensions(ExtenderUtil.java:917)
	at com.dynamo.bob.bundle.BundleHelper.generateAndroidResources(BundleHelper.java:416)
	at com.dynamo.bob.Project.buildEngine(Project.java:714)
	at com.dynamo.bob.Project.doBuild(Project.java:844)
	at com.dynamo.bob.Project.build(Project.java:435)
	... 1 more

which is very useful.

After fixing that bug I get:

Exception in thread "main" com.dynamo.bob.CompileExceptionError: Extension manifest '/Users/mathiaswesterdahl/work/projects/gerrykwok/extension/luajavaoc/ext.manifest' contains invalid values: java.lang.RuntimeException: Class types differ: 'class java.util.HashMap' != 'class java.util.LinkedHashMap' for values '{flags=[]}' and '{flags=[]}'
	at com.dynamo.bob.pipeline.ExtenderUtil.getPlatformSettingsFromExtensions(ExtenderUtil.java:917)
	at com.dynamo.bob.bundle.BundleHelper.generateAndroidResources(BundleHelper.java:416)
	at com.dynamo.bob.Project.buildEngine(Project.java:714)
	at com.dynamo.bob.Project.doBuild(Project.java:844)
	at com.dynamo.bob.Project.build(Project.java:435)
	at com.dynamo.bob.Bob.main(Bob.java:557)

It seems we have an issue comparing some values in your manifest files.
However, the workaround is to simply remove all the empty lines, and just have:

name: "luajavaoc"
2 Likes

#18

A fix is in review and is expected to land in the next release (next week)

1 Like