Skip to content

Commit

Permalink
Merge branch 'master' into epypj
Browse files Browse the repository at this point in the history
  • Loading branch information
Thrameos committed Feb 10, 2024
2 parents d691207 + 4471a27 commit 5c70502
Show file tree
Hide file tree
Showing 232 changed files with 4,528 additions and 2,986 deletions.
59 changes: 33 additions & 26 deletions .azure/build.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# JPype CI pipeline
pr:
trigger:
branches:
include:
- master
Expand All @@ -22,68 +22,75 @@ variables:
jobs:
- job: Deps
pool:
vmImage: "ubuntu-16.04"
vmImage: "ubuntu-latest"
steps:
- template: scripts/ivy.yml

- job: Documentation
pool:
vmImage: "ubuntu-16.04"
vmImage: "ubuntu-latest"
steps:
- template: scripts/documentation.yml

- job: Coverage
pool:
vmImage: "ubuntu-16.04"
vmImage: "ubuntu-latest"
dependsOn: Deps
steps:
- template: scripts/deps.yml
- template: scripts/coverage.yml

- job: Tracing
pool:
vmImage: "ubuntu-16.04"
vmImage: "ubuntu-latest"
steps:
- template: scripts/tracing.yml

- job: Test
dependsOn: Deps
strategy:
matrix:
linux-3.5:
imageName: "ubuntu-16.04"
python.version: '3.5'
linux-3.6:
imageName: "ubuntu-16.04"
python.version: '3.6'
linux-3.7:
imageName: "ubuntu-16.04"
imageName: "ubuntu-latest"
python.version: '3.7'
linux-3.8:
imageName: "ubuntu-16.04"
imageName: "ubuntu-latest"
python.version: '3.8'
linux-3.9:
imageName: "ubuntu-16.04"
imageName: "ubuntu-latest"
python.version: '3.9'
windows-3.5:
imageName: "vs2017-win2016"
python.version: '3.5'
windows-3.6:
imageName: "vs2017-win2016"
python.version: '3.6'
linux-3.10:
imageName: "ubuntu-latest"
python.version: '3.10'
linux-3.11:
imageName: "ubuntu-latest"
python.version: '3.11'
linux-3.12:
imageName: "ubuntu-latest"
python.version: '3.12'
windows-3.7:
imageName: "vs2017-win2016"
imageName: "windows-2019"
python.version: '3.7'
windows-3.8:
imageName: "vs2017-win2016"
imageName: "windows-2019"
python.version: '3.8'
#windows-3.9:
#imageName: "vs2017-win2016"
#python.version: '3.9'
windows-3.9:
imageName: "windows-2019"
python.version: '3.9'
#jpypetest.fast: 'true'
windows-3.10:
imageName: "windows-2019"
python.version: '3.10'
windows-3.11:
imageName: "windows-2019"
python.version: '3.11'
windows-3.12:
imageName: "windows-2019"
python.version: '3.12'
mac-3.9:
imageName: "macos-10.14"
imageName: "macos-11"
python.version: '3.9'
jpypetest.fast: 'true'

pool:
vmImage: $(imageName)
Expand Down
2 changes: 1 addition & 1 deletion doc/doc-requirements.txt → .azure/doc-requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

# TODO: consider unpinning these?
Pygments==2.3.1
Pygments==2.15.0
docutils==0.14
commonmark==0.8.1
recommonmark==0.5.0
Expand Down
45 changes: 23 additions & 22 deletions .azure/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ stages:
jobs:
- job: SourceDistribution
pool:
vmImage: "ubuntu-16.04"
vmImage: "ubuntu-latest"
steps:
- template: scripts/sdist.yml
- template: scripts/ivy.yml
Expand All @@ -29,28 +29,24 @@ stages:
condition: eq(1,1)
strategy:
matrix:
64Bit2010:
# Disabled because it is fetching beta images
# 64Bit2014:
# arch: aarch64
# plat: manylinux2014_aarch64
# image: quay.io/pypa/manylinux2014_aarch64
# python.architecture: aarch64
64Bit:
arch: x86_64
plat: manylinux2010_x86_64
image: quay.io/pypa/manylinux2010_x86_64
python.architecture: x64
64Bit2014:
arch: aarch64
plat: manylinux2014_aarch64
image: quay.io/pypa/manylinux2014_aarch64
python.architecture: aarch64
64Bit:
arch: x86_64
plat: manylinux1_x86_64
image: quay.io/pypa/manylinux1_x86_64
python.architecture: x64
32Bit:
arch: i686
plat: manylinux1_i686
image: quay.io/pypa/manylinux1_i686
plat: manylinux2010_i686
image: quay.io/pypa/manylinux2010_i686
python.architecture: x86
pool:
vmImage: "ubuntu-16.04"
vmImage: "ubuntu-latest"
steps:
- template: scripts/deps.yml
- template: scripts/wheels-linux.yml
Expand All @@ -60,9 +56,6 @@ stages:
condition: eq(1,1)
strategy:
matrix:
Python36:
python.version: '3.6'
python.architecture: 'x64'
Python37:
python.version: '3.7'
python.architecture: 'x64'
Expand All @@ -72,8 +65,14 @@ stages:
Python39:
python.version: '3.9'
python.architecture: 'x64'
Python310:
python.version: '3.10'
python.architecture: 'x64'
Python311:
python.version: '3.11'
python.architecture: 'x64'
pool:
vmImage: 'vs2017-win2016'
vmImage: "windows-2019"
steps:
- template: scripts/deps.yml
- task: UsePythonVersion@0
Expand All @@ -92,16 +91,18 @@ stages:
python.architecture: 'x64'
strategy:
matrix:
Python36:
python.version: '3.6'
Python37:
python.version: '3.7'
Python38:
python.version: '3.8'
Python39:
python.version: '3.9'
Python310:
python.version: '3.10'
Python311:
python.version: '3.11'
pool:
vmImage: "macOS-10.14"
vmImage: "macos-11"
steps:
- template: scripts/deps.yml
- script: .azure/scripts/osx-python.sh '$(python.version)'
Expand Down
7 changes: 3 additions & 4 deletions .azure/scripts/build-wheels.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,10 @@
set -e -x

# Collect the pythons
pys=(/opt/python/*/bin)
pys=(/opt/python/cp*/bin)

# Filter out Python 3.4
pys=(${pys[@]//*34*/})
pys=(${pys[@]//*27*/})
# Exclude specific Pythons (3.6)
pys=(${pys[@]//*36*/})

# Compile wheels
for PYBIN in "${pys[@]}"; do
Expand Down
4 changes: 2 additions & 2 deletions .azure/scripts/documentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ steps:
versionSpec: '3.8'

- script: |
pip install --exists-action=w --no-cache-dir -r test-requirements.txt -r doc/doc-requirements.txt
pip install --exists-action=w --no-cache-dir -r test-requirements.txt -r .azure/doc-requirements.txt
displayName: 'Install requirements'

- script: |
python -m sphinx -T -b readthedocs -W -d _build/doctrees-readthedocs -D language=en doc build/html
python -m sphinx -T -b readthedocs -d _build/doctrees-readthedocs -D language=en doc build/html
displayName: 'Check documentation'

- task: CopyFiles@2
Expand Down
19 changes: 13 additions & 6 deletions .azure/scripts/osx-python.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,28 @@
PYTHON_VERSION="$1"

case $PYTHON_VERSION in
3.6)
FULL_VERSION=3.6.8
;;
3.7)
FULL_VERSION=3.7.9
INSTALLER_NAME=python-$FULL_VERSION-macosx10.9.pkg
;;
3.8)
FULL_VERSION=3.8.6
FULL_VERSION=3.8.10
INSTALLER_NAME=python-$FULL_VERSION-macosx10.9.pkg
;;
3.9)
FULL_VERSION=3.9.0
FULL_VERSION=3.9.12
INSTALLER_NAME=python-$FULL_VERSION-macosx10.9.pkg
;;
3.10)
FULL_VERSION=3.10.4
INSTALLER_NAME=python-$FULL_VERSION-macos11.pkg
;;
3.11)
FULL_VERSION=3.11.0
INSTALLER_NAME=python-$FULL_VERSION-macos11.pkg
;;
esac

INSTALLER_NAME=python-$FULL_VERSION-macosx10.9.pkg
URL=https://www.python.org/ftp/python/$FULL_VERSION/$INSTALLER_NAME

PY_PREFIX=/Library/Frameworks/Python.framework/Versions
Expand Down
1 change: 1 addition & 0 deletions .azure/scripts/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ steps:
version: 11

- script: |
python -m pip install --upgrade pytest setuptools
python setup.py build_ext --inplace
displayName: 'Build module'

Expand Down
3 changes: 1 addition & 2 deletions .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[bumpversion]
current_version = 1.2.2_dev0
current_version = 1.5.0_dev0
commit = True
tag = False
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)(\_(?P<release>[a-z]+)(?P<build>\d+))?
Expand Down Expand Up @@ -28,4 +28,3 @@ values =
search = Latest Changes:
replace = Latest Changes:
- **{new_version} - {now:%Y-%m-%d}**

50 changes: 50 additions & 0 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: "CodeQL"

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
schedule:
- cron: "27 1 * * 1"

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write

strategy:
fail-fast: false
matrix:
language: [ java, cpp, python ]

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
queries: +security-and-quality

- name: Autobuild
uses: github/codeql-action/autobuild@v2
if: ${{ matrix.language == 'python' }}

- name: Build cpp
run: python3 setup.py build
if: ${{ matrix.language == 'cpp' }}

- name: Build java
run: ant -f native/build.xml
if: ${{ matrix.language == 'java' }}

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
with:
category: "/language:${{ matrix.language }}"
20 changes: 20 additions & 0 deletions .github/workflows/mypy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Mypy

on: [push, pull_request]

jobs:
build:
runs-on: ubuntu-latest
name: mypy
steps:
- uses: actions/checkout@v1
- name: Set up Python 3.11
uses: actions/setup-python@v1
with:
python-version: 3.11
- name: Install Dependencies
run: |
pip install mypy numpy types-pyinstaller pytest packaging
- name: mypy
run: |
mypy ./jpype/ ./test/jpypetest/
17 changes: 14 additions & 3 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,17 @@ sphinx:

# Optionally set the version of Python and requirements required to build your docs
python:
version: 3.8
install:
- requirements: doc/requirements.txt
install:
- method: pip
path: .
extra_requirements:
- docs

build:
tools:
python: "3.8"
os: ubuntu-22.04
apt_packages:
- openjdk-8-jdk


3 changes: 2 additions & 1 deletion MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
recursive-include native *.h *.xml *.java *.jar *.class
recursive-include examples *
include *.rst doc/* LICENSE
# include everything under test/
# include test/
graft test
prune test/classes/*
graft setupext
global-exclude *.pyc
Loading

0 comments on commit 5c70502

Please sign in to comment.