thrift-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mario Emmenlauer (Jira)" <j...@apache.org>
Subject [jira] [Updated] (THRIFT-5143) Can not use .NET std Thrift.dll in .NET Framework due to missing dependency
Date Thu, 19 Mar 2020 10:55:00 GMT

     [ https://issues.apache.org/jira/browse/THRIFT-5143?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Mario Emmenlauer updated THRIFT-5143:
-------------------------------------
    Description: 
I could build Thrift .NET Std quite easily with dotnet on MSVC and Linux. However when trying
to use it in a .NET Framework project, I can not get past the following error:

{{src\gen-netstd\MyThriftAPI.cs(54,23): error CS0012: The type 'ValueTask<>' is defined
in an assembly that is not referenced. You must add a reference to assembly 'System.Threading.Tasks.Extensions,
Version=4.2.0.1, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'. [C:\data\Debug\WPFGui\WPFGui_w0ude4yv_wpftmp.csproj]}}

I've spent by now almost a full day to try different variations of workarounds. What I could
find on the web was:
 * Switch to a newer .NET Framework. But 4.7.2 did not help.
 * Remove the reference to "System.Threading.Tasks.Extensions" from Thrift. This causes an
alternative transitive reference to "System.Threading.Tasks.Extensions, Version=4.2.0.0" (last
digit zero instead of one) instead, but does not help
 * Build Thrift with netstandard2.1 instead of netstandard2.0. This causes further undefined
references of netstandard2.0.
 * Install "System.Threading.Tasks.Extensions" 4.5.3 from NuGet. This did not make any difference

 I'm at the end of my wit here. Did other people experience this problem, and/or who can
use Thrift for .NET Std in a WPF application? Any tips or tricks? Help would be greatly appreciated!

  was:
I could build Thrift .NET Std quite easily with dotnet on MSVC and Linux. However when trying
to use it in a .NET Framework project, I can not get past the following error:

{{src\gen-netstd\MyThriftAPI.cs(54,23): error CS0012: The type 'ValueTask<>' is defined
in an assembly that is not referenced. You must add a reference to assembly 'System.Threading.Tasks.Extensions,
Version=4.2.0.1, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'. [C:\data\Debug\WPFGui\WPFGui_w0ude4yv_wpftmp.csproj]}}

I've spent by now almost a full day to try different variations of workarounds. What I could
find on the web was:

  * Switch to a newer .NET Framework. But 4.7.2 did not help.

  * Remove the reference to "System.Threading.Tasks.Extensions" from Thrift. This causes
an alternative transitive reference to "System.Threading.Tasks.Extensions, Version=4.2.0.0"
(last digit zero instead of one) instead, but does not help

  * Build Thrift with netstandard2.1 instead of netstandard2.0. This causes further undefined
references of netstandard2.0.

  * Install "System.Threading.Tasks.Extensions" 4.5.3 from NuGet. This did not make any
difference

 

I'm at the end of my wit here. Did other people experience this problem, and/or who can use
Thrift for .NET Std in a WPF application? Any tips or tricks?


> Can not use .NET std Thrift.dll in .NET Framework due to missing dependency
> ---------------------------------------------------------------------------
>
>                 Key: THRIFT-5143
>                 URL: https://issues.apache.org/jira/browse/THRIFT-5143
>             Project: Thrift
>          Issue Type: Improvement
>          Components: netstd - Library
>    Affects Versions: 0.13.0
>            Reporter: Mario Emmenlauer
>            Priority: Minor
>
> I could build Thrift .NET Std quite easily with dotnet on MSVC and Linux. However when
trying to use it in a .NET Framework project, I can not get past the following error:
> {{src\gen-netstd\MyThriftAPI.cs(54,23): error CS0012: The type 'ValueTask<>' is
defined in an assembly that is not referenced. You must add a reference to assembly 'System.Threading.Tasks.Extensions,
Version=4.2.0.1, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'. [C:\data\Debug\WPFGui\WPFGui_w0ude4yv_wpftmp.csproj]}}
> I've spent by now almost a full day to try different variations of workarounds. What
I could find on the web was:
>  * Switch to a newer .NET Framework. But 4.7.2 did not help.
>  * Remove the reference to "System.Threading.Tasks.Extensions" from Thrift. This causes
an alternative transitive reference to "System.Threading.Tasks.Extensions, Version=4.2.0.0"
(last digit zero instead of one) instead, but does not help
>  * Build Thrift with netstandard2.1 instead of netstandard2.0. This causes further undefined
references of netstandard2.0.
>  * Install "System.Threading.Tasks.Extensions" 4.5.3 from NuGet. This did not make any
difference
>  I'm at the end of my wit here. Did other people experience this problem, and/or who
can use Thrift for .NET Std in a WPF application? Any tips or tricks? Help would be greatly
appreciated!



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Mime
View raw message