I am on a Linux system running TeX Live 2023 installed manually (not through the distro's repo), and up to date at the time of this writing (2023-04-21).
The following short document has started erroring after the most recent upgrade:
\documentclass[11pt]{article}
\usepackage{mathtools}
\usepackage{hyperref}
\usepackage{ntheorem}
\usepackage{cleveref}
\theoremstyle{plain}
\newtheorem{lemma}{Lemma}[section]
\title{}
\begin{document}
\maketitle
\begin{lemma}
\end{lemma}
\end{document}
Specifically, the error I receive is
ERROR: LaTeX Error: No counter '[' defined.
It goes away under any of the following circumstances:
I comment out
\usepackage{hyperref}I comment out
\usepackage{cleveref}I move
\usepackage{cleveref}above\usepackage{ntheorem}
I would like to use all three packages, so that 1. and 2. aren't really fixes. As for 3., it too has drawbacks: if it loads before ntheorem, cleveref seems to lose track of environment types when cross-referencing: \Cref{blah} always produces Lemma <blah> even if <blah> was something else (theorem, proposition, definition, etc.).
This is not happening on other systems I have access to (still Linux, still TeX Live 2023), which update their respective TeX Live distributions more rarely. I distinctly remember hyperref received a very recent upgrade that may have introduced this.
Edit
I have followed the advice in one of the comments below to roll back hyperref. Since I did not immediately how to do this, I am recording that here (per this other answer):
One first lists abvailable versions to revert to:
$ tlmgr restore hyperref
Available backups for hyperref: 65758 (2023-04-21 17:23)
and then, to actually effect the restoration:
$ tlmgr restore hyperref 65758
Do you really want to restore hyperref to revision 65758 (y/N): y
This will do fine for now: the file compiles all right on this earlier version of the package.
ntheoremnorcleverefhave received an update of late, a change inhyperref(which was updated most recently on Apr 20, i.e., just two days ago) may be the source of the issue. Note that I'm not going as far as calling it a "bug". – Mico Apr 22 '23 at 05:36