Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DPE-4219] Fix missing kwargs in some methods #143

Merged
merged 1 commit into from
Apr 30, 2024
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
2 changes: 1 addition & 1 deletion src/machine_workload.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class AuthenticatedMachineWorkload(workload.AuthenticatedWorkload):
def _get_bootstrap_command(
self, *, event, connection_info: "relations.database_requires.ConnectionInformation"
) -> typing.List[str]:
command = super()._get_bootstrap_command(connection_info)
command = super()._get_bootstrap_command(event=event, connection_info=connection_info)
if self._charm.is_externally_accessible(event=event):
command.extend(
[
Expand Down
2 changes: 1 addition & 1 deletion src/upgrade.py
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ def authorized(self) -> bool:
"""

@abc.abstractmethod
def upgrade_unit(self, *, workload_: workload.Workload, tls: bool) -> None:
def upgrade_unit(self, *, event, workload_: workload.Workload, tls: bool) -> None:
"""Upgrade this unit.
Only applies to machine charm
Expand Down
4 changes: 2 additions & 2 deletions src/workload.py
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ def _cleanup_after_upgrade_or_potential_container_restart(self) -> None:

# TODO python3.10 min version: Use `list` instead of `typing.List`
def _get_bootstrap_command(
self, connection_info: "relations.database_requires.ConnectionInformation"
self, *, event, connection_info: "relations.database_requires.ConnectionInformation"
) -> typing.List[str]:
return [
"--bootstrap",
Expand Down Expand Up @@ -430,7 +430,7 @@ def upgrade(
if enabled:
logger.debug("Disabling MySQL Router service before upgrade")
self._disable_router()
super().upgrade(unit=unit, tls=tls, exporter_config=exporter_config)
super().upgrade(event=event, unit=unit, tls=tls, exporter_config=exporter_config)
if enabled:
logger.debug("Re-enabling MySQL Router service after upgrade")
self._enable_router(event=event, tls=tls, unit_name=unit.name)
Expand Down
Loading