Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Doctest failures in nfactor_enumerable_word.py on 32-bit Linux #9589

Closed
qed777 mannequin opened this issue Jul 24, 2010 · 9 comments
Closed

Doctest failures in nfactor_enumerable_word.py on 32-bit Linux #9589

qed777 mannequin opened this issue Jul 24, 2010 · 9 comments

Comments

@qed777
Copy link
Mannequin

qed777 mannequin commented Jul 24, 2010

Seen on 32-bit SUSE Linux by John Cremona:

sage -t -long "devel/sage/sage/combinat/words/nfactor_enumerable_word.py"
**********************************************************************
File "/local/jec/sage-4.5.2.alpha0/devel/sage/sage/combinat/words/nfactor_enumerable_word.py",
line 612:
    sage: for i in range(10):
        for u in w.bispecial_factors_iterator(i):
            print i,u
Expected:
    0 word:
    1 word: 1
    1 word: 0
    2 word: 10
    2 word: 01
    3 word: 101
    3 word: 010
    4 word: 0110
    4 word: 1001
    6 word: 100110
    6 word: 011001
    8 word: 10010110
Got:
    0 word:
    1 word: 1
    1 word: 0
    2 word: 10
    2 word: 01
    3 word: 101
    3 word: 010
    4 word: 0110
    4 word: 1001
    6 word: 011001
    6 word: 100110
    8 word: 10010110
**********************************************************************
File "/local/jec/sage-4.5.2.alpha0/devel/sage/sage/combinat/words/nfactor_enumerable_word.py",
line 630:
    sage: for u in w.bispecial_factors_iterator(): u
Expected:
    word:
    word: 1
    word: 0
    word: 10
    word: 01
    word: 101
    word: 010
    word: 0110
    word: 1001
    word: 100110
    word: 011001
    word: 10010110
Got:
    word:
    word: 1
    word: 0
    word: 10
    word: 01
    word: 101
    word: 010
    word: 0110
    word: 1001
    word: 011001
    word: 100110
    word: 10010110

Leif Leonhardy sees the same on 32-bit Ubuntu.

These may be caused by #8604.

CC: @sagetrac-abmasse @JohnCremona @sagetrac-jleroy @nexttime @seblabbe

Component: combinatorics

Author: Alexandre Blondin Massé

Reviewer: Leif Leonhardy

Merged: sage-4.5.2.alpha1

Issue created by migration from https://trac.sagemath.org/ticket/9589

@qed777 qed777 mannequin added this to the sage-4.5.2 milestone Jul 24, 2010
@qed777 qed777 mannequin added c: combinatorics labels Jul 24, 2010
@sagetrac-abmasse
Copy link
Mannequin

sagetrac-abmasse mannequin commented Jul 24, 2010

comment:1

Hello !

I'm sorry about that... this is really a bad habit to have tests that depend too much on the implementation of an iterator that may differ from one platform to another.

I'll try to correct the problem tonight or at most tomorrow, if Sébastien doesn't correct it before me.

@sagetrac-abmasse
Copy link
Mannequin

sagetrac-abmasse mannequin commented Jul 24, 2010

Fixes doctest failing -- depends on #8604

@sagetrac-abmasse
Copy link
Mannequin

sagetrac-abmasse mannequin commented Jul 24, 2010

comment:2

Attachment: trac_9589-nfactor_doctest_fail-abm.patch.gz

I uploaded a patch that should fix the problem.

I tested it on sage-4.5.1 and all tests passed. Needs review.

@sagetrac-abmasse
Copy link
Mannequin

sagetrac-abmasse mannequin commented Jul 24, 2010

comment:3

By the way, I'm not sure if Sébastien is available right now... But almost anyone can review this ticket, as it does not require any combinatorics on word background.

@nexttime
Copy link
Mannequin

nexttime mannequin commented Jul 24, 2010

comment:4
leif@californication:~/sage-4.5.2.alpha0-j6/devel/sage-9590$ time ../../sage -t -long sage/combinat/words/
sage -t -long "devel/sage-9590/sage/combinat/words/alphabet.py"
	 [3.2 s]
sage -t -long "devel/sage-9590/sage/combinat/words/__init__.py"
	 [0.1 s]
sage -t -long "devel/sage-9590/sage/combinat/words/word.py" 
	 [3.3 s]
sage -t -long "devel/sage-9590/sage/combinat/words/finite_word.py"
	 [25.3 s]
sage -t -long "devel/sage-9590/sage/combinat/words/all.py"  
	 [0.1 s]
sage -t -long "devel/sage-9590/sage/combinat/words/paths.py"
	 [12.1 s]
sage -t -long "devel/sage-9590/sage/combinat/words/shuffle_product.py"
	 [3.2 s]
sage -t -long "devel/sage-9590/sage/combinat/words/word_infinite_datatypes.py"
	 [3.3 s]
sage -t -long "devel/sage-9590/sage/combinat/words/suffix_trees.py"
	 [6.7 s]
sage -t -long "devel/sage-9590/sage/combinat/words/word_content.py"
	 [3.2 s]
sage -t -long "devel/sage-9590/sage/combinat/words/word_options.py"
	 [3.0 s]
sage -t -long "devel/sage-9590/sage/combinat/words/infinite_word.py"
	 [3.0 s]
sage -t -long "devel/sage-9590/sage/combinat/words/nfactor_enumerable_word.py"
	 [8.4 s]
sage -t -long "devel/sage-9590/sage/combinat/words/morphism.py"
	 [3.9 s]
sage -t -long "devel/sage-9590/sage/combinat/words/word_datatypes.pyx"
	 [3.2 s]
sage -t -long "devel/sage-9590/sage/combinat/words/abstract_word.py"
	 [3.6 s]
sage -t -long "devel/sage-9590/sage/combinat/words/utils.py"
	 [3.1 s]
sage -t -long "devel/sage-9590/sage/combinat/words/words.py"
	 [3.4 s]
sage -t -long "devel/sage-9590/sage/combinat/words/word_generators.py"
	 [13.0 s]
 
----------------------------------------------------------------------
All tests passed!
Total time for all tests: 105.0 seconds

real	1m45.120s
user	1m34.414s
sys	0m9.101s
leif@californication:~/sage-4.5.2.alpha0-j6/devel/sage-9590$ hg log | head -n 16
changeset:   14743:474058a85f79
tag:         tip
user:        Alexandre Blondin Masse < alexandre.blondin.masse at gmail.com>
date:        Sat Jul 24 09:59:44 2010 -0400
summary:     #9589 Doctest failure correction in nfactor_enumerable_word.py

changeset:   14742:ebb1e171e138
user:        Andrey Novoseltsev <[email protected]>
date:        Fri Jul 23 23:09:59 2010 -0600
summary:     Trac 9590: Doctest failures in cone and toric_lattice_element.

changeset:   14741:af5f40a73eda
user:        Mitesh Patel <[email protected]>
date:        Wed Jul 21 20:13:55 2010 -0700
summary:     4.5.2.alpha0

leif@californication:~/sage-4.5.2.alpha0-j6/devel/sage-9590$ 

(This is on Ubuntu 9.04 x86.)

@qed777
Copy link
Mannequin Author

qed777 mannequin commented Aug 6, 2010

Changed author from Alexandre Blondin Masse to Alexandre Blondin Massé

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant
and others