Custom Query (1173 matches)

Filters
 
Or
 
  
 
Columns

Show under each result:


Results (112 - 114 of 1173)

Ticket Resolution Summary Owner Reporter
#5452 no-action Slow gmg command Elinvention
Description

On my tiny home server, the gmg command takes ages just to show the usage message. I think the first thing it should do is parsing the command line and possibly throw errors immediately. Only after that import all other required modules.

% time ./bin/gmg

usage: gmg [-h] [-cf CONF_FILE]

{batchaddmedia,shell,adduser,assetlink,makeadmin,reprocess,serve,deleteuser,addmedia,dbupdate,deletemedia,changepw,alembic} ...

gmg: error: too few arguments ./bin/gmg 6,30s user 2,89s system 86% cpu 10,612 total

6,30 seconds just to list possible commands!!! I'd say it's a bit unresponsive.

#5460 fixed Log IP address when a user enters a wrong password Elinvention
Description

If I try to login with a wrong password, this message is logged:

WARNING:mediagoblin.auth.tools:Wrong password for u'elinvention'

I'd like to set up fail2ban for Mediagoblin, but without IP address I can't do much...

A message like this would be better:

WARNING:mediagoblin.auth.tools:Wrong password for u'elinvention' from xxx.xxx.xxx.xxx

#5441 fixed raw_input is depreceated in python3 Espionage724
Description

Was trying out python3 and was trying to add a new user via gmg. I was getting this error:

Traceback (most recent call last):
  File "/srv/www/media/bin/gmg", line 9, in <module>
    load_entry_point('mediagoblin', 'console_scripts', 'gmg')()
  File "/srv/www/media/mediagoblin/gmg_commands/__init__.py", line 148, in main_cli
    args.func(args)
  File "/srv/www/media/mediagoblin/gmg_commands/users.py", line 46, in adduser
    args.email = commands_util.prompt_if_not_set(args.email, "Email:")
  File "/srv/www/media/mediagoblin/gmg_commands/util.py", line 36, in prompt_if_not_set
    variable=raw_input(text + u' ')
NameError: name 'raw_input' is not defined

Did a little searching and noticed: https://www.codecademy.com/forum_questions/535b85237c82ca9f46000f87#answer-535ba57f52f86373e30012ce

In Python 3.x, input() replaces raw_input(), for input from the console.

So I edited mediagoblin/gmg_commands/util.py and changed the only raw_input occurrence to input, re-ran the gmg command, and it created the user successfully (or said it did anyway; haven't tested it yet :p).

Outside of this one situation, I'm not sure if raw_input affects anything else.

Batch Modify
Note: See TracBatchModify for help on using batch modify.
Note: See TracQuery for help on using queries.