[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #65900] [octave forge] (symbolic) Failing unit
From: |
Rafael Laboissière |
Subject: |
[Octave-bug-tracker] [bug #65900] [octave forge] (symbolic) Failing unit test in @sym/bernoulli.m |
Date: |
Thu, 20 Jun 2024 04:57:47 -0400 (EDT) |
URL:
<https://savannah.gnu.org/bugs/?65900>
Summary: [octave forge] (symbolic) Failing unit test in
@sym/bernoulli.m
Group: GNU Octave
Submitter: rlaboiss
Submitted: Thu 20 Jun 2024 08:57:47 AM UTC
Category: Octave Package
Severity: 3 - Normal
Priority: 5 - Normal
Item Group: Unexpected Error or Warning
Status: None
Assigned to: None
Originator Name:
Originator Email:
Open/Closed: Open
Release: other
Discussion Lock: Any
Operating System: GNU/Linux
Fixed Release: None
Planned Release: None
_______________________________________________________
Follow-up Comments:
-------------------------------------------------------
Date: Thu 20 Jun 2024 08:57:47 AM UTC By: Rafael Laboissière <rlaboiss>
With Octave 9.2.0, symbolic 3.2.1, Python 3.11.9, and SymPy 1.12.1, one of the
unit tests in vpa.m fails:
***** test
% we use B_1 = 1/2
if (pycall_sympy__ ('return Version(spver) >= Version("1.12.dev")'))
assert (isequal (bernoulli (sym(1)), sym(1)/2))
end
!!!!! test failed
Python exception: TypeError: '>=' not supported between instances of 'int' and
'str'
occurred at line 1 of the Python code block:
return Version(spver) >= Version("1.12.dev")
In my Debian system, with package python3-packaging installed, the problem
disappears.
This may be caused by this piece of code in inst/private/python_header.py:
try:
from packaging.version import Version
except ImportError:
try:
# available on SymPy >= 1.9
from sympy.external.importtools import version_tuple as Version
except ImportError:
# will fail on Python 3.12: drop this soon in favour of above
from distutils.version import LooseVersion
def Version(v):
return LooseVersion(v.replace('.dev', ''))
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?65900>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
- [Octave-bug-tracker] [bug #65900] [octave forge] (symbolic) Failing unit test in @sym/bernoulli.m,
Rafael Laboissière <=