akshaychitneni commented on code in PR #34840: URL: https://github.com/apache/airflow/pull/34840#discussion_r1359945002
########## airflow/providers/papermill/operators/papermill.py: ########## @@ -20,14 +20,97 @@ from typing import TYPE_CHECKING, ClassVar, Collection, Sequence import attr +from papermill.utils import remove_args, merge_kwargs +from pydantic import typing + import papermill as pm +from papermill.engines import NBClientEngine +from papermill.clientwrap import PapermillNotebookClient +from jupyter_client.manager import AsyncKernelManager +from jupyter_client.client import KernelClient +from traitlets import Unicode from airflow.lineage.entities import File from airflow.models import BaseOperator if TYPE_CHECKING: from airflow.utils.context import Context +JUPYTER_KERNEL_SHELL_PORT = 60316 +JUPYTER_KERNEL_IOPUB_PORT = 60317 +JUPYTER_KERNEL_STDIN_PORT = 60318 +JUPYTER_KERNEL_CONTROL_PORT = 60319 +JUPYTER_KERNEL_HB_PORT = 60320 +LOCALHOST = '127.0.0.1' +REMOTE_KERNEL_ENGINE = "remote_kernel_engine" + + +class RemoteKernelManager(AsyncKernelManager): Review Comment: Thanks for the recommendation. I have updated to use hook to connect to remote kernel. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@airflow.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org