mod_python bytecompiling

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

    #1

    mod_python bytecompiling

    Hello!

    I am writing a small program using mod_python publisher extension. I
    have created several python files and imported them in a `main' file.
    How can I stop mod_python to byte compile the files? I want to make
    changes to the files and see result imediately!

    In the current setup only the changes to the `main' file are applied
    imediately. I is nearly imposible to develop an application this way.

    I want to mention that I'm a newby to mod_python.

  • Fredrik Lundh

    #2
    Re: mod_python bytecompiling

    "mneagul" wrote:
    [color=blue]
    > I am writing a small program using mod_python publisher extension. I
    > have created several python files and imported them in a `main' file.
    > How can I stop mod_python to byte compile the files? I want to make
    > changes to the files and see result imediately!
    >
    > In the current setup only the changes to the `main' file are applied
    > imediately. I is nearly imposible to develop an application this way.
    >
    > I want to mention that I'm a newby to mod_python.[/color]

    the FAQ has the answer:


    "Q. My module imports other modules - how do I reload those?"

    (another approach, used by several frameworks, is to use a stand-alone
    test server for development, and mod_python for deployment)

    </F>



    Comment

    • grahamd@dscpl.com.au

      #3
      Re: mod_python bytecompiling


      Fredrik Lundh wrote:[color=blue]
      > "mneagul" wrote:
      >[color=green]
      > > I am writing a small program using mod_python publisher extension. I
      > > have created several python files and imported them in a `main' file.
      > > How can I stop mod_python to byte compile the files? I want to make
      > > changes to the files and see result imediately!
      > >
      > > In the current setup only the changes to the `main' file are applied
      > > imediately. I is nearly imposible to develop an application this way.
      > >
      > > I want to mention that I'm a newby to mod_python.[/color]
      >
      > the FAQ has the answer:
      >
      > http://www.modpython.org/FAQ/faqw.py...=faq03.001.htp
      > "Q. My module imports other modules - how do I reload those?"
      >
      > (another approach, used by several frameworks, is to use a stand-alone
      > test server for development, and mod_python for deployment)[/color]

      Simply using apache.import_m odule() is not going to necessarily help
      at the moment as it has various problems and shortcomings. One of
      them is that it does not check multiple levels of dependencies between
      modules. Thus simply replacing global imports in a module with a call
      to apache.import_m odule() will not help.

      For a full list of problems and issues with the mod_python module
      importer see:



      There is a new module importer being tested with mod_python 3.3
      which will hopefully eliminate the major problems.

      Highly recommend that original poster get onto the mod_python mailing
      list to discuss what he can do in the interim.

      Graham

      Comment

      • mneagul

        #4
        Re: mod_python bytecompiling

        Problem solved!!!
        Thank You!

        Comment

        Working...