Skip to content

Read geometric_dimension as attribute or method, for Firedrake 2026 and earlier - #3

Open
hoffmaao wants to merge 1 commit into
icepack:mainfrom
hoffmaao:fix/firedrake-2026-geometric-dimension
Open

hoffmaao wants to merge 1 commit into
icepack:mainfrom
hoffmaao:fix/firedrake-2026-geometric-dimension

Conversation

@hoffmaao

Copy link
Copy Markdown
Member

Firedrake 2026 made Mesh.geometric_dimension an attribute; earlier releases expose it as a method. viscous_power and flow_law call it, so the ISMIP7 inversion could not run on the 2026 environment without this. The edit has lived uncommitted in the editable installs at Rice and on my workstation since 9 June (identical on both, md5 51db0898…), which is icepack/ismip7#46: two sites could not be shown to run the same icepack2, and Quartz runs without it.

Four lines, both call sites:

d = mesh.geometric_dimension          # FD2026: attribute; FD<=2025: method
d = d() if callable(d) else d

test/composite_rheology_test.py and test/momentum_balance_test.py pass on Firedrake 2026.4.1 (13 passed). Once this lands, install_deps.sh can clone rather than rsync and every site is on one committed state.

…nd earlier

Firedrake 2026 made Mesh.geometric_dimension an attribute; earlier releases
expose it as a method. viscous_power and flow_law called it, so the
inversion in icepack/ismip7 could not run on the 2026 environment without
this edit, which has lived uncommitted in the editable installs at Rice and
on one workstation since 9 June. Landing it so every site can clone rather
than rsync (icepack/ismip7#46).
@hoffmaao

Copy link
Copy Markdown
Member Author

@dlilien @danshapero for review: four lines, the Firedrake 2026 geometric_dimension shim that icepack/ismip7#46 traced to two uncommitted editable installs. Tests: 13 passed on 2026.4.1.

@dlilien

dlilien commented Sep 21, 2026

Copy link
Copy Markdown

Good by me, I think a similar approach is in icepack1, but I'll leave this one to @danshapero to decide since there are other failing tests.

@danshapero

Copy link
Copy Markdown
Member

We can also change this to only read it as an attribute and change the test suite to run on firedrake-2026.4.2 or whatever the latest release is. We're going to have to drop support for old Firedrakes from mainline icepack soon anyway.

dlilien added a commit to icepack/ismip7 that referenced this pull request Sep 22, 2026
The inversion needs two lines Firedrake 2026 forces on icepack2. They were
uncommitted edits in one workstation checkout, rsynced to the clusters, so
nobody could tell whether two sites ran the same code. They are now a commit
on the branch of icepack/icepack2#3, which is icepack2 main (40e848b) plus
those two files.

install_deps.sh names that branch's head by SHA and clones it, and
--check-icepack2 prints what a site has. A checkout that is not a clone, or
that carries local changes, is reported and left alone: the rsynced copy may
hold the only record of whatever else is in it. The three ICEPACK2_* variables
follow the fix onto main when the pull request merges, and
tests/test_icepack2_pin.py pins the defaults so that edit is deliberate.

The two annotations pointing at issue #66 are retargeted now that it is
closed: the re-measure the readiness rows owe belongs to issue #30.

Closes #46

Co-Authored-By: Claude Opus 5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants