Skip to content
This repository was archived by the owner on Feb 19, 2026. It is now read-only.
This repository was archived by the owner on Feb 19, 2026. It is now read-only.

Test that generated notebook conform to black, isort and pylint #75

Description

@lukany

Black, isort and pylint are used to enforce code style in edvart. However, there is no code style check for generated code by edvart. This could be added to edvart's tests.

See below for an example how to check generated code via black:

import tempfile
import nbformat as nbf

from black import Mode, format_file_contents

handle, file = tempfile.mkstemp(suffix='.ipynb')
nbf.write(nb, file)

with open(file, "rw") as f:
    format_file_contents(f.read(), fast=False, mode=Mode())

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

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions