Home > other > The import can, from the import doesn't (work well)
The import can, from the import doesn't (work well)
Time:09-24
Call python in c + +, python program in import __future__ can become the from __future__ import absolute_import, PyImport_ImportModule returns empty, don't know why, for the great spirit guide
CodePudding user response:
From __future__ import absolute_import You add a point in front of the __future__ & lt; . & gt; , said the current path, this kind of question I stepped over a considerable amount of pit, or the path is added, are used. The way
CodePudding user response:
A little also not line, because there is no current path __future__, tried to use absolute paths and the relative path to __future__ directory, all not line, don't know why