Opened 10 years ago

Closed 9 years ago

#936 closed defect (cant-reproduce)

wtforms dependency error in setup.py

Reported by: ZHANG Weiwu Owned by:
Priority: major Milestone:
Component: programming Keywords:
Cc: Parent Tickets:

Description

git cloned master a few minutes ago.

setup.py depends on wtforms without specifying version. So I used 1.0.1, the most common wtforms version found (e.g. on Ubuntu 14.04 released 4 months ago).

Error follows.

$ gmg dbupdate
Traceback (most recent call last):
  File "/usr/local/bin/gmg", line 9, in <module>
    load_entry_point('mediagoblin==0.6.2.dev', 'console_scripts', 'gmg')()
  File "/var/mediagoblin/mediagoblin/gmg_commands/__init__.py", line 108, in main_cli
    setup_func = import_component(command_struct['setup'])
  File "/var/mediagoblin/mediagoblin/tools/common.py", line 34, in import_component
    __import__(module_name)
  File "/var/mediagoblin/mediagoblin/gmg_commands/shell.py", line 21, in <module>
    from mediagoblin.gmg_commands import util as commands_util
  File "/var/mediagoblin/mediagoblin/gmg_commands/util.py", line 18, in <module>
    from mediagoblin import app
  File "/var/mediagoblin/mediagoblin/app.py", line 29, in <module>
    from mediagoblin.tools import common, session, translate, template
  File "/var/mediagoblin/mediagoblin/tools/template.py", line 34, in <module>
    from mediagoblin.meddleware.csrf import render_csrf_form_token
  File "/var/mediagoblin/mediagoblin/meddleware/csrf.py", line 44, in <module>
    class CsrfForm(Form):
  File "/var/mediagoblin/mediagoblin/meddleware/csrf.py", line 49, in CsrfForm
    [validators.InputRequired()])
AttributeError: 'module' object has no attribute 'InputRequired'

On wtforms 1.0.1 there is only wtforms.validators.Required.

Either change code to stay with wtforms 1.0.1 (most commonly found),

or be explicit that this version is not acceptable in setup.py - wtforms 2 seems have this class.

Change History (1)

comment:1 by Loic Dachary, 9 years ago

Resolution: worksforme
Status: newclosed

This dependency problem no longer happens on Ubuntu 14.04, as verified yesterday.

Note: See TracTickets for help on using tickets.