I'm getting a warning during compilation from the hyperref package and would like to solve it. Here's a MWE showing the issue:
\documentclass[11pt,twoside]{book} \usepackage[T1]{fontenc} \usepackage[nomath]{lmodern} \usepackage[french]{babel} \usepackage[letterpaper,left=1.25in,right=1in,top=0.5in,bottom=0.5in,includeheadfoot,headheight=14pt]{geometry} % Option showframe pour montrer les bordures. \usepackage{amssymb} \usepackage[dvipsnames,table]{xcolor} \usepackage{hyperref} \usepackage[pagestyles,medium]{titlesec} \begin{document} \setcounter{tocdepth}{2} \tableofcontents \cleardoublepage \phantomsection \pagestyle{plain} \section*{\centering Introduction} % Need to be shown in the ToC \addcontentsline{toc}{chapter}{\textbf{Introduction}} Blabla \subsection*{\textsf{Remerciements}} % Need to be shown in the ToC. \addcontentsline{toc}{section}{\textsf{Remerciements}} Text \chapter{Chapter title} Text \end{document} From this code, I'm getting the following pesky warning:
Package hyperref Warning: The anchor of a bookmark and its parent's must not (hyperref) be the same. Added a new anchor on input line 31. How can I fix this?

titlesecfor other things and the section above shoulnd't have a number. What should be a proper solution?titlesec? it will be much easier to do withouttitlesecthan withouthyperref. disclaimer: I strongly disliketitlesec, so I could delete the 'than withouthyperref'.