Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9301879
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T23:07:49+00:00 2026-06-18T23:07:49+00:00

When I run my unit test I get this error: FAIL: test_syntax (mezzanine.core.tests.Tests) Traceback

  • 0

When I run my unit test I get this error:

FAIL: test_syntax (mezzanine.core.tests.Tests)

Traceback (most recent call last):

File “/Users/taylor/aco/lib/python2.7/site-packages/mezzanine/core/tests.py”, line 459, in test_syntax

self.fail(“Syntax warnings!\n\n%s” % “\n”.join(warnings))
AssertionError: Syntax warnings!

mezzanine/core/models.py:340: list comprehension redefines ‘name’ from line 331

This is the only error I get when I run my unit tests and I have searched everywhere to figure out how to fix this error but I have found nothing useful.
Can someone please explain to me what is going on here and how I can fix it?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T23:07:50+00:00Added an answer on June 18, 2026 at 11:07 pm

    I presume you are running Mezzanine 1.3.0, the current stable release. The current master branch in github does not have this issue. I just installed performed the following:

    $ pip install git+https://github.com/stephenmcd/mezzanine.git#egg=Mezzanine
    $ mezzanine-project project
    $ python project/manage.py test
    Creating test database for alias 'default'...
    .................................................................................
    .................................................................................
    .................................................................................
    ...............................s......s..................................s.......
    ................................................................
    ----------------------------------------------------------------------
    Ran 388 tests in 30.556s
    
    OK (skipped=3)
    Destroying test database for alias 'default'...
    

    For what it is worth, the test_syntax method that is failing in 1.3.0 runs tests with the pyflakes.Checker and pep8 Python modules. The file mezzanine/core/models.py had (has?) syntax errors. A brief scan of the commits indicates that test_syntax has not changed. The specific syntax that was giving the error is in mezzanine.core.models.Orderable‘s with_respect_to method, which doesn’t have any PEP8 nor pyflakes errors. When I run pyflakes against the 1.3.0 version of mezzanine.core.models:

    $ pyflakes ../lib/python2.6/site-packages/mezzanine/core/models.py
    ../lib/python2.6/site-packages/mezzanine/core/models.py:340: list comprehension
    redefines 'name' from line 331
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i'm trying to run this node.js unit tests and i get this error: module.js:340
I get a java.lang.NoClassDefFoundError: android/util/Log error when I try to run my unit test
I am getting this error when running some unit tests (using the Test::Unit module
On remote build machine, I get the following error when I run my unit
When I run this unit test: require 'test_helper' class MyControllerTest < ActionController::TestCase test "my
Has anybody run into the following error when trying to run unit tests in
When I run unit tests in Xcode GUI I receive this warning Skipping tests;
I use this command to run a unit test in rails: $ ruby -Itest
I cannot successfully run unit tests for MvcMailer using the visual studio test suite
I want to run a hadoop unit test, using the local filesystem mode... I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.