What does sage: C Set partitions of {'a', 'c', 'b'}
reveal? Is it helpful, or can it be omitted? Maybe it's good enough to do sage: C = SetPartitions(["a", "b", "c"]) sage: C.cardinality() 5 sage: sorted(C) [{{'a'}, {'b'}, {'c'}}, {{'a'}, {'b', 'c'}}, {{'a', 'b'}, {'c'}}, {{'a', 'b', 'c'}}, {{'a', 'c'}, {'b'}}] You should use your judgment about whether the doctest prints useful output for a reader, for example. If it needs different cases for py2 and py3, is it more helpful to print it or is it more confusing? On Friday, April 19, 2019 at 4:10:28 PM UTC-7, Andrew wrote: > > What the accepted best practice for fixing the failing python3 doc-tests? > For example, in `combinat/tutorial.py` I can fix one of the failing > doc-tests with: > > sage: C = SetPartitions(["a", "b", "c"]) > sage: C #py2 > Set partitions of {'a', 'c', 'b'} > sage: C #py3 > Set partitions of {'a', 'b', 'c'} > > but this does not address the underlying problem. At first sight this > looks like an issue with `SetPartitions` and, indeed, > `combinat/setpartition.py` has several failing doc-tests but as far as I > can see this is actually an issue with `Set` even though `sets/set.py` > passes all doc-tests. You can see this because > > Set(['a', 'b', 'c']) > > gives different output with each sage session, at least when `sage` is > compiled with python3. > > On Monday, 15 April 2019 21:56:54 UTC+10, Frédéric Chapoton wrote: >> >> Hello, >> >> sage-with-python3 (now using python 3.7.3) has now *less than 100 files* >> (94 precisely) with failing doctests, for a total of *324 failing >> doctests*. Among these, 34 files have a single failing doctest. >> >> A detailed summary can be found here : >> https://trac.sagemath.org/ticket/26212 >> >> There remains many hard-to-fix issues. Please help if you can. >> >> * Matroid, dynamics and combinat people should care for their code. The >> cluster code needs particular work. >> >> * We should also strive to make all tests pass in rings/ >> >> * An expert is required on src/sage/misc/classcall_metaclass.pyx >> >> Frédéric >> >> >> >> -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at https://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.