-
Notifications
You must be signed in to change notification settings - Fork 64
Weekly stable updates #415
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
Conversation
jpobst
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is causing the need to rework these methods:
Removed methods:
public virtual void OnNestedScrollAccepted (Android.Views.View child, Android.Views.View target, Android.Views.ScrollAxis axes, int type);
public virtual bool OnStartNestedScroll (Android.Views.View child, Android.Views.View target, Android.Views.ScrollAxis axes, int type);Added methods:
public virtual void OnNestedScrollAccepted (Android.Views.View child, Android.Views.View target, int axes);
public virtual void OnNestedScrollAccepted2 (Android.Views.View child, Android.Views.View target, int axes, int type);
public virtual bool OnStartNestedScroll (Android.Views.View child, Android.Views.View target, int axes);
public virtual bool OnStartNestedScroll2 (Android.Views.View child, Android.Views.View target, int axes, int type);This seems to hit several packages. If these are widely used, this has the possibility to cause extensive breaks to the ecosystem. Is there a way we can do this in a backwards compatible way?
mappings/dependencies.json
Outdated
| [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file looks like it was replaced with config.json, is that intentional?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no.
I need to see what I have done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I resolved conflicts manually in github editor. Seems like I pasted config.json somehow. Not sure.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
building fromscratch to regenerate dependencies.json
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
|
It looks like something changed to the parameter names in AndroidX.Core, which is causing the enumification changes to fail: /Users/runner/work/1/s/generated/androidx.core.core/obj/Release/monoandroid9.0/generated/metadata(8,4): warning BG8A04: Metadata.xml element '<attr path="/api/package[@name='androidx.core.view']/*[@name='NestedScrollingParent']/method[@name='onStartNestedScroll']/parameter[@name='axis']" />' matched no nodes. [/Users/runner/work/1/s/generated/androidx.core.core/androidx.core.core.csproj]However we should still be changing the parameter name with this in <attr path="/api/package[@name='androidx.core.view']/interface[@name='NestedScrollingParent']/method[@name='onStartNestedScroll' and count(parameter)=3 and parameter[1][@type='android.view.View'] and parameter[2][@type='android.view.View'] and parameter[3][@type='int']]/parameter[3]" name="managedName">axes</attr>This does not happen on |
Not sure. I noticed some changes in interfaces in https://developer.android.com/reference/androidx/core/view/NestedScrollingParent https://developer.android.com/reference/androidx/core/view/NestedScrollingParent2 https://developer.android.com/reference/androidx/core/view/NestedScrollingParent3 It is interfaces that inherit one from another and I was not sure if that was google's breaking change or C# limitations or binding tooling issue. The culprit are changes in AndroidX.Core and i simply could not solve some build errors, but this way. I might overlooked something. I will try to redo those changes. Maybe some time off will help me or if you could take a look... I will try to fix thoses over the weekend |
|
The issue appears to be that Because these are based off parameter names which no longer exist, they no longer match and are no longer being applied. The good news is we have already have a The issue is that these transforms modify the parameter Replacing every |
|
attempt to fix parameters with corrected paths for fails with following error: Seems to be single project/artifact. |
jpobst
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like the ParameterNames.Metadata.xml for AndroidX.Core isn't very complete. There are still a lot of parameter names missing, resulting in actual API breaks like:
Type Changed: AndroidX.Core.View.WindowInsetsControllerCompat.ControllableInsetsChangedEventArgs
Removed properties:
public WindowInsetsControllerCompat Controller { get; }
public int TypeMask { get; }Added properties:
public WindowInsetsControllerCompat P0 { get; }
public int P1 { get; }Maybe we should try using the JavaSourceJar for only this library to see if it gets us back to where we were before.
I think once we get AndroidX.Core back to normal, we also won't need the Additions added for things like OnNestedScrollAccepted.
OK. Let me try that |
## Depends on #415 - do not merge before that
From the diff, it does not look like
This is because they are properties automatically generated for EventArgs from the listener method parameters: public interface OnControllableInsetsChangedListener
{
void onControllableInsetsChanged(@NonNull final WindowInsetsControllerCompat p0, final int p1);
}Without the parameter names, these properties get renamed: Type Changed: AndroidX.Core.View.WindowInsetsControllerCompat.ControllableInsetsChangedEventArgsRemoved properties: public WindowInsetsControllerCompat Controller { get; }
public int TypeMask { get; }Added properties: public WindowInsetsControllerCompat P0 { get; }
public int P1 { get; } |
|
|
|
so many changes on CI in last 2 weeks. Seems like Fixing that |
|
Seems that methods were moved to other interfaces and there is no other removed stuff in Core api-diff!! Namespace AndroidX.Core.ViewType Changed: AndroidX.Core.View.INestedScrollingParentRemoved methods: public virtual void OnNestedScrollAccepted (Android.Views.View child, Android.Views.View target, Android.Views.ScrollAxis axes);
public virtual bool OnStartNestedScroll (Android.Views.View child, Android.Views.View target, Android.Views.ScrollAxis axes);Type Changed: AndroidX.Core.View.INestedScrollingParent2Modified methods: -public abstract void OnNestedScrollAccepted (Android.Views.View child, Android.Views.View target, Android.Views.ScrollAxis axes, int type)
+public abstract void OnNestedScrollAccepted (Android.Views.View child, Android.Views.View target, Android.Views.ScrollAxis axes, int _type)
-public abstract bool OnStartNestedScroll (Android.Views.View child, Android.Views.View target, Android.Views.ScrollAxis axes, int type)
+public abstract bool OnStartNestedScroll (Android.Views.View child, Android.Views.View target, Android.Views.ScrollAxis axes, int _type)Type Changed: AndroidX.Core.View.INestedScrollingParent3Modified methods: -public abstract void OnNestedScroll (Android.Views.View target, int dxConsumed---p1---, int dyConsumed---p2---, int dxUnconsumed---p3---, int dyUnconsumed---p4---, int type---p5---, int[] consumed---p6---)
+public abstract void OnNestedScroll (Android.Views.View p0, int +++dxConsumed+++p1, int +++dyConsumed+++p2, int +++dxUnconsumed+++p3, int +++dyUnconsumed+++p4, int +++type+++p5, int[] +++consumed+++p6) |
This reverts commit 7ba5d15.
Use metadata from 1.6.0 to restore parameter names for AndroidX.Core.
|
merging and will bump for tomorrow |
|
@moljac @jpobst the The 1.0.0.3-beta03 build from #418 works fine (although we never merged this to main). Googling turned up this StackOverflow post which suggests the issue is related to a version of Xamarin.AndroidX.Core (1.6 vs 1.7 possibly) but I can't be sure this is the problem. Any thoughts? |
I have never seen this.
We had issues with Googling a bit https://exerror.com/solved-aapt-error-resource-androidattr-lstar-not-found-in-android/ https://www.nuget.org/packages/Xamarin.AndroidX.Core.Core.Ktx/1.7.0.1 https://www.nuget.org/packages/Xamarin.AndroidX.Core.Core.Ktx/1.6.0.3
|
|
🤦♂️ thanks @moljac - first time I've hit an API requiring API 31... I should have thought to try that before bothering you. The beta04 binding seems to work now (I've tested with one sample) - will update the rest but I don't anticipate any other problems. Thank you! |
You did not bother. Too bad I don't have time to use all those packages.
Great news. Glad to hear that!
You are welcome. I hope next time I'll be faster with update[s]. |
|
Final comment - confirmed that the Surface Duo samples were updated and work fine |
Update to latest stable versions of components:
Updated artifacts
androidx.activity:activity - 1.3.1 -> 1.4.0
diff.md.txt
breaking.md.txt
androidx.activity:activity-ktx - 1.3.1 -> 1.4.0
androidx.core:core - 1.6.0 -> 1.7.0
diff.md.txt
breaking.md.txt
androidx.core:core-ktx - 1.6.0 -> 1.7.0
androidx.lifecycle:lifecycle-common - 2.3.1 -> 2.4.0
androidx.lifecycle:lifecycle-common-java8 - 2.3.1 -> 2.4.0
androidx.lifecycle:lifecycle-livedata - 2.3.1 -> 2.4.0
androidx.lifecycle:lifecycle-livedata-core - 2.3.1 -> 2.4.0
androidx.lifecycle:lifecycle-livedata-core-ktx - 2.3.1 -> 2.4.0
androidx.lifecycle:lifecycle-livedata-ktx - 2.3.1 -> 2.4.0
androidx.lifecycle:lifecycle-process - 2.3.1 -> 2.4.0
diff.md.txt
breaking.md.txt
androidx.lifecycle:lifecycle-reactivestreams - 2.3.1 -> 2.4.0
androidx.lifecycle:lifecycle-reactivestreams-ktx - 2.3.1 -> 2.4.0
androidx.lifecycle:lifecycle-runtime - 2.3.1 -> 2.4.0
androidx.lifecycle:lifecycle-runtime-ktx - 2.3.1 -> 2.4.0
androidx.lifecycle:lifecycle-service - 2.3.1 -> 2.4.0
androidx.lifecycle:lifecycle-viewmodel - 2.3.1 -> 2.4.0
diff.md.txt
breaking.md.txt
androidx.lifecycle:lifecycle-viewmodel-ktx - 2.3.1 -> 2.4.0
diff.md.txt
breaking.md.txt
androidx.lifecycle:lifecycle-viewmodel-savedstate - 2.3.1 -> 2.4.0
androidx.wear:wear-input - 1.0.0 -> 1.1.0
androidx.wear:wear-ongoing - 1.1.0 -> 1.0.0
androidx.window:window - 1.0.0-beta02 -> 1.0.0-beta04
diff.md.txt
breaking.md.txt
androidx.window:window-java - 1.0.0-beta02 -> 1.0.0-beta04
diff.md.txt
breaking.md.txt
com.google.code.gson:gson - 2.8.8 -> 2.8.9
org.jetbrains.kotlinx:kotlinx-coroutines-guava - -> 1.5.2
com.google.firebase:firebase-appindexing - -> 20.0.0
Changed, but not updated
androidx.constraintlayout.constraintlayout
Xamarin.AndroidX.ConstraintLayout
diff.md.txt
androidx.coordinatorlayout.coordinatorlayout
Xamarin.AndroidX.CoordinatorLayout
diff.md.txt
androidx.security.security-crypto
Xamarin.AndroidX.Security.SecurityCrypto
diff.md.txt
breaking.md.txt
androidx.swiperefreshlayout.swiperefreshlayout
Xamarin.AndroidX.SwipeRefreshLayout
diff.md.txt
androidx.wear.wear
Xamarin.AndroidX.Wear
diff.md.txt
com.google.crypto.tink.tink-android
Xamarin.Google.Crypto.Tink.Android
diff.md.txt
breaking.md.txt
Checklist