Skip to content

Package with pip dep fails with Jupyter notebook on Windows #226

@madhavkrishnan

Description

@madhavkrishnan

I am writing a package with a pip depencency which works correctly in the REPL but fails in a Jupyter notebook on Windows. However, it works correctly on Ubuntu using WSL.

OS : Win 10
Julia 1.8.1
PythonCall 0.9.6

The error message I get from CondaPkg is

CondaPkg Installing Pip packages
failed to create process.

I've made MWE here https://github.com/madhavkrishnan/TestPkg.jl. Adding relavant files here for ease.

src/TestPkg.jl

module TestPkg

using PythonCall

const scipy = PythonCall.pynew() # initially NULL

function __init__()
	PythonCall.pycopy!(scipy, pyimport("scipy"))
end


end

CondaPkg.toml

[deps]
python = ">=3.5,<4"


[pip.deps]
scipy = ""

Failing notebook - https://github.com/madhavkrishnan/TestPkg.jl/blob/main/debug/test.ipynb

Working script
debug/test.jl

using TestPkg

println(TestPkg.scipy)

println(TestPkg.scipy.sin(π / 4))

Could someone check if this is reproducable or if it is a problem with my system?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions