Debian Codegraph @

django_pgschemas/management/commands/whowill.py

raw
1 from typing import Any
2
3 from django_pgschemas.schema import Schema
4
5 from . import SchemaCommand
6
7
8 class Command(SchemaCommand):
9 help = "Displays which schemas would be used based on the passed schema selectors"
10
11 def handle_schema(self, schema: Schema, *args: Any, **options: Any) -> None:
12 if options["verbosity"] >= 1:
13 self.stdout.write(str(schema.routing) if schema.routing else schema.schema_name)