Open lkastner opened 8 years ago
I haven't been working on Polyhedra2.m2. The original ideas was that gfanInterface2 would depend on PolyhedralObjects.m2 but not on Polyhedra.m2. I haven't been keeping up with the current status of gfanInterface2,Tropical, etc. You might want to check with Diane.
Re: "What is best practice for the tests for this interface? Can I make tests that only run if lrs is installed? "
For interfaces to proprietary software, such as Maple, we don't run tests. There are two ways to do that: have no tests; or use the option CacheExampleOutput => true. The latter will result in no tests being run automatically, and you must run the tests manually and add the output to the repository yourself whenever you think of it.
There seems to be an ubuntu package for it: http://packages.ubuntu.com/precise/i386/lrslib/filelist . If the software is free, we could add it as a library, as we do with many other packages, so, in case it's not installed on the system, we download the source and build it and ship it ourselves. That might be best, if you want people to be able to use it where it's not easily available. You could try adding the libary yourself as a subdirectory of the directory libraries
.
Re: "Can I make tests that should fail, i.e. check that an error is thrown?"
Yes, see "try ... catch ... ". But there is no way to tell whether the correct error was thrown! The function generateAssertions even knows that trick:
i10 : generateAssertions " 1/0 "
o10 =
assert( (try 1/0 else oops) === oops );
Re: "Can I send a pull request, even though the documentation is not fully updated yet?"
The major requirement for a pull request is that it be error free.
Here's the home page of lrs: http://cgm.cs.mcgill.ca/~avis/C/lrs.html
Thank you for your answers @DanGrayson .
Some minor issues are: @mikestillman @kathlenkohn @dmaclagan @nilten
Here is another problem: 'volume' projects the polytope down if dimension and ambient dimension do not agree. Is this behaviour we want?
@ggsmith
I will now send the first pull request. There are three commits on my master branch concerning other packages:
I thought these might help you what the issues might be. You can just cherry-pick around them and send the diff of these commits to the authors as a proposal on what to change.
Please tell me if I broke something else or should do something differently.
I'd appreciate it if, instead, you would just flag all the authors with @names in your pull request and ask them to comment.
This issue is dedicated to discussing various questions that came up while refactoring Polyhedra.m2. The current status can be found at my fork and can hopefully be merged soon. The bugs 1, in minkowskiSum and at various other places have been fixed. Many tests have been and will be added. The following should be discussed:
Additionally I have the following minor questions:
Can I send a pull request, even though the documentation is not fully updated yet? All the old and new tests work, as well as all the examples from the documentation. Except for a few exceptions, all functions still exhibit the same behaviour.