-
Notifications
You must be signed in to change notification settings - Fork 713
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
.NET Remoting support broken #276
Comments
|
Forgot to copy original text from PythonDotNet mailing list discussion: Does pythonnet-2.1.0 support .NET Remoting? When I try to get an interface, python 2.7 crashes: Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object. It's getting past these lines in my script: and choking on a static method in my app's remoting DLL call which returns the interface. Through logging, I can tell that the code in that static method call is successfully executing: This worked fine before when my app targeted .NET 3.5 and I used the CLR2 version of the Python for .NET package. Now my app targets .NET 4.5.2 so I:
In C:\Python27\Lib\site-packages\ I see: |
|
Denis's reply on PythonDotNet mailing list discussion: Can you provide minimal reproducible code sample for both C# and Python? Are you testing this from interactive python or ipython? There are some Please also open an issue on github. BTW, why have you not switched to WCF? |
|
My reply on PythonDotNet mailing list discussion: I only ever used pythonnet-2.0-alpha2-clr2.0_131_py27_UCS2 with Python 2.7.2, where it worked when controlling my .Net 3.5-based-based GUI app. I only updated my app to .NET 4.5.2 last week, which is the first time I tried CLR4-compatible PythonDotNet with Python 2.7.12. Command shell: C:\Python27> python my.py Yeah, I know, Remoting is deprecated : ( Need to learn about WCF and see what kind of pain it will cause my long-established user base. |
|
@jcarole I tried your example C# apps and it seems this has nothing to do with pythonnet, but rather only .NET 4.6 vs 3.5 differences. In fact 3.5 is the last version supported for .NET remoting. |
|
@denfromufa Sorry, config mgmt fail on my part. Updated the dropbox link with working C# code for the .NET 4.5.2 C# server and client. .NET Remoting may be deprecated, but it is definitely still working. |
|
Hi, I was getting the same exact error as "jcarole commented on Oct 25 " using PythonNet 2.1.0 and then using 2.2.0 from Python 2.7.12 64-bit version and then I tried the python2.0.0 binaries from https://pypi.python.org/pypi/pythonnet/2.0.0 It all worked nicely after that. So, something is broken from 2.0.0 to 2.1.0 and onwards. Hope this help debug the problem |
|
Well, in the example above, the code with Neat. The typedproxy code was needed when I was using IronPython to communicate with NX. |
|
@jcarole I tried extracting your zip file and got an error about bad format. |
|
@cadourian have you resolved your issue? |
|
I'm getting the same error here when using a library which uses .NET remoting internally. As with submitter this worked on v2.0.0 and is broken in v2.1.0 onward. I identified the issue and a workaround (2bbe5b1) that works for me. I don't know anything about .NET Remoting and can't be sure of any side effect (or other places in the code needing this) regression introduced in 7e0226f |
|
@callumnoble thanks for digging this! Your workaround looks reasonable, does this also work for @cadourian and @jcarole? |
|
Can I get compiled bits to try? (What version would the fix be available in?)
…--------- Original Message --------- Subject: Re: [pythonnet/pythonnet] .NET Remoting support broken (#276)
From: "Denis Akhiyarov" <notifications@github.com>
Date: 12/19/17 9:33 pm
To: "pythonnet/pythonnet" <pythonnet@noreply.github.com>
Cc: "jcarole" <github@jnpcarole.com>, "Mention" <mention@noreply.github.com>
@callumnoble thanks for digging this! Your workaround looks reasonable, does this also work for @cadourian and @jcarole?
-
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.
|
|
@denfromufa @callumnoble How/where do I get compiled bits to see if this fix works for me? |
|
@jcarole i created a pull request with @callumnoble commit, feel free to grab the wheels/binaries from the build artifacts on this PR from Appveoyr CI: |
|
@denfromufa Thanks Denis. I'm not sure exactly what you said means (I'm a github newbie), but I'll check the link you included during the day and hopefully find download links there or on the pages linked to by the details links. |
|
@jcarole here is direct link to one of builds, pick the one that corresponds to your Python version/architecture: https://ci.appveyor.com/project/pythonnet/pythonnet/build/master-1147/job/a462ce019ao2nxle/artifacts |
|
@denfromufa Thanks for making this easy for me, Denis...it works! I haven't done exhaustive testing, but if I were to run into a problem with a specific feature, that would belong in its own issue. Is there a target date for releasing 2.4? |
|
@denfromufa Thanks Denis. From the comments on the 514 page, looks like robbmcleod submitted a fix. Is that a partial or complete fix? Just trying to gauge how close we may be to the release. |
|
@jcarole please provide your opinion on how to resolve that issue, but please read all comments and linked issues. What happened is that one fixed bug caused another regression for this particular CLR List <---> numpy.array conversion behavior. I'm not sure how to fix both of them at the same time without double-conversion like described in #451 |
|
@callumnoble @jcarole this PR for .NET Remoting cannot be merged, because more general solution that would work on .NET Core is necessary. .NET Remoting is deprecated and its API is not available in .NET Core and .NET Standard. Here is a pull request with merged master: |
Fixed errors breaking .NET Remoting on method invoke (#276)
|
Resolved in #637 |


Opening this issue per request from Denis Akhiyarov in PythonDotNet mailing list discussion.
Tried uploading a .zip file but got error "We don't support that file type." So here is a link to that file:
https://www.dropbox.com/s/66pkgd1m2l3kbmh/DotNetRemotingHelloWorld.zip?dl=0
The text was updated successfully, but these errors were encountered: