Skip to content

Commit daa43db

Browse files
committed
Convert to 9.0.0 API
1 parent 5309177 commit daa43db

File tree

5 files changed

+61
-69
lines changed

5 files changed

+61
-69
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
*~
22
.python-version
33
/ChangeLog
4+
/Mathics3_Module_PyICU.egg-info
45
/build
56
/dist
67
/pymathics_language.egg-info

pymathics/language/__main__.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
from icu import Locale, LocaleData
1313
from typing import List, Optional
1414

15-
from mathics.builtin.base import Builtin
15+
from mathics.core.builtin import Builtin
1616
from mathics.core.atoms import String
1717
from mathics.core.convert.expression import to_mathics_list
1818

@@ -27,6 +27,7 @@ def eval_alphabet(language_name: String) -> Optional[List[String]]:
2727

2828
py_language_name = language_name.value
2929
locale = language2locale.get(py_language_name, py_language_name)
30+
print(locale)
3031
if locale not in availableLocales:
3132
return
3233
alphabet_set = LocaleData(locale).getExemplarSet(0, 0)
@@ -70,7 +71,7 @@ class Alphabet(Builtin):
7071

7172
summary_text = "lowercase letters in an alphabet"
7273

73-
def apply(self, alpha: String, evaluation):
74+
def eval(self, alpha: String, evaluation):
7475
"""Alphabet[alpha_String]"""
7576
alphabet_list = eval_alphabet(alpha)
7677
if alphabet_list is None:

pymathics/language/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55
# well as importing into Python. That's why there is no
66
# space around "=" below.
77
# fmt: off
8-
__version__="5.0.0" # noqa
8+
__version__="9.0.0" # noqa

pyproject.toml

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
[build-system]
2+
requires = [
3+
"setuptools",
4+
"Mathics3-Module-Base >= 9.0.0",
5+
"Mathics3>=9.0.0",
6+
"PyICU>=2.9",
7+
]
8+
build-backend = "setuptools.build_meta"
9+
10+
[project]
11+
name = "Mathics3-Module-PyICU"
12+
description = 'Mathics3 Hello, World! module'
13+
dependencies = [
14+
"Mathics3-Module-Base >= 9.0.0",
15+
"Mathics3 >= 9.0.0",
16+
"PyICU>=2.9",
17+
]
18+
requires-python = ">=3.10"
19+
readme = "README.rst"
20+
license = "GPL-3.0-or-later"
21+
keywords = ["Mathematica", "Wolfram", "Interpreter", "Shell", "Math", "CAS"]
22+
maintainers = [
23+
{name = "Mathics Group", email = "[email protected]"},
24+
]
25+
classifiers = [
26+
"Intended Audience :: Developers",
27+
"Intended Audience :: Science/Research",
28+
"Programming Language :: Python",
29+
"Programming Language :: Python :: 3.10",
30+
"Programming Language :: Python :: 3.11",
31+
"Programming Language :: Python :: 3.12",
32+
"Programming Language :: Python :: 3.13",
33+
"Programming Language :: Python :: Implementation :: CPython",
34+
"Programming Language :: Python :: Implementation :: PyPy",
35+
"Topic :: Scientific/Engineering",
36+
"Topic :: Scientific/Engineering :: Mathematics",
37+
"Topic :: Software Development :: Interpreters",
38+
]
39+
dynamic = ["version"]
40+
41+
[project.urls]
42+
Homepage = "https://github.com/Mathics3/Mathics3-Module-PyICU"
43+
Downloads = "https://github.com/Mathics3/Mathics-Module-PyICU/releases"
44+
45+
[project.optional-dependencies]
46+
dev = [
47+
"pytest",
48+
]
49+
50+
[tool.setuptools]
51+
packages = [
52+
"pymathics.language",
53+
]
54+
55+
[tool.setuptools.dynamic]
56+
version = {attr = "pymathics.language.__version__"}

setup.py

Lines changed: 0 additions & 66 deletions
This file was deleted.

0 commit comments

Comments
 (0)