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

Upgrade pip to 24.2 and support for python 3.12 #126

Merged
merged 20 commits into from
Sep 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
5ab9b3a
Added docs server script, dark mode & copybutton for docs
OmkarPh Oct 18, 2023
af7e542
Merge pull request #83 from OmkarPh/enhance/docs
AyanSinhaMahapatra Oct 18, 2023
0a9d983
Update CSS to widen page and handle mobile #84
johnmhoran Nov 21, 2023
4e36fc6
Delete theme_overrides_SUPERSEDED.css as no longer needed #84
johnmhoran Jan 16, 2024
7d74b8a
Fix top padding for rst content
AyanSinhaMahapatra Jan 18, 2024
0071028
Merge pull request #85 from nexB/84-widen-rtd-page
AyanSinhaMahapatra Jan 18, 2024
008d521
Update CI runners and python version
AyanSinhaMahapatra Feb 19, 2024
acf94b3
Merge pull request #87 from nexB/update-macos-runners
AyanSinhaMahapatra Feb 19, 2024
124da3d
Replace deprecated macos CI runners
AyanSinhaMahapatra Jul 1, 2024
be4e14d
Update minimum required python version to 3.8
AyanSinhaMahapatra Jul 1, 2024
5c3e935
Merge pull request #90 from nexB/update-ci-runners
keshav-space Jul 1, 2024
9c57f34
Update link references of ownership from nexB to aboutcode-org
chinyeungli Aug 20, 2024
fdc425a
Merge remote-tracking branch 'skeleton/main' into skeleton-update
keshav-space Sep 10, 2024
e870e2a
Remove macos-14 runner
keshav-space Sep 10, 2024
a73c35b
Upgrade pip to 24.2
keshav-space Sep 10, 2024
b425fb8
Remove deprecated pseudo VCS URLs
keshav-space Sep 10, 2024
ab7a6bc
Remove pycache files while cleaning
keshav-space Sep 10, 2024
1a7288b
Drop support for python 3.6 and 3.7
keshav-space Sep 11, 2024
01b1664
Move release data to separate JSON files
keshav-space Sep 11, 2024
5283ef7
Apply black and isort formatting
keshav-space Sep 11, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
5 changes: 1 addition & 4 deletions .github/workflows/docs-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on: [push, pull_request]

jobs:
build:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04

strategy:
max-parallel: 4
Expand All @@ -20,9 +20,6 @@ jobs:
with:
python-version: ${{ matrix.python-version }}

- name: Give permission to run scripts
run: chmod +x ./docs/scripts/doc8_style_check.sh

- name: Install Dependencies
run: pip install -e .[docs]

Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/pypi-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ on:
jobs:
build-pypi-distribs:
name: Build and publish library to PyPI
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v4
with:
Expand All @@ -47,7 +47,7 @@ jobs:
name: Create GH release
needs:
- build-pypi-distribs
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04

steps:
- name: Download built archives
Expand All @@ -67,7 +67,7 @@ jobs:
name: Create PyPI release
needs:
- create-gh-release
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04

steps:
- name: Download built archives
Expand Down
14 changes: 8 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# ScanCode is a trademark of nexB Inc.
# SPDX-License-Identifier: Apache-2.0
# See http://www.apache.org/licenses/LICENSE-2.0 for the license text.
# See https://github.com/nexB/skeleton for support or download.
# See https://github.com/aboutcode-org/skeleton for support or download.
# See https://aboutcode.org for more information about nexB OSS projects.
#

Expand All @@ -19,11 +19,11 @@ dev:

isort:
@echo "-> Apply isort changes to ensure proper imports ordering"
${VENV}/bin/isort --sl -l 100 src tests setup.py
${VENV}/bin/isort --sl -l 100 --skip=src/fetchcode/vcs/pip setup.py src tests

black:
@echo "-> Apply black code formatter"
${VENV}/bin/black -l 100 src tests setup.py
${VENV}/bin/black -l 100 --exclude=src/fetchcode/vcs/pip src tests setup.py

doc8:
@echo "-> Run doc8 validation"
Expand All @@ -33,15 +33,17 @@ valid: isort black

check:
@echo "-> Run pycodestyle (PEP8) validation"
@${ACTIVATE} pycodestyle --max-line-length=100 --exclude=.eggs,venv,lib,thirdparty,docs,migrations,settings.py,.cache .
@${ACTIVATE} pycodestyle --max-line-length=100 --exclude=.eggs,venv,lib,thirdparty,docs,migrations,settings.py,.cache,etc,src/fetchcode/vcs/pip,tests/data/ .
@echo "-> Run isort imports ordering validation"
@${ACTIVATE} isort --sl --check-only -l 100 setup.py src tests .
@${ACTIVATE} isort --sl --check-only -l 100 --skip=src/fetchcode/vcs/pip setup.py src tests
@echo "-> Run black validation"
@${ACTIVATE} black --check --check -l 100 src tests setup.py
@${ACTIVATE} black --check --check -l 100 --exclude=src/fetchcode/vcs/pip src tests setup.py

clean:
@echo "-> Clean the Python env"
./configure --clean
rm -rf .venv/ .*cache/ *.egg-info/ build/ dist/
find . -type f -name '*.py[co]' -delete -o -type d -name __pycache__ -delete

test:
@echo "-> Run the test suite"
Expand Down
92 changes: 50 additions & 42 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,50 +5,58 @@
################################################################################

jobs:
- template: etc/ci/azure-posix.yml
parameters:
job_name: ubuntu20_cpython
image_name: ubuntu-20.04
python_versions: ["3.7", "3.8", "3.9", "3.10", "3.11"]
test_suites:
all: venv/bin/pytest -n 2 -vvs
- template: etc/ci/azure-posix.yml
parameters:
job_name: ubuntu20_cpython
image_name: ubuntu-20.04
python_versions: ['3.8', '3.9', '3.10', '3.11', '3.12']
test_suites:
all: venv/bin/pytest -n 2 -vvs

- template: etc/ci/azure-posix.yml
parameters:
job_name: ubuntu22_cpython
image_name: ubuntu-22.04
python_versions: ["3.7", "3.8", "3.9", "3.10", "3.11"]
test_suites:
all: venv/bin/pytest -n 2 -vvs
- template: etc/ci/azure-posix.yml
parameters:
job_name: ubuntu22_cpython
image_name: ubuntu-22.04
python_versions: ['3.8', '3.9', '3.10', '3.11', '3.12']
test_suites:
all: venv/bin/pytest -n 2 -vvs

- template: etc/ci/azure-posix.yml
parameters:
job_name: macos12_cpython
image_name: macOS-12
python_versions: ["3.7", "3.8", "3.9", "3.10", "3.11"]
test_suites:
all: venv/bin/pytest -n 2 -vvs
- template: etc/ci/azure-posix.yml
parameters:
job_name: macos12_cpython
image_name: macOS-12
python_versions: ['3.8', '3.9', '3.10', '3.11', '3.12']
test_suites:
all: venv/bin/pytest -n 2 -vvs

- template: etc/ci/azure-posix.yml
parameters:
job_name: macos13_cpython
image_name: macOS-13
python_versions: ["3.7", "3.8", "3.9", "3.10", "3.11"]
test_suites:
all: venv/bin/pytest -n 2 -vvs
- template: etc/ci/azure-posix.yml
parameters:
job_name: macos13_cpython
image_name: macOS-13
python_versions: ['3.8', '3.9', '3.10', '3.11', '3.12']
test_suites:
all: venv/bin/pytest -n 2 -vvs

- template: etc/ci/azure-win.yml
parameters:
job_name: win2019_cpython
image_name: windows-2019
python_versions: ["3.7", "3.8", "3.9", "3.10", "3.11"]
test_suites:
all: venv\Scripts\pytest -n 2 -vvs
- template: etc/ci/azure-posix.yml
parameters:
job_name: macos14_cpython_arm64
image_name: macOS-14
python_versions: ['3.8', '3.9', '3.10', '3.11', '3.12']
test_suites:
all: venv/bin/pytest -n 2 -vvs

- template: etc/ci/azure-win.yml
parameters:
job_name: win2022_cpython
image_name: windows-2022
python_versions: ["3.7", "3.8", "3.9", "3.10", "3.11"]
test_suites:
all: venv\Scripts\pytest -n 2 -vvs
- template: etc/ci/azure-win.yml
parameters:
job_name: win2019_cpython
image_name: windows-2019
python_versions: ['3.8', '3.9', '3.10', '3.11', '3.12']
test_suites:
all: venv\Scripts\pytest -n 2 -vvs

- template: etc/ci/azure-win.yml
parameters:
job_name: win2022_cpython
image_name: windows-2022
python_versions: ['3.8', '3.9', '3.10', '3.11', '3.12']
test_suites:
all: venv\Scripts\pytest -n 2 -vvs
8 changes: 8 additions & 0 deletions docs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SPHINXAUTOBUILD = sphinx-autobuild
SOURCEDIR = source
BUILDDIR = build

Expand All @@ -14,6 +15,13 @@ help:

.PHONY: help Makefile

# Run the development server using sphinx-autobuild
docs:
@echo
@echo "Starting up the docs server..."
@echo
$(SPHINXAUTOBUILD) --port 8000 --watch ${SOURCEDIR} $(SOURCEDIR) "$(BUILDDIR)/html" $(SPHINXOPTS) $(O)

# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
Expand Down
12 changes: 12 additions & 0 deletions docs/make.bat
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,16 @@ REM Command file for Sphinx documentation
if "%SPHINXBUILD%" == "" (
set SPHINXBUILD=sphinx-build
)
if "%SPHINXAUTOBUILD%" == "" (
set SPHINXAUTOBUILD=sphinx-autobuild
)
set SOURCEDIR=source
set BUILDDIR=build

if "%1" == "" goto help

if "%1" == "docs" goto docs

%SPHINXBUILD% >NUL 2>NUL
if errorlevel 9009 (
echo.
Expand All @@ -28,6 +33,13 @@ if errorlevel 9009 (
%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
goto end

:docs
@echo
@echo Starting up the docs server...
@echo
%SPHINXAUTOBUILD% --port 8000 --watch %SOURCEDIR% %SOURCEDIR% %BUILDDIR%\html %SPHINXOPTS% %O%
goto end

:help
%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%

Expand Down
Empty file modified docs/scripts/doc8_style_check.sh
100644 → 100755
Empty file.
Loading
Loading