| title | NuGet Error NU1012 | |
|---|---|---|
| description | NU1012 error code | |
| author | nkolev92 | |
| ms.author | nikolev | |
| ms.date | 01/02/2022 | |
| ms.topic | reference | |
| f1_keywords |
|
Platform version is not present for one or more target frameworks, even though they have specified a platform: net6.0-android.
You have specified a target framework with a platform in your project file but the platform version is not available.
- If you are specifying
TargetPlatformVersionmanually, please ensure a version is included. - If you are using the .NET SDK, and the TargetFramework(s) property contains
net6.0-android, the .NET SDK is supposed to automatically add a platform version. If you are experiencing this, file an issue at dotnet/sdk.
Some dependency group TFMs are missing a platform version: net6.0-android
When creating a package for a framework with a platform such as android, you need to specify the correct platform version.
Specify the platform version in your nuspec.
Example: <group targetFramework="net6.0-android32.0">
If you are using the pack targets, the platform version will be automatically inferred.
Some included files are included under TFMs which are missing a platform version: lib/net6.0-android/Foo.dll, build/net9.0-windows/Foo.props
Some of the files being packaged according to the NuGet packaging conventions have framework parts that are missing a platform version.
Specify the platform version in your nuspec or in the pack extensibility targets in your project file.
Example: lib/net6.0-android32.0/Foo.dll, build/net9.0-windows10.0.19041/Foo.props