Comments (4)
I agree with the title of this issue, but vehemently disagree that return integer codes is a good, or even decent, means of accomplishing this aim. In order to provide "an appropriate non-zero value on failure" means parsing the OperationalError anyway, so why not convert it to a goose.exceptions.SomeAppropriateException, with a "more informative and user-friendly" message attribute?
from goose.
I'm not advocating that the return code be used by people using Goose as a library within their startup process.
I'm also not thinking that they should use a return code ("Just run goose and then "echo $?" to check the return code!").
I'm just thinking that any traceback is irrelevant in the case of an error in a SQL file but the migration should still fail in a way that is unambiguous for a runner like Buildbot or Jenkins.
http://buildbot.net/buildbot/docs/0.8.5/manual/cfg-buildsteps.html
from goose.
I'm not quite with you yet, though I agree with what you said regarding buildbot/jenkins. What I don't understand is the phrase "any traceback is irrelevant in the case of an error in a SQL file"; it seems pretty relevant to me. Sure the database driver is the thing that actually raises the OperationalError, or what-have-you, but I think it is no different than raising OSError when performing a file-system operation: I still want to know why the error was raised, and the traceback will contain the actual exception message (from the rdbms in this case), and I would want to know that.
from goose.
Yeah, I see your point.
On Mar 11, 2012 1:34 PM, "L. Daniel Burr" <
[email protected]>
wrote:
I'm not quite with you yet, though I agree with what you said regarding
buildbot/jenkins. What I don't understand is the phrase "any traceback is
irrelevant in the case of an error in a SQL file"; it seems pretty relevant
to me. Sure the database driver is the thing that actually raises the
OperationalError, or what-have-you, but I think it is no different than
raising OSError when performing a file-system operation: I still want to
know why the error was raised, and the traceback will contain the actual
exception message (from the rdbms in this case), and I would want to know
that.
Reply to this email directly or view it on GitHub:
#16 (comment)
from goose.
Related Issues (16)
- Use Distribute / Packaging instead of Setuptools HOT 2
- Nicer UX: Commandline examples are kind of verbose / repetitive
- Python Migrations
- Someday
- Add tox support
- Documentation
- Cram Tests
- Fail faster on bad migration ranges
- Add reverse migrations HOT 1
- Naming HOT 3
- Why it gots to be yaml? HOT 2
- There are no examples of altering a table
- SQL Output for Deployment
- Structuring Migrations (Removing Monolithic Migrations)
- Templates for Migrations
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from goose.