Skip to content

Commit

Permalink
Merge pull request #54 from mohamed-barakat/devel
Browse files Browse the repository at this point in the history
comply with CAP v2022.11-06
  • Loading branch information
mohamed-barakat authored Nov 3, 2022
2 parents 936d30e + e4ce4fe commit 6dedd54
Show file tree
Hide file tree
Showing 7 changed files with 38 additions and 15 deletions.
9 changes: 4 additions & 5 deletions .github/workflows/Tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,8 @@ jobs:
steps:
# keep workflow active even if repository has no activity for 60 days (do not execute for pull requests)
- run: '[ "$GITHUB_EVENT_NAME" = "pull_request" ] || curl --fail -X PUT -H "Accept: application/vnd.github.v3+json" -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" https://api.github.com/repos/$GITHUB_REPOSITORY/actions/workflows/Tests.yml/enable'
- uses: actions/checkout@v1
- run: mkdir -p /home/gap/.gap/pkg/
- run: sudo cp -a $GITHUB_WORKSPACE /home/gap/.gap/pkg/
- run: sudo chown -R gap:gap /home/gap/.gap/pkg/
- uses: actions/checkout@v3
- run: cp -a $GITHUB_WORKSPACE /home/gap/.gap/pkg/
- run: |
export HOME="/home/gap"
cd /home/gap/.gap/pkg/
Expand Down Expand Up @@ -53,7 +51,7 @@ jobs:
[ -d "homalg_project/homalg" ] && make -C "homalg_project/homalg" doc
[ -d "homalg_project/Modules" ] && make -C "homalg_project/Modules" doc
[ -d "Toposes" ] && make -C "Toposes" doc
TERM=dumb make -C CatReps -j $(nproc) --output-sync ci-test
make -C CatReps -j $(nproc) --output-sync ci-test
cp ./CatReps/.codecov.yml ./
(cd CatReps && LANG=C.UTF-8 python3 process_coverage.py)
[ "$GITHUB_EVENT_NAME" != "schedule" ] && [ "${{ matrix.image }}" = "ghcr.io/homalg-project/gap-docker-master:latest" ] && ./CatReps/upload_codecov.sh
Expand All @@ -62,6 +60,7 @@ jobs:
cd CatReps
CUR_SHA=$(git rev-parse --verify HEAD)
if [ "${{ matrix.image }}" = "ghcr.io/homalg-project/gap-docker:latest" ] && [ "$CUR_SHA" = "$(git rev-parse origin/master)" ] && [ $(dirname "$GITHUB_REPOSITORY") = "homalg-project" ]; then \
git fetch origin gh-pages; \
git worktree add gh-pages/ gh-pages || (echo "There was an error. Make sure there is a branch named 'gh-pages'. See https://github.com/homalg-project/PackageJanitor#error-there-was-an-error-make-sure-there-is-a-branch-named-gh-pages"; exit 1); \
git checkout master; \
LANG=C.UTF-8 ./make_dist.sh --token "${{ secrets.GITHUB_TOKEN }}"; \
Expand Down
6 changes: 3 additions & 3 deletions PackageInfo.g
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ SetPackageInfo( rec(

PackageName := "CatReps",
Subtitle := "Representations and cohomology of finite categories",
Version := "2022.10-04",
Version := "2022.11-01",

Date := ~.Version{[ 1 .. 10 ]},
Date := Concatenation( "01/", ~.Version{[ 6, 7 ]}, "/", ~.Version{[ 1 .. 4 ]} ),
Expand Down Expand Up @@ -97,10 +97,10 @@ PackageDoc := rec(
),

Dependencies := rec(
GAP := ">= 4.11.1",
GAP := ">= 4.12.1",
NeededOtherPackages := [
[ "GAPDoc", ">= 1.5" ],
[ "CAP", ">= 2022.09-17" ],
[ "CAP", ">= 2022.11-06" ],
[ "MonoidalCategories", ">= 2021.08-01" ],
[ "LinearAlgebraForCAP", ">= 2021.07-01" ],
[ "FinSetsForCAP", ">= 2022.05-07" ],
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ The supported categorical doctrine of the category of representations is

```gap
gap> InfoOfInstalledOperationsOfCategory( CatReps );
95 primitive operations were used to derive 317 operations for this category
95 primitive operations were used to derive 318 operations for this category
which constructively
* IsEquippedWithHomomorphismStructure
* IsLinearCategoryOverCommutativeRing
Expand Down
30 changes: 27 additions & 3 deletions ci_gaprc
Original file line number Diff line number Diff line change
@@ -1,12 +1,36 @@
# Prefer GAPInfo.UserGapRoot over other package directories to prevent accidentally testing package
# versions distributed with GAP.
(function()

FORCE_LOADING_FROM_USER_GAP_ROOT := function ( )
local name, package_info, pos;
for name in RecNames( GAPInfo.PackagesInfo ) do
package_info := GAPInfo.PackagesInfo.(name);
pos := PositionProperty( package_info, info -> StartsWith( info.InstallationPath, GAPInfo.UserGapRoot ) );
if pos <> fail then
SetPackagePath( name, package_info[pos].InstallationPath );
# work around https://github.com/gap-system/gap/pull/5178
if IsBound( GAPInfo.PackagesLoaded.(name) ) then
if StartsWith( GAPInfo.PackagesLoaded.(name)[1], GAPInfo.UserGapRoot ) then
continue;
else
Error( "package already loaded at ", GAPInfo.PackagesLoaded.(name)[1] );
fi;
else
SetPackagePath( name, package_info[pos].InstallationPath );
fi;
fi;
od;
end)();
end;

FORCE_LOADING_FROM_USER_GAP_ROOT( );

MakeReadWriteGlobal( "InitializePackagesInfoRecords" );
FORCE_LOADING_FROM_USER_GAP_ROOT_InitializePackagesInfoRecords_orig := InitializePackagesInfoRecords;
InitializePackagesInfoRecords := function ( args... )
local old_PackagesInfo;
old_PackagesInfo := GAPInfo.PackagesInfo;
CallFuncList( FORCE_LOADING_FROM_USER_GAP_ROOT_InitializePackagesInfoRecords_orig, args );
if not IsIdenticalObj( old_PackagesInfo, GAPInfo.PackagesInfo ) then
FORCE_LOADING_FROM_USER_GAP_ROOT( );
fi;
end;
MakeReadOnlyGlobal( "InitializePackagesInfoRecords" );
2 changes: 1 addition & 1 deletion examples/CategoryOfRepresentations.g
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ CatReps := FunctorCategory( A, GF3 );
#! RightQuiver( "q(2)[a:1->1,b:1->2,c:2->2]" ) ) ) / relations,
#! Category of matrices over GF(3) )
InfoOfInstalledOperationsOfCategory( CatReps );
#! 95 primitive operations were used to derive 317 operations for this category
#! 95 primitive operations were used to derive 318 operations for this category
#! which algorithmically
#! * IsEquippedWithHomomorphismStructure
#! * IsLinearCategoryOverCommutativeRing
Expand Down
2 changes: 1 addition & 1 deletion examples/notebooks/CategoryOfRepresentations.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -515,7 +515,7 @@
"name": "stdout",
"output_type": "stream",
"text": [
"95 primitive operations were used to derive 317 operations for this category which algorithmically\n",
"95 primitive operations were used to derive 318 operations for this category which algorithmically\n",
"* IsEquippedWithHomomorphismStructure\n",
"* IsLinearCategoryOverCommutativeRing\n",
"* IsSymmetricMonoidalCategory\n",
Expand Down
2 changes: 1 addition & 1 deletion upload_codecov.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ shasum -a 256 -c codecov.SHA256SUM

# execute
chmod +x codecov
./codecov -Z || ./codecov -Z || ./codecov -Z
./codecov -Z || (sleep 30; ./codecov -Z || (sleep 30; ./codecov -Z))

0 comments on commit 6dedd54

Please sign in to comment.