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

chore: update pre-commit hooks #403

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
14 changes: 7 additions & 7 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ ci:

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0
rev: v5.0.0
hooks:
- id: check-case-conflict
- id: check-ast
Expand All @@ -21,12 +21,12 @@ repos:
- id: trailing-whitespace

- repo: https://github.com/python-jsonschema/check-jsonschema
rev: 0.28.4
rev: 0.30.0
hooks:
- id: check-github-workflows

- repo: https://github.com/executablebooks/mdformat
rev: 0.7.17
rev: 0.7.19
hooks:
- id: mdformat

Expand All @@ -37,7 +37,7 @@ repos:
types_or: [yaml, html, json]

- repo: https://github.com/adamchainz/blacken-docs
rev: "1.16.0"
rev: "1.19.1"
hooks:
- id: blacken-docs
additional_dependencies: [black==23.7.0]
Expand All @@ -56,7 +56,7 @@ repos:
- id: rst-inline-touching-normal

- repo: https://github.com/pre-commit/mirrors-mypy
rev: "v1.10.0"
rev: "v1.13.0"
hooks:
- id: mypy
files: "^nbformat"
Expand All @@ -65,7 +65,7 @@ repos:
["jsonschema>=2.6", "traitlets>=5.13", "jupyter_core>5.4"]

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.4.7
rev: v0.8.1
hooks:
- id: ruff
types_or: [python, jupyter]
Expand All @@ -76,7 +76,7 @@ repos:
types_or: [python, jupyter]

- repo: https://github.com/scientific-python/cookie
rev: "2024.04.23"
rev: "2024.08.19"
hooks:
- id: sp-repo-review
additional_dependencies: ["repo-review[cli]"]
10 changes: 5 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -318,11 +318,11 @@ sure to generate valid notebooks.

## 5.0.8

- Add optional support for using \[fastjsonschema\]{.title-ref} as the
- Add optional support for using [fastjsonschema]{.title-ref} as the
JSON validation library. To enable fast validation, install
\[fastjsonschema\]{.title-ref} and set the environment variable
\[NBFORMAT_VALIDATOR\]{.title-ref} to the value
\[fastjsonschema\]{.title-ref}.
[fastjsonschema]{.title-ref} and set the environment variable
[NBFORMAT_VALIDATOR]{.title-ref} to the value
[fastjsonschema]{.title-ref}.

## 5.0.7

Expand Down Expand Up @@ -397,7 +397,7 @@ sure to generate valid notebooks.
database.
- Dict-like objects added to NotebookNode attributes are now
transformed to be NotebookNode objects; transformation also works
for \[.update()\]{.title-ref}.
for [.update()]{.title-ref}.

## 4.3

Expand Down
22 changes: 11 additions & 11 deletions nbformat/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,23 +16,23 @@
from .sentinel import Sentinel

__all__ = [
"versions",
"validate",
"NO_CONVERT",
"NBFormatError",
"NotebookNode",
"Sentinel",
"ValidationError",
"__version__",
"convert",
"from_dict",
"NotebookNode",
"current_nbformat",
"current_nbformat_minor",
"NBFormatError",
"NO_CONVERT",
"reads",
"from_dict",
"read",
"writes",
"write",
"reads",
"validate",
"version_info",
"__version__",
"Sentinel",
"versions",
"write",
"writes",
]

versions = {
Expand Down
32 changes: 16 additions & 16 deletions nbformat/current.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,32 +47,32 @@
)

__all__ = [
"NBFormatError",
"NotebookNode",
"convert",
"nbformat",
"nbformat_minor",
"nbformat_schema",
"new_author",
"new_code_cell",
"new_text_cell",
"new_heading_cell",
"new_metadata",
"new_notebook",
"new_output",
"new_text_cell",
"new_worksheet",
"parse_filename",
"new_metadata",
"new_author",
"new_heading_cell",
"nbformat",
"nbformat_minor",
"nbformat_schema",
"to_notebook_json",
"convert",
"validate",
"NBFormatError",
"parse_py",
"read",
"reads",
"reads_json",
"writes_json",
"reads_py",
"writes_py",
"reads",
"writes",
"read",
"to_notebook_json",
"validate",
"write",
"writes",
"writes_json",
"writes_py",
]

current_nbformat = nbformat
Expand Down
6 changes: 3 additions & 3 deletions nbformat/json_compat.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@
from jsonschema.exceptions import ErrorTree, ValidationError

__all__ = [
"ValidationError",
"JsonSchemaValidator",
"VALIDATORS",
"FastJsonSchemaValidator",
"JsonSchemaValidator",
"ValidationError",
"get_current_validator",
"VALIDATORS",
]


Expand Down
32 changes: 16 additions & 16 deletions nbformat/v3/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,30 +6,30 @@

__all__ = [
"NotebookNode",
"downgrade",
"nbformat",
"nbformat_minor",
"nbformat_schema",
"new_author",
"new_code_cell",
"new_text_cell",
"new_heading_cell",
"new_metadata",
"new_notebook",
"new_output",
"new_text_cell",
"new_worksheet",
"new_metadata",
"new_author",
"new_heading_cell",
"nbformat",
"nbformat_minor",
"nbformat_schema",
"reads_json",
"writes_json",
"parse_filename",
"read_json",
"write_json",
"to_notebook_json",
"reads_py",
"writes_py",
"read_py",
"write_py",
"reads_json",
"reads_py",
"to_notebook_json",
"to_notebook_py",
"downgrade",
"upgrade",
"parse_filename",
"write_json",
"write_py",
"writes_json",
"writes_py",
]

import os
Expand Down
6 changes: 3 additions & 3 deletions nbformat/v4/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,20 @@
from __future__ import annotations

__all__ = [
"downgrade",
"nbformat",
"nbformat_minor",
"nbformat_schema",
"new_code_cell",
"new_markdown_cell",
"new_raw_cell",
"new_notebook",
"new_output",
"new_raw_cell",
"output_from_msg",
"reads",
"writes",
"to_notebook",
"downgrade",
"upgrade",
"writes",
]

from .convert import downgrade, upgrade
Expand Down
6 changes: 3 additions & 3 deletions nbformat/validator.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@


__all__ = [
"NotebookValidationError",
"ValidationError",
"better_validation_error",
"get_validator",
"isvalid",
"NotebookValidationError",
"better_validation_error",
"iter_validate",
"normalize",
"validate",
"iter_validate",
]


Expand Down
Loading