Skip to content

PythonCall not playing nicely with pyinstaller #248

Closed
@KeithWM

Description

@KeithWM

First of all I'd like to express my appreciation for all the great work being done here. I think this package is a great facilitator for moving Julia out of it's initial niche towards integration into real, practical applications.

In that line, I've been trying to call Julia from a Python application that is then made into a (Windows) executable using pyinstaller. This did not work "out of the box". After a lot of digging, I discovered the bug was in the init_consts function, in particular in the evaluation of

:(pycopy!(pybuiltins.help, pybuiltinsmodule.help)), 

Commenting the :help in src/constants/consts.jl:66 gave a working application, much to my joy and that of my colleagues, but I don't know exactly why this helped, and if there's any downside to doing this. Even if my immediate problem has been resolved/avoided, I thought I should share what I found for the benefit of the community.

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