[sasview] 03/08: Refresh patches for new upstream version

Stuart Prescott stuart at debian.org
Tue Oct 31 14:52:42 UTC 2017


This is an automated email from the git hooks/post-receive script.

stuart pushed a commit to branch master
in repository sasview.

commit fba5dc82a2c699f0110ff24129c4e7025935ba9d
Author: Stuart Prescott <stuart at debian.org>
Date:   Wed Nov 1 01:10:50 2017 +1100

    Refresh patches for new upstream version
---
 debian/patches/plotting-none.patch        | 96 -------------------------------
 debian/patches/series                     |  1 -
 debian/patches/sphinx-local-mathjax.patch | 27 ++++++---
 3 files changed, 18 insertions(+), 106 deletions(-)

diff --git a/debian/patches/plotting-none.patch b/debian/patches/plotting-none.patch
deleted file mode 100644
index 31420a5..0000000
--- a/debian/patches/plotting-none.patch
+++ /dev/null
@@ -1,96 +0,0 @@
-diff --git a/src/sas/sasgui/plottools/plottables.py b/src/sas/sasgui/plottools/plottables.py
-index 756a16a..567f187 100644
---- a/src/sas/sasgui/plottools/plottables.py
-+++ b/src/sas/sasgui/plottools/plottables.py
-@@ -226,7 +226,7 @@ class Graph(object):
-         for p in self.plottables:
-             if p.hidden == True:
-                 continue
--            if not p.x == None:
-+            if p.x is not None:
-                 for x_i in p.x:
-                     if min_value == None or x_i < min_value:
-                         min_value = x_i
-@@ -559,10 +559,8 @@ class Plottable(object):
-         """
-         Returns True if there is no data stored in the plottable
-         """
--        if not self.x == None and len(self.x) == 0 \
--            and not self.y == None and len(self.y) == 0:
--            return True
--        return False
-+        return (self.x is not None and len(self.x) == 0
-+                and self.y is not None and len(self.y) == 0)
- 
-     def colors(self):
-         """Return the number of colors need to render the object"""
-@@ -676,11 +674,11 @@ class View(object):
-         """
-         # Sanity check
-         # Do the transofrmation only when x and y are empty
--        has_err_x = not (dx == None or len(dx) == 0)
--        has_err_y = not (dy == None or len(dy) == 0)
-+        has_err_x = not (dx is None or len(dx) == 0)
-+        has_err_y = not (dy is None or len(dy) == 0)
- 
--        if(x != None) and (y != None):
--            if not dx == None and not len(dx) == 0 and not len(x) == len(dx):
-+        if(x is not None) and (y is not None):
-+            if dx is not None and not len(dx) == 0 and not len(x) == len(dx):
-                 msg = "Plottable.View: Given x and dx are not"
-                 msg += " of the same length"
-                 raise ValueError, msg
-@@ -690,7 +688,7 @@ class View(object):
-                 msg += "and x are not of the same length"
-                 raise ValueError, msg
- 
--            if not dy == None and not len(dy) == 0 and not len(y) == len(dy):
-+            if dy is not None and not len(dy) == 0 and not len(y) == len(dy):
-                 msg = "Plottable.View: Given y and dy are not of the same "
-                 msg += "length: len(y)=%s, len(dy)=%s" % (len(y), len(dy))
-                 raise ValueError, msg
-@@ -794,9 +792,9 @@ class View(object):
-         tempdx = []
-         tempy = []
-         tempdy = []
--        if self.dx == None:
-+        if self.dx is None:
-             self.dx = numpy.zeros(len(self.x))
--        if self.dy == None:
-+        if self.dy is None:
-             self.dy = numpy.zeros(len(self.y))
-         if self.xLabel == "log10(x)":
-             for i in range(len(self.x)):
-@@ -824,9 +822,9 @@ class View(object):
-         tempdx = []
-         tempy = []
-         tempdy = []
--        if self.dx == None:
-+        if self.dx is None:
-             self.dx = numpy.zeros(len(self.x))
--        if self.dy == None:
-+        if self.dy is None:
-             self.dy = numpy.zeros(len(self.y))
-         if self.yLabel == "log10(y)":
-             for i in range(len(self.x)):
-@@ -857,9 +855,9 @@ class View(object):
-         tempdx = []
-         tempy = []
-         tempdy = []
--        if self.dx == None:
-+        if self.dx is None:
-             self.dx = numpy.zeros(len(self.x))
--        if self.dy == None:
-+        if self.dy is None:
-             self.dy = numpy.zeros(len(self.y))
-         if xmin != None and xmax != None:
-             for i in range(len(self.x)):
-@@ -1203,7 +1201,7 @@ class Chisq(Plottable):
-     def render(self, plot, **kw):
-         """
-         """
--        if  self._chisq == None:
-+        if  self._chisq is None:
-             chisqTxt = r'$\chi^2=$'
-         else:
-             chisqTxt = r'$\chi^2=%g$' % (float(self._chisq))
diff --git a/debian/patches/series b/debian/patches/series
index d6c56c9..f436b68 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,2 +1 @@
 sphinx-local-mathjax.patch
-plotting-none.patch
diff --git a/debian/patches/sphinx-local-mathjax.patch b/debian/patches/sphinx-local-mathjax.patch
index 61ce4cb..c433e84 100644
--- a/debian/patches/sphinx-local-mathjax.patch
+++ b/debian/patches/sphinx-local-mathjax.patch
@@ -3,12 +3,21 @@ Author: Stuart Prescott <stuart at debian.org>
 
 --- a/docs/sphinx-docs/source/conf.py
 +++ b/docs/sphinx-docs/source/conf.py
-@@ -39,7 +39,7 @@
-               'sphinx.ext.viewcode']
- 
- #set mathjax path
--mathjax_path="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-MML-AM_CHTML"
-+mathjax_path = 'mathjax/MathJax.js?config=TeX-AMS-MML_HTMLorMML'
- 
- # Add any paths that contain templates here, relative to this directory.
- templates_path = ['_templates']
+@@ -39,9 +39,7 @@
+               'dollarmath',
+               'sphinx.ext.viewcode']
+ 
+-mathjax_path = (
+-    'https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?'
+-    'config=TeX-MML-AM_CHTML')
++mathjax_path = 'mathjax/MathJax.js?config=TeX-AMS-MML_HTMLorMML'
+ 
+ # For katex uncomment the following
+ """
+@@ -308,4 +306,4 @@
+     with open('rst_prolog') as fid:
+         rst_prolog = fid.read()
+ 
+-numfig = True
+\ No newline at end of file
++numfig = True

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/sasview.git



More information about the debian-science-commits mailing list