another aspect you might want to consider (we had to) is that you must make 
sure that the migration scripts will become part of an eggified version of your 
package.

once we started to deploy our code from packaged eggs (rather than source 
checkouts) we found it easiest to simply move the alembic folder *inside* our 
package.

YMMV,

tom


> On 27 Jan 2015, at 00:56, Matt McClure <m...@cens.io> wrote:
> 
> Thanks for clarifying!
> 
> On Mon, Jan 26, 2015 at 6:50 PM, Michael Bayer <mike...@zzzcomputing.com 
> <mailto:mike...@zzzcomputing.com>> wrote:
> 
> 
> Matt McClure <m...@cens.io <mailto:m...@cens.io>> wrote:
> 
> > After reading the tutorial, and searching a little in the documentation and 
> > group archives, I'm unclear on the best location and name of the Alembic 
> > scripts directory.
> >
> > The tutorial advises:
> >
> > yourproject/
> >     alembic/
> >
> > And indicates:
> >
> > yourproject - this is the root of your application’s source code, or some 
> > directory within it.
> >
> > If my project directory structure looks like:
> >
> > my-project/
> >     mypackage/
> >         __init__.py
> >
> > Then, is it better to make the scripts directory a child or a sibling of my 
> > package?
> 
> 
> I tend to go with sibling, it’s not really a “package”.
> 
> >
> > Is the intent that the scripts directory be an importable module?
> 
> it’s not.   some people try to treat it that way, putting the migration files 
> at least deep within their package tree, and that is fine also, but Alembic 
> itself doesn’t need it to behave that way.
> 
> 
> >
> > Would it be best to name it something other than "alembic" to avoid import 
> > conflicts with Alembic itself?
> 
> you can name it whatever, but it’s not a package so doesn’t have any kind of 
> module name conflicts.
> 
> 
> 
> 
> >
> > Best,
> > Matt
> >
> > --
> > http://matthewlmcclure.com <http://matthewlmcclure.com/>
> >
> > --
> > You received this message because you are subscribed to the Google Groups 
> > "sqlalchemy-alembic" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to sqlalchemy-alembic+unsubscr...@googlegroups.com 
> > <mailto:sqlalchemy-alembic%2bunsubscr...@googlegroups.com>.
> > For more options, visit https://groups.google.com/d/optout 
> > <https://groups.google.com/d/optout>.
> 
> --
> You received this message because you are subscribed to a topic in the Google 
> Groups "sqlalchemy-alembic" group.
> To unsubscribe from this topic, visit 
> https://groups.google.com/d/topic/sqlalchemy-alembic/pET7mHg59H4/unsubscribe 
> <https://groups.google.com/d/topic/sqlalchemy-alembic/pET7mHg59H4/unsubscribe>.
> To unsubscribe from this group and all its topics, send an email to 
> sqlalchemy-alembic+unsubscr...@googlegroups.com 
> <mailto:sqlalchemy-alembic%2bunsubscr...@googlegroups.com>.
> For more options, visit https://groups.google.com/d/optout 
> <https://groups.google.com/d/optout>.
> 
> 
> 
> -- 
> http://cens.io <http://cens.io/>
> http://matthewlmcclure.com <http://matthewlmcclure.com/>
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "sqlalchemy-alembic" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to sqlalchemy-alembic+unsubscr...@googlegroups.com 
> <mailto:sqlalchemy-alembic+unsubscr...@googlegroups.com>.
> For more options, visit https://groups.google.com/d/optout 
> <https://groups.google.com/d/optout>.

-- 
You received this message because you are subscribed to the Google Groups 
"sqlalchemy-alembic" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sqlalchemy-alembic+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to