Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions airflow-core/src/airflow/cli/cli_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -598,7 +598,7 @@ def string_lower_type(val):
# database
ARG_MIGRATION_TIMEOUT = Arg(
("-t", "--migration-wait-timeout"),
help="timeout to wait for db to migrate ",
help="timeout to wait for db to migrate",
type=int,
default=60,
)
Expand Down Expand Up @@ -1461,8 +1461,8 @@ class GroupCommand(NamedTuple):
DB_COMMANDS = (
ActionCommand(
name="check-migrations",
help="Check if migration have finished",
description="Check if migration have finished (or continually check until timeout)",
help="Check if migrations have finished",
description="Check if migrations have finished (or continually check until timeout)",
func=lazy_load_command("airflow.cli.commands.db_command.check_migrations"),
args=(ARG_MIGRATION_TIMEOUT, ARG_VERBOSE),
),
Expand Down
2 changes: 1 addition & 1 deletion airflow-core/src/airflow/cli/commands/db_command.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ def run_db_migrate_command(args, command, revision_heads_map: dict[str, str]):
show_sql_only=args.show_sql_only,
)
if not args.show_sql_only:
print("Database migrating done!")
print("Database migration done!")


def run_db_downgrade_command(args, command, revision_heads_map: dict[str, str]):
Expand Down
2 changes: 1 addition & 1 deletion airflow-core/tests/unit/cli/commands/test_db_command.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def fake_command(**kwargs):
db_command.run_db_migrate_command(Args(), fake_command, heads)
out = capsys.readouterr().out
assert "Performing upgrade" in out
assert "Database migrating done!" in out
assert "Database migration done!" in out
assert called == {"to_revision": None, "from_revision": None, "show_sql_only": False}

def test_run_db_migrate_command_offline_generation(self, capsys):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,5 +46,5 @@ def migratedb(args):
def downgrade(args):
"""Downgrades the metadata database."""
session = settings.Session()
dwongrade_command = FABDBManager(session).downgrade
run_db_downgrade_command(args, dwongrade_command, revision_heads_map=_REVISION_HEADS_MAP)
downgrade_command = FABDBManager(session).downgrade
run_db_downgrade_command(args, downgrade_command, revision_heads_map=_REVISION_HEADS_MAP)
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ def users_create(args):
raise SystemExit(f"{args.role} is not a valid role. Valid roles are: {valid_roles}")
password = _create_password(args)
if appbuilder.sm.find_user(args.username):
print(f"{args.username} already exist in the db")
print(f"{args.username} already exists in the db")
return
user = appbuilder.sm.add_user(
args.username, args.firstname, args.lastname, args.email, role, password
Expand Down Expand Up @@ -101,7 +101,7 @@ def _find_user(args):
@cli_utils.action_cli
@providers_configuration_loaded
def user_reset_password(args):
"""Reset user password user from DB."""
"""Reset user password from DB."""
user = _find_user(args)
password = _create_password(args)
with get_application_builder() as appbuilder:
Expand Down Expand Up @@ -143,7 +143,7 @@ def users_delete(args):
@cli_utils.action_cli
@providers_configuration_loaded
def users_manage_role(args, remove=False):
"""Delete or appends user roles."""
"""Delete or append user roles."""
with get_application_builder() as appbuilder:
user = _find_user(args)
role = appbuilder.sm.find_role(args.role)
Expand Down
4 changes: 2 additions & 2 deletions providers/fab/src/airflow/providers/fab/cli/definition.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@
),
epilog=(
"examples:\n"
'To create an user with "Admin" role and username equals to "admin", run:\n'
'To create a user with "Admin" role and username equals to "admin", run:\n'
"\n"
" $ airflow users create \\\n"
" --username admin \\\n"
Expand All @@ -172,7 +172,7 @@
),
epilog=(
"examples:\n"
'To reset an user with username equals to "admin", run:\n'
'To reset a user with username equals to "admin", run:\n'
"\n"
" $ airflow users reset-password \\\n"
" --username admin"
Expand Down