Unable to publish Shiny App on Rstudio-Connect

I suddenly became unable to publish my app onto RStudio Connect, and I am not sure what the cause is. It is failing because of an error with lme4 and/or R snapshot restore. There app runs locally and I published it successfully a few days ago with no problems.

Here is the output from the log file:

11/07 07:48:45.612 (GMT)
g++ -std=gnu++17 -I"/usr/share/R/include" -DNDEBUG -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include' -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -c glmFamily.cpp -o glmFamily.o
11/07 07:48:45.612 (GMT)
g++ -std=gnu++17 -I"/usr/share/R/include" -DNDEBUG -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include' -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -c optimizer.cpp -o optimizer.o
11/07 07:48:45.612 (GMT)
g++ -std=gnu++17 -I"/usr/share/R/include" -DNDEBUG -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include' -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -c predModule.cpp -o predModule.o
11/07 07:48:45.612 (GMT)
g++ -std=gnu++17 -I"/usr/share/R/include" -DNDEBUG -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include' -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -c respModule.cpp -o respModule.o
11/07 07:48:45.612 (GMT)
In file included from predModule.h:13:0,
11/07 07:48:45.612 (GMT)
from predModule.cpp:8:
11/07 07:48:45.612 (GMT)
lme4CholmodDecomposition.h:20:72: error: expected template-name before ‘<’ token
11/07 07:48:45.612 (GMT)
class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {
11/07 07:48:45.612 (GMT)
^
11/07 07:48:45.612 (GMT)
lme4CholmodDecomposition.h:20:72: error: expected ‘{’ before ‘<’ token
11/07 07:48:45.612 (GMT)
In file included from predModule.h:13:0,
11/07 07:48:45.612 (GMT)
from predModule.cpp:8:
11/07 07:48:45.612 (GMT)
lme4CholmodDecomposition.h: In function ‘SEXPREC* lme4::Eigen_cholmod_wrap(const lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<Scalar> >&)’:
11/07 07:48:45.612 (GMT)
lme4CholmodDecomposition.h:77:15: error: ‘cholmod_factor’ does not name a type; did you mean ‘chkder_factor’?
11/07 07:48:45.612 (GMT)
const cholmod_factor* f = obj.factor();
11/07 07:48:45.612 (GMT)
^~~~~~~~~~~~~~
11/07 07:48:45.612 (GMT)
chkder_factor
11/07 07:48:45.612 (GMT)
lme4CholmodDecomposition.h:78:13: error: ‘f’ was not declared in this scope
11/07 07:48:45.612 (GMT)
if (f->minor < f->n)
11/07 07:48:45.612 (GMT)
^
11/07 07:48:45.612 (GMT)
lme4CholmodDecomposition.h:82:36: error: ‘f’ was not declared in this scope
11/07 07:48:45.612 (GMT)
::Rcpp::S4 ans(std::string(f->is_super ? "dCHMsuper" : "dCHMsimpl"));
11/07 07:48:45.612 (GMT)
^
11/07 07:48:45.612 (GMT)
In file included from predModule.cpp:8:0:
11/07 07:48:45.612 (GMT)
predModule.h: At global scope:
11/07 07:48:45.612 (GMT)
predModule.h:40:23: error: field ‘d_L’ has incomplete type ‘lme4::merPredD::ChmDecomp {aka lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
11/07 07:48:45.612 (GMT)
ChmDecomp d_L;
11/07 07:48:45.613 (GMT)
^~~
11/07 07:48:45.613 (GMT)
In file included from predModule.h:13:0,
11/07 07:48:45.613 (GMT)
from predModule.cpp:8:
11/07 07:48:45.613 (GMT)
lme4CholmodDecomposition.h:20:11: note: declaration of ‘lme4::merPredD::ChmDecomp {aka class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
11/07 07:48:45.613 (GMT)
class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {
11/07 07:48:45.613 (GMT)
^~~~~~~~~~~~~~~~~~~~~~~~
11/07 07:48:45.613 (GMT)
In file included from predModule.h:13:0,
11/07 07:48:45.613 (GMT)
from external.cpp:8:
11/07 07:48:45.613 (GMT)
lme4CholmodDecomposition.h:20:72: error: expected template-name before ‘<’ token
11/07 07:48:45.613 (GMT)
class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {
11/07 07:48:45.613 (GMT)
^
11/07 07:48:45.613 (GMT)
lme4CholmodDecomposition.h:20:72: error: expected ‘{’ before ‘<’ token
11/07 07:48:45.613 (GMT)
In file included from predModule.h:13:0,
11/07 07:48:45.613 (GMT)
from external.cpp:8:
11/07 07:48:45.613 (GMT)
lme4CholmodDecomposition.h: In function ‘SEXPREC* lme4::Eigen_cholmod_wrap(const lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<Scalar> >&)’:
11/07 07:48:45.613 (GMT)
lme4CholmodDecomposition.h:77:15: error: ‘cholmod_factor’ does not name a type; did you mean ‘chkder_factor’?
11/07 07:48:45.613 (GMT)
const cholmod_factor* f = obj.factor();
11/07 07:48:45.613 (GMT)
^~~~~~~~~~~~~~
11/07 07:48:45.613 (GMT)
chkder_factor
11/07 07:48:45.613 (GMT)
lme4CholmodDecomposition.h:78:13: error: ‘f’ was not declared in this scope
11/07 07:48:45.613 (GMT)
if (f->minor < f->n)
11/07 07:48:45.613 (GMT)
^
11/07 07:48:45.613 (GMT)
lme4CholmodDecomposition.h:82:36: error: ‘f’ was not declared in this scope
11/07 07:48:45.613 (GMT)
::Rcpp::S4 ans(std::string(f->is_super ? "dCHMsuper" : "dCHMsimpl"));
11/07 07:48:45.613 (GMT)
^
11/07 07:48:45.613 (GMT)
predModule.cpp: In member function ‘Rcpp::List lme4::merPredD::condVar(const Environment&) const’:
11/07 07:48:45.613 (GMT)
predModule.cpp:122:43: error: ‘CHOLMOD_A’ was not declared in this scope
11/07 07:48:45.613 (GMT)
d_L.solveInPlace(LvT, CHOLMOD_A);
11/07 07:48:45.613 (GMT)
^~~~~~~~~
11/07 07:48:45.613 (GMT)
In file included from external.cpp:8:0:
11/07 07:48:45.613 (GMT)
predModule.h: At global scope:
11/07 07:48:45.613 (GMT)
predModule.h:40:23: error: field ‘d_L’ has incomplete type ‘lme4::merPredD::ChmDecomp {aka lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
11/07 07:48:45.613 (GMT)
ChmDecomp d_L;
11/07 07:48:45.613 (GMT)
^~~
11/07 07:48:45.613 (GMT)
In file included from predModule.h:13:0,
11/07 07:48:45.613 (GMT)
from external.cpp:8:
11/07 07:48:45.613 (GMT)
lme4CholmodDecomposition.h:20:11: note: declaration of ‘lme4::merPredD::ChmDecomp {aka class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
11/07 07:48:45.613 (GMT)
class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {
11/07 07:48:45.613 (GMT)
^~~~~~~~~~~~~~~~~~~~~~~~
11/07 07:48:45.613 (GMT)
external.cpp: In function ‘SEXPREC* glmerAGQ(SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP)’:
11/07 07:48:45.613 (GMT)
external.cpp:437:18: error: invalid use of incomplete type ‘const ChmDecomp {aka const class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
11/07 07:48:45.613 (GMT)
if (pp->L().factor()->nzmax != q)
11/07 07:48:45.613 (GMT)
~~~~~^~
11/07 07:48:45.613 (GMT)
In file included from predModule.h:13:0,
11/07 07:48:45.613 (GMT)
from external.cpp:8:
11/07 07:48:45.613 (GMT)
lme4CholmodDecomposition.h:20:11: note: declaration of ‘lme4::merPredD::ChmDecomp {aka class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
11/07 07:48:45.613 (GMT)
class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {
11/07 07:48:45.613 (GMT)
^~~~~~~~~~~~~~~~~~~~~~~~
11/07 07:48:45.613 (GMT)
external.cpp:439:49: error: invalid use of incomplete type ‘const ChmDecomp {aka const class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
11/07 07:48:45.613 (GMT)
const Ar1 sd(MAr1((double*)pp->L().factor()->x, q).inverse());
11/07 07:48:45.613 (GMT)
~~~~~^~
11/07 07:48:45.614 (GMT)
In file included from predModule.h:13:0,
11/07 07:48:45.614 (GMT)
from external.cpp:8:
11/07 07:48:45.614 (GMT)
lme4CholmodDecomposition.h:20:11: note: declaration of ‘lme4::merPredD::ChmDecomp {aka class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
11/07 07:48:45.614 (GMT)
class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {
11/07 07:48:45.614 (GMT)
11/07 07:48:45.614 (GMT)
11/07 07:48:45.614 (GMT)
Unable to fully restore the R packages associated with this deployment.
11/07 07:48:45.614 (GMT)
Please review the preceding messages to determine which package
11/07 07:48:45.614 (GMT)
encountered installation difficulty and the cause of the failure.

Here is the output from the Deploy tab in Rstudio:

curl: HTTP 200 https://cran.rstudio.com/src/contrib/Archive/lme4/lme4_1.1-34.tar.gz
[1] "Command failed (1)\n\nFailed to run system command:\n\n\t'/usr/lib/R/bin/R' --vanilla CMD INSTALL --preclean '/opt/rstudio-connect/mnt/tmp/Rtmpbc5bvi/packrat-install-6dfd3e5d03fb/lme4' --library='/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0' --install-tests --no-docs --no-multiarch --no-demo \n\nThe command failed with output:\n* installing *source* package ‘lme4’ ...\n** package ‘lme4’ successfully unpacked and MD5 sums checked\n** using staged installation\n** libs\nusing C++ compiler: ‘g++ (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0’\ng++ -std=gnu++17 -I\"/usr/share/R/include\" -DNDEBUG  -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include'    -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=
2  -c external.cpp -o external.o\ng++ -std=gnu++17 -I\"/usr/share/R/include\" -DNDEBUG  -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include'    -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -c glmFamily.cpp -o glmFamily.o\ng++ -std=gnu++17 -I\"/usr/share/R/include\" -DNDEBUG  -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include'    -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -c optimizer.cpp -o optimizer.o\ng++ -std=gnu++17 -I\"/usr/share/R/include\" -DNDEBUG  -I'/opt/rstudio-connect/mn
t/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include'    -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -c predModule.cpp -o predModule.o\ng++ -std=gnu++17 -I\"/usr/share/R/include\" -DNDEBUG  -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include'    -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -c respModule.cpp -o respModule.o\nIn file included from predModule.h:13:0,\n                 from predModule.cpp:8:\nlme4CholmodDecomposition.h:20:72: error: expected template-name before ‘<’ token\n     class lme4Cholmo
dDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {\n                                                                        ^\nlme4CholmodDecomposition.h:20:72: error: expected ‘{’ before ‘<’ token\nIn file included from predModule.h:13:0,\n                 from predModule.cpp:8:\nlme4CholmodDecomposition.h: In function ‘SEXPREC* lme4::Eigen_cholmod_wrap(const lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<Scalar> >&)’:\nlme4CholmodDecomposition.h:77:15: error: ‘cholmod_factor’ does not name a type; did you mean ‘chkder_factor’?\n         const cholmod_factor* f = obj.factor();\n               ^~~~~~~~~~~~~~\n               chkder_factor\nlme4CholmodDecomposition.h:78:13: error: ‘f’ was not declared in this scope\n         if (f->minor < f->n)\n             ^\nlme4CholmodDecomposition.h:82:36: error: ‘f’ was not declared in this scope\n         ::Rcpp::S4 ans(std::string(f->is_super ? \"dCHMsuper\" : \"dCHMsimpl\"));\n                                    ^
\nIn file included from predModule.cpp:8:0:\npredModule.h: At global scope:\npredModule.h:40:23: error: field ‘d_L’ has incomplete type ‘lme4::merPredD::ChmDecomp {aka lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’\n         ChmDecomp     d_L;\n                       ^~~\nIn file included from predModule.h:13:0,\n                 from predModule.cpp:8:\nlme4CholmodDecomposition.h:20:11: note: declaration of ‘lme4::merPredD::ChmDecomp {aka class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’\n     class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {\n           ^~~~~~~~~~~~~~~~~~~~~~~~\nIn file included from predModule.h:13:0,\n                 from external.cpp:8:\nlme4CholmodDecomposition.h:20:72: error: expected template-name before ‘<’ token\n     class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {\n                                                                       
 ^\nlme4CholmodDecomposition.h:20:72: error: expected ‘{’ before ‘<’ token\nIn file included from predModule.h:13:0,\n                 from external.cpp:8:\nlme4CholmodDecomposition.h: In function ‘SEXPREC* lme4::Eigen_cholmod_wrap(const lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<Scalar> >&)’:\nlme4CholmodDecomposition.h:77:15: error: ‘cholmod_factor’ does not name a type; did you mean ‘chkder_factor’?\n         const cholmod_factor* f = obj.factor();\n               ^~~~~~~~~~~~~~\n               chkder_factor\nlme4CholmodDecomposition.h:78:13: error: ‘f’ was not declared in this scope\n         if (f->minor < f->n)\n             ^\nlme4CholmodDecomposition.h:82:36: error: ‘f’ was not declared in this scope\n         ::Rcpp::S4 ans(std::string(f->is_super ? \"dCHMsuper\" : \"dCHMsimpl\"));\n                                    ^\npredModule.cpp: In member function ‘Rcpp::List lme4::merPredD::condVar(const Environment&) const’:\npredModule.cpp:122:43: error: ‘CHOLMOD_A
’ was not declared in this scope\n                     d_L.solveInPlace(LvT, CHOLMOD_A);\n                                           ^~~~~~~~~\nIn file included from external.cpp:8:0:\npredModule.h: At global scope:\npredModule.h:40:23: error: field ‘d_L’ has incomplete type ‘lme4::merPredD::ChmDecomp {aka lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’\n         ChmDecomp     d_L;\n                       ^~~\nIn file included from predModule.h:13:0,\n                 from external.cpp:8:\nlme4CholmodDecomposition.h:20:11: note: declaration of ‘lme4::merPredD::ChmDecomp {aka class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’\n     class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {\n           ^~~~~~~~~~~~~~~~~~~~~~~~\nexternal.cpp: In function ‘SEXPREC* glmerAGQ(SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP)’:\nexternal.cpp:437:18: error: invalid use of incomplete type ‘const ChmDecomp {aka const class lme4:
:lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’\n         if (pp->L().factor()->nzmax !=  q)\n             ~~~~~^~\nIn file included from predModule.h:13:0,\n                 from external.cpp:8:\nlme4CholmodDecomposition.h:20:11: note: declaration of ‘lme4::merPredD::ChmDecomp {aka class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’\n     class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {\n           ^~~~~~~~~~~~~~~~~~~~~~~~\nexternal.cpp:439:49: error: invalid use of incomplete type ‘const ChmDecomp {aka const class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’\n         const Ar1         sd(MAr1((double*)pp->L().factor()->x, q).inverse());\n                                            ~~~~~^~\nIn file included from predModule.h:13:0,\n                 from external.cpp:8:\nlme4CholmodDecomposition.h:20:11: note: declaration of ‘lme4::merPredD::ChmDecomp {aka class lme4::lme4CholmodDecomposi
tion<Eigen::SparseMatrix<double, 0, int> >}’\n     class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {\n           ^~~~~~~~~~~~~~~~~~~~~~~~\npredModule.cpp: In member function ‘void lme4::merPredD::updateL()’:\npredModule.cpp:154:20: error: ‘::M_chm_factor_ldetL2’ has not been declared\n         d_ldL2 = ::M_chm_factor_ldetL2(d_L.factor());\n                    ^~~~~~~~~~~~~~~~~~~\npredModule.cpp: In member function ‘lme4::merPredD::Scalar lme4::merPredD::solve()’:\npredModule.cpp:186:34: error: ‘CHOLMOD_P’ was not declared in this scope\n         d_L.solveInPlace(d_delu, CHOLMOD_P);\n                                  ^~~~~~~~~\npredModule.cpp:187:34: error: ‘CHOLMOD_L’ was not declared in this scope\n         d_L.solveInPlace(d_delu, CHOLMOD_L);    // d_delu now contains cu\n                                  ^~~~~~~~~\npredModule.cpp:195:34: error: ‘CHOLMOD_Lt’ was not declared in this scope\n         d_L.solveInPlace(d_delu, CHOLMOD_Lt);\n     
                             ^~~~~~~~~~\npredModule.cpp:195:34: note: suggested alternative: ‘COLAMD_OK’\n         d_L.solveInPlace(d_delu, CHOLMOD_Lt);\n                                  ^~~~~~~~~~\n                                  COLAMD_OK\npredModule.cpp:196:34: error: ‘CHOLMOD_Pt’ was not declared in this scope\n         d_L.solveInPlace(d_delu, CHOLMOD_Pt);\n                                  ^~~~~~~~~~\npredModule.cpp:196:34: note: suggested alternative: ‘COLAMD_OK’\n         d_L.solveInPlace(d_delu, CHOLMOD_Pt);\n                                  ^~~~~~~~~~\n                                  COLAMD_OK\npredModule.cpp: In member function ‘lme4::merPredD::Scalar lme4::merPredD::solveU()’:\npredModule.cpp:203:34: error: ‘CHOLMOD_P’ was not declared in this scope\n         d_L.solveInPlace(d_delu, CHOLMOD_P);\n                                  ^~~~~~~~~\npredModule.cpp:204:34: error: ‘CHOLMOD_L’ was not declared in this scope\n         d_L.solveInPlace(d_delu, CHOLMOD_L);    // d_d
elu now contains cu\n                                  ^~~~~~~~~\npredModule.cpp:206:34: error: ‘CHOLMOD_Lt’ was not declared in this scope\n         d_L.solveInPlace(d_delu, CHOLMOD_Lt);\n                                  ^~~~~~~~~~\npredModule.cpp:206:34: note: suggested alternative: ‘COLAMD_OK’\n         d_L.solveInPlace(d_delu, CHOLMOD_Lt);\n                                  ^~~~~~~~~~\n                                  COLAMD_OK\npredModule.cpp:207:34: error: ‘CHOLMOD_Pt’ was not declared in this scope\n         d_L.solveInPlace(d_delu, CHOLMOD_Pt);\n                                  ^~~~~~~~~~\npredModule.cpp:207:34: note: suggested alternative: ‘COLAMD_OK’\n         d_L.solveInPlace(d_delu, CHOLMOD_Pt);\n                                  ^~~~~~~~~~\n                                  COLAMD_OK\npredModule.cpp: In member function ‘void lme4::merPredD::updateDecomp(const MatrixXd*)’:\npredModule.cpp:279:37: error: ‘CHOLMOD_P’ was not declared in this scope\n             d_L.solveIn
Place(d_RZX, CHOLMOD_P);\n                                     ^~~~~~~~~\npredModule.cpp:280:37: error: ‘CHOLMOD_L’ was not declared in this scope\n             d_L.solveInPlace(d_RZX, CHOLMOD_L);\n                                     ^~~~~~~~~\npredModule.cpp: In member function ‘void lme4::merPredD::MCMC_beta_u(const Scalar&)’:\npredModule.cpp:346:32: error: ‘CHOLMOD_Lt’ was not declared in this scope\n         d_L.solveInPlace(del1, CHOLMOD_Lt);\n                                ^~~~~~~~~~\npredModule.cpp:346:32: note: suggested alternative: ‘COLAMD_OK’\n         d_L.solveInPlace(del1, CHOLMOD_Lt);\n                                ^~~~~~~~~~\n                                COLAMD_OK\n/usr/lib/R/etc/Makeconf:200: recipe for target 'external.o' failed\nmake: *** [external.o] Error 1\nmake: *** Waiting for unfinished jobs....\n/usr/lib/R/etc/Makeconf:200: recipe for target 'predModule.o' failed\nmake: *** [predModule.o] Error 1\nERROR: compilation failed for package ‘lme4’\n* removing ‘/
opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/lme4’"
Error: Command failed (1)

Failed to run system command:

	'/usr/lib/R/bin/R' --vanilla CMD INSTALL --preclean '/opt/rstudio-connect/mnt/tmp/Rtmpbc5bvi/packrat-install-6dfd3e5d03fb/lme4' --library='/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0' --install-tests --no-docs --no-multiarch --no-demo 

The command failed with output:
* installing *source* package ‘lme4’ ...
** package ‘lme4’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
using C++ compiler: ‘g++ (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0’
g++ -std=gnu++17 -I"/usr/share/R/include" -DNDEBUG  -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include'    -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -c external.cpp -o external.o
g++ -std=gnu++17 -I"/usr/share/R/include" -DNDEBUG  -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include'    -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -c glmFamily.cpp -o glmFamily.o
g++ -std=gnu++17 -I"/usr/share/R/include" -DNDEBUG  -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include'    -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -c optimizer.cpp -o optimizer.o
g++ -std=gnu++17 -I"/usr/share/R/include" -DNDEBUG  -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include'    -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -c predModule.cpp -o predModule.o
g++ -std=gnu++17 -I"/usr/share/R/include" -DNDEBUG  -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/Rcpp/include' -I'/opt/rstudio-connect/mnt/app/packrat/lib/x86_64-pc-linux-gnu/4.3.0/RcppEigen/include'    -DNDEBUG -DEIGEN_DONT_VECTORIZE -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-cRDaP8/r-base-4.3.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -c respModule.cpp -o respModule.o
In file included from predModule.h:13:0,
                 from predModule.cpp:8:
lme4CholmodDecomposition.h:20:72: error: expected template-name before ��<’ token
     class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {
                                                                        ^
lme4CholmodDecomposition.h:20:72: error: expected ‘{’ before ‘<’ token
In file included from predModule.h:13:0,
                 from predModule.cpp:8:
lme4CholmodDecomposition.h: In function ‘SEXPREC* lme4::Eigen_cholmod_wrap(const lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<Scalar> >&)’:
lme4CholmodDecomposition.h:77:15: error: ‘cholmod_factor’ does not name a type; did you mean ‘chkder_factor’?
         const cholmod_factor* f = obj.factor();
               ^~~~~~~~~~~~~~
               chkder_factor
lme4CholmodDecomposition.h:78:13: error: ‘f’ was not declared in this scope
         if (f->minor < f->n)
             ^
lme4CholmodDecomposition.h:82:36: error: ‘f’ was not declared in this scope
         ::Rcpp::S4 ans(std::string(f->is_super ? "dCHMsuper" : "dCHMsimpl"));
                                    ^
In file included from predModule.cpp:8:0:
predModule.h: At global scope:
predModule.h:40:23: error: field ‘d_L’ has incomplete type ‘lme4::merPredD::ChmDecomp {aka lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
         ChmDecomp     d_L;
                       ^~~
In file included from predModule.h:13:0,
                 from predModule.cpp:8:
lme4CholmodDecomposition.h:20:11: note: declaration of ‘lme4::merPredD::ChmDecomp {aka class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
     class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {
           ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from predModule.h:13:0,
                 from external.cpp:8:
lme4CholmodDecomposition.h:20:72: error: expected template-name before ‘<’ token
     class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {
                                                                        ^
lme4CholmodDecomposition.h:20:72: error: expected ‘{’ before ‘<’ token
In file included from predModule.h:13:0,
                 from external.cpp:8:
lme4CholmodDecomposition.h: In function ‘SEXPREC* lme4::Eigen_cholmod_wrap(const lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<Scalar> >&)’:
lme4CholmodDecomposition.h:77:15: error: ‘cholmod_factor’ does not name a type; did you mean ‘chkder_factor’?
         const cholmod_factor* f = obj.factor();
               ^~~~~~~~~~~~~~
               chkder_factor
lme4CholmodDecomposition.h:78:13: error: ‘f’ was not declared in this scope
         if (f->minor < f->n)
             ^
lme4CholmodDecomposition.h:82:36: error: ‘f’ was not declared in this scope
         ::Rcpp::S4 ans(std::string(f->is_super ? "dCHMsuper" : "dCHMsimpl"));
                                    ^
predModule.cpp: In member function ‘Rcpp::List lme4::merPredD::condVar(const Environment&) const’:
predModule.cpp:122:43: error: ‘CHOLMOD_A’ was not declared in this scope
                     d_L.solveInPlace(LvT, CHOLMOD_A);
                                           ^~~~~~~~~
In file included from external.cpp:8:0:
predModule.h: At global scope:
predModule.h:40:23: error: field ‘d_L’ has incomplete type ‘lme4::merPredD::ChmDecomp {aka lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
         ChmDecomp     d_L;
                       ^~~
In file included from predModule.h:13:0,
                 from external.cpp:8:
lme4CholmodDecomposition.h:20:11: note: declaration of ‘lme4::merPredD::ChmDecomp {aka class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
     class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {
           ^~~~~~~~~~~~~~~~~~~~~~~~
external.cpp: In function ‘SEXPREC* glmerAGQ(SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP)’:
external.cpp:437:18: error: invalid use of incomplete type ‘const ChmDecomp {aka const class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
         if (pp->L().factor()->nzmax !=  q)
             ~~~~~^~
In file included from predModule.h:13:0,
                 from external.cpp:8:
lme4CholmodDecomposition.h:20:11: note: declaration of ‘lme4::merPredD::ChmDecomp {aka class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
     class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {
           ^~~~~~~~~~~~~~~~~~~~~~~~
external.cpp:439:49: error: invalid use of incomplete type ‘const ChmDecomp {aka const class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
         const Ar1         sd(MAr1((double*)pp->L().factor()->x, q).inverse());
                                            ~~~~~^~
In file included from predModule.h:13:0,
                 from external.cpp:8:
lme4CholmodDecomposition.h:20:11: note: declaration of ‘lme4::merPredD::ChmDecomp {aka class lme4::lme4CholmodDecomposition<Eigen::SparseMatrix<double, 0, int> >}’
     class lme4CholmodDecomposition : public Eigen::CholmodDecomposition<_MatrixType, _UpLo> {
   

Unable to fully restore the R packages associated with this deployment.
Please review the preceding messages to determine which package
encountered installation difficulty and the cause of the failure.
Build error: exit status 1
── Deployment complete ─────────────────────────────────────────────────────────
✖ Deployment failed with error: exit status 1

It looks like you're trying to compile the package on deployment, which you may be able to avoid by configuring your Connect server to use Posit Public Package Manager instead: