Opened 12 years ago

Closed 10 years ago

#469 closed enhancement (fixed)

Warn when the database structures need “./bin/gmg dbupdate”

Reported by: Aleksej Owned by:
Priority: major Milestone:
Component: programming Keywords:
Cc: Stephen Compall, Simon Fondrie-Teitler Parent Tickets:


Sometimes the database structures need to be generated using “./bin/gmg dbupdate”.

E.g. when there is no database yet, this is necessary for GMG to start.
When you add media types, it is necessary to be able to store the media of those types (GMG transcoded a video clip but failed to store it).

Change History (7)

comment:1 by Will Kahn-Greene, 12 years ago

Milestone: 0.3.1

Where would the warnings show up and what would trigger them?

comment:2 by Stephen Compall, 11 years ago

Cc: Stephen Compall added

in reply to:  1 comment:3 by Simon Fondrie-Teitler, 11 years ago

Replying to willkg:

Where would the warnings show up and what would trigger them?

Having just spent a while debugging something that turned out to be gmg dbupdate not getting the correct config file, I was going to file this exact ticket. In my case I was actually able to upload an audio file and have it show up and work, however I was not able to fully delete it.

I recommend that mediagoblin not start, or at least print out a very nasty warning on the console, if the db does not reflect the correct database state. This can be done by running through the same commands that db uses to figure out how to update the db, and making sure that those tables exist.


comment:4 by Simon Fondrie-Teitler, 11 years ago

Cc: Simon Fondrie-Teitler added

comment:5 by Christopher Allan Webber, 11 years ago

The ideal situation is that the application should both spit a warning to the console at the very least and either shut down or instead of showing the normal application, run a minimalist application that explains that the administrator needs to update the database to match the present system.

comment:6 by rodney757, 11 years ago

Status: newreview

Here is my solution for this, I'm not sure if this is the cleanest way to quit the app though.

comment:7 by Christopher Allan Webber, 10 years ago

Resolution: fixed
Status: reviewclosed

Probably not the cleanest way to quit the app, but it works. Good enough for me for now! ;)

Committed to master! Thanks Rodney!

Note: See TracTickets for help on using tickets.