List for cgit developers and users
 help / color / mirror / Atom feed
* syntax-highlighting.py: file not shown if no lexer found
@ 2016-11-18  3:41 peter
  0 siblings, 0 replies; only message in thread
From: peter @ 2016-11-18  3:41 UTC (permalink / 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>


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2016-11-18  3:41 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-18  3:41 syntax-highlighting.py: file not shown if no lexer found peter

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).