Skip to content
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

Readd basetargets in Microsoft.ML.OnnxRuntime.csproj #18789

Merged
merged 4 commits into from
Dec 14, 2023
Merged

Conversation

mszhanyi
Copy link
Contributor

@mszhanyi mszhanyi commented Dec 12, 2023

Description

Motivation and Context

Now, the nightly Microsoft.ML.Onnxruntime.Managed Nuget Packag couldn't be added in dotnet console program in VS2022 with target framework .NET 6.0.
I just restore it to previous setting to make it work.

snnn
snnn previously approved these changes Dec 12, 2023
@yuslepukhin
Copy link
Member

I do not know what the motivation was for removal of net6.0. Generally, portable libraries are required to implement netstandard2.1.
Such a library should run pretty much anywhere regardless of .net version. What is the specific issue?

@mszhanyi
Copy link
Contributor Author

mszhanyi commented Dec 12, 2023

I do not know what the motivation was for removal of net6.0. Generally, portable libraries are required to implement netstandard2.1. Such a library should run pretty much anywhere regardless of .net version. What is the specific issue?

Nightly Microsoft.ML.Onnxruntime.Managed Nuget Package couldn't be loaded

@snnn snnn dismissed their stale review December 13, 2023 00:49

Build log says "The target framework 'netcoreapp3.1' is out of support ". So do we really need to add it back?

@mszhanyi mszhanyi requested a review from snnn December 13, 2023 10:43
@yuslepukhin
Copy link
Member

yuslepukhin commented Dec 13, 2023

They are all old now, but there is not a replacement for NETSTANDARD and NetCore if you want to have a portable library and/or executable that runs on a variety of platforms including Linux, and we need to support it.

Here is the rule. If you want a portable library, one needs NETSTANDARD2.0 compliance. If you want a portable executable, you need NetCore3.1 compliance. This means that our tests need to be compliant.

The reason why our library has NetCore3.1 target may be because some source files are shared between the lib and the tests.
So adding NetCore3.1 automatically alerts the developer who is using IDE if the code he writes is non-compliant.
Thus, I would not remove NetCore3.1.

See this for more info.

This reverts commit 6a3b014.
@mszhanyi mszhanyi merged commit 7dade5d into main Dec 14, 2023
92 checks passed
@mszhanyi mszhanyi deleted the zhanyi/nettarget branch December 14, 2023 06:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants