Skip to content
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

Interface with string parameters fail #91

Open
large opened this issue Feb 23, 2020 · 5 comments
Open

Interface with string parameters fail #91

large opened this issue Feb 23, 2020 · 5 comments
Labels
question Further information is requested

Comments

@large
Copy link

large commented Feb 23, 2020

Describe the bug
Functions like this fails:
bool Reload(string item);
Functions without string works as it should:
bool ReloadAll();
bool ReloadIteml(int num);
bool TryAll(bool areyousure);

It worked in earlier releases, but failing now.

Expected behavior
Strings should work, the IpcServiceClient.InvokeAsync returns false always not triggering the function in the other side.

@dmiu
Copy link

dmiu commented Feb 24, 2020

Hi @large ,

Is the bool Reload(string item) operation defined in a service contract currently shared between server and your client?

In the latest release (v2.3.1), both TCP and NamedPipe server types should be able to work with this kind of service contract signature.

@large
Copy link
Author

large commented Feb 25, 2020

@dmiu yes it is share between server and client.
But I thinks the serialize process fails because the server is .net 472 and client is .core 3.1.
Seems like .net process strings with mscorlib and .core are using System.Private.CoreLib

But it works on everything else than the strings.

@jacqueskang
Copy link
Owner

@large Sorry but I'm not able to reproduce your issue and string should work for every existing version (covered by tests)

@jacqueskang jacqueskang added the question Further information is requested label May 3, 2020
@mheskol
Copy link

mheskol commented May 18, 2020

I'm facing the same issue. Communication between a .NET Core and .NET Framework process is throwing the following exception:
Newtonsoft.Json.JsonSerializationException: Error converting value "System.String, System.Private.CoreLib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" to type 'System.Type'. Path 'ParameterTypes[0]'
This is happening on latest version 2.3.1 but doesn't seem to happen so far on version 2.2.2
I had to downgrade to get the software working again. Any ideas why the behaviour has changed between versions?

@large
Copy link
Author

large commented May 18, 2020

@mheskol I did not have any success on this, so I created my own IPC to handle it. Maybe this can be implemented into this?

https://github.com/large/SimpleCrossFrameworkIPC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

4 participants