compiling python

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Birgit Rahm

    compiling python

    Hallo newsgroup,
    because so many people helped me, I hope for help onesmore.
    If I compile a python py file to a pyc file, will there the paths of the
    included files (or other paths) hardly be written to the pyc file and why.
    (Does not find this import file without this path anymore?)
    Which sense is behind there?
    TIA,Birgit




  • Scott David Daniels

    #2
    Re: compiling python

    Birgit Rahm wrote:
    [color=blue]
    > Hallo newsgroup,
    > because so many people helped me, I hope for help onesmore.
    > If I compile a python py file to a pyc file, will there the paths of the
    > included files (or other paths) hardly be written to the pyc file and why.
    > (Does not find this import file without this path anymore?)
    > Which sense is behind there?
    > TIA,Birgit[/color]

    The model is that you import "modules" not files. As a result,
    where you find the module is kind of accidental. For example,
    when I am working on a largish program, I'll have several modules
    in my 'current development' directory, get the application to work
    with with those updated modules, and then check the modules back in
    to the central directories. If the .pyc files remebered locations,
    I might accidentally be testing the accepted code, rather than my
    new implementations .

    -Scott David Daniels
    Scott.Daniels@A cm.Org

    Comment

    Working...