Re: HTML/PDF Build Errors

From: Sarah Conway Schnurr <xenophenes42(at)gmail(dot)com>
To: Dave Page <dpage(at)pgadmin(dot)org>
Cc: "pgadmin-support lists(dot)postgresql(dot)org" <pgadmin-support(at)lists(dot)postgresql(dot)org>
Subject: Re: HTML/PDF Build Errors
Date: 2018-12-29 03:56:50
Message-ID: CA+m7vT76oAnGfrWSXNep7PAeBUj9RFpVR88=5wtZrV0TdFzz5w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-support

Sorry about the delay, didn't actually revisit the issue until today.

When you run sphinx-build (sphinx-build -b latex $SRC $DST), it generates
the chapter titles like so:

\chapter{\index{Getting Started}Getting Started}

whereas they need to be:

\chapter{Getting Started}

Cleaning that up manually or running the following sed command fixes it and
seems to generate a perfectly fine PDF:

sed -Ei 's/chapter\{\\index\{(.*?)\}(.*?)}/chapter{\1}/g'
${DST}/pgadmin4.tex

There may be a way to prevent sphinx-build from creating this error in the
first place, but wanted to share my workaround in case someone else comes
across this error. Hopefully that helps!

On Fri, Dec 21, 2018 at 7:17 AM Dave Page <dpage(at)pgadmin(dot)org> wrote:

> Hi
>
> On Fri, Dec 21, 2018 at 3:04 PM Sarah Conway Schnurr
> <xenophenes42(at)gmail(dot)com> wrote:
> >
> >
> >>
> >> Is your Sphinx an RPM installation? If so, they may have split that
> >> theme out into a different package. We always install using PIP, which
> >> works fine in every case I know of.
> >
> >
> > No, it's installed through pip as well. Might it be version specific?
> I'm on the latest version supported by pip, Sphinx v1.1.3.
>
> Hmm, odd. Well if it helps any, all our CI/CD systems (Windows, Mac,
> Linux, Docker) all rebuild the virtual environment on every test run
> and build, based on just a plain old 'pip install sphinx' (as well as
> the other requirements in requirements.txt).
>
> >> > sed -i "/html_theme = 'classic'/d" docs/en_US/conf.py
> >> >
> >> > The PDF errors as mentioned previously in detail are additionally
> reproducible in the community packages from Git for 3.2, 3.6, and HEAD.
> >> >
> >> > ! Use of \(at)icentercr doesn't match its definition.
> >>
> >> Yeah, I see that as well. There's something in the doc source that is
> >> getting converted into invalid TEX I think. I have no idea what
> >> though, as I haven't really used TEX directly in 20+ years. It seems
> >> like a Sphinx bug, in that it's quite happy with the input for other
> >> formats, but barfs on anything that uses TEX.
> >>
> >> Do you know anyone that is familiar with TEX that might be able to
> >> help? Maybe Joe?
> >
> >
> > I'll do some research and see if I can determine what syntax it might be
> unhappy about; if able to figure it out, will follow up here with the fix.
>
> Awesome - thanks!
>
> --
> Dave Page
> Blog: http://pgsnake.blogspot.com
> Twitter: @pgsnake
>
> EnterpriseDB UK: http://www.enterprisedb.com
> The Enterprise PostgreSQL Company
>

--
Sarah Conway Schnurr

In response to

Responses

Browse pgadmin-support by date

  From Date Subject
Next Message Mark Murawski 2018-12-30 21:06:57 pgadmin4 not working
Previous Message SQL Design 2018-12-25 16:40:45 No graphical explain plan with pgadmin4 3.6.5 : solved