Skip to content

Commit

Permalink
4.4.0
Browse files Browse the repository at this point in the history
  • Loading branch information
jzuhone committed Mar 6, 2024
1 parent ec3079e commit 240f59d
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 12 deletions.
3 changes: 2 additions & 1 deletion doc/source/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,13 @@
ChangeLog
=========

Version 4.3.3
Version 4.4.0
-------------

This version of pyXSIM contains a bugfix and updates compatibility with other
packages.

* Support for Python 3.8 has been dropped.
* The minimum required version of yt has been bumped up to 4.3.0.
* Cython 3.0 is now supported as a compile-time dependency for those building
pyXSIM from source.
Expand Down
4 changes: 2 additions & 2 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,9 @@
# built documents.
#
# The short X.Y version.
version = "4.3.3"
version = "4.4.0"
# The full version, including alpha/beta/rc tags.
release = "4.3.3"
release = "4.4.0"

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
2 changes: 1 addition & 1 deletion doc/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ pyXSIM is released under a
Current Version
---------------

The current stable version is 4.3.3. See the :ref:`changelog` for details on
The current stable version is 4.4.0. See the :ref:`changelog` for details on
changes from previous versions.

Table of Contents
Expand Down
13 changes: 5 additions & 8 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,17 @@ requires = [
"setuptools_scm[toml]>=6.2",
# see https://github.com/numpy/numpy/pull/18389
"wheel>=0.36.2",

# cython version is imposed by that of numpy, see release notes
# https://github.com/numpy/numpy/releases/tag/v1.19.2
# Cython 3.0 is the next version after 0.29, and a major change,
# we forbid it until we can properly test against it
"Cython>=0.29.21",
"oldest-supported-numpy",
"Cython>=0.29.21, <3.1",
"numpy>=1.25, <2.0",
]

requires-python = ">=3.9.2"

[tool.setuptools_scm]

[tool.black]
line-length = 88
target-version = ['py38']
target-version = ['py39']
include = '\.pyi?$'
exclude = '''
/(
Expand Down
8 changes: 8 additions & 0 deletions pyxsim/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,10 +219,18 @@ def _metal_field(field, data):


def compute_H_abund(abund_table):
if abund_table not in abund_tables:
raise KeyError(
f"Abundance table {abund_table} not found! Options are: {list(abund_tables.keys())}"
)
return atomic_weights[1] / (atomic_weights * abund_tables[abund_table]).sum()


def compute_zsolar(abund_table):
if abund_table not in abund_tables:
raise KeyError(
f"Abundance table {abund_table} not found! Options are: {list(abund_tables.keys())}"
)
elems = atomic_weights * abund_tables[abund_table]
return elems[3:].sum() / elems.sum()

Expand Down

0 comments on commit 240f59d

Please sign in to comment.