Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Apr 1, 2024
1 parent 6f7e6d8 commit 2c04e5d
Show file tree
Hide file tree
Showing 12 changed files with 36 additions and 29 deletions.
1 change: 1 addition & 0 deletions nbformat/_struct.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Can probably be replaced by types.SimpleNamespace from Python 3.3
"""

from __future__ import annotations

from typing import Any, Dict
Expand Down
1 change: 1 addition & 0 deletions nbformat/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""The version information for nbformat."""

# Use "hatchling version xx.yy.zz" to handle version changes
from __future__ import annotations

Expand Down
1 change: 1 addition & 0 deletions nbformat/corpus/words.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Generate a corpus id."""

from __future__ import annotations

import uuid
Expand Down
1 change: 1 addition & 0 deletions nbformat/json_compat.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Common validator wrapper to provide a uniform usage of other schema validation
libraries.
"""

# Copyright (c) Jupyter Development Team.
# Distributed under the terms of the Modified BSD License.
from __future__ import annotations
Expand Down
1 change: 1 addition & 0 deletions nbformat/notebooknode.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""NotebookNode - adding attribute access to dicts"""

from __future__ import annotations

from collections.abc import Mapping
Expand Down
4 changes: 2 additions & 2 deletions nbformat/v2/nbxml.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
"""REMOVED: Read and write notebook files as XML.
"""
"""REMOVED: Read and write notebook files as XML."""

from __future__ import annotations

REMOVED_MSG = """\
Expand Down
3 changes: 1 addition & 2 deletions nbformat/v3/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
"""The main API for the v3 notebook format.
"""
"""The main API for the v3 notebook format."""

# Copyright (c) IPython Development Team.
# Distributed under the terms of the Modified BSD License.
Expand Down
1 change: 1 addition & 0 deletions nbformat/validator.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Notebook format validators."""

# Copyright (c) IPython Development Team.
# Distributed under the terms of the Modified BSD License.
from __future__ import annotations
Expand Down
1 change: 1 addition & 0 deletions nbformat/warnings.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Warnings that can be emitted by nbformat.
"""

from __future__ import annotations


Expand Down
46 changes: 23 additions & 23 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
{
"name": "nbformat-schema",
"version": "5.10.3",
"description": "JSON schemata for Jupyter notebook formats",
"main": "index.js",
"files": [
"nbformat/v3/nbformat.v3.schema.json",
"nbformat/v4/nbformat.v4.schema.json"
],
"repository": {
"type": "git",
"url": "git+https://github.com/jupyter/nbformat.git"
},
"keywords": [
"jupyter",
"notebook",
"json-schema"
],
"author": "Project Jupyter Contributors",
"license": "BSD-3-Clause",
"bugs": {
"url": "https://github.com/jupyter/nbformat/issues"
},
"homepage": "https://nbformat.readthedocs.io"
"name": "nbformat-schema",
"version": "5.10.3",
"description": "JSON schemata for Jupyter notebook formats",
"main": "index.js",
"files": [
"nbformat/v3/nbformat.v3.schema.json",
"nbformat/v4/nbformat.v4.schema.json"
],
"repository": {
"type": "git",
"url": "git+https://github.com/jupyter/nbformat.git"
},
"keywords": [
"jupyter",
"notebook",
"json-schema"
],
"author": "Project Jupyter Contributors",
"license": "BSD-3-Clause",
"bugs": {
"url": "https://github.com/jupyter/nbformat/issues"
},
"homepage": "https://nbformat.readthedocs.io"
}
4 changes: 2 additions & 2 deletions tests/v4/test_json.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,6 @@ def test_latest_matches_nbformat(self):
os.path.join(BASE_PATH, "nbformat.v4.schema.json"), encoding="utf-8"
) as schema_file:
schema = json.load(schema_file)
assert schema["description"] == "Jupyter Notebook v{major}.{minor} JSON schema.".format(
major=nbformat, minor=nbformat_minor
assert (
schema["description"] == f"Jupyter Notebook v{nbformat}.{nbformat_minor} JSON schema."
)
1 change: 1 addition & 0 deletions tests/v4/test_nbbase.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
"""Tests for the Python API for composing notebook elements"""

from __future__ import annotations

from nbformat.v4.nbbase import (
Expand Down

0 comments on commit 2c04e5d

Please sign in to comment.