10

After updating my MiKTeX 2.9 package, .tex files which compiled perfectly with 0 error 0 warning now gives 0 error 1 warning:

Package etoolbox Warning: Patching '\begin' failed!  (pdflatex)
(etoolbox)  'AtBeginenvironment' will not work

A minimum working example is

\documentclass[11pt]{article}
\usepackage{html}
\usepackage{datetime}
\begin{document}
   MWE!
\end{document}

I don't really like to let unanswered warnings piling ups at the end of compilations, what, short of not using one of the two packages, can I do to suppress the warning?

lockstep
  • 250,273
c05772
  • 864
  • 6
  • 15

1 Answers1

6

Because the minimum working example is short enough, it is tempting to try to run the datetime package before the html one, it gives

\documentclass[11pt]{article}
\usepackage{datetime}
\usepackage{html}
\begin{document}
  MWE!
\end{document}

Surprisingly, it works, there is no more warning!

Joseph Wright
  • 259,911
  • 34
  • 706
  • 1,036
c05772
  • 864
  • 6
  • 15
  • 2
    Probably what happens here is that datetime loads etoolbox and patches successfully, while in the MWE in the question the html package probably alters \document in some very odd way. An alternative work around would therefore be to load etoolbox directly at some stage before loading html. – Joseph Wright Aug 19 '13 at 06:03
  • 1
    In a different document using revtex4-1, I resolved a similar warning by loading etoolbox immediately after declaring \documentclass. – EL_DON Jul 24 '18 at 14:16