Skip to content

Commit 7562e51

Browse files
author
Release Manager
committed
gh-40686: Install pyx sources with meson Currently the meson build doesn't install the pyx source files, as opposed to the setuptools build. This has caused/is causing several issues: - The method `sage_getsource` as well as ipython's own source viewer `??` don't work for cython methods. This creates an inconsistency with python methods, and breaks several tests when the sage source is not available (eg. distro packages). - It breaks the doc builder #39973 (comment) - It used to cause issues when accessing some methods (#39735), now worked around. The only reason why these issues are not present in sage-the-distro is that cython wrongly embeds the absolute paths of source files, which masks the issues as long as the source is present in its original location. But as soon as cython/cython#6755 is released this will affect all types of sage build. In any case, I believe being able to inspect the methods implementation from the sage interface itself is a valuable feature for mathematicians, which are its main user base. I have only done one dir so far so I don't waste my time in case this is rejected or a different implementation is proposed. I will do the rest when I get the OK. Fixes #39874 URL: #40686 Reported by: Antonio Rojas Reviewer(s): Tobias Diez
2 parents 3df6f01 + 79bca41 commit 7562e51

File tree

101 files changed

+575
-3
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

101 files changed

+575
-3
lines changed

src/sage/algebras/finite_dimensional_algebras/meson.build

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ py.install_sources(
33
'all.py',
44
'finite_dimensional_algebra.py',
55
'finite_dimensional_algebra_element.pxd',
6+
'finite_dimensional_algebra_element.pyx',
67
'finite_dimensional_algebra_ideal.py',
78
'finite_dimensional_algebra_morphism.py',
89
subdir: 'sage/algebras/finite_dimensional_algebras',

src/sage/algebras/fusion_rings/meson.build

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,15 @@ py.install_sources(
33
'all.py',
44
'f_matrix.py',
55
'fast_parallel_fmats_methods.pxd',
6+
'fast_parallel_fmats_methods.pyx',
67
'fast_parallel_fusion_ring_braid_repn.pxd',
8+
'fast_parallel_fusion_ring_braid_repn.pyx',
79
'fusion_double.py',
810
'fusion_ring.py',
911
'poly_tup_engine.pxd',
12+
'poly_tup_engine.pyx',
1013
'shm_managers.pxd',
14+
'shm_managers.pyx',
1115
subdir: 'sage/algebras/fusion_rings',
1216
)
1317

src/sage/algebras/letterplace/meson.build

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,10 @@ py.install_sources(
22
'__init__.py',
33
'all.py',
44
'free_algebra_element_letterplace.pxd',
5+
'free_algebra_element_letterplace.pyx',
56
'free_algebra_letterplace.pxd',
7+
'free_algebra_letterplace.pyx',
8+
'letterplace_ideal.pyx',
69
subdir: 'sage/algebras/letterplace',
710
)
811

src/sage/algebras/lie_algebras/meson.build

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ py.install_sources(
1313
'heisenberg.py',
1414
'lie_algebra.py',
1515
'lie_algebra_element.pxd',
16+
'lie_algebra_element.pyx',
1617
'morphism.py',
1718
'nilpotent_lie_algebra.py',
1819
'onsager.py',

src/sage/algebras/meson.build

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,12 @@ py.install_sources(
88
'cellular_basis.py',
99
'clifford_algebra.py',
1010
'clifford_algebra_element.pxd',
11+
'clifford_algebra_element.pyx',
1112
'cluster_algebra.py',
1213
'commutative_dga.py',
1314
'down_up_algebra.py',
1415
'exterior_algebra_groebner.pxd',
16+
'exterior_algebra_groebner.pyx',
1517
'finite_gca.py',
1618
'free_algebra.py',
1719
'free_algebra_element.py',
@@ -24,6 +26,7 @@ py.install_sources(
2426
'jordan_algebra.py',
2527
'nil_coxeter_algebra.py',
2628
'octonion_algebra.pxd',
29+
'octonion_algebra.pyx',
2730
'orlik_solomon.py',
2831
'orlik_terao.py',
2932
'q_commuting_polynomials.py',

src/sage/algebras/quatalg/meson.build

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@ py.install_sources(
22
'__init__.py',
33
'all.py',
44
'quaternion_algebra.py',
5+
'quaternion_algebra_cython.pyx',
56
'quaternion_algebra_element.pxd',
7+
'quaternion_algebra_element.pyx',
68
subdir: 'sage/algebras/quatalg',
79
)
810

src/sage/arith/meson.build

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,18 @@ py.install_sources(
33
'all.py',
44
'constants.pxd',
55
'functions.pxd',
6+
'functions.pyx',
67
'long.pxd',
78
'misc.py',
89
'multi_modular.pxd',
10+
'multi_modular.pyx',
911
'numerical_approx.pxd',
12+
'numerical_approx.pyx',
1013
'power.pxd',
14+
'power.pyx',
1115
'rational_reconstruction.pxd',
16+
'rational_reconstruction.pyx',
17+
'srange.pyx',
1218
subdir: 'sage/arith',
1319
)
1420

src/sage/calculus/meson.build

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,17 @@ py.install_sources(
66
'expr.py',
77
'functional.py',
88
'functions.py',
9+
'integration.pyx',
910
'interpolation.pxd',
11+
'interpolation.pyx',
12+
'interpolators.pyx',
1013
'ode.pxd',
14+
'ode.pyx',
1115
'predefined.py',
16+
'riemann.pyx',
1217
'test_sympy.py',
1318
'tests.py',
19+
'var.pyx',
1420
'wester.py',
1521
subdir: 'sage/calculus',
1622
)

src/sage/calculus/transforms/meson.build

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@ py.install_sources(
33
'all.py',
44
'dft.py',
55
'dwt.pxd',
6+
'dwt.pyx',
67
'fft.pxd',
8+
'fft.pyx',
79
subdir: 'sage/calculus/transforms',
810
)
911

src/sage/categories/examples/meson.build

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ py.install_sources(
2929
'monoids.py',
3030
'posets.py',
3131
'semigroups.py',
32+
'semigroups_cython.pyx',
3233
'semirings.py',
3334
'sets_cat.py',
3435
'sets_with_grading.py',

0 commit comments

Comments
 (0)