Remove the f-strings in the Jupyter web app's backend (kubeflow/kubeflow#5680)
This commit is contained in:
parent
2a0d0c7857
commit
2e5eaa1dc6
|
|
@ -9,9 +9,9 @@ log = logging.getLogger(__name__)
|
||||||
"/api/namespaces/<namespace>/notebooks/<notebook>", methods=["DELETE"]
|
"/api/namespaces/<namespace>/notebooks/<notebook>", methods=["DELETE"]
|
||||||
)
|
)
|
||||||
def delete_notebook(notebook, namespace):
|
def delete_notebook(notebook, namespace):
|
||||||
log.info(f"Deleting Notebook '{namespace}/{notebook}'")
|
log.info("Deleting Notebook '%s/%s'" % (namespace, notebook))
|
||||||
api.delete_notebook(notebook, namespace)
|
api.delete_notebook(notebook, namespace)
|
||||||
|
|
||||||
return api.success_response(
|
return api.success_response(
|
||||||
"message", f"Notebook {notebook} successfully deleted."
|
"message", "Notebook %s successfully deleted." % notebook
|
||||||
)
|
)
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ log = logging.getLogger(__name__)
|
||||||
@decorators.required_body_params("name")
|
@decorators.required_body_params("name")
|
||||||
def post_pvc(namespace):
|
def post_pvc(namespace):
|
||||||
body = request.get_json()
|
body = request.get_json()
|
||||||
log.info(f"Got body: {body}")
|
log.info("Got body: %s" % body)
|
||||||
|
|
||||||
notebook = helpers.load_param_yaml(
|
notebook = helpers.load_param_yaml(
|
||||||
utils.NOTEBOOK_TEMPLATE_YAML,
|
utils.NOTEBOOK_TEMPLATE_YAML,
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@ log = logging.getLogger(__name__)
|
||||||
@decorators.required_body_params("name")
|
@decorators.required_body_params("name")
|
||||||
def post_notebook(namespace):
|
def post_notebook(namespace):
|
||||||
body = request.get_json()
|
body = request.get_json()
|
||||||
log.info(f"Got body: {body}")
|
log.info("Got body: %s" % body)
|
||||||
|
|
||||||
notebook = helpers.load_param_yaml(
|
notebook = helpers.load_param_yaml(
|
||||||
utils.NOTEBOOK_TEMPLATE_YAML,
|
utils.NOTEBOOK_TEMPLATE_YAML,
|
||||||
|
|
|
||||||
|
|
@ -41,7 +41,7 @@ if UI_FLAVOR == "default":
|
||||||
elif UI_FLAVOR == "rok":
|
elif UI_FLAVOR == "rok":
|
||||||
app = rok.create_app(APP_NAME, cfg)
|
app = rok.create_app(APP_NAME, cfg)
|
||||||
else:
|
else:
|
||||||
log.error(f"No UI flavor for '{UI_FLAVOR}'")
|
log.error("No UI flavor for '%s'" % UI_FLAVOR)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue