ergo / ziggurat_foundations

Framework agnostic set of sqlalchemy classes that make building applications that require permissions an easy task.
BSD 3-Clause "New" or "Revised" License
71 stars 22 forks source link

fix script_location in docs to show a placeholder value #39

Closed RaHus closed 8 years ago

RaHus commented 8 years ago

instead of ziggurat_foundation.migrations which is needed only for development

ergo commented 8 years ago

@RaHus You shoud be using package name like in the example - you can have multiple alembic configs and script locations that will not conflict eachother.

What kind of issues you were facing that you had to change the script location?

RaHus commented 8 years ago

@ergo I couldn't figure out why would i need the actual ziggurat migration files in my project, so i guessed that it was a copy/paste typo.

RaHus commented 8 years ago

Is there a reason for keeping the ziggurat migration files linked with the alembic.ini of a project? All the relevant changes of the db get recognized through the mixins imported to the project and any future updates to the package would also get recognized normally. Only possible reason for keeping them there would be if your project policy is to manage migrations manually but that would be generally the exception. Am i missing something here? Regardless, it would be nice if the docs mentioned the reason the ziggurat migration directory is being used in the example alembic.ini in the docs.

ergo commented 8 years ago

I couldn't figure out why would i need the actual ziggurat migration files in my project

@RaHus - the way things are set up currently you do not require ziggurat migration files in your project - they are read directly from the package, hence script_location = ziggurat_foundations:migrations. I'm a bit confused right now.

My script location should never point to %(here)s/alembic - your own project dependant migrations can if you want.

RaHus commented 8 years ago

The patch is against the documentation. The docs at that point refer to the user project alembic.ini not ziggurats alembic.ini IIRC. I hope this clarifies things a bit.

ergo commented 8 years ago

@RaHus I think you are misunderstanding something, you are NOT supposed to use the ini file here in the repo - it is used only for me internally to create new revisions.

The package in pypi doesn't even distribute the ini file at all - you are supposed to create your OWN ini file and point script location to ziggurat like in docs. Everything seems to be in order here.

When you are around maybe join my gitter channel and we can chat about this next time. For now I will close this because I think everything is correct.