Commits

Andrew Godwin committed 2e7ec63

Fixed #937: Say when you're not printing stuff during dry run

Comments (0)

Files changed (1)

south/db/generic.py

         """
         
         if self.dry_run:
+            if self.debug:
+                print '   - no dry run output for alter_column() due to dynamic DDL, sorry'
             return
 
         # hook for the field to do any resolution prior to it's attributes being queried
 
         # Dry runs mean we can't do anything.
         if self.dry_run:
+            if self.debug:
+                print '   - no dry run output for delete_unique_column() due to dynamic DDL, sorry'
             return
 
         constraints = list(self._constraints_affecting_columns(table_name, columns))
     def delete_foreign_key(self, table_name, column):
         "Drop a foreign key constraint"
         if self.dry_run:
+            if self.debug:
+                print '   - no dry run output for delete_foreign_key() due to dynamic DDL, sorry'
             return # We can't look at the DB to get the constraints
         constraints = list(self._constraints_affecting_columns(table_name, [column], "FOREIGN KEY"))
         if not constraints:
         """
         # Dry runs mean we can't do anything.
         if self.dry_run:
+            if self.debug:
+                print '   - no dry run output for delete_primary_key() due to dynamic DDL, sorry'
             return
         
         constraints = list(self._constraints_affecting_columns(table_name, None, type="PRIMARY KEY"))
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.