homalg-project / CategoricalTowers

Towers of category constructors
GNU General Public License v2.0
6 stars 4 forks source link

Missing case distinctions for precompiled code #595

Open zickgraf opened 1 week ago

zickgraf commented 1 week ago

If a category comes with different "cases" (like CategoryOfRows for fields, commutative rings, etc.), precompiled code of one case must not be loaded in the other cases. The required case distinctions seem to be missing in CategoricalTowers. For example, PreSheavesOfFreeAlgebroidInCategoryOfRowsPrecompiled is only precompiled for fields but loaded for non-fields, which leads to warnings and an error:

gap> LoadPackage( "FunctorCategories", false );
true
gap> QQ := HomalgFieldOfRationals( );;
gap> quiver := RightQuiver( "q(3)[a:1->2,b:2->3]" );;
gap> A := QQ[FreeCategory( quiver )];;
gap> A_bar := A / [ A.ab ];;
gap> PreSheaves( A, CategoryOfRows( HomalgRingOfIntegers() ) : no_precompiled_code );
PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )
gap> PreSheaves( A, CategoryOfRows( HomalgRingOfIntegers() ) );
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
WARNING: You are calling an Add function for a CAP operation for "PreSheaves( Algebroid( Q, FreeCategory( RightQuiver( "q(3)[a:1->2,b:2->3]" ) ) ), Rows( Z ) )" which is part of a homomorphism structure but the category has no RangeCategoryOfHomomorphismStructure (yet)
Error, <category> has operations related to the homomorphism structure but no range category is set. This is not supported.

Here, the different cases of CategoryOfRows have to be taken into account. Moreover, I expect that also the different cases of Algebroids (over_Z can be true or false) have to be taken into account. This also applies to other categories in CategoricalTowers.