Skip to content

Log: avoid logging all the latex output when the command failed #9105

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
humitos opened this issue Apr 13, 2022 · 3 comments
Closed

Log: avoid logging all the latex output when the command failed #9105

humitos opened this issue Apr 13, 2022 · 3 comments
Assignees
Labels
Accepted Accepted issue on our roadmap Improvement Minor improvement to code

Comments

@humitos
Copy link
Member

humitos commented Apr 13, 2022

We are logging all the output to syslog on this command.

Apr 12 04:29:39 build-default-i-0c6cedba9ca4531f0 /supervisord: build readthedocs[1044]: [warning  ] Command latexmk -r latexmkrc -pdf -f -dvi- -ps- -jobname=brushin -interaction=nonstopmode failed:

The output is hundred of lines, which is crazy. We should truncate this output or remove logging or something.

@humitos humitos added Improvement Minor improvement to code Accepted Accepted issue on our roadmap labels Apr 13, 2022
@humitos humitos moved this to Planned in 📍Roadmap Apr 13, 2022
@humitos
Copy link
Member Author

humitos commented May 31, 2022

This is the place in code where we need to chunk the output logged,

if build_cmd.failed:
if warn_only:
msg = 'Command {cmd} failed'.format(cmd=build_cmd.get_command())
if build_cmd.output:
msg += ':\n{out}'.format(out=build_cmd.output)
log.warning(
msg,
project_slug=self.project.slug if self.project else '',
version_slug=self.version.slug if self.version else '',
)

@ericholscher
Copy link
Member

@humitos thanks :)

@ericholscher
Copy link
Member

Fixed by #9286

Repository owner moved this from Needs review to Done in 📍Roadmap Jun 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Accepted Accepted issue on our roadmap Improvement Minor improvement to code
Projects
Archived in project
Development

No branches or pull requests

3 participants