Skip to content

py"print 'hello world'" fails in Julia 0.6 #434

Closed
@rahulkp220

Description

@rahulkp220

I am trying to run this code, but it fails throwing these errors.

julia> py"print 'hello world'"
ERROR: PyError (ccall(@pysym(:Py_CompileString), PyPtr, (Cstring, Cstring, Cint), sb, fname, input_type)) <type 'exceptions.SyntaxError'>
SyntaxError('invalid syntax', ('/Users/rlakhanpal/.julia/v0.6/PyCall/src/pyeval.jl', 1, 5, "print 'hello world'"))

Stacktrace:
 [1] pyerr_check at /Users/rlakhanpal/.julia/v0.6/PyCall/src/exception.jl:56 [inlined]
 [2] pyerr_check at /Users/rlakhanpal/.julia/v0.6/PyCall/src/exception.jl:61 [inlined]
 [3] macro expansion at /Users/rlakhanpal/.julia/v0.6/PyCall/src/exception.jl:81 [inlined]
 [4] pyeval_(::String, ::PyCall.PyDict{String,PyCall.PyObject,false}, ::PyCall.PyDict{String,PyCall.PyObject,false}, ::Int64, ::String) at /Users/rlakhanpal/.julia/v0.6/PyCall/src/pyeval.jl:20

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions