Errores de compilación: (el comando \c@days ya está definido, el entorno end{} se ignora)

Errores de compilación: (el comando \c@days ya está definido, el entorno end{} se ignora)

Estoy intentando crear un calendario usando el paquete calendar.sty (agregado a continuación). Para eso utilicé knitr .rnw en R para recorrer una matriz con los parámetros del calendario y creé un archivo .tex. En mi opinión, el archivo .tex debería funcionar, pero no se compila con los siguientes errores. Estoy bastante seguro de que hay alguna colisión con ese paquete, pero parece que no puedo descubrir qué sucede exactamente para poder solucionarlo.

mis mensajes de error son esos dos (pero repetidos):

\@calendarwidth=\dimen274
\@currday=\count300
\@numdays=\count301
! LaTeX Error: Command \c@days already defined.
               Or name \end... illegal, see p.192 of the manual.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
...                                              
                                                      
l.148 \end{calendar}
                        
Your command was ignored.
Type  I <command> <return>  to replace it with another command,
or  <return>  to continue without it.

No tengo idea de cómo funciona \c@days o con qué colisiona, pero por alguna razón también ignora el \end{calendar} que debería finalizar el entorno, por lo que puede crear un nuevo entorno de calendario en la página siguiente.

mi archivo .tex (el primer error ocurre en \begin{document}, el otro error en \end{calendar}):

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Monthly Calendar
% LaTeX Template
% Version 1.2 (February 3, 2023)
%
% This template was downloaded from:
  % http://www.LaTeXTemplates.com
%
% Original author:
  % Evan Sultanik with modifications by 
% Vel ([email protected])
%
% License:
  % CC BY-NC-SA 4.0 (https://creativecommons.org/licenses/by-nc-sa/4.0/)
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%----------------------------------------------------------------------------------------
  % PACKAGES AND OTHER DOCUMENT CONFIGURATIONS
%----------------------------------------------------------------------------------------
  
\documentclass[10p]{article}\usepackage[]{graphicx}\usepackage[]{xcolor}
% maxwidth is the original width if it is less than linewidth
% otherwise use linewidth (to make sure the graphics do not exceed the margin)
\makeatletter
\def\maxwidth{ %
  \ifdim\Gin@nat@width>\linewidth
    \linewidth
  \else
    \Gin@nat@width
  \fi
}
\makeatother

\definecolor{fgcolor}{rgb}{0.345, 0.345, 0.345}
\newcommand{\hlnum}[1]{\textcolor[rgb]{0.686,0.059,0.569}{#1}}%
\newcommand{\hlstr}[1]{\textcolor[rgb]{0.192,0.494,0.8}{#1}}%
\newcommand{\hlcom}[1]{\textcolor[rgb]{0.678,0.584,0.686}{\textit{#1}}}%
\newcommand{\hlopt}[1]{\textcolor[rgb]{0,0,0}{#1}}%
\newcommand{\hlstd}[1]{\textcolor[rgb]{0.345,0.345,0.345}{#1}}%
\newcommand{\hlkwa}[1]{\textcolor[rgb]{0.161,0.373,0.58}{\textbf{#1}}}%
\newcommand{\hlkwb}[1]{\textcolor[rgb]{0.69,0.353,0.396}{#1}}%
\newcommand{\hlkwc}[1]{\textcolor[rgb]{0.333,0.667,0.333}{#1}}%
\newcommand{\hlkwd}[1]{\textcolor[rgb]{0.737,0.353,0.396}{\textbf{#1}}}%
\let\hlipl\hlkwb

\usepackage{framed}
\makeatletter
\newenvironment{kframe}{%
 \def\at@end@of@kframe{}%
 \ifinner\ifhmode%
  \def\at@end@of@kframe{\end{minipage}}%
  \begin{minipage}{\columnwidth}%
 \fi\fi%
 \def\FrameCommand##1{\hskip\@totalleftmargin \hskip-\fboxsep
 \colorbox{shadecolor}{##1}\hskip-\fboxsep
     % There is no \\@totalrightmargin, so:
     \hskip-\linewidth \hskip-\@totalleftmargin \hskip\columnwidth}%
 \MakeFramed {\advance\hsize-\width
   \@totalleftmargin\z@ \linewidth\hsize
   \@setminipage}}%
 {\par\unskip\endMakeFramed%
 \at@end@of@kframe}
\makeatother

\definecolor{shadecolor}{rgb}{.97, .97, .97}
\definecolor{messagecolor}{rgb}{0, 0, 0}
\definecolor{warningcolor}{rgb}{1, 0, 1}
\definecolor{errorcolor}{rgb}{1, 0, 0}
\newenvironment{knitrout}{}{} % an empty environment to be redefined in TeX

\usepackage{alltt} % Can also use 9pt or 11pt for a smaller or larger overall font size

%\usepackage{typearea} % makes switching between landscape and portrait possible
% use: 
  %\newpage
%\KOMAoptions{paper={portrait or landscape},pagesize}
%\recalctypearea
% to set up a change in rotation

\usepackage{calendar} % Use the calendar.sty style bundled with the template
\usepackage{parallel}
%\usepackage{enumitem}
\usepackage[landscape, a4paper, margin=0.5in]{geometry} % Page dimensions and margins
\usepackage{tikz}
\usepackage{pgffor} % creating forloops with foreach
\usepackage{forloop} %creating forloops with forloop
\usepackage{tabularx}
%\setlist{nosep}
%\usepackage{palatino} % Use the Palatino font

%----------------------------------------------------------------------------------------
  
%library(tikzDevice)


\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
\begin{document}
tlmgr search --global --file calendar.sty
tlmgr search --global --file forloop.sty
tlmgr search --global --file palatino.sty
\pagestyle{empty}
\noindent
\StartingDayNumber=2
\begin{center}
\textsc{\LARGE{ 
January
}}\newline
\textsc{\large {2024}}
\end{center}
\begin{calendar}{\linewidth}
\BlankDay
\BlankDay
\setcounter{calendardate}{1}
\newcounter{days}{0}
\day{Level 8}{easy non-crimp boulders of new set \eventskip chinups \eventskip stretching}
\day{Level 8}{new set \dayheader{Notes:}{}}
\day{~}{~}
\day{Hangboard}{\dayheader{Notes:}{}}
\day{Strength}{weighted Pullups \eventskip Deadlifts \eventskip Benchpulls \eventskip Flys \eventskip Muscleups}
\day{~}{\vspace{2.5cm}}
\day{Kilterboard}{Notes:}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\finishCalendar
\end{calendar}
\newpage
\noindent
\StartingDayNumber=2
\begin{center}
\textsc{\LARGE{ 
February
}}\newline
\textsc{\large {2024}}
\end{center}
\begin{calendar}{\linewidth}
\BlankDay
\BlankDay
\BlankDay
\setcounter{calendardate}{1}
\newcounter{days}{0}
\day{Hangboard}{\dayheader{Notes:}{}}
\day{Strength}{weighted Pullups \eventskip Deadlifts \eventskip Benchpulls \eventskip Flys \eventskip Muscleups}
\day{~}{\vspace{2.5cm}}
\day{Kilterboard}{Notes:}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\finishCalendar
\end{calendar}
\newpage
\noindent
\StartingDayNumber=2
\begin{center}
\textsc{\LARGE{ 
March
}}\newline
\textsc{\large {2024}}
\end{center}
\begin{calendar}{\linewidth}
\BlankDay
\BlankDay
\BlankDay
\BlankDay
\setcounter{calendardate}{1}
\newcounter{days}{0}
\day{Strength}{weighted Pullups \eventskip Deadlifts \eventskip Benchpulls \eventskip Flys \eventskip Muscleups}
\day{~}{\vspace{2.5cm}}
\day{Kilterboard}{Notes:}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\finishCalendar
\end{calendar}
\newpage
\noindent
\StartingDayNumber=2
\begin{center}
\textsc{\LARGE{ 
April
}}\newline
\textsc{\large {2024}}
\end{center}
\begin{calendar}{\linewidth}
\BlankDay
\BlankDay
\setcounter{calendardate}{1}
\newcounter{days}{0}
\day{Level 8}{easy non-crimp boulders of new set \eventskip chinups \eventskip stretching}
\day{Level 8}{new set \dayheader{Notes:}{}}
\day{~}{~}
\day{Hangboard}{\dayheader{Notes:}{}}
\day{Strength}{weighted Pullups \eventskip Deadlifts \eventskip Benchpulls \eventskip Flys \eventskip Muscleups}
\day{~}{\vspace{2.5cm}}
\day{Kilterboard}{Notes:}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\finishCalendar
\end{calendar}
\newpage
\noindent
\StartingDayNumber=2
\begin{center}
\textsc{\LARGE{ 
May
}}\newline
\textsc{\large {2024}}
\end{center}
\begin{calendar}{\linewidth}
\BlankDay
\BlankDay
\setcounter{calendardate}{1}
\newcounter{days}{0}
\day{~}{~}
\day{Hangboard}{\dayheader{Notes:}{}}
\day{Strength}{weighted Pullups \eventskip Deadlifts \eventskip Benchpulls \eventskip Flys \eventskip Muscleups}
\day{~}{\vspace{2.5cm}}
\day{Kilterboard}{Notes:}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\finishCalendar
\end{calendar}
\newpage
\noindent
\StartingDayNumber=2
\begin{center}
\textsc{\LARGE{ 
June
}}\newline
\textsc{\large {2024}}
\end{center}
\begin{calendar}{\linewidth}
\BlankDay
\BlankDay
\BlankDay
\BlankDay
\setcounter{calendardate}{1}
\newcounter{days}{0}
\day{Strength}{weighted Pullups \eventskip Deadlifts \eventskip Benchpulls \eventskip Flys \eventskip Muscleups}
\day{~}{\vspace{2.5cm}}
\day{Kilterboard}{Notes:}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\finishCalendar
\end{calendar}
\newpage
\noindent
\StartingDayNumber=2
\begin{center}
\textsc{\LARGE{ 
July
}}\newline
\textsc{\large {2024}}
\end{center}
\begin{calendar}{\linewidth}
\BlankDay
\BlankDay
\setcounter{calendardate}{1}
\newcounter{days}{0}
\day{Level 8}{easy non-crimp boulders of new set \eventskip chinups \eventskip stretching}
\day{Level 8}{new set \dayheader{Notes:}{}}
\day{~}{~}
\day{Hangboard}{\dayheader{Notes:}{}}
\day{Strength}{weighted Pullups \eventskip Deadlifts \eventskip Benchpulls \eventskip Flys \eventskip Muscleups}
\day{~}{\vspace{2.5cm}}
\day{Kilterboard}{Notes:}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\finishCalendar
\end{calendar}
\newpage
\noindent
\StartingDayNumber=2
\begin{center}
\textsc{\LARGE{ 
August
}}\newline
\textsc{\large {2024}}
\end{center}
\begin{calendar}{\linewidth}
\BlankDay
\BlankDay
\BlankDay
\setcounter{calendardate}{1}
\newcounter{days}{0}
\day{Hangboard}{\dayheader{Notes:}{}}
\day{Strength}{weighted Pullups \eventskip Deadlifts \eventskip Benchpulls \eventskip Flys \eventskip Muscleups}
\day{~}{\vspace{2.5cm}}
\day{Kilterboard}{Notes:}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\finishCalendar
\end{calendar}
\newpage
\noindent
\StartingDayNumber=2
\begin{center}
\textsc{\LARGE{ 
September
}}\newline
\textsc{\large {2024}}
\end{center}
\begin{calendar}{\linewidth}
\BlankDay
\setcounter{calendardate}{1}
\newcounter{days}{0}
\day{Level 8}{new set \dayheader{Notes:}{}}
\day{~}{~}
\day{Hangboard}{\dayheader{Notes:}{}}
\day{Strength}{weighted Pullups \eventskip Deadlifts \eventskip Benchpulls \eventskip Flys \eventskip Muscleups}
\day{~}{\vspace{2.5cm}}
\day{Kilterboard}{Notes:}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\finishCalendar
\end{calendar}
\newpage
\noindent
\StartingDayNumber=2
\begin{center}
\textsc{\LARGE{ 
October
}}\newline
\textsc{\large {2024}}
\end{center}
\begin{calendar}{\linewidth}
\BlankDay
\setcounter{calendardate}{1}
\newcounter{days}{0}
\day{Level 8}{new set \dayheader{Notes:}{}}
\day{~}{~}
\day{Hangboard}{\dayheader{Notes:}{}}
\day{Strength}{weighted Pullups \eventskip Deadlifts \eventskip Benchpulls \eventskip Flys \eventskip Muscleups}
\day{~}{\vspace{2.5cm}}
\day{Kilterboard}{Notes:}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\finishCalendar
\end{calendar}
\newpage
\noindent
\StartingDayNumber=2
\begin{center}
\textsc{\LARGE{ 
November
}}\newline
\textsc{\large {2024}}
\end{center}
\begin{calendar}{\linewidth}
\BlankDay
\BlankDay
\BlankDay
\setcounter{calendardate}{1}
\newcounter{days}{0}
\day{Hangboard}{\dayheader{Notes:}{}}
\day{Strength}{weighted Pullups \eventskip Deadlifts \eventskip Benchpulls \eventskip Flys \eventskip Muscleups}
\day{~}{\vspace{2.5cm}}
\day{Kilterboard}{Notes:}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\finishCalendar
\end{calendar}
\newpage
\noindent
\StartingDayNumber=2
\begin{center}
\textsc{\LARGE{ 
December
}}\newline
\textsc{\large {2024}}
\end{center}
\begin{calendar}{\linewidth}
\BlankDay
\setcounter{calendardate}{1}
\newcounter{days}{0}
\day{Level 8}{new set \dayheader{Notes:}{}}
\day{~}{~}
\day{Hangboard}{\dayheader{Notes:}{}}
\day{Strength}{weighted Pullups \eventskip Deadlifts \eventskip Benchpulls \eventskip Flys \eventskip Muscleups}
\day{~}{\vspace{2.5cm}}
\day{Kilterboard}{Notes:}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\day{~}{\vspace{2.5cm}}
\finishCalendar
\end{calendar}
\newpage
\end{document}

calendario.sty:

\NeedsTeXFormat{LaTeX2e}

\def\CalendarVersion{3.3}
\def\CalendarVersionDate{2023/02/03}

\ProvidesClass{calendar}[\CalendarVersionDate
           LaTeX2e class file `calendar' v\CalendarVersion]

\typeout{'calendar' style \CalendarVersion \CalendarVersionDate.}
\typeout{Created by Evan Sultanik}
\typeout{****** Bugs/comments/suggestions/technicalities to Evan Sultanik -- [email protected] ******}

\RequirePackage{tabularx}

\def\@CALtrue{1}
\newcount\@currentdaynum
\newcounter{calendardate}
\newcount\StartingDayNumber

\def\dayheader#1#2{
  \vspace{2pt} % Whitespace above the heading
  \begin{minipage}[t]{0.87\hsize}
    \raggedright
    \small % Small font size
    \textit{#1}
  \end{minipage}
  \begin{minipage}[t]{0.1\hsize}
    \raggedleft
    \textit{#2}
  \end{minipage}%
}
\def\activities#1{
  \parbox{\hsize}{\vspace*{5pt}\raggedright\scriptsize #1}\smallskip
}

\let\@colbreak=&

\def\printdayname#1{\hfil\textsc{#1}\hfil}

\newcommand{\dayname}[1]{
  \ifnum#1=1 Sunday\else
  \ifnum#1=2 Monday\else
  \ifnum#1=3 Tuesday\else
  \ifnum#1=4 Wednesday\else
  \ifnum#1=5 Thursday\else
  \ifnum#1=6 Friday\else
  \ifnum#1=7 Saturday\else
    \PackageError{calendar}{Unrecognized day number: #1!}
  \fi\fi\fi\fi\fi\fi\fi
}

\StartingDayNumber=1
\newenvironment{calendar}[1]{
  \newdimen\@calendarwidth
  \@calendarwidth=#1
  \begingroup
    \def\@calendarmode{\@CALtrue}
  \def\day##1##2{
  \if\@calendarmode\@CALtrue\else\PackageWarning{calendar}{The '\day' macro is expected to be used in the 'calendar' environment!}\fi
  \ifnum\@currentdaynum>7\global\@currentdaynum=1\fi
  \global\advance\@currentdaynum by 1
  \vspace{-0.5\baselineskip} % Reduce the whitespace above the first day heading
  \dayheader{##1}{\thecalendardate}\def\daysep{\vskip1pt\hrule\vskip1pt}
  \activities{##2}
  \addtocounter{calendardate}{1}
  \ifnum\@currentdaynum>7\@arraycr\hline\else&\fi
  }
\def\finishCalendar{
  \ifnum\@currentdaynum=7 \\\hline\else
  \ifnum\@currentdaynum=6 &\\\hline\else
  \ifnum\@currentdaynum=5 &&\\\hline\else
  \ifnum\@currentdaynum=4 &&&\\\hline\else
  \ifnum\@currentdaynum=3 &&&&\\\hline\else
  \ifnum\@currentdaynum=2 &&&&&\\\hline\else
  \ifnum\@currentdaynum=1 &&&&&&\\\hline
  \fi\fi\fi\fi\fi\fi\fi
}
\def\eventskip{\\\vspace{4pt}}
  \def\BlankDay{
  \if\@calendarmode\@CALtrue\else\PackageWarning{calendar}{The '\calendarday' macro is expected to be used in the 'calendar' environment!}\fi
  \ifnum\@currentdaynum>7\global\@currentdaynum=1\fi
  \global\advance\@currentdaynum by 1
  \addtocounter{calendardate}{1}
  \ifnum\@currentdaynum>7\@arraycr\hline\else&\fi
  }

    \setcounter{calendardate}{1}
    \newcount\@currday
    \@currday=\StartingDayNumber
    \newcount\@numdays
    \@numdays=7
    \let\@cbreak=&
    \tabularx{\@calendarwidth}{|X|X|X|X|X|X|X|} \hline
    \ifnum\@currday>\@numdays\@currday=1\fi\printdayname{\dayname{\@currday}} \global\advance\@currday by 1 &
    \ifnum\@currday>\@numdays\@currday=1\fi\printdayname{\dayname{\@currday}} \global\advance\@currday by 1 &
    \ifnum\@currday>\@numdays\@currday=1\fi\printdayname{\dayname{\@currday}} \global\advance\@currday by 1 &
    \ifnum\@currday>\@numdays\@currday=1\fi\printdayname{\dayname{\@currday}} \global\advance\@currday by 1 &
    \ifnum\@currday>\@numdays\@currday=1\fi\printdayname{\dayname{\@currday}} \global\advance\@currday by 1 &
    \ifnum\@currday>\@numdays\@currday=1\fi\printdayname{\dayname{\@currday}} \global\advance\@currday by 1 &
    \ifnum\@currday>\@numdays\@currday=1\fi\printdayname{\dayname{\@currday}} \global\advance\@currday by 1 \\ \hline \hline
      \@currentdaynum=1
      \let\@firstline=\@CALtrue
}{
    \endtabularx
  \endgroup
}

\pagestyle{empty} % Disable default headers and footers

\setlength{\parindent}{0pt} % Stop paragraph indentation

Respuesta1

tienes multiples

\newcounter{days}{0}

\newcountersolo tiene un argumento por lo que todos deberían ser

\setcounter{days}{0}

Luego debe asignar el contador (¡sólo una vez!) en el preámbulo del documento, así que agregue

\newcounter{days}

información relacionada