Open EverybodyKurts opened 1 year ago
I should note I have net7.0 installed on my machine. I noticed https://github.com/fslaborg/RProvider/blob/008c08476d04eda984be5564e367f93954062f38/src/RProvider.Server/RProvider.Server.fsproj#L5 doesn't mention net7.0
It's also worth noting that when I run a dotnet 6 bullseye container with aarch64
hardware, rprovider tries to look in a nonexistent directory:
$ dotnet fsi script.fsx
/usr/share/dotnet/sdk/6.0.404/Microsoft.Common.CurrentVersion.targets(2302,5): warning MSB3270: There was a mismatch between the processor architecture of the project being built "" and the processor architecture of the reference "/home/vscode/.nuget/packages/rprovider/2.1.0/lib/net5.0/RProvider.Server.dll", "AMD64". This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project. [/home/vscode/.packagemanagement/nuget/Projects/845--3c980b4e-05c9-47d3-b65d-a630fd882448/Project.fsproj]
chmod: cannot access "'/home/vscode/.nuget/packages/rprovider/2.1.0/lib/net5.0/server/linux-x64/RProvider.Server'": No such file or directory
qemu-x86_64: Could not open '/lib64/ld-linux-x86-64.so.2': No such file or directory
/home/vscode/.packagemanagement/nuget/Cache/fb9242c43856bc61aaeecc6eaf2047d16c0039d25de22f3eb2769b4aed1eb227.fsx(19,1): error FS3053: The type provider 'RProvider.RProvider' reported an error: The type provider constructor has thrown an exception: Failed to start the R.NET server within 20 seconds.To enable logging set RPROVIDER_LOG to an existing file name.
Looks like a possible resolution folder issue, such as needing to provide a resolution folder to CsvProvider
so that it doesn't look for the file in the .nuget path. This arose with the introduction of #r nuget...
and it looks like solving this would require adding a ResolutionFolder
static type to the RData
type provider.
See documentation of CsvProvider using ResolutionFolder.
Static parameters in RProvider: https://github.com/fslaborg/RProvider/blob/008c08476d04eda984be5564e367f93954062f38/src/RProvider.DesignTime/RData.fs#L98-L101
Similar in CsvProvider defining the resolution folder can be seen here
Describe the bug
Running an fsx script from Reading and writing RData files with fsi throws a
System.Reflection.TargetInvocationException
exception.To Reproduce
Create a script that loads
sample.rdata
as shown in the Reading and writing RData files example:Run it in VSCode (with Ionide installed) via the Command Pallette via send file OR run it on the command line with the following command:
Expected behavior
The script to run successfully without throwing an error.
Screenshots
Environment (please complete the following information):
Additional context Add any other context about the problem here.