Skip to content

Papermill provider enable logging from notebook to be visible in task's log. #35408

Description

@wno-xyt

Description

Function execute_notebook in papermill accepts named parameter log_output:
execute_notebook(nb, kernel_name, output_path=None, progress_bar=True, log_output=False, autosave_cell_every=30, **kwargs)

Unfortunatelly currently the interface of the provider package does not allow setting it to True.
It would be great to have this possibility to have logs from executed notebook visible in airflow's task log.
If I understand correctly how this works setting log_output=True would just make papermill to use configured logger (in this case airflow's) for the output of the notebook.

Use case/motivation

I think it would be nice to have logs from notebooks execution visible in airflow task log to be able to:

  • monitor progress
  • catch errors coming from inside the notebook easier

Related issues

No response

Are you willing to submit a PR?

  • Yes I am willing to submit a PR!

Code of Conduct

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions