Skip to content

Commit

Permalink
Add flake8 and git-blame-ignore-revs (#6337)
Browse files Browse the repository at this point in the history
  • Loading branch information
blink1073 authored Apr 1, 2022
1 parent a7717d9 commit 0390be2
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 22 deletions.
2 changes: 2 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Run auto-formatters: https://github.com/jupyter/notebook/pull/6335
a7717d90f128368296fe3434deba5acd6031edab
20 changes: 10 additions & 10 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,16 +33,16 @@ repos:
files: \.py$
args: [--profile=black]

# - repo: https://github.com/pycqa/flake8
# rev: 4.0.1
# hooks:
# - id: flake8
# additional_dependencies:
# [
# "flake8-bugbear==20.1.4",
# "flake8-logging-format==0.6.0",
# "flake8-implicit-str-concat==0.2.0",
# ]
- repo: https://github.com/pycqa/flake8
rev: 4.0.1
hooks:
- id: flake8
additional_dependencies:
[
"flake8-bugbear==20.1.4",
"flake8-logging-format==0.6.0",
"flake8-implicit-str-concat==0.2.0",
]

- repo: https://github.com/sirosen/check-jsonschema
rev: 0.10.2
Expand Down
13 changes: 2 additions & 11 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -256,16 +256,7 @@

# -- Options for LaTeX output ---------------------------------------------

latex_elements = {
# The paper size ('letterpaper' or 'a4paper').
#'papersize': 'letterpaper',
# The font size ('10pt', '11pt' or '12pt').
#'pointsize': '10pt',
# Additional stuff for the LaTeX preamble.
#'preamble': '',
# Latex figure (float) alignment
#'figure_align': 'htbp',
}
latex_elements = {}

# Grouping the document tree into LaTeX files. List of tuples
# (source start file, target name, title,
Expand Down Expand Up @@ -313,7 +304,7 @@

# -- Options for link checks ----------------------------------------------

linkcheck_ignore = ["http://127\.0\.0\.1/*"]
linkcheck_ignore = [r"http://127\.0\.0\.1/*"]


# -- Options for Texinfo output -------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion notebook/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from ._version import __version__
from ._version import __version__ # noqa


def _jupyter_server_extension_paths():
Expand Down
14 changes: 14 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,17 @@ test =
[options.entry_points]
console_scripts =
jupyter-notebook = notebook.app:main

[flake8]
ignore = E501, W503, E402
builtins = c, get_config
exclude =
.cache,
.github,
docs,
setup.py
enable-extensions = G
extend-ignore =
G001, G002, G004, G200, G201, G202,
# black adds spaces around ':'
E203,

0 comments on commit 0390be2

Please sign in to comment.