Home
Help
Register
Log in

Search

 
   Active Threads  

You are here: Home > LLBLGen Pro > Designer> Exception type: FileNotFoundException Could not load file or assembly 'System.Runtime.CompilerServices.Unsafe, Version=4.0.4.0,
 

Pages: 1
Designer
Exception type: FileNotFoundException Could not load file or assembly 'System.Runtime.CompilerServices.Unsafe, Version=4.0.4.0,
Page:1/1 

  Print all messages in this thread  
Poster Message
sherifr
User



Location:

Joined on:
26-Apr-2018 21:18:02
Posted:
11 posts
# Posted on: 05-Jul-2018 13:21:43. Goto attachments  
Hi, I encounter this error when I try to sync my Relational Model.

Exception message:
-------------------------------
Exception type: FileNotFoundException
Could not load file or assembly 'System.Runtime.CompilerServices.Unsafe, Version=4.0.4.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.

Attached screenshots of the error and build.

Thanks.
  Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
37858 posts
# Posted on: 05-Jul-2018 15:39:48.  
I think you use an Npgsql version which requires a .NET full version you don't have installed yet, please install .net 4.7.2 and try again

Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
sherifr
User



Location:

Joined on:
26-Apr-2018 21:18:02
Posted:
11 posts
# Posted on: 05-Jul-2018 21:16:28.  
I have it already installed and I also, updated the Npgsql driver to 4.0.1.
Still see the problem.
  Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
37858 posts
# Posted on: 06-Jul-2018 11:12:26.  
Could you please click the 'copy to clipboard' button in the exception dialog so you get a stacktrace (just paste it here in a new post). We don't use that assembly so it's something related to npgsql.

Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
dodyg
User



Location:

Joined on:
04-Dec-2014 15:48:05
Posted:
30 posts
# Posted on: 07-Jul-2018 14:33:45.  
I also encounter the same problem (https://github.com/npgsql/Npgsql/releases) using Npgsql v4.0.1

Code:

Exception information.
=============================================================
LLBLGen Pro version: v5.4. Build: 5.4.1

Exception details:
=====================
Message: Could not load file or assembly 'System.Runtime.CompilerServices.Unsafe, Version=4.0.4.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.
Source: System.Threading.Tasks.Extensions
Stack trace:
at System.Threading.Tasks.ValueTask`1.get_IsCompleted()
at Npgsql.NpgsqlConnection.<>c__DisplayClass32_0.<<Open>g__OpenLong|0>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Npgsql.NpgsqlConnection.Open()
at SD.LLBLGen.Pro.Gui.Controls.WizardPages.MetaDataRetrievalWizard_Step_ConnectionData.TestConnectionData(Boolean showSuccess)

Inner exception: <null>

  Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
37858 posts
# Posted on: 08-Jul-2018 09:38:03.  
Looks like a problem with npgsql, but not sure if it's .net full version related. You too have .net 4.7.2 installed?

Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
sherifr
User



Location:

Joined on:
26-Apr-2018 21:18:02
Posted:
11 posts
# Posted on: 08-Jul-2018 09:59:48.  
Quote:

Exception information.
=============================================================
LLBLGen Pro version: v5.4. Build: 5.4.1

Exception details:
=====================
Message: Could not load file or assembly 'System.Runtime.CompilerServices.Unsafe, Version=4.0.4.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.
Source: System.Threading.Tasks.Extensions
Stack trace:
at System.Threading.Tasks.ValueTask`1.get_IsCompleted()
at Npgsql.NpgsqlConnection.<>c__DisplayClass32_0.<<Open>g__OpenLong|0>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Npgsql.NpgsqlConnection.Open()
at SD.LLBLGen.Pro.Gui.Controls.WizardPages.MetaDataRetrievalWizard_Step_ConnectionData.TestConnectionData(Boolean showSuccess)

Inner exception: <null>


Also, I opened an issue in the Npgsql repository, but I seem to be not able to answer his question. Kinda took it on my behalf Cool
https://github.com/npgsql/npgsql/issues/2049
  Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
37858 posts
# Posted on: 08-Jul-2018 12:52:00.  
thanks for that Regular Smiley

He wants you to post the C# project file (the csproj file) you created for the project which you used to reproduce the issue as that csproj file (the xml) contains the references you have, he suspects you miss a reference. I think it's something else but don't know what exactly. I replied as well, perhaps that gives more insight to roji what it can be.


Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
sherifr
User



Location:

Joined on:
26-Apr-2018 21:18:02
Posted:
11 posts
# Posted on: 08-Jul-2018 12:58:30.  
I know that when I said "I just open a NpgsqlConnection", I was talking about me as LLBLgen designer developer, right Regular Smiley?
  Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
37858 posts
# Posted on: 08-Jul-2018 16:57:05.  
Please see the github thread, it's an issue with the npgsql installer, some assemblies need to be added to the gac to make this work (for the designer at least), i.e. for DbProviderFactories to work

Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
dodyg
User



Location:

Joined on:
04-Dec-2014 15:48:05
Posted:
30 posts
# Posted on: 11-Jul-2018 10:36:32.  
This problem is solved with the latest installer Npgsql v4.0.2

https://github.com/npgsql/npgsql/releases
  Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
37858 posts
# Posted on: 11-Jul-2018 16:13:15.  
Thanks for the heads up!

Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
JSobell
User



Location:

Joined on:
07-Jan-2006 06:44:46
Posted:
89 posts
# Posted on: 08-Oct-2019 15:02:42.  
Looks like the same issue may be back:

Code:

Exception information.
=============================================================
LLBLGen Pro version: v5.6. Build: 5.6.1

Exception details:
=====================
Message: Could not load file or assembly 'System.Runtime.CompilerServices.Unsafe, Version=4.0.4.1, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.
Source: System.Threading.Tasks.Extensions
Stack trace:
at System.Threading.Tasks.ValueTask`1.get_IsCompleted()
at Npgsql.NpgsqlConnection.<>c__DisplayClass32_0.<<Open>g__OpenLong|0>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
at Npgsql.NpgsqlConnection.Open()
at SD.LLBLGen.Pro.Gui.Controls.WizardPages.MetaDataRetrievalWizard_Step_ConnectionData.TestConnectionData(Boolean showSuccess)

Inner exception: <null>

  Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
37858 posts
# Posted on: 08-Oct-2019 15:14:58.  
You're using their latest build? If not, could you open a new issue on the npgsql repo? There's little we can do, I'm afraid.

These are the shipped releases and release notes.
https://github.com/npgsql/npgsql/releases


Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
JSobell
User



Location:

Joined on:
07-Jan-2006 06:44:46
Posted:
89 posts
# Posted on: 09-Oct-2019 13:53:58.  
Otis wrote:
You're using their latest build? If not, could you open a new issue on the npgsql repo? There's little we can do, I'm afraid.

These are the shipped releases and release notes.
https://github.com/npgsql/npgsql/releases


Yes, it's already been commented on https://github.com/npgsql/npgsql/issues/2677
I've gone back to an older version of npgsql until they fix it.
  Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
37858 posts
# Posted on: 09-Oct-2019 14:39:00.  
I think there's a reason why it occurs: The minimum dependency on .NET Framework for Npgsql is 4.6.1. The designer however uses 4.5.2.

If you have 4.6.2 installed, and you change in the llblgenpro.exe.config file the following line:
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />

to
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.2" />

does it then load the 4.1.1 npgsql driver?
(doesn't work)

In the next version of llblgen pro (5.7) we'll move to 4.6.2 or higher, to overcome this problem, as I was reminded this morning that google spanner makes a move to 4.6.2 soon, and now reading this I realize this might be the problem with 5.6.x.

I'll try to reproduce it here too.

(edit) hmm, setting that version to a higher version doesn't work. It's then indeed something related to npgsql.


Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
Benjamin23
User



Location:

Joined on:
15-Nov-2017 15:50:13
Posted:
26 posts
# Posted on: 14-Feb-2020 14:24:59.  
Hi Otis,

Was there any progress on this (if it is possible to resolve it on LLBLGen Designer side at all)?

We'd like to upgrade to latest version of Npgsql, but we're seeing same issue. I see that issue on github is still open. Is there anything you can do, or we need to wait for fix from Npgsql.

Cheers
  Top
daelmo
Support Team



Location:
Guatemala City
Joined on:
28-Nov-2005 23:35:24
Posted:
8108 posts
# Posted on: 15-Feb-2020 06:33:27.  
I read this thread completely and the npgsql's thread as well. It seems you will have to wait for a fix from npgsql.

David Elizondo
LLBLGen'ing (articles and code snippets) | linkedin | twitter
 
Top
Otis
LLBLGen Pro Team



Location:
The Hague, The Netherlands
Joined on:
17-Aug-2003 18:00:36
Posted:
37858 posts
# Posted on: 15-Feb-2020 09:55:05.  
Yeah it's still not fixed and I think they can't fix it too without dropping support for a version of an assembly they reference as it's due to a reference they have that causes this. I do recall there's a workaround listed in the Npgsql github thread, did you try that?
Frans Bouma
LLBLGen Pro / ORM Profiler Lead Developer | Blog | Twitter
 
Top
Pages: 1  


Powered by HnD ©2002-2007 Solutions Design
HnD uses LLBLGen Pro

Version: 2.1.12172008 Final.