Skip to content

Commit

Permalink
Release/2.8.1 (#54)
Browse files Browse the repository at this point in the history
- Improving performance of bytes plugin and of capnp transfers over XDR/RPC
- Adding fixes for fatclient pyuda build
- adding support for python3.13 wheels in linux and macos (not windows)
- fixing timestamp microseconds error in uda logging
- updating plugin::version() function convention to return the server semantic version number so server version can be queried from remote clients. 
- updates to documentation and adding a contributing.md
- fixing some UKAEA issues with the IDL wrapper
---------

Co-authored-by: Adam Parker <[email protected]>
Co-authored-by: Jonathan Hollocombe <[email protected]>
Co-authored-by: Maarten Sebregts <[email protected]>
Co-authored-by: Olivier Hoenen <[email protected]>
Co-authored-by: Adam Parker <[email protected]>
  • Loading branch information
6 people authored Jan 23, 2025
1 parent cb503c0 commit 8515a1a
Show file tree
Hide file tree
Showing 56 changed files with 1,149 additions and 606 deletions.
35 changes: 20 additions & 15 deletions .github/workflows/build_wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,20 +28,20 @@ jobs:
# which are only executed on push to tag.
# Test wheels are also generated for the other platforms (and uploaded to testpypi)
# on pushes to release branches and to main
- [ubuntu-latest, x86_64, manylinux2014_x86_64]
- [ubuntu-latest, x86_64, manylinux_2_28_x86_64]
- [ubuntu-latest, aarch64, manylinux_2_28_aarch64]
- [macos-13, x86_64, macosx_x86_64]
- [macos-14, arm64, macosx_arm64]
- [windows-latest, AMD64, win_amd64]
- [ubuntu-latest, x86_64, manylinux2014_x86_64, 0.0]
- [ubuntu-latest, x86_64, manylinux_2_28_x86_64, 0.0]
- [ubuntu-latest, aarch64, manylinux_2_28_aarch64, 0.0]
- [macos-13, x86_64, macosx_x86_64, 13.0]
- [macos-14, arm64, macosx_arm64, 14.0]
- [windows-latest, AMD64, win_amd64, 0.0]

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
# need git tags available for setuptools_scm to grab tags
with:
fetch-depth: 0

- uses: actions/github-script@v6
- uses: actions/github-script@v7
with:
script: |
core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || '');
Expand Down Expand Up @@ -107,15 +107,15 @@ jobs:
- name: build windows wheels
if: runner.OS == 'Windows'
uses: pypa/cibuildwheel@v2.17.0
uses: pypa/cibuildwheel@v2.22.0
with:
package-dir: ${{github.workspace}}/install/python_installer
config-file: ${{github.workspace}}/install/python_installer/pyproject.toml
env:
CIBW_ARCHS: ${{matrix.build-platform[1]}}
CIBW_PLATFORM: windows
CIBW_BUILD: cp3*-${{matrix.build-platform[2]}}
CIBW_SKIP: cp36* cp37*
CIBW_SKIP: cp36* cp37* cp313*
CIBW_REPAIR_WHEEL_COMMAND_WINDOWS: "delvewheel repair -w {dest_dir} {wheel} --add-path ${{github.workspace}}/install/lib"
CIBW_BEFORE_BUILD_WINDOWS: "pip install delvewheel"

Expand All @@ -125,7 +125,7 @@ jobs:
startswith(matrix.build-platform[2], 'manylinux2014') &&
github.event_name == 'push' &&
startsWith(github.ref, 'refs/tags/')
uses: pypa/cibuildwheel@v2.17.0
uses: pypa/cibuildwheel@v2.22.0
with:
package-dir: ./source/wrappers/python
config-file: ./source/wrappers/python/pyproject.toml
Expand Down Expand Up @@ -176,7 +176,7 @@ jobs:
startswith(matrix.build-platform[2], 'manylinux_2_28') &&
! ( startswith(matrix.build-platform[1], 'aarch64') &&
!startsWith(github.ref, 'refs/tags/') )
uses: pypa/cibuildwheel@v2.17.0
uses: pypa/cibuildwheel@v2.22.0
with:
package-dir: ./source/wrappers/python
config-file: ./source/wrappers/python/pyproject.toml
Expand All @@ -189,7 +189,7 @@ jobs:
CIBW_BEFORE_ALL: >
dnf update -y &&
dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm &&
dnf install -y boost-devel openssl-devel libxml2-devel libtirpc-devel
dnf install -y boost1.78-devel openssl-devel libxml2-devel libtirpc-devel
fmt fmt-devel spdlog spdlog-devel capnproto capnproto-devel &&
cd /project &&
cmake -B build
Expand All @@ -203,6 +203,10 @@ jobs:
- name: build uda on macos
if: runner.os == 'macOS'
# note: it's recommended in cibuildwheel to build all deps from source in macos
# instead of using homebrew as this way the wheel will be back-compatible with
# other macos versions. MACOSX_DEPLOYMENT_TARGET will no longer be required if
# this change is made.
run: >
brew update-reset && brew install
git
Expand All @@ -222,18 +226,19 @@ jobs:
-DCMAKE_INSTALL_PREFIX=$PWD/install
-DCLIENT_ONLY=ON &&
cmake --build build -j --config Release --target install &&
cp -r $PWD/install/python_installer/* ${{github.workspace}}/source/wrappers/python/
cp -r $PWD/install/python_installer/* ${{github.workspace}}/source/wrappers/python/
- name: Build macos wheels
if: runner.os == 'macOS'
uses: pypa/cibuildwheel@v2.17.0
uses: pypa/cibuildwheel@v2.22.0
with:
package-dir: ./source/wrappers/python
config-file: ./source/wrappers/python/pyproject.toml
env:
CIBW_ARCHS: ${{matrix.build-platform[1]}}
CIBW_PLATFORM: macos
CIBW_BUILD: cp*-${{matrix.build-platform[2]}}
MACOSX_DEPLOYMENT_TARGET: ${{matrix.build-platform[3]}}

- uses: actions/upload-artifact@v4
with:
Expand Down
24 changes: 12 additions & 12 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@ jobs:
build:
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
os: [ubuntu-22.04, windows-latest, macos-latest]
release: [Release]
ssl: [ON, OFF]
client-only: [ON, OFF]
capnp: [ON, OFF]
exclude:
- os: windows-latest
client-only: OFF
- os: ubuntu-latest
- os: ubuntu-22.04
client-only: ON
- os: macos-latest
client-only: ON
Expand All @@ -38,7 +38,7 @@ jobs:
shell: bash

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- uses: actions/github-script@v7
with:
Expand All @@ -47,7 +47,7 @@ jobs:
core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || '');
- name: Install linux dependencies
if: matrix.os == 'ubuntu-latest'
if: matrix.os == 'ubuntu-22.04'
run: >
sudo apt update && sudo apt install -y
git
Expand All @@ -67,7 +67,7 @@ jobs:
python3-venv
- name: Install Intel compiler
if: matrix.os == 'ubuntu-latest'
if: matrix.os == 'ubuntu-22.04'
run: >
sudo apt install -y wget &&
wget https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB &&
Expand Down Expand Up @@ -115,7 +115,7 @@ jobs:
spdlog
- name: Configure CMake (linux)
if: matrix.os == 'ubuntu-latest'
if: matrix.os == 'ubuntu-22.04'
run: >
cmake -G Ninja -B build
-DBUILD_SHARED_LIBS=ON
Expand All @@ -125,7 +125,7 @@ jobs:
-DENABLE_CAPNP=${{ matrix.capnp }}
- name: Configure CMake (linux Intel)
if: matrix.os == 'ubuntu-latest'
if: matrix.os == 'ubuntu-22.04'
run: >
source /opt/intel/oneapi/setvars.sh &&
CXX=icpx CC=icx cmake -G Ninja -B build-intel
Expand Down Expand Up @@ -176,7 +176,7 @@ jobs:
run: cmake --build build --config ${{ matrix.release }}

- name: Build Intel
if: matrix.os == 'ubuntu-latest'
if: matrix.os == 'ubuntu-22.04'
run: cmake --build build-intel --config ${{ matrix.release }}

- name: Install
Expand All @@ -188,7 +188,7 @@ jobs:
run: cmake --install build --config ${{ matrix.release }}

- name: Install pyuda
if: matrix.os == 'ubuntu-latest'
if: matrix.os == 'ubuntu-22.04'
run: >
cp -r /usr/local/python_installer ${{github.workspace}}/python_installer &&
python3 -m venv ${{github.workspace}}/venv &&
Expand All @@ -198,13 +198,13 @@ jobs:
pip3 install ${{github.workspace}}/python_installer
- name: Test pyuda import
if: matrix.os == 'ubuntu-latest'
if: matrix.os == 'ubuntu-22.04'
run: >
source ${{github.workspace}}/venv/bin/activate &&
python3 -c 'import pyuda; client=pyuda.Client()'
- name: Run non-SSL system tests
if: matrix.os == 'ubuntu-latest' && matrix.ssl == 'OFF'
if: matrix.os == 'ubuntu-22.04' && matrix.ssl == 'OFF'
run: >
sudo cp /usr/local/etc/uda.socket /usr/local/etc/[email protected] /etc/systemd/system &&
sudo systemctl start uda.socket &&
Expand All @@ -216,7 +216,7 @@ jobs:
./build/test/plugins/plugin_test_testplugin
- name: Run SSL system tests
if: matrix.os == 'ubuntu-latest' && matrix.ssl == 'ON'
if: matrix.os == 'ubuntu-22.04' && matrix.ssl == 'ON'
run: >
sudo cp /usr/local/etc/uda.socket /usr/local/etc/[email protected] /etc/systemd/system &&
sudo chown -R $USER:$USER /usr/local/etc &&
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required( VERSION 3.0 )
cmake_minimum_required( VERSION 3.12 )

########################################################################################################################
# Macro used to convert Windows path to Unix
Expand Down
91 changes: 91 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
# Contributing to UDA

UDA is an open-source project and we welcome contributions. This guide explains the process and expectations for getting your changes added.

---

## Table of Contents

1. [Getting Started](#getting-started)
- [Fork the Repository](#fork-the-repository)
- [Create an Issue](#create-an-issue)
- [Set Up Your Local Environment](#set-up-your-local-environment)
2. [Branching Strategy](#branching-strategy)
3. [Making Changes](#making-changes)
4. [Submitting Your Contribution](#submitting-your-contribution)
5. [Review Process](#review-process)

---

## Getting Started

### 1. Fork the Repository
1. Navigate to the [uda repository](https://github.com/ukaea/uda).
2. Click the **Fork** button in the top-right corner to create a copy of the repository under your GitHub account.

### 2. Create an Issue
Before starting work, please open an issue to describe your contribution. This helps us track ongoing efforts.

1. Go to the [Issues tab](https://github.com/ukaea/uda/issues).
2. Create a new issue with a clear description of the bug, feature, or improvement you want to work on.
3. Wait for a project maintainer to approve or provide feedback.

### 3. Set Up Your Local Environment
See the [development guide](https://ukaea.github.io/UDA/development/) in the UDA documentation pages for more detialed instructions on getting started.

---

## Branching Strategy

We use the **GitFlow branching model**. Here's how branches are structured:

- **`main`**: Contains stable, production-ready code. Do not merge changes directly into `main`.
- **`develop`**: The active development branch. Your contributions should be merged into `develop`.
- **Feature branches**: Used for individual features. Create a feature branch off `develop`:
```bash
git checkout -b feature/your-feature-name develop
```

---

## Making Changes

1. Pull the latest changes from the `develop` branch to ensure your branch is up to date:
```bash
git checkout develop
git pull upstream develop
```
2. Create a new feature branch for your work:
```bash
git checkout -b feature/your-feature-name develop
```
3. Make your changes and commit them with clear, descriptive commit messages:
```bash
git add .
git commit -m "Add feature X to improve Y"
```

---

## Submitting Your Contribution

1. Push your changes to your fork:
```bash
git push origin feature/your-feature-name
```
2. Open a pull request (PR) from your feature branch to the `develop` branch in the original repository:
- Navigate to your fork on GitHub.
- Click the **Compare & Pull Request** button.
- Select the `develop` branch of the original repository as the base branch.
3. Provide a clear title and description for your PR. Reference the issue you are addressing.

---

## Review Process

1. Once your PR is submitted, a maintainer will review it.
2. Be prepared to make changes based on feedback.
3. When your PR is approved, a maintainer will merge it into the `develop` branch.

---

12 changes: 11 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,14 @@ remote server, or as fat-client API where both the client access and plugin func

UDA is licenced under an Apache 2.0 licence. See [LICENCE.txt](https://github.com/ukaea/UDA/blob/main/LICENCE.txt) for details.

## documentation
## Documentation

See the github pages for current [Docs](https://ukaea.github.io/UDA/)

## Contributing

See [CONTRIBUTING.md](https://github.com/ukaea/UDA/blob/main/CONTRIBUTING.md) for contribution guidelines.

## Getting UDA

The source code can be downloaded from:
Expand Down Expand Up @@ -55,6 +59,7 @@ UDA requires the following to packages in order to build:
| libfmt | | |
| spdlog | | |
| capnproto | | |
| tirpc | | |
| boost | | C++, Python & HTTP wrappers |
| LibMemcached | | to enable caching |
| python | \> 3.0 | Python wrapper |
Expand All @@ -64,6 +69,7 @@ Start by installing all system-level dependencies.
```sh
sudo apt update && sudo apt install -y
git
libtirpc-dev
libboost-dev
libboost-program-options-dev
libssl-dev
Expand Down Expand Up @@ -94,4 +100,8 @@ build and install
```sh
cmake --build build -j --config Release --target install
```
## Events and training

Slide packs including some hands-on exercises are available from an UDA workshop delivered at ITER in 2023. These resources provide some additional details and working examples for working with UDA, especially in the context of the ITER Modelling and Analysis Suite (IMAS).

See event details and resources [here](https://indico.iter.org/event/81/).
Loading

0 comments on commit 8515a1a

Please sign in to comment.