Open tipa opened 2 months ago
I can confirm this, our code is missing availability attributes in quite a few places.
The reason we don't get the usual warnings in our build is because we have a rather old build system in place, and we don't run the corresponding analyzers.
So the fix here is to:
Here's code to build with the analyzers: https://github.com/rolfbjarne/xamarin-macios/commit/cec7a10a0709427d1c2e37798f02dffaa986f03e
That ends up reporting ~1200 warnings across all platforms (many duplicates though).
@rolfbjarne I have found another case where a method is not correctly annotated.
AvAudioSession.RequestRecordPermission
seems to be deprecated since iOS 17.
Will this deprecation be detected with the changes you made to the analyzer? Let me know if I should open a new issue.
@rolfbjarne I have found another case where a method is not correctly annotated.
AvAudioSession.RequestRecordPermission
seems to be deprecated since iOS 17.Will this deprecation be detected with the changes you made to the analyzer? Let me know if I should open a new issue.
Our tests already detects that one, so no need to file an issue: https://github.com/xamarin/xamarin-macios/blob/c8300a15021bad46e0a48fd6fa9d169cb2c6dc31/tests/xtro-sharpie/api-annotations-dotnet/iOS-AVFoundation.todo#L294
Framework version
net8.0-ios
Description
The
SecKeychain
class has what I believe are convenience methods likeAddGenericPassword
: https://github.com/xamarin/xamarin-macios/blob/a6b5d22d7420c0fb655026968832fe348dc72c77/src/Security/Items.cs#L511-L532 They call other methods under the hood, like SecKeychainAddGenericPassword. As those methods are deprecated, the "wrapper" method should perhaps also be marked with the obsolete attribute.