Skip to content

Commit d6a8168

Browse files
committed
run auto formatters
1 parent a9c39b3 commit d6a8168

37 files changed

+1593
-1501
lines changed

.github/workflows/codeql-analysis.yml

Lines changed: 31 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -14,16 +14,15 @@ name: "CodeQL"
1414

1515
on:
1616
push:
17-
branches: [ master ]
17+
branches: [master]
1818
pull_request:
1919
# The branches below must be a subset of the branches above
20-
branches: [ master ]
20+
branches: [master]
2121
schedule:
22-
- cron: '41 6 * * 6'
22+
- cron: "41 6 * * 6"
2323

2424
permissions:
25-
security-events:
26-
write
25+
security-events: write
2726

2827
jobs:
2928
analyze:
@@ -33,41 +32,41 @@ jobs:
3332
strategy:
3433
fail-fast: false
3534
matrix:
36-
language: ['python' ]
35+
language: ["python"]
3736
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
3837
# Learn more...
3938
# https://docs.github.com/en/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#overriding-automatic-language-detection
4039

4140
steps:
42-
- name: Checkout repository
43-
uses: actions/checkout@v2
41+
- name: Checkout repository
42+
uses: actions/checkout@v2
4443

45-
# Initializes the CodeQL tools for scanning.
46-
- name: Initialize CodeQL
47-
uses: github/codeql-action/init@v1
48-
with:
49-
languages: ${{ matrix.language }}
50-
# If you wish to specify custom queries, you can do so here or in a config file.
51-
# By default, queries listed here will override any specified in a config file.
52-
# Prefix the list here with "+" to use these queries and those in the config file.
53-
# queries: ./path/to/local/query, your-org/your-repo/queries@main
54-
queries: security-and-quality
44+
# Initializes the CodeQL tools for scanning.
45+
- name: Initialize CodeQL
46+
uses: github/codeql-action/init@v1
47+
with:
48+
languages: ${{ matrix.language }}
49+
# If you wish to specify custom queries, you can do so here or in a config file.
50+
# By default, queries listed here will override any specified in a config file.
51+
# Prefix the list here with "+" to use these queries and those in the config file.
52+
# queries: ./path/to/local/query, your-org/your-repo/queries@main
53+
queries: security-and-quality
5554

56-
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
57-
# If this step fails, then you should remove it and run the build manually (see below)
58-
- name: Autobuild
59-
uses: github/codeql-action/autobuild@v1
55+
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
56+
# If this step fails, then you should remove it and run the build manually (see below)
57+
- name: Autobuild
58+
uses: github/codeql-action/autobuild@v1
6059

61-
# ℹ️ Command-line programs to run using the OS shell.
62-
# 📚 https://git.io/JvXDl
60+
# ℹ️ Command-line programs to run using the OS shell.
61+
# 📚 https://git.io/JvXDl
6362

64-
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
65-
# and modify them (or add more) to build your code if your project
66-
# uses a compiled language
63+
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
64+
# and modify them (or add more) to build your code if your project
65+
# uses a compiled language
6766

68-
#- run: |
69-
# make bootstrap
70-
# make release
67+
#- run: |
68+
# make bootstrap
69+
# make release
7170

72-
- name: Perform CodeQL Analysis
73-
uses: github/codeql-action/analyze@v1
71+
- name: Perform CodeQL Analysis
72+
uses: github/codeql-action/analyze@v1

.github/workflows/test.yml

Lines changed: 31 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,10 @@ name: Python package
66
on:
77
push:
88
pull_request:
9-
branches: [ "master" ]
9+
branches: ["master"]
1010

1111
jobs:
1212
build:
13-
1413
runs-on: ${{ matrix.os }}
1514
strategy:
1615
fail-fast: false
@@ -22,33 +21,33 @@ jobs:
2221
- os: windows-latest
2322
python-version: 3.10-dev
2423
steps:
25-
- uses: actions/checkout@v2
26-
- name: Set up Python ${{ matrix.python-version }}
27-
uses: actions/setup-python@v2
28-
with:
29-
python-version: ${{ matrix.python-version }}
30-
- name: Get pip cache dir
31-
id: pip-cache
32-
run: |
33-
echo "::set-output name=dir::$(pip cache dir)"
34-
- name: pip cache
35-
uses: actions/cache@v2
36-
with:
37-
path: ${{ steps.pip-cache.outputs.dir }}
38-
key: |
39-
${{ runner.os }}-pip-${{ matrix.python-version }}-${{ hashFiles('dev-requirements.txt', 'setup.cfg') }}
40-
restore-keys: |
41-
${{ runner.os }}-pip-${{ matrix.python-version }}-
42-
${{ runner.os }}-pip-
43-
- name: Install dependencies
44-
run: |
45-
python -m pip install --upgrade pip
46-
pip install --upgrade setuptools wheel
47-
pip install -r dev-requirements.txt .
48-
- name: Test with pytest
49-
run: |
50-
pytest -vv jupyter_core --timeout 60 --cov jupyter_core --cov-report term-missing:skip-covered
51-
- name: Check manifest
52-
run: |
53-
pip install check-manifest
54-
check-manifest -v
24+
- uses: actions/checkout@v2
25+
- name: Set up Python ${{ matrix.python-version }}
26+
uses: actions/setup-python@v2
27+
with:
28+
python-version: ${{ matrix.python-version }}
29+
- name: Get pip cache dir
30+
id: pip-cache
31+
run: |
32+
echo "::set-output name=dir::$(pip cache dir)"
33+
- name: pip cache
34+
uses: actions/cache@v2
35+
with:
36+
path: ${{ steps.pip-cache.outputs.dir }}
37+
key: |
38+
${{ runner.os }}-pip-${{ matrix.python-version }}-${{ hashFiles('dev-requirements.txt', 'setup.cfg') }}
39+
restore-keys: |
40+
${{ runner.os }}-pip-${{ matrix.python-version }}-
41+
${{ runner.os }}-pip-
42+
- name: Install dependencies
43+
run: |
44+
python -m pip install --upgrade pip
45+
pip install --upgrade setuptools wheel
46+
pip install -r dev-requirements.txt .
47+
- name: Test with pytest
48+
run: |
49+
pytest -vv jupyter_core --timeout 60 --cov jupyter_core --cov-report term-missing:skip-covered
50+
- name: Check manifest
51+
run: |
52+
pip install check-manifest
53+
check-manifest -v

.pre-commit-config.yaml

Lines changed: 34 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -6,41 +6,41 @@ repos:
66
rev: v4.1.0
77
hooks:
88
- id: debug-statements
9-
# - id: end-of-file-fixer
10-
# - id: check-case-conflict
11-
# - id: check-executables-have-shebangs
12-
# - id: requirements-txt-fixer
13-
# - id: check-added-large-files
14-
# - id: check-case-conflict
15-
# - id: check-toml
16-
# - id: check-yaml
17-
# - id: forbid-new-submodules
18-
# - id: check-builtin-literals
19-
# - id: trailing-whitespace
9+
- id: end-of-file-fixer
10+
- id: check-case-conflict
11+
- id: check-executables-have-shebangs
12+
- id: requirements-txt-fixer
13+
- id: check-added-large-files
14+
- id: check-case-conflict
15+
- id: check-toml
16+
- id: check-yaml
17+
- id: forbid-new-submodules
18+
- id: check-builtin-literals
19+
- id: trailing-whitespace
2020

21-
# - repo: https://github.com/psf/black
22-
# rev: 22.3.0
23-
# hooks:
24-
# - id: black
25-
# args: ["--line-length", "100"]
21+
- repo: https://github.com/psf/black
22+
rev: 22.3.0
23+
hooks:
24+
- id: black
25+
args: ["--line-length", "100"]
2626

27-
# - repo: https://github.com/PyCQA/isort
28-
# rev: 5.10.1
29-
# hooks:
30-
# - id: isort
31-
# files: \.py$
32-
# args: [--profile=black]
27+
- repo: https://github.com/PyCQA/isort
28+
rev: 5.10.1
29+
hooks:
30+
- id: isort
31+
files: \.py$
32+
args: [--profile=black]
3333

34-
# - repo: https://github.com/pre-commit/mirrors-prettier
35-
# rev: v2.6.2
36-
# hooks:
37-
# - id: prettier
34+
- repo: https://github.com/pre-commit/mirrors-prettier
35+
rev: v2.6.2
36+
hooks:
37+
- id: prettier
3838

39-
# - repo: https://github.com/asottile/pyupgrade
40-
# rev: v2.31.1
41-
# hooks:
42-
# - id: pyupgrade
43-
# args: [--py37-plus]
39+
- repo: https://github.com/asottile/pyupgrade
40+
rev: v2.31.1
41+
hooks:
42+
- id: pyupgrade
43+
args: [--py37-plus]
4444

4545
- repo: https://github.com/PyCQA/doc8
4646
rev: 0.11.1
@@ -59,10 +59,10 @@ repos:
5959
# "flake8-implicit-str-concat==0.2.0",
6060
# ]
6161

62-
# - repo: https://github.com/pre-commit/mirrors-eslint
63-
# rev: v8.12.0
62+
# - repo: https://github.com/pre-commit/mirrors-mypy
63+
# rev: v0.942
6464
# hooks:
65-
# - id: eslint
65+
# - id: mypy
6666

6767
- repo: https://github.com/sirosen/check-jsonschema
6868
rev: 0.14.2

COPYING.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ software without specific prior written permission.
2424
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
2525
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
2626
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
27-
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
27+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
2828
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
2929
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
3030
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
@@ -35,7 +35,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
3535
## About the Jupyter Development Team
3636

3737
The Jupyter Development Team is the set of all contributors to the Jupyter
38-
project. This includes all of the Jupyter subprojects. A full list with
38+
project. This includes all of the Jupyter subprojects. A full list with
3939
details is kept in the documentation directory, in the file
4040
`about/credits.txt`.
4141

@@ -48,8 +48,8 @@ Jupyter uses a shared copyright model. Each contributor maintains copyright
4848
over their contributions to Jupyter. It is important to note that these
4949
contributions are typically only changes to the repositories. Thus, the Jupyter
5050
source code in its entirety is not the copyright of any single person or
51-
institution. Instead, it is the collective copyright of the entire Jupyter
52-
Development Team. If individual contributors want to maintain a record of what
51+
institution. Instead, it is the collective copyright of the entire Jupyter
52+
Development Team. If individual contributors want to maintain a record of what
5353
changes/contributions they have specific copyright on, they should indicate
5454
their copyright in the commit message of the change, when they commit the
5555
change to one of the Jupyter repositories.

README.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ Core common functionality of Jupyter projects.
55
This package contains base application classes and configuration inherited by other projects.
66
It doesn't do much on its own.
77

8-
98
# Development Setup
109

1110
The [Jupyter Contributor Guides](http://jupyter.readthedocs.io/en/latest/contributor/content-contributor.html) provide extensive information on contributing code or documentation to Jupyter projects. The limited instructions below for setting up a development environment are for your convenience.
@@ -23,8 +22,8 @@ and download the dependencies of code and test suite by executing:
2322

2423
The last command runs the test suite to verify the setup. During development, you can pass filenames to `py.test`, and it will execute only those tests.
2524

26-
2725
## Code Styling
26+
2827
`jupyter_core` has adopted automatic code formatting so you shouldn't
2928
need to worry too much about your code style.
3029
As long as your code is valid,
@@ -69,5 +68,4 @@ The following commands build the documentation in HTML format and check for brok
6968

7069
Point your browser to the following URL to access the generated documentation:
7170

72-
_file:///my/projects/jupyter\_core/docs/\_build/html/index.html_
73-
71+
_file:///my/projects/jupyter_core/docs/\_build/html/index.html_

dev-requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
ipykernel
2+
pre-commit
23
pytest
34
pytest-cov
45
pytest-timeout
5-
pre-commit

0 commit comments

Comments
 (0)