Hi Dima,

On 2016-08-17, Dima Pasechnik <dimp...@gmail.com> wrote:
> Do you mean to sat that  src/sage/groups/modular_cohomology/ would be 
> standard, and relying on meataxe
> at the same time (i.e., useless without meataxe) ? 

Let's better talk about code that you can look at, i.e.
src/sage/matrix/matrix_gfpn_dense.pyx

OptionalExtension results in a module *only* if meataxe is present. So,
if you do not have the optional meataxe spkg installed, then
  from sage.matrix import matrix_gfpn_dense
should simply result in an ImportError.

However, the source code src/sage/matrix/matrix_gfpn_dense.pyx is
present regardless whether meataxe is installed or not.

If I am not mistaken, SageMath's doctesting framework relies on what
source files can be found in the src/sage tree. It does not care whether
a source file corresponds to an actual importable module or not. And
that's bad IMHO.

That's why I believe that either the doctesting framework should only test
source files that correspond to an importable module, or at least there
should be a way to declare a whole source-file's tests as optional.

> IMHO it might be better to make it optional, and dependent on meataxe.
> This way if it is installed then meataxe is installed, too, and you can 
> doctest without #optional tags just fine.

Yes, it is optional, and at least in
src/sage/matrix/matrix_gfpn_dens.pyx I do use #optional tags. But no, I
don't think it is fine to use 5000 #optional tags, which would become
necessary when turning the Cython and Python parts of my cohomology
package into an OptionalExtension --- unless the doctesting framework is
changed as indicated above.

Best regards,
Simon


-- 
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.

Reply via email to