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

Fix for #1479 : Incorrect usage of i18n format #1500

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
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 jupyter_server/auth/identity.py
Original file line number Diff line number Diff line change
Expand Up @@ -651,7 +651,7 @@ def process_login_form(self, handler: web.RequestHandler) -> User | None:
config_dir = handler.settings.get("config_dir", "")
config_file = os.path.join(config_dir, "jupyter_server_config.json")
self.hashed_password = set_password(new_password, config_file=config_file)
self.log.info(_i18n(f"Wrote hashed password to {config_file}"))
self.log.info(_i18n("Wrote hashed password to {file}").format(file=config_file))

return user

Expand Down
4 changes: 3 additions & 1 deletion jupyter_server/serverapp.py
Original file line number Diff line number Diff line change
Expand Up @@ -2857,7 +2857,9 @@ def running_server_info(self, kernel_count: bool = True) -> str:
info += kernel_msg % n_kernels
info += "\n"
# Format the info so that the URL fits on a single line in 80 char display
info += _i18n(f"Jupyter Server {ServerApp.version} is running at:\n{self.display_url}")
info += _i18n("Jupyter Server {version} is running at:\n{url}").format(
version=ServerApp.version, url=self.display_url
)
if self.gateway_config.gateway_enabled:
info += (
_i18n("\nKernels will be managed by the Gateway server running at:\n%s")
Expand Down