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
Is defined multiple times #1
Comments
|
Same problem. Hope soon will be fixed. |
|
It will be helpful if you can provide the version number of:
|
|
Last version of unity 2017.1f3, released 11 July 2017 |
|
Unity 5.5.1f1 |
|
As I know, you can use .NET v4.5 on Windows/XBOX platform, but to build runtime for cross platform like iOS or Android, you need select Mono and .NET 2.0. See: |
|
This error present in editor and break all work. |
|
Weird, I still did not figure out what happens in your situation. It works quite well when I test the demo project with Unity 5.4.4 in my office and Unity 5.6.1 at home. Or, you may try building the library from source code here (using branch net20): |
|
Also having this issue, with completely unrelated libraries.
Sounds like maybe something in one of these DLLs is writing something to |
|
Yes if you just use this package its not have a problem, errors came from when you add other packages to your project |
|
Sample code for receive this issues |
|
I am seeing the same System.Action collision issue with a BLE plugin. |
|
Same problem here, System.Func' is defined multiple times all around |
|
Encountering this problem with Vuforia. What can we do in such a case? |
|
Here is the source code, If anyone wanna contribute, try forking the code and help to fix it. |
|
Looks like two different packages try to define the same type in the same namespace by either
My eyes are on System.Threading.Tasks.Unofficial. It seems to be defining some types for compatibility. If, for example, some other plugin would be using the TaskParallelLibrary - then I could see why these two plugins would probably not work together. Unfortunately I won't have any time for this until next week. A sample project on Git to reproduce the issue would help a lot. |
|
I'm getting an error in Unity that is probably related to this.
It looks like that's being triggered when I try to connect to the server after initially declaring I'm also running on latest Unity 2017.1.1f1 |
|
Just getting on the "I'm having problems too" train. Here's my output:
As stated above, only seems to break in the presence of other packages. In my specific case it's https://github.com/neuecc/UniRx |
|
Just researching this for now... but: @marius-bughiu - Did you ever get a chance to work on this a bit more? |
|
I am using UnityAction until the problem will be solved. @floatinghotpot, can you fix this = #10 ? |
|
Same problem here guys |
|
Hi , |
|
@siordache94 Hi, good luck in GGJ. |
|
it's very deep , if you try to import this and https://www.assetstore.unity3d.com/en/#!/content/32647 this asset, there's conflict on action , i tried putting either unityaction in steamvr , tried wrappin system in sys (in case of conflicting namespace) |
|
@siordache94 I change Util.cs and now working, i think. |
|
I'm having the same issue. Unity 2017.3 and .NET 3.5. Replacing System.Action with UnityAction works sometimes, but not always, so it isn't really a valid fix for me. Does anybody have any thoughts as to what might be causing this? I'm new to Unity and C#, so unfortunately I'm pretty clueless |
|
@GkhanKINAY If you think you've got a viable fix, could you submit a PR and reference this ticket? |
|
@patricknelson OK, i fixed the problem on the source code. (https://github.com/floatinghotpot/SocketIoClientDotNet/pull/1) |
|
Thanks to @GkhanKINAY , the file has been merged. |
|
I'm attempting to use this library alongside Google Poly Toolkit. I'm still running into the System.Action is defined multiple times, even with the new dlls from @GkhanKINAY. Did the issue actually get fixed, or is this potentially an issue with the Poly Toolkit? |
|
@James-Quigley hmm, i will test in 1-2 hour. |
|
@James-Quigley Hi again, sorry for delay. I tested and your problem is WebSocket4Net.dll, not SocketIoClientDotNet.dll. (And you need delete Newtonsoft.Json.dll because "Poly Toolkit" project is have one.) Problem: https://github.com/kerryjiang/WebSocket4Net/blob/master/WebSocket4Net/Action.cs |
|
@GkhanKINAY Thanks so much for your help. So the fix is to go into the source for WebSocket4Net and change the Action definition and all its references to something else e.g. CustomAction? |
|
@James-Quigley Yes, you are right. (I changed "ActionTrigger" instead of "Action" and build:SocketIoClientDotNet.dll) |
|
I have a similar issue where "System.Func" is defined multiple times Replacing it with other things just causes more errors like ".Contains is not defined, are you missing a using reference" which then suggest System.Linq or Quobject.Collections.Immutable in some classes like "Unity3DRider.cs" |
|
Hi, |
|
Hi , It seams WebSocket4Net got a mscorelib different of .NET 2.0 included in recent versions of Unity.. And Zenject is using it and don't know what reference he must use. ( same package , but 2 different sources ) :/ |
|
Hi I have the issue where the System.Func<T, TResult> is defined multiple times with the websocket4net dll in combination with the mapbox api. I am using unity2017.2 |
|
Hi, Seems the fix only changed "Action fn" to "ActionTrigger fn". (source code in AckImpl.cs or elsewhere) Believe, others such as Action fn1; also need to be changed as well. As I encountered the issue (defined multiple times) for those calls (ie. System.Action, System.Action<T1,T2>, System.Action<T1,T2,T3> ... is defined multiple times) Cheers |
|
Hi, I still have this problem when I uses Fingers - Touch Gestures from AssetStore. I face it with System,Action<T1,T2,T3>() and System.Func() Any hints or workarounds? |
|
same error but with websocket4net.dll the error with SocketIoClientDotNet works. |
|
короче, просто нужно взять другой провайдер сокета для юнити и всё |
|
same error with websocket4net.dll : Assets/GMES/UTIL/ExpressionParser.cs(303,43): error CS0433: The imported type |
|
Wich new provider recommend? |
|
I wanted to use this with IBM Watson SDK (speech-to-text) and got "Is defined multiple times" problem. Also another time I was tryng to use it alongside the Embedded browser asset (https://assetstore.unity.com/packages/tools/gui/embedded-browser-55459) and that gave me loads of "Is defined multiple times" problems. |
|
I'm having the same problem trying to use Socket.IO and Hololens in Unity. |
|
@det3d I ended up using the BestHTTP Unity library to do Socket.IO stuff on the HoloLens. It worked great! It is paid, but honestly saved me so much headache that it is probably worth it. |
|
Thanks for the tip! Best HTTP worked out great for Socket.IO and Hololens!
…On Tue, May 22, 2018 at 7:20 PM, James Quigley ***@***.***> wrote:
@det3d <https://github.com/det3d> I ended up using the BestHTTP Unity
library to do Socket.IO stuff on the HoloLens. It worked great! It is paid,
but honestly saved me so much headache that it is probably worth it.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AFzgxLWO0hRxzwdyI3mjYkuGcB82WYpUks5t1J0sgaJpZM4OVeEG>
.
|
|
It still doesn't work because it is a indus code! |
|
same error with websocket4net.dll : |
|
Hm, running into this too, conflicting with mscorlib: error CS0433: The type 'Action<T1, T2, T3>' exists in both 'WebSocket4Net, Version=0.14.1.0, Culture=neutral, PublicKeyToken=eb4e154b696bf72a' and 'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' |
|
No solutions for this??? |
|
For me, the issue I had was I was somewhere in my code or a framework I was using, I had my own enum or class that was also called Action, and in the same namespace. I think moving it into a different namespace helped me. |
|
This link is to .NET 2.0 versions of the libraries for WebSocket4Net that will both work in Unity and won't cause problems with non-2.0 features such as Func, Action and Linq. https://drive.google.com/drive/folders/1p0MRrFCdbWM4oCNTv_wGvcRQ_PlZpnlP?usp=sharing |
|
Is there a solution, can't still find one ? Should we do something to remove the Func in the package manager, instead of the dll ? |
|
The new versions of Unity (2018.4+) allow you to use .NET Standard 2 and .NET 4.x as your scripting backend. This means that you can use the much later versions of your libraries, so that this problem doesn't occur. Alternatively, you need to do what I did for WebSocket4Net, and go into the code. If you search for the definition of 'func' and rename it to something else, you'll remove the problem. It's caused by the fact that quite a few libraries use LINQ-style code techniques, and then define those types (like Action and Func) themselves so that they compile in .NET 2. If you remove those definitions, it should work. |
|
@OptrixAU Sorry, so if I understand you, the WebSocket4Net you uploaded above (23 aug) is already corrected to remove the "func" ? Are the two others dlls in the drive required ? Since I never edited a dll, i tryied yours and have others errors instead, like: May you help me, thx |


I have errors in some of my packages.
Is this error under test and resolving? if yes, please let me know how long it takes to be resolved and help me solve the problem temporarily.
The packages that had conflict in my project were NGUI and UnityMainThreadDispatcher.
and
The text was updated successfully, but these errors were encountered: