nl: raise an CommandError with an argument string "Cache table '%s' could not be created.\nThe error was: %s.", replace '%s' with:
code: raise CommandError ( "Cache table '%s' could not be created.\nThe error was: %s." % ( tablename , force_text ( e ) ) )