Loading ...
Sorry, an error occurred while loading the content.

Re: [Cheetahtemplate-discuss] New cheetah compile problem

Expand Messages
  • Mike Orr
    ... Fixed. I also uncovered a couple other bugs. Here s the changelog entry: - Fix three bugs in cheetah compile -R : (1) the generated class name contained
    Message 1 of 6 , Oct 9, 2002
    • 0 Attachment
      On Wed, Oct 02, 2002 at 04:20:19PM +1000, Huy Do wrote:
      > I am running the new cheetah compile --odir /tmp -R
      >
      > And my cheetah classes are being generated with the full path names
      >
      > Eg.
      >
      > Class ./DefaultPage
      >
      > Or
      >
      > Class ./user/DefaultUserPage

      Fixed. I also uncovered a couple other bugs. Here's the changelog
      entry:

      - Fix three bugs in "cheetah compile -R": (1) the generated class name
      contained the subdirectory, (2) the destination path did not contain
      the subdirectory, (3) Cheetah failed to create the destination
      subdirectory if missing. (MO)

      I tested this with source files:
      x.tmpl
      user/x.tmpl
      user/subuser/x.tmpl

      Huy and Ian, please get the CVS version of Cheetah and see if it works
      correctly on your files.

      --
      -Mike (Iron) Orr, iron@... (if mail problems: mso@...)
      http://iron.cx/ English * Esperanto * Russkiy * Deutsch * Espan~ol


      -------------------------------------------------------
      This sf.net email is sponsored by:ThinkGeek
      Welcome to geek heaven.
      http://thinkgeek.com/sf
      _______________________________________________
      Cheetahtemplate-discuss mailing list
      Cheetahtemplate-discuss@...
      https://lists.sourceforge.net/lists/listinfo/cheetahtemplate-discuss
    • Huy Do
      Hi Mike, It works great with my setup. Just one other note ? Is it possible for cheetah to create the __init__.py files in each of the output directories.
      Message 2 of 6 , Oct 10, 2002
      • 0 Attachment
        Hi Mike,

        It works great with my setup. Just one other note ? Is it possible for
        cheetah to create the __init__.py files in each of the output
        directories.

        Thanks

        Huy

        > -----Original Message-----
        > From: cheetahtemplate-discuss-admin@...
        > [mailto:cheetahtemplate-discuss-admin@...]
        > On Behalf Of Mike Orr
        > Sent: Thursday, 10 October 2002 4:23 PM
        > To: Cheetah Template List
        > Subject: Re: [Cheetahtemplate-discuss] New cheetah compile problem
        >
        >
        > On Wed, Oct 02, 2002 at 04:20:19PM +1000, Huy Do wrote:
        > > I am running the new cheetah compile --odir /tmp -R
        > >
        > > And my cheetah classes are being generated with the full path names
        > >
        > > Eg.
        > >
        > > Class ./DefaultPage
        > >
        > > Or
        > >
        > > Class ./user/DefaultUserPage
        >
        > Fixed. I also uncovered a couple other bugs. Here's the changelog
        > entry:
        >
        > - Fix three bugs in "cheetah compile -R": (1) the generated
        > class name
        > contained the subdirectory, (2) the destination path did
        > not contain
        > the subdirectory, (3) Cheetah failed to create the destination
        > subdirectory if missing. (MO)
        >
        > I tested this with source files:
        > x.tmpl
        > user/x.tmpl
        > user/subuser/x.tmpl
        >
        > Huy and Ian, please get the CVS version of Cheetah and see if
        > it works correctly on your files.
        >
        > --
        > -Mike (Iron) Orr, iron@... (if mail problems: mso@...)
        > http://iron.cx/ English * Esperanto * Russkiy *
        > Deutsch * Espan~ol
        >
        >
        > -------------------------------------------------------
        > This sf.net email is sponsored by:ThinkGeek
        > Welcome to geek heaven.
        > http://thinkgeek.com/sf
        > _______________________________________________
        > Cheetahtemplate-discuss mailing list
        > Cheetahtemplate-discuss@...
        > https://lists.sourceforge.net/lists/listinfo/cheetahtemplate-discuss
        >



        -------------------------------------------------------
        This sf.net email is sponsored by:ThinkGeek
        Welcome to geek heaven.
        http://thinkgeek.com/sf
        _______________________________________________
        Cheetahtemplate-discuss mailing list
        Cheetahtemplate-discuss@...
        https://lists.sourceforge.net/lists/listinfo/cheetahtemplate-discuss
      • Mike Orr
        Sending to the list because I m not sure whether it should or not. Should cheetah compile put an __init__.py in every directory it creates? What about the
        Message 3 of 6 , Oct 10, 2002
        • 0 Attachment
          Sending to the list because I'm not sure whether it should or not.
          Should "cheetah compile" put an __init__.py in every directory it
          creates? What about the top-level destination directory if it already
          exists?

          --
          -Mike (Iron) Orr, iron@... (if mail problems: mso@...)
          http://iron.cx/ English * Esperanto * Russkiy * Deutsch * Espan~ol

          On Fri, Oct 11, 2002 at 10:17:51AM +1000, Huy Do wrote:
          > Hi Mike,
          >
          > It works great with my setup. Just one other note ? Is it possible for
          > cheetah to create the __init__.py files in each of the output
          > directories.
          >
          > Thanks
          >
          > Huy
          >
          > > -----Original Message-----
          > > From: cheetahtemplate-discuss-admin@...
          > > [mailto:cheetahtemplate-discuss-admin@...]
          > > On Behalf Of Mike Orr
          > > Sent: Thursday, 10 October 2002 4:23 PM
          > > To: Cheetah Template List
          > > Subject: Re: [Cheetahtemplate-discuss] New cheetah compile problem
          > >
          > >
          > > On Wed, Oct 02, 2002 at 04:20:19PM +1000, Huy Do wrote:
          > > > I am running the new cheetah compile --odir /tmp -R
          > > >
          > > > And my cheetah classes are being generated with the full path names
          > > >
          > > > Eg.
          > > >
          > > > Class ./DefaultPage
          > > >
          > > > Or
          > > >
          > > > Class ./user/DefaultUserPage
          > >
          > > Fixed. I also uncovered a couple other bugs. Here's the changelog
          > > entry:
          > >
          > > - Fix three bugs in "cheetah compile -R": (1) the generated
          > > class name
          > > contained the subdirectory, (2) the destination path did
          > > not contain
          > > the subdirectory, (3) Cheetah failed to create the destination
          > > subdirectory if missing. (MO)
          > >
          > > I tested this with source files:
          > > x.tmpl
          > > user/x.tmpl
          > > user/subuser/x.tmpl
          > >
          > > Huy and Ian, please get the CVS version of Cheetah and see if
          > > it works correctly on your files.
          > >
          > > --
          > > -Mike (Iron) Orr, iron@... (if mail problems: mso@...)
          > > http://iron.cx/ English * Esperanto * Russkiy *
          > > Deutsch * Espan~ol
          > >
          > >
          > > -------------------------------------------------------
          > > This sf.net email is sponsored by:ThinkGeek
          > > Welcome to geek heaven.
          > > http://thinkgeek.com/sf
          > > _______________________________________________
          > > Cheetahtemplate-discuss mailing list
          > > Cheetahtemplate-discuss@...
          > > https://lists.sourceforge.net/lists/listinfo/cheetahtemplate-discuss
          > >


          -------------------------------------------------------
          This sf.net email is sponsored by:ThinkGeek
          Welcome to geek heaven.
          http://thinkgeek.com/sf
          _______________________________________________
          Cheetahtemplate-discuss mailing list
          Cheetahtemplate-discuss@...
          https://lists.sourceforge.net/lists/listinfo/cheetahtemplate-discuss
        • Mike Warren
          ... Hash: SHA1 ... IMO, yes, if those files don t exist; aren t the compiled templates basically useless if the __init__ s aren t in subdirectories? It could
          Message 4 of 6 , Oct 10, 2002
          • 0 Attachment
            -----BEGIN PGP SIGNED MESSAGE-----
            Hash: SHA1

            iron@... (Mike Orr) writes:

            > Sending to the list because I'm not sure whether it should or not.
            > Should "cheetah compile" put an __init__.py in every directory it
            > creates? What about the top-level destination directory if it
            > already exists?

            IMO, yes, if those files don't exist; aren't the compiled templates
            basically useless if the __init__'s aren't in subdirectories? It could
            be a --create-init option or something...

            - --
            mike [at] mike [dash] warren [dot] com
            <URL:http://www.mike-warren.com>
            gpg --keyserver 80.71.227.37 --recv-key 579911BD
            87F2 4D98 BDB0 0E90 EE2A 0CF9 1087 0884 5799 11BD



            -----BEGIN PGP SIGNATURE-----
            Version: GnuPG v1.2.0 (GNU/Linux)
            Comment: Processed by Mailcrypt 3.5.6 and Gnu Privacy Guard <http://www.gnupg.org/>

            iEYEARECAAYFAj2mPB0ACgkQEIcIhFeZEb2trACfbxT5VEFYb5/z+mTiR7VGpGps
            NuwAoKnIuz2tHHsR2VZsHBOTts0LAXNV
            =t4eB
            -----END PGP SIGNATURE-----


            -------------------------------------------------------
            This sf.net email is sponsored by:ThinkGeek
            Welcome to geek heaven.
            http://thinkgeek.com/sf
            _______________________________________________
            Cheetahtemplate-discuss mailing list
            Cheetahtemplate-discuss@...
            https://lists.sourceforge.net/lists/listinfo/cheetahtemplate-discuss
          • Mike Orr
            ... I decided to create an empty __init__.py whenever it creates a directory, but not if the directory already exists. This is not configurable because I
            Message 5 of 6 , Oct 12, 2002
            • 0 Attachment
              On Thu, Oct 10, 2002 at 08:49:03PM -0600, Mike Warren wrote:
              > iron@... (Mike Orr) writes:
              >
              > > Sending to the list because I'm not sure whether it should or not.
              > > Should "cheetah compile" put an __init__.py in every directory it
              > > creates? What about the top-level destination directory if it
              > > already exists?
              >
              > IMO, yes, if those files don't exist; aren't the compiled templates
              > basically useless if the __init__'s aren't in subdirectories? It could
              > be a --create-init option or something...

              I decided to create an empty __init__.py whenever it creates a
              directory, but not if the directory already exists. This is not
              configurable because I can't think of any reason you wouldn't
              want it.

              Do people have a preference about empty __init__.py files vs those
              containing "#\n"? The former is theoretically cleaner, but the
              latter makes the file CVSable.

              It's not checked in yet because I uncovered a couple other bugs while
              fixing this and the "class ./subdirectory/MyClass" problem. This
              argues for a test suite for recursive compiles/fills, which is what
              I'm working on this weekend. I'm sure other bugs will be uncovered
              once the test suite is written, so it could take this weekend and
              next weekend to clean them all up.

              --
              -Mike (Iron) Orr, iron@... (if mail problems: mso@...)
              http://iron.cx/ English * Esperanto * Russkiy * Deutsch * Espan~ol


              -------------------------------------------------------
              This sf.net email is sponsored by:ThinkGeek
              Welcome to geek heaven.
              http://thinkgeek.com/sf
              _______________________________________________
              Cheetahtemplate-discuss mailing list
              Cheetahtemplate-discuss@...
              https://lists.sourceforge.net/lists/listinfo/cheetahtemplate-discuss
            Your message has been successfully submitted and would be delivered to recipients shortly.