Basic python questino about import -


i trying run python (2.7.6) code, , compiler can't find "util" module.

here line code: from util import getargs, write

and error this:

traceback (most recent call last): file "rs.py", line 11, in util import getargs, write importerror: no module named util

i can't find util module anywhere, , pip install not recognize util, getargs, , write. how can fix problem?

as of comments have pointed out, should utils (plural) , not util

from utils import <your package> 

Comments

Popular posts from this blog

Prolog - Listing -

python - can't seem to get an output from my class -

orchardcms - change base url in local copy in Orchard CMS -