Ticket #479 (closed defect: fixed)

Opened 5 years ago

Last modified 5 years ago

Unused variables

Reported by: Leo Owned by: andrew
Priority: major Milestone: 0.7.2
Component: databaseapi Version: 0.7.1
Keywords: Cc:


Running South 0.7.1 through PyDev? reveals some unused variables and imports. Some of these are harmless, but some may be bugs. Here's a couple that stood out for me:

south.db.sql_server.pyodbc:42 - q_table_name and q_name are unused - should they be used instead of table_name and name down on line 57?

Same thing in the next function, _find_constraints_for_column.

south.db.generic.py:623 in create_index_sql - 'connection' is unused - was it meant to be reused in the next line?

south.management.commands.datamigration:40 - gasp! A tab!

south.management.commands.migrate:54 - looks like resolve_mode is commented out below? is it still used?

south.management.commands.schemamigration:48 - Another tab.

south.creator.changes:154 - still_there seems to be completely unused

south.migration.__init__:39 - problems(pending, done) is defined twice.

south.tests.logic:476 - in test_guess_migration M2 is set but unused, were there meant to be some tests against it?

Change History

comment:1 Changed 5 years ago by andrew

  • Status changed from new to assigned
  • Milestone set to 0.7.2

I'll take a look at these at some point (there's probably a few copy-and-paste errors in there, as well as stuff that was used in 0.6 or earlier).

comment:2 Changed 5 years ago by andrew

  • Status changed from assigned to closed
  • Resolution set to fixed

All fixed in [e59d246af1e6].

Note: See TracTickets for help on using tickets.