Skip to content

ImportException: No module named _______ #2

@brollsroyce

Description

@brollsroyce

Hello,

Your method works very well to use Python in Unity. But since my python script requires several module imports, I get an ImportException when I hit Play on Unity. For example:
ImportException: No module named serial
Microsoft.Scripting.Runtime.LightExceptions.ThrowException (Microsoft.Scripting.Runtime.LightExceptions+LightException lightEx) (at :0)
Microsoft.Scripting.Runtime.LightExceptions.CheckAndThrow (System.Object value) (at :0)
Microsoft.Scripting.Interpreter.FuncCallInstruction2[T0,TRet].Run (Microsoft.Scripting.Interpreter.InterpretedFrame frame) (at <bdde1939ff4d4d6b828ba549cdd24694>:0) Microsoft.Scripting.Interpreter.Interpreter.Run (Microsoft.Scripting.Interpreter.InterpretedFrame frame) (at <bdde1939ff4d4d6b828ba549cdd24694>:0) Microsoft.Scripting.Interpreter.LightLambda.Run2[T0,T1,TRet] (T0 arg0, T1 arg1) (at <bdde1939ff4d4d6b828ba549cdd24694>:0) IronPython.Compiler.PythonCallTargets.OriginalCallTarget1 (IronPython.Runtime.PythonFunction function, System.Object arg0) (at <0569a20e5dd94f74a766cc11c6214b7c>:0) IronPython.Runtime.FunctionCaller1[T0].Call1 (System.Runtime.CompilerServices.CallSite site, IronPython.Runtime.CodeContext context, System.Object func, T0 arg0) (at <0569a20e5dd94f74a766cc11c6214b

Any ideas?

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions