Sanity checks should be mandatory in all commands that modify the state of the repository. It appears that stg uncommit doesn't perform some checks, so it produces a result that the next command rejects. Here's my actual session:
proski@ins1:~/src/mono$ stg uncommit
> fix-sending-responses-from
proski@ins1:~/src/mono$ stg pop
error: HEAD and stack top are not the same. This can happen if you modify the branch with git. See `stg repair --help` for next steps to take.
proski@ins1:~/src/mono$ stg version
Stacked Git 2.3.1
Copyright (C) 2005-2022 StGit authors
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
SPDX-License-Identifier: GPL-2.0-only
git version 2.34.1