UiPath throws Bad IL Request when its compiling the activities

Hi,
I recently converted one of my projects from Windows-Legacy to Windows, using the popup that would come up while we open a project which has been developed over the Windows-Legacy mode.
When I debug for activities, I gave a test run to one of sequences, and every time the compilation leads to the same error in the logs

Bad IL format. The format of the file 'C:\Users\<username>\.nuget\packages\uipath.database.activities\1.7.1\lib/net5.0-windows7.0/runtimes/win-x64/native/sni.dll' is invalid.

The same project with same set of packages seems to be working just fine over Windows-Legacy.
Is this some migration issue from converting the project from Windows-Legacy to Windows mode?

Kindly suggest what can be done to tackle this issue.

1 Like

Hello @Peeyush_Yadav

After migrating to windows from windows-legacy have you tried updating all the packages to the stable version? If not give it a try. Manager package->Update all packages.

Thanks

Hi @Rahul_Unnikrishnan, yes I have all the stable releases of the packages, even then the error persists.

@Peeyush_Yadav

Is there any custom library in use in the project?

Thanks

Currently to make connection to MySQL DB, I’m only using UiPath.Database.Activities package in my project.
Thanks.

If there are no updates available for the Database package, then can you try downgrade to the below version and check again. The error seems to be a compatibility issue.

Thanks

Hi @Rahul_Unnikrishnan Yes I tried that as well. But it doesn’t seem to work.
Thanks

Have you found a solution to your issue yet? I am having the exact same issue as you did. Would love to find an answer to this problem. Thank you.

Same here. I’ve read some posts on this forum that all have this problem but have not seen a solution yet.

I have same issue after upgraded with v2022.10.5 (from v2021.10.5) and converted to Windows compatibility.

@uipath
Please support ASAP.

Could you share the solution for this issue?
Is it resolved ? @uipath

Can you please share the solutions for this issue

I am also facing the same problem

Any solution for this?
I am also facing similar issue.

Tossing my hat in here. Seems I’m also getting a very similar issue.

Bad IL format. The format of the file Bad IL format. The format of the file 'C:\Users\duad\.nuget\packages\uipath.database.activities\1.7.1\lib/net5.0-windows7.0/runtimes/win-x64/native/Microsoft.Data.SqlClient.SNI.dll' is invalid. C:\Users\duad\.nuget\packages\uipath.database.activities\1.7.1\lib/net5.0-windows7.0/runtimes/win-x64/native/Microsoft.Data.SqlClient.SNI.dll
Unexpected error has occurred during the library compilation process:
The assembly compilation returned the following errors:
 * (339,90): error CS0103: The name 'False' does not exist in the current context
 * (345,24): error CS0103: The name 'False' does not exist in the current context

I have tried both 1.7.0 and 1.7.1 and I’ve tried deleting the UiPath.database.activities files from my .nuget folder. This is for a Windows Modern UI process with Studio version 23.10.1. 23.10.0 had the same issue.

This is clearly a bug related to UiPath.Database.Activities as there are several forum posts related to the Bad IL Request error when compiling and this specific package almost ALWAYS comes up.

Bad IL format. The format of the file 'C:\Users\<username>\.nuget\packages\uipath.database.activities\1.7.1\lib/net5.0-windows7.0/runtimes/win-x64/native/Microsoft.Data.SqlClient.SNI.dll' is invalid. 

Has anyone put in a support request to UiPath about this?