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 to Python3.11 + Cython3 #213

Merged
merged 14 commits into from
Jan 25, 2024
Merged

Conversation

PeterMeisrimelModelon
Copy link
Collaborator

@PeterMeisrimelModelon PeterMeisrimelModelon commented Jan 24, 2024

Still some cleanup to do, but will do that as part of another PR. This is the current minimum to get PyFMI up and running with Cython3.

Core changes are as follows/address the following issues:

  1. New import path formats
  2. Removing replacing "__" prefixes from variables/functions as appropriate, where not private variables.
  3. Replaced <numy.ndarray>.size by numpy.size(<numpy.ndarray>). This caused segfaults, not sure why.
  4. Renaming variables using built-in names; e.g., sum, type. More cases remaining.
  5. Intermediate variables to cast sqrt output to double.
  6. Cython3/newer numpy is more strict on disallowing nested arrays; various fixes related to that.
  7. Some misc. cleanup.

@PeterMeisrimelModelon PeterMeisrimelModelon self-assigned this Jan 24, 2024
setup.cfg Outdated Show resolved Hide resolved
.github/workflows/build.yml Show resolved Hide resolved
src/pyfmi/fmi.pxd Show resolved Hide resolved
src/pyfmi/fmi_algorithm_drivers.py Show resolved Hide resolved
tests/test_util.py Outdated Show resolved Hide resolved
.github/workflows/build.yml Show resolved Hide resolved
src/pyfmi/fmi.pxd Show resolved Hide resolved
src/pyfmi/fmi_algorithm_drivers.py Show resolved Hide resolved
tests/test_util.py Outdated Show resolved Hide resolved
tests/test_util.py Show resolved Hide resolved
tests/test_fmi_estimate.py Show resolved Hide resolved
tests/test_fmi_estimate.py Show resolved Hide resolved
@PeterMeisrimelModelon PeterMeisrimelModelon merged commit fd56f13 into dev-pm-python311 Jan 25, 2024
2 checks passed
@PeterMeisrimelModelon PeterMeisrimelModelon deleted the dev-pm-cy3 branch January 25, 2024 12:48
@modelonrobinandersson modelonrobinandersson linked an issue Jan 25, 2024 that may be closed by this pull request
PeterMeisrimelModelon added a commit that referenced this pull request Feb 29, 2024
PeterMeisrimelModelon added a commit that referenced this pull request Apr 19, 2024
PeterMeisrimelModelon added a commit that referenced this pull request May 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add support for Cython 3.0
2 participants