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 of JasperReports to version 6.20.6 #154

Merged
merged 36 commits into from
Dec 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
f269118
Updated compatible versions of Python and Java, along with documentat…
jadsonbr Dec 18, 2023
b3f3fe2
Updated GitHub Action
jadsonbr Dec 18, 2023
0b6ec45
Updated GitHub Action distribuition java
jadsonbr Dec 18, 2023
346d861
Updated GitHub Action distribuition java
jadsonbr Dec 18, 2023
e520622
Changed the version of setup-java
jadsonbr Dec 18, 2023
9c61f75
Reverted to version 6.16 of JasperReports, added log4j configuration …
jadsonbr Dec 18, 2023
a582ca1
Removed Python 3.12 from GitHub Actions tests.
jadsonbr Dec 18, 2023
0b19981
Removed Python 3.13 from GitHub Actions tests.
jadsonbr Dec 18, 2023
4b0de93
Updated setup-java version
jadsonbr Dec 19, 2023
4f49a6c
Updated distribuition java github action
jadsonbr Dec 19, 2023
ca7c88c
Updated distribuition java github action
jadsonbr Dec 19, 2023
3786f16
Updated list java version github action
jadsonbr Dec 19, 2023
90178e9
Removed Java version 8.0.392+8 from GitHub Actions
jadsonbr Dec 19, 2023
62109c9
Adjusted Java versions for Windows in GitHub Actions
jadsonbr Dec 19, 2023
6eb918b
Update libraries of JasperReports Community Edition to 6.20.6.
jadsonbr Dec 19, 2023
6ad17f8
Removed java version 21.0.1+12.0.LTS to action github
jadsonbr Dec 19, 2023
582e79c
Example of custom font usage and documentation update.
jadsonbr Dec 20, 2023
b59c436
Code adjustments and improvements
jadsonbr Dec 20, 2023
737125a
Added version information to the CHANGES.md file.
jadsonbr Dec 22, 2023
e030de3
Add release system
jadsonbr Dec 22, 2023
c0c5643
Change workflow
jadsonbr Dec 22, 2023
5c8fec8
Added file .bumpversion.cfg and move CHANGES.md to docs/CHANGELOGS.rst
jadsonbr Dec 22, 2023
1f12d30
Commented template jdk in release
jadsonbr Dec 26, 2023
86ac3d1
Adjustment documentation.yml
jadsonbr Dec 28, 2023
4d30de5
Adjustment permission files *.sh
jadsonbr Dec 28, 2023
8d80739
Adjustment dependencie jpype in file build-wheels.sh
jadsonbr Dec 28, 2023
5fa1802
Add deps in template release.yml manylinux
jadsonbr Dec 28, 2023
751933f
Commented auditwheel repair
jadsonbr Dec 28, 2023
7d20665
Adjustment build-wheels and add dependencies doc in setup.py
jadsonbr Dec 28, 2023
e476652
Test dist build-wheels azure
jadsonbr Dec 28, 2023
986173b
Test dist with platform name
jadsonbr Dec 28, 2023
fb50c93
Added tag argument platform in command wheel
jadsonbr Dec 28, 2023
4de3ddc
Added extension build_ext
jadsonbr Dec 28, 2023
7198dcb
Removed universal from the bdist_wheel section in setup.cfg
jadsonbr Dec 28, 2023
355a695
Adjustments in setup.py
jadsonbr Dec 28, 2023
471cc77
Active Tests in branch feature/**
jadsonbr Dec 28, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
65 changes: 65 additions & 0 deletions .azure/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# pyreportjasper CI pipeline
trigger:
branches:
include:
- master
- releases/*
paths:
include:
- .azure/build.yml
- docs/*
- setup.py
- setupext/*
- pyreportjasper/*
- tests/*

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

- job: Test
# dependsOn: Deps
strategy:
matrix:
linux-3.8:
imageName: "ubuntu-latest"
python.version: '3.8'
linux-3.9:
imageName: "ubuntu-latest"
python.version: '3.9'
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.8:
imageName: "windows-2019"
python.version: '3.8'
windows-3.9:
imageName: "windows-2019"
python.version: '3.9'
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-11"
python.version: '3.9'

pool:
vmImage: $(imageName)
# steps:
# # - template: scripts/deps.yml
# # - template: scripts/test.yml
108 changes: 108 additions & 0 deletions .azure/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
# pyreportjasper Release pipeline
trigger: none
pr:
branches:
include:
- releases/*
- feature/*
paths:
include:
- .bumpversion.cfg
- .azure/release.yml

variables:
package_name: pyreportjasper

stages:
- stage: Initial
jobs:
- job: SourceDistribution
pool:
vmImage: "ubuntu-latest"
steps:
- template: scripts/sdist.yml

- stage: Package
jobs:
# From https://iscinumpy.gitlab.io/post/azure-devops-python-wheels/
- job: ManyLinux
condition: eq(1,1)
strategy:
matrix:
64Bit:
arch: x86_64
plat: manylinux2014_x86_64
image: quay.io/pypa/manylinux2014_x86_64
python.architecture: x64
32Bit:
arch: i686
plat: manylinux2014_i686
image: quay.io/pypa/manylinux2014_i686
python.architecture: x86
pool:
vmImage: "ubuntu-latest"
steps:
# - template: scripts/deps.yml
- template: scripts/wheels-linux.yml
- template: scripts/publish-dist.yml

- job: Windows_x64
condition: eq(1,1)
strategy:
matrix:
Python38:
python.version: '3.8'
python.architecture: 'x64'
Python39:
python.version: '3.9'
python.architecture: 'x64'
Python310:
python.version: '3.10'
python.architecture: 'x64'
Python311:
python.version: '3.11'
python.architecture: 'x64'
Python312:
python.version: '3.12'
python.architecture: 'x64'
pool:
vmImage: "windows-2019"
steps:
# - template: scripts/deps.yml
- task: UsePythonVersion@0
inputs:
versionSpec: '$(python.version)'
architecture: '$(python.architecture)'
# - template: scripts/jdk.yml
# parameters:
# version: '8'
- template: scripts/wheels.yml
- template: scripts/publish-dist.yml

- job: OSX
condition: eq(1,1)
variables:
python.architecture: 'x64'
strategy:
matrix:
Python38:
python.version: '3.8'
Python39:
python.version: '3.9'
Python310:
python.version: '3.10'
Python311:
python.version: '3.11'
# Python312:
# python.version: '3.12'
pool:
vmImage: "macos-11"
steps:
# - template: scripts/deps.yml
- script: .azure/scripts/osx-python.sh '$(python.version)'
displayName: Install Python.org Python
# - template: scripts/jdk.yml
# parameters:
# version: '8'
- template: scripts/wheels.yml
- template: scripts/publish-dist.yml
33 changes: 33 additions & 0 deletions .azure/scripts/build-wheels.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#!/bin/bash
set -e -x

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

# Exclude specific Pythons (3.6)
pys=(${pys[@]//*36*/})

# Compile wheels
for PYBIN in "${pys[@]}"; do
echo "Compile $PYBIN"
ls -l /io/dist
"${PYBIN}/pip" install jpype1
"${PYBIN}/pip" wheel /io/dist/$package_name-*.tar.gz -w /io/wheelhouse/ -v
done
echo "=============="

# # Bundle external shared libraries into the wheels
# for whl in wheelhouse/$package_name-*.whl; do
# echo "Audit $whl"
# auditwheel repair --plat $PLAT "$whl" -w /io/wheelhouse/
# done
# echo "=============="

# # Install packages and test
# for PYBIN in "${pys[@]}"; do
# echo "Test install $PYBIN $package_name"
# "${PYBIN}/python" -m pip install $package_name --no-index -f /io/wheelhouse
# # Manylinux does not have a JVM so there is no way to test the wheel in the docker
# # "${PYBIN}/pip" install -r /io/test-requirements.txt
# # "${PYBIN}/pytest" /io/test/jpypetest
# done
7 changes: 7 additions & 0 deletions .azure/scripts/deps.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
steps:
- task: DownloadPipelineArtifact@2
inputs:
source: current
artifact: artifact_Deps
path: lib

24 changes: 24 additions & 0 deletions .azure/scripts/documentation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# This task tries to verify if the documentation will build properly on RTD
steps:
- task: UsePythonVersion@0
inputs:
versionSpec: '3.8'

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

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

- task: CopyFiles@2
inputs:
contents: 'build/html/**'
targetFolder: $(Build.ArtifactStagingDirectory)

- task: PublishBuildArtifacts@1
inputs:
pathToPublish: $(Build.ArtifactStagingDirectory)
artifactName: documentation

14 changes: 14 additions & 0 deletions .azure/scripts/jdk.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
parameters:
- name: version
type: string
default: 8

steps:
- script: |
set v="##vso[task.setvariable variable=JAVA_HOME]%JAVA_HOME_${{parameters.version}}_X64%"
echo %v:"=%
condition: eq(variables['Agent.OS'], 'Windows_NT')

- script: |
echo "##vso[task.setvariable variable=JAVA_HOME]$(JAVA_HOME_${{parameters.version}}_X64)"
condition: ne(variables['Agent.OS'], 'Windows_NT')
47 changes: 47 additions & 0 deletions .azure/scripts/osx-python.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
#!/usr/bin/env bash

PYTHON_VERSION="$1"

case $PYTHON_VERSION in
3.7)
FULL_VERSION=3.7.9
INSTALLER_NAME=python-$FULL_VERSION-macosx10.9.pkg
;;
3.8)
FULL_VERSION=3.8.10
INSTALLER_NAME=python-$FULL_VERSION-macosx10.9.pkg
;;
3.9)
FULL_VERSION=3.9.12
INSTALLER_NAME=python-$FULL_VERSION-macosx10.9.pkg
;;
3.10)
FULL_VERSION=3.10.11
INSTALLER_NAME=python-$FULL_VERSION-macos11.pkg
;;
3.11)
FULL_VERSION=3.11.7
INSTALLER_NAME=python-$FULL_VERSION-macos11.pkg
;;
3.12)
FULL_VERSION=3.12.0
INSTALLER_NAME=python-$FULL_VERSION-macos11.pkg
esac

URL=https://www.python.org/ftp/python/$FULL_VERSION/$INSTALLER_NAME

PY_PREFIX=/Library/Frameworks/Python.framework/Versions

set -e -x

curl $URL > $INSTALLER_NAME

sudo installer -pkg $INSTALLER_NAME -target /

sudo rm -f /usr/local/bin/python
sudo ln -s /usr/local/bin/python$PYTHON_VERSION /usr/local/bin/python

which python
python --version
python -m ensurepip
python -m pip install setuptools wheel
5 changes: 5 additions & 0 deletions .azure/scripts/publish-dist.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
steps:
- task: PublishPipelineArtifact@0
inputs:
artifactName: 'artifact_$(Agent.JobName)_$(Agent.OS)_$(python.architecture)'
targetPath: 'dist'
13 changes: 13 additions & 0 deletions .azure/scripts/sdist.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
steps:
- task: UsePythonVersion@0
inputs:
versionSpec: '3.8'
- script: |
python -m pip install setuptools jpype1
python setup.py sdist
displayName: Build sdist
- task: PublishPipelineArtifact@0
inputs:
artifactName: 'artifact_SourceDistribution'
targetPath: 'dist'
displayName: Publish sdist
33 changes: 33 additions & 0 deletions .azure/scripts/wheels-linux.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
steps:
- task: UsePythonVersion@0
inputs:
versionSpec: '3.8'

- task: DownloadPipelineArtifact@2
inputs:
source: current
artifact: artifact_SourceDistribution
path: dist

- script: |
sudo apt-get update
sudo apt-get install -y qemu qemu-user-static qemu-user binfmt-support
sudo docker run --rm --privileged hypriot/qemu-register
condition: and(succeeded(), eq(variables['arch'], 'aarch64'))
displayName: 'Install QEMU'

- script: |
ls -l
ls -l dist
displayName: Sanity check

- script: |
set -ex
docker run -e PLAT=$(plat) -e package_name=$(package_name) --rm -v `pwd`:/io $(image) /io/.azure/scripts/build-wheels.sh
displayName: Build wheels

- script: |
ls -lh wheelhouse/
rm dist/*
cp wheelhouse/$(package_name)*.whl dist/.
displayName: Copy wheels
21 changes: 21 additions & 0 deletions .azure/scripts/wheels.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# This job creates wheels for Windows/OSX
steps:
- script: |
mkdir -p dist
python -m pip install --upgrade pip
python -m pip install --upgrade wheel setuptools
displayName: 'Install dependencies'

- script: |
python -m pip wheel . -w wheelhouse/
displayName: 'Build wheel'

- script: |
ls -lh wheelhouse
cp wheelhouse/$(package_name)* dist/.
displayName: 'Show wheelhouse'

- script: |
python -m pip install pyreportjasper --no-index -f wheelhouse
displayName: 'Install module'

Loading