Skip to content

Messes up python's import? #81

@wusspuss

Description

@wusspuss

tohil::exec {import mymodule} or tohil::import mymodule will both complain No module named 'mymodule' (while evaluating python code) from python code executed by tohil whereas a mymodule.py exists in same dir the script is running from. import mymodule from normal python works fine. Importing system modules through tohil works fine. Tohil passes all tests.

I also noticed python's cffi module is broken in a similar manner: cffi itself imports fine, but smth like
ffi.set_source("_test", "..."); ffi.compile(); from _test import lib
Will again complain of module _test not being found, whereas it will work fine in standalone python

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