Description: Download Film Rumah Kentang
Movie info:
Alternative Titles: Rumah Kentang
Language: English
Where to download Rumah Kentang :
Disclaimer of involved content:
This video was uploaded from third party and we don't have any relation with this file uploader. We are a media search engine and we process information about movies from different sources by using toplist submission.
Attention! This website contains assitive content. You must be 18 years of age or older to view this website
We are investigating this report and will remove it ASAP.Q:
How do I import a submodule using `` and not ``?
I'm trying to import the _path module with python 3.5 using this package:
The code is:
from _path import *
However, this gives an ImportError: _path/__init__.py: cannot import name *
I'm not sure why this is, because I have seen people use the code on github ( and they don't have an ImportError when importing the module.
A:
The project you linked is based on Python 2, so _path.py is a module and _path.py isn't the same as _path.py, and even if they were the same, the import form would be different.
On Python 3, the project includes _path.pyc (as a Python bytecode file) but _path.py is not the same thing, so import _path (as opposed to _path.py) will fail to import that module.
You can work around this issue by manually re-creating the _path.pyc file:
>>> import _path
>>> import io
>>> with io.open('_path.pyc', 'w', encoding='utf-8') as f:
... f.write('print(1)
')
...
>>> from _path import *
>>>
If you really want to automate this, you can use a module called importlib, which will automatically (if the import fails) write out a module that will load the same module, but fail to import anything, which should be good enough.
>>> from importlib import reload
>>> from importlib
Related links:
コメント