List for cgit developers and users
 help / color / mirror / Atom feed
From: peter at colberg.org (Peter Colberg)
Subject: syntax-highlighting.py: file not shown if no lexer found
Date: Thu, 17 Nov 2016 22:41:45 -0500	[thread overview]
Message-ID: <20161118034145.smkynrpif3vbnthy@alcyone> (raw)

Hi,

I am forwarding a bug reported against cgit 1.0 in Debian.

https://bugs.debian.org/784621

syntax-highlighting.py aborts due to an unhandled exception if the
inner call to guess_lexer() throws ClassNotFound. Please see the
attached patch by Daniel Reichelt that resolves the issue.

Is the handling of TypeError for the outer call still needed? The
documentation mentions only ClassNotFound as a possible exception.

http://pygments.org/docs/api/#pygments.lexers.guess_lexer_for_filename

Regards,
Peter
-------------- next part --------------
An embedded message was scrubbed...
From: Daniel Reichelt <debian at nachtgeist.net>
Subject: [Pkg-cgit-devel] Bug#784621: cgit: file not shown if no lexer found
Date: Thu, 17 Nov 2016 23:48:57 +0100
Size: 6460
URL: <http://lists.zx2c4.com/pipermail/cgit/attachments/20161117/1cbb03ca/attachment.mht>


                 reply	other threads:[~2016-11-18  3:41 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161118034145.smkynrpif3vbnthy@alcyone \
    --to=cgit@lists.zx2c4.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).