Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
20 changes: 10 additions & 10 deletions .github/workflows/autoblack.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
# GitHub Action that uses Black to reformat the Python code in an incoming pull request.
# If all Python code in the pull request is compliant with Black then this Action does nothing.
# Othewrwise, Black is run and its changes are committed back to the incoming pull request.
# https://github.com/cclauss/autoblack
# GitHub Action that uses Black to reformat the Python code in an
# incoming pull request. If all Python code in the pull request is
# compliant with Black then this Action does nothing. Othewrwise,
# Black is run and its changes are committed back to the incoming pull
# request. https://github.com/cclauss/autoblack

---
name: autoblack
on: [pull_request]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- name: Set up Python 3.13
uses: actions/setup-python@v5
- uses: actions/checkout@v6
- name: Set up Python 3.14
uses: actions/setup-python@v6
with:
python-version: 3.14
- name: Install click, black and isort
run: pip install 'click==8.2.1' 'black==25.11.0' 'isort==5.13.2'
- name: Run isort --check .
run: isort --check .
run: pip install 'click==8.2.1' 'black==25.11.0' 'isort==8.0.1'
- name: Run black --check --diff .
run: black --check --diff .
- name: If needed, commit black changes to the pull request
Expand Down
32 changes: 0 additions & 32 deletions .github/workflows/isort-and-black-checks.yml

This file was deleted.

56 changes: 29 additions & 27 deletions .github/workflows/macos.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
name: Mathics3 Module PyICU (macOS)

on:
push:
branches: [ master ]
branches: [master]
pull_request:
branches: '**'

Expand All @@ -14,29 +15,30 @@ jobs:
os: [macOS]
python-version: ['3.13', '3.14']
steps:
- uses: actions/checkout@v5
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Set ICU version
run: |
echo "PKG_CONFIG_PATH=$(brew --prefix icu4c)/lib/pkgconfig" >> $GITHUB_ENV
- name: Install dependencies
run: |
brew install llvm
python -m pip install --upgrade pip
python -m pip install pytest
# # Go over and comment out stuff when next Mathics3 core and Mathics-scanner are released
# python -m pip install -e git+https://github.com/Mathics3/mathics-scanner#egg=Mathics-Scanner[full]
# git clone https://github.com/Mathics3/mathics-core
# (cd mathics-core && pip3 install -e .[full])
# (cd mathics-core && bash ./admin-tools/make-JSON-tables.sh)
# python -m pip install -e git+https://github.com/Mathics3/Mathics3-Module-Base#egg=Mathics3-Module-Base
- name: Install Mathic3 PyICU Module
run: |
python -m pip install Mathics3 PyICU
python -m pip install --no-build-isolation -e .
- name: Test Mathics3 Module PyICU
run: |
make check
- uses: actions/checkout@v5
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Set ICU version
run: |
echo "PKG_CONFIG_PATH=$(brew --prefix icu4c)/lib/pkgconfig" >> $GITHUB_ENV
- name: Install dependencies
run: |
brew install llvm
python -m pip install --upgrade pip
python -m pip install pytest
# # Go over and comment out stuff when next Mathics3 core and Mathics-scanner are released
# python -m pip install -e git+https://github.com/Mathics3/mathics-scanner#egg=Mathics-Scanner[full]
# We use recently-added message tags from mathics core.
# Until next mathics-core release...
git clone https://github.com/Mathics3/mathics-core
(cd mathics-core && pip3 install -e .[full])
# python -m pip install -e git+https://github.com/Mathics3/Mathics3-Module-Base#egg=Mathics3-Module-Base
- name: Install Mathic3 PyICU Module
run: |
python -m pip install Mathics3 PyICU
python -m pip install --no-build-isolation -e .
- name: Test Mathics3 PyICU Module
run: |
make check
50 changes: 26 additions & 24 deletions .github/workflows/ubuntu.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
---
name: Mathics3-Module-pyICU (ubuntu)

on:
push:
branches: [ master ]
branches: [master]
pull_request:
branches: '**'

Expand All @@ -13,26 +14,27 @@ jobs:
matrix:
python-version: ['3.12', '3.13', '3.14']
steps:
- uses: actions/checkout@v5
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
sudo apt install libicu-dev
python -m pip install --upgrade pip
python -m pip install pytest
# # Go over and comment out stuff when next Mathics3 core and Mathics-scanner are released
# python -m pip install -e git+https://github.com/Mathics3/mathics-scanner#egg=Mathics-Scanner[full]
# git clone https://github.com/Mathics3/mathics-core
# (cd mathics-core && pip3 install -e .[full])
# (cd mathics-core && bash ./admin-tools/make-JSON-tables.sh)
# python -m pip install -e git+https://github.com/Mathics3/Mathics3-Module-Base#egg=Mathics3-Module-Base
- name: install Mathic3 PyICU Module
run: |
python -m pip install Mathics3 PyICU
python -m pip install --no-build-isolation -e .
- name: Test Mathics3 PyICU Module
run: |
make check
- uses: actions/checkout@v5
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
sudo apt install libicu-dev
python -m pip install --upgrade pip
python -m pip install pytest
# # Go over and comment out stuff when next Mathics3 core and Mathics-scanner are released
# python -m pip install -e git+https://github.com/Mathics3/mathics-scanner#egg=Mathics-Scanner[full]
# We use recently-added message tags from mathics core.
# Until next mathics-core release...
git clone https://github.com/Mathics3/mathics-core
(cd mathics-core && pip3 install -e .[full])
# python -m pip install -e git+https://github.com/Mathics3/Mathics3-Module-Base#egg=Mathics3-Module-Base
- name: Install Mathic3 PyICU Module
run: |
python -m pip install Mathics3 PyICU
python -m pip install --no-build-isolation -e .
- name: Test Mathics3 PyICU Module
run: |
make check
25 changes: 13 additions & 12 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,22 +1,23 @@
---
default_language_version:
python: python
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.0.1
hooks:
- id: check-merge-conflict
- id: debug-statements
stages: [commit]
- id: end-of-file-fixer
stages: [commit]
- id: trailing-whitespace
- repo: https://github.com/psf/black
- id: check-merge-conflict
- id: debug-statements
stages: [commit]
- id: end-of-file-fixer
stages: [commit]
- id: trailing-whitespace
- repo: https://github.com/psf/black
rev: 25.11.0
hooks:
- id: black
language_version: python3
exclude: 'mathicsscript/version.py'
- repo: https://github.com/pycqa/flake8
- id: black
language_version: python3
exclude: 'pymathics/icu/version.py'
- repo: https://github.com/pycqa/flake8
rev: 3.9.2
hooks:
- id: flake8
Expand Down
3 changes: 1 addition & 2 deletions pymathics/icu/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
= {ʼ, а, б, в, г, д, е, ж, з, и, й, к, л, м, н, о, п, р, с, т, у, ф, х, ц, ч, ш, щ, ь, ю, я, є, і, ї, ґ}
"""

from pymathics.icu.__main__ import Alphabet, AlphabeticOrder, Language
from pymathics.icu.__main__ import Alphabet, AlphabeticOrder
from pymathics.icu.version import __version__

pymathics_version_data = {
Expand All @@ -39,7 +39,6 @@
__all__ = [
"Alphabet",
"AlphabeticOrder",
"Language",
"pymathics_version_data",
"__version__",
]
Loading
Loading