Skip to content

Update API description and Android SDK components for P preview 3. - #1728

Merged
jonpryor merged 1 commit into
dotnet:masterfrom
atsushieno:api-p-preview3
May 30, 2018
Merged

Update API description and Android SDK components for P preview 3.#1728
jonpryor merged 1 commit into
dotnet:masterfrom
atsushieno:api-p-preview3

Conversation

@atsushieno

Copy link
Copy Markdown
Contributor

The API updates are regeneration from the xamarin-android-docimporter-ng
tool fixes.

The API updates are regeneration from the xamarin-android-docimporter-ng
tool fixes.
@atsushieno
atsushieno requested a review from jonpryor as a code ownerMay 24, 2018 09:34
@atsushieno

Copy link
Copy Markdown
ContributorAuthor

There is a bunch of removal of valueOf() method description, but there is no relevant removal in my tool. My explanation on that is, there used to be embedded valueOf() methods in the stub source code but they have vanished in the latest stubs. They don't affect API anyways.

@atsushieno

Copy link
Copy Markdown
ContributorAuthor

Relevant Java.Interop PR: dotnet/java-interop#325

@jonpryor

Copy link
Copy Markdown
Contributor

Are the Java.Interop changes required to merge this PR?

@jonpryor

Copy link
Copy Markdown
Contributor

Why does this PR change e.g. src/Mono.Android/Profiles/api-24.params.txt?

I imagine your earlier comment was attempting to address that question, so let me rephrase it (as I'm still confused):

Why is API-24 (and 25-27) being changed? API-28 would make sense, as API-P is being changed.

Also, why is the subject of this PR "components for P preview 3"? The Android API-P Overview page make it look like DP2 is the current version.

@jonpryorjonpryor added the full-mono-integration-build For PRs; run a full build (~6-10h for mono bumps), not the faster PR subset (~2h for mono bumps) label May 29, 2018
@jonpryor

Copy link
Copy Markdown
Contributor

build

@jonpryor

Copy link
Copy Markdown
Contributor

Why is API-24 (and 25-27) being changed? API-28 would make sense, as API-P is being changed.

The cause for the enumeration valueOf() method removals in the *.params.txt is because we are using the Java source stub parser to determine parameter names, and the valueOf() method is produced by the Java compiler, and is not present in Java source code. For example, the src/android/database/CursorJoiner.java entry within the platforms/android-24/android-stubs-src.jar file contains:

packageandroid.database;
publicfinalclassCursorJoinerimplementsjava.util.Iterator<android.database.CursorJoiner.Result>, java.lang.Iterable<android.database.CursorJoiner.Result>
{
publicstaticenumResult
{
BOTH(),
LEFT(),
RIGHT();
}
publicCursorJoiner(android.database.CursorcursorLeft, java.lang.String[] columnNamesLeft, android.database.CursorcursorRight, java.lang.String[] columnNamesRight) { thrownewRuntimeException("Stub!"); }
publicjava.util.Iterator<android.database.CursorJoiner.Result> iterator() { thrownewRuntimeException("Stub!"); }
publicbooleanhasNext() { thrownewRuntimeException("Stub!"); }
publicandroid.database.CursorJoiner.Resultnext() { thrownewRuntimeException("Stub!"); }
publicvoidremove() { thrownewRuntimeException("Stub!"); }
}

Note that there is no valueOf() method. (Again, nor should there be, because the valueOf() method is compiler-generated.)


What we don't currently know is why the *.params.txt files originally had the valueOf() methods on the enum types. Perhaps those were from before we used the Java source parser and were instead parsing documentation?

@jonpryor

Copy link
Copy Markdown
Contributor

It looks like the build error is ignorable:

 Making sure we have http://dl-ssl.google.com/android/repository/build-tools_r24-macosx.zip downloaded and extracted from it... (TaskId:76)
Downloading http://dl-ssl.google.com/android/repository/build-tools_r24-macosx.zip into /Users/builder/jenkins/workspace/xamarin-android-pr-builder/xamarin-android/bin/TestRelease/temp/DesignTimeBuild_False_False_True/Cache/zips (TaskId:76)
/Users/builder/jenkins/workspace/xamarin-android-pr-builder/xamarin-android/bin/Release/lib/xamarin.android/xbuild/Xamarin/Android/Xamarin.Android.Common.targets(439,2): error XA5208: Download failed. Please build again. [/Users/builder/jenkins/workspace/xamarin-android-pr-builder/xamarin-android/bin/TestRelease/temp/DesignTimeBuild_False_False_True/UnnamedProject/UnnamedProject.csproj]
/Users/builder/jenkins/workspace/xamarin-android-pr-builder/xamarin-android/bin/Release/lib/xamarin.android/xbuild/Xamarin/Android/Xamarin.Android.Common.targets(439,2): error XA5208: Reason: The remote server returned an error: (502) Bad Gateway. [/Users/builder/jenkins/workspace/xamarin-android-pr-builder/xamarin-android/bin/TestRelease/temp/DesignTimeBuild_False_False_True/UnnamedProject/UnnamedProject.csproj]

This is probably ignorable, but just in case, let's try another build...

@jonpryor

Copy link
Copy Markdown
Contributor

build

@jonpryor

Copy link
Copy Markdown
Contributor

As hoped, the rebuild has no test failures. Instead, it has different unrelated (and unreported!) test failures:

 mono --debug packages/NUnit.ConsoleRunner.3.7.0/tools/nunit3-console.exe /Users/builder/jenkins/workspace/xamarin-android-pr-builder/xamarin-android/external/Java.Interop/build-tools/scripts/../../bin/TestRelease/Java.Interop.Dynamic-Tests.dll --result="TestResult-Java.Interop.Dynamic-Tests.xml;format=nunit2" --output="bin/TestRelease/TestOutput-Java.Interop.Dynamic-Tests.txt"
...
Native stacktrace: (TaskId:34)
(TaskId:34)
0 mono 0x000000010d1b12d8 mono_handle_native_crash + 264 (TaskId:34)
1 mono 0x000000010d21c896 altstack_handle_and_restore + 70 (TaskId:34)
2 mono 0x000000010d27bf09 mono_class_init + 329 (TaskId:34)
3 mono 0x000000010d27bf14 mono_class_init + 340 (TaskId:34)
4 mono 0x000000010d287dcf mono_class_is_subclass_of + 31 (TaskId:34)
5 libjava-interop.dylib 0x0000000131ca2968 get_gc_bridge_index + 120 (TaskId:34)
...
=================================================================
Got a SIGSEGV while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries used by your application.
=================================================================
.../RunNUnitTests.targets(30,5): error MSB3073: The command "mono --debug packages/NUnit.ConsoleRunner.3.7.0/tools/nunit3-console.exe /Users/builder/jenkins/workspace/xamarin-android-pr-builder/xamarin-android/external/Java.Interop/build-tools/scripts/../../bin/TestRelease/Java.Interop.Dynamic-Tests.dll --result="TestResult-Java.Interop.Dynamic-Tests.xml;format=nunit2" --output="bin/TestRelease/TestOutput-Java.Interop.Dynamic-Tests.txt"" exited with code -1.

@jonpryor
jonpryor merged commit 10e1ec1 into dotnet:masterMay 30, 2018
@github-actionsgithub-actionsBot locked and limited conversation to collaborators Feb 2, 2024
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

full-mono-integration-buildFor PRs; run a full build (~6-10h for mono bumps), not the faster PR subset (~2h for mono bumps)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@atsushieno@jonpryor