I'm using the Nuget package System.Net.Sockets
in a project and I'm trying compile it, but when I do I receive a System.IO.FileNotFoundException
.
It's referenced in a Web Console Project using frameworks dnx451 and dnxcore50 (but it's only referenced in the core50 project.json, 451 doesn't need it). I can use it in the project with no errors, but once it won't actually run anything because it gets an error as soon as it starts. I checked my .dnx file, and the package (and all of its dependencies) are installed. I've tried clearing and reinstalling my packages, but nothing works.
Another weird error I'm having is when I'm using any of the actual classes from System.Net.Sockets, I get an error about the class being defined in System as well as System.Net.Sockets, and it shows that there's one version of the class available for Framework 4.5.1, and one available for Core 5.
Overall, I think the problem has to do with the Package being available for Framework 4.5.1 under the System namespace and under the System.Net.Sockets namespace for Core 5.0... I'm not sure why that would result in a System.IO.FileNotFound exception, so if anybody has ideas post them below.
My Project.json:
"frameworks": {
"dnx451": { },
"dnxcore50": {
"dependencies": {
"System.Collections": "4.0.10-beta-23019",
"System.Console": "4.0.0-beta-23019",
"System.Linq": "4.0.0-beta-23019",
"System.Threading": "4.0.10-beta-23019",
"Microsoft.CSharp": "4.0.0-beta-23019",
"System.Net.Sockets": "4.1.0-beta-23225"
}
}
}
My Program.cs:
public class Program
{
public void Main(string[] args)
{
BasicClient client1 = new BasicClient("127.0.0.1", 6379);
client1.SetString("foo", "bar");
Console.WriteLine(client1.GetString("foo"));
Console.ReadLine();
}
}
If you need anything else, feel free to poke around the repo.