translate / amagama

Web service for implementing a large-scale translation memory
http://amagama.translatehouse.org
GNU General Public License v3.0
90 stars 27 forks source link

Commands improvements #18

Closed unho closed 10 years ago

unho commented 10 years ago

Creating the PR because I am not sure if all people will be OK with the commands having output when no error happens.

jleclanche commented 10 years ago

Can you add a --quiet flag then?

unho commented 10 years ago

Gave a thought and I don't see why having more verbose output in this management commands can create problems. If someone complains we can quickly add a --quiet flag or even revert the changes.

jleclanche commented 10 years ago

gtm

khaledhosny commented 10 years ago

Adding a --quite option would be nice, but I would not block this on it. LGTM otherwise.

dwaynebailey commented 10 years ago

OK, so I'm of the old Unix school. Keep quiet unless something goes wrong.

Now to the real practical, not a toy, amaGama setup.

150 LO languages * maybe 200 stores 200 Firefox languages * 250 stores

Now try find the error from the noise.

I would invert this add --verbose if you want to commands to talk to you. I don't really want to have cron job logs that are so noisy and just mask real errors. I prefer to just know what that error is.

I'm not giving this a gtm unless we have --quiet or as I'd prefer --verbose.

jleclanche commented 10 years ago

Changing my +0 to a -1 given @dwaynebailey's comments.

unho commented 10 years ago

@dwaynebailey @jleclanche @khaledhosny Added a new --verbose parameter for the build_tmdb command since that is the only one that can get noisy. Please let me know if now it is gtm for you.

unho commented 10 years ago

@dwaynebailey Also noticed that we are actually not printing errors on stdout but using logging.

dwaynebailey commented 10 years ago

@unho if we are using logging then why are we using print() for informational messages instead of just using logging? We really should be using logging. It feels like we get a lot of noise and code clutter for this. But apart from that gripe I'm gtm

unho commented 10 years ago

@dwaynebailey Maybe it is better to forget about logging for the management commands. At least for now, because I actually have no idea where the logs are saved.