Macaulay2 / M2

The primary source code repository for Macaulay2, a system for computing in commutative algebra, algebraic geometry and related fields.
https://macaulay2.com
347 stars 231 forks source link

Failing factor test #1500

Closed d-torrance closed 4 years ago

d-torrance commented 4 years ago

I'm getting the following when running tests/normal/factor.m2 on a recent draft of the Debian package:

i15 : -- factoring over extension fields
      R=ZZ/101[x,a]

o15 = R

o15 : PolynomialRing

i16 : debug Core

i17 : t = rawFactor ( raw(x^4 - 2), raw(a^2 - 2) )

o17 = ((x2+a, x2-a), (1, 1))

o17 : Sequence

i18 : assert(
           t === ((raw 1_R, raw (x^2+a), raw (x^2-a)), (1, 1, 1)) 
           or
           t === ((raw 1_R, raw (x^2-a), raw (x^2+a)), (1, 1, 1)) 
           )
stdio:55:1:(3): error: assertion failed

I'm really confused by this, as I don't remember this assertion ever failing before, and there haven't been any changes to Debian's factory package since January. (As I mentioned in https://github.com/Macaulay2/M2/issues/1316#issuecomment-647742904, the Debian Sage maintainers are holding off on updating singular from 4.1.1 to 4.1.3 for the time being.).

DanGrayson commented 4 years ago

We'll be driving cross-country tomorrow and the next day, but I'll try to take a look at this ...

DanGrayson commented 4 years ago

Re: "Debian's factory package"

What's the name of that package?

d-torrance commented 4 years ago

Re: "Debian's factory package"

What's the name of that package?

The source package is singular. The .so file itself is in libsingular4m1, and the headers are in libsingular4-dev and libsingular4-dev-common.

DanGrayson commented 4 years ago

How did you obtain the blas library? (I'm having a problem ... )

d-torrance commented 4 years ago

libblas-dev, although I don't specify it in the build dependencies. I think it's pulled in by liblapack-dev. Here's the full list of build-dependencies from the current debian/control file:

Build-Depends: 4ti2,
               bison,
               cohomcalg,
               coinor-csdp,
               debhelper-compat (= 13),
               dh-elpa,
               fflas-ffpack,
               flex,
               gfan,
               install-info,
               jdupes,
               libatomic-ops-dev,
               libboost-dev,
               libcdd-dev,
               libeigen3-dev,
               libflint-dev (>= 2.6.0~),
               libfrobby-dev,
               libgc-dev,
               libgdbm-dev,
               libgivaro-dev,
               libglpk-dev,
               libgtest-dev,
               liblapack-dev,
               liblzma-dev,
               libmathic-dev,
               libmathicgb-dev,
               libmemtailor-dev,
               libmpfr-dev,
               libntl-dev,
               libreadline-dev,
               libsingular-dev,
               libxml2-dev,
               lrslib,
               nauty,
               normaliz,
               pkg-config,
               singular-data,
               time,
               topcom
DanGrayson commented 4 years ago

Could you remind me how I get the development packages that you're using? Just switch from buster to "unstable"?

(I thought I did this before, but find no remnant of having done so.)

d-torrance commented 4 years ago

Could you remind me how I get the development packages that you're using? Just switch from buster to "unstable"?

Yes, exactly. "sid" works, too:

(sid-amd64)dtorrance@nimmie:/$ cat /etc/apt/sources.list
deb http://ftp.debian.org/debian sid main non-free contrib
deb-src http://ftp.debian.org/debian sid main non-free contrib
DanGrayson commented 4 years ago

Okay, I'm on the unstable branch. The configure script reports that it will build mpsolve and normaliz. Is that also the case for you? Will it eventually not be the case?

d-torrance commented 4 years ago

Okay, I'm on the unstable branch. The configure script reports that it will build mpsolve and normaliz. Is that also the case for you? Will it eventually not be the case?

It would be the case without the following patches:

mpsolve has been packaged for Debian, but it's still waiting in the NEW queue for final approval to get in. The normaliz issue should be fixed if/when #1417 is merged.

DanGrayson commented 4 years ago

By the way, it would be good if factory were unbundled from singular in the debian distribution, since it's a small part of something big, and Schoenemann is always willing to produce separate tar files for it.

DanGrayson commented 4 years ago

Okay, I've reproduced the bug.

dylanpeifer commented 4 years ago

Just to give extra confirmation, Daoji and I noticed this issue last week as well: I see this error and am using factory 4.1.3 and she does not see the error and is using factory 4.1.1. We are both on MacOS-10.15.6, and I also have mpfr 4.1.0 versus her mpfr 4.0.2.