Package: release.debian.org
Severity: normal
User: release.debian....@packages.debian.org
Usertags: unblock

Please unblock package trac

This fixes https://bugs.debian.org/771799

diff -Nru trac-1.0.2+dfsg/debian/changelog trac-1.0.2+dfsg/debian/changelog
--- trac-1.0.2+dfsg/debian/changelog    2014-11-26 00:03:49.000000000 +0100
+++ trac-1.0.2+dfsg/debian/changelog    2014-12-03 13:25:01.000000000 +0100
@@ -1,3 +1,9 @@
+trac (1.0.2+dfsg-2) unstable; urgency=medium
+
+  * apply upstream patch to fix syntax highlighting (Closes: #771799)
+
+ -- W. Martin Borgert <deba...@debian.org>  Wed, 03 Dec 2014 12:00:13 +0000
+
 trac (1.0.2+dfsg-1) unstable; urgency=medium
 
   [gregor herrmann <gre...@debian.org>  Tue, 25 Nov 2014 23:25:18 +0100]
diff -Nru trac-1.0.2+dfsg/debian/patches/70_fix_syntax_highlighting.patch 
trac-1.0.2+dfsg/debian/patches/70_fix_syntax_highlighting.patch
--- trac-1.0.2+dfsg/debian/patches/70_fix_syntax_highlighting.patch     
1970-01-01 01:00:00.000000000 +0100
+++ trac-1.0.2+dfsg/debian/patches/70_fix_syntax_highlighting.patch     
2014-12-03 13:25:01.000000000 +0100
@@ -0,0 +1,59 @@
+Description: this fixes pygments syntax highlighting
+Author: W. Martin Borgert <deba...@debian.org>
+Origin: upstream
+Bug: http://trac.edgewall.org/ticket/11796
+Bug-Debian: https://bugs.debian.org/771799
+Applied-Upstream: 
http://trac.edgewall.org/changeset/4580ae4fe53056a4cca802b49856efd34746c1d1/jomae.git/
 
+Last-Update: 2014-12-03
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/trac/mimeview/pygments.py
++++ b/trac/mimeview/pygments.py
+@@ -10,6 +10,8 @@
+ #
+ # Author: Matthew Good <m...@matt-good.net>
+ 
++from __future__ import absolute_import
++
+ from datetime import datetime
+ import os
+ from pkg_resources import resource_filename
+@@ -29,14 +31,10 @@
+ from genshi import QName, Stream
+ from genshi.core import Attrs, START, END, TEXT
+ 
+-# Kludge to workaround the lack of absolute imports in Python version prior to
+-# 2.5
+-pygments = __import__('pygments', {}, {}, ['lexers', 'styles', 'formatters'])
+-get_all_lexers = pygments.lexers.get_all_lexers
+-get_lexer_by_name = pygments.lexers.get_lexer_by_name
+-HtmlFormatter = pygments.formatters.html.HtmlFormatter
+-get_all_styles = pygments.styles.get_all_styles
+-get_style_by_name = pygments.styles.get_style_by_name
++import pygments
++from pygments.formatters.html import HtmlFormatter
++from pygments.lexers import get_all_lexers, get_lexer_by_name
++from pygments.styles import get_all_styles, get_style_by_name
+ 
+ __all__ = ['PygmentsRenderer']
+ 
+--- a/trac/mimeview/tests/pygments.py
++++ b/trac/mimeview/tests/pygments.py
+@@ -11,6 +11,8 @@
+ # individuals. For the exact contribution history, see the revision
+ # history and logs, available at http://trac.edgewall.org/log/.
+ 
++from __future__ import absolute_import
++
+ import os
+ import unittest
+ 
+@@ -18,7 +20,7 @@
+ from genshi.input import HTMLParser
+ 
+ try:
+-    pygments = __import__('pygments', {}, {}, [])
++    import pygments
+     have_pygments = True
+ except ImportError:
+     have_pygments = False
diff -Nru trac-1.0.2+dfsg/debian/patches/series 
trac-1.0.2+dfsg/debian/patches/series
--- trac-1.0.2+dfsg/debian/patches/series       2014-11-26 00:03:49.000000000 
+0100
+++ trac-1.0.2+dfsg/debian/patches/series       2014-12-03 13:25:01.000000000 
+0100
@@ -1,3 +1,4 @@
+70_fix_syntax_highlighting.patch
 20_add_interpreter_line.patch
 50_sqlitetopg_script.patch
 60_do_not_ship_jquery_ui_images.patch

unblock trac/1.0.2+dfsg-2


-- 
To UNSUBSCRIBE, email to debian-release-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: https://lists.debian.org/20141203123544.GA24570@fama

Reply via email to