[arch-commits] Commit in gourmet/repos/community-any (7 files)

Balló György bgyorgy at archlinux.org
Thu Dec 27 15:13:36 UTC 2018


    Date: Thursday, December 27, 2018 @ 15:13:36
  Author: bgyorgy
Revision: 418506

archrelease: copy trunk to community-any

Added:
  gourmet/repos/community-any/0001-Fix-AppStream-metadata-validation.patch
    (from rev 418505, gourmet/trunk/0001-Fix-AppStream-metadata-validation.patch)
  gourmet/repos/community-any/PKGBUILD
    (from rev 418505, gourmet/trunk/PKGBUILD)
  gourmet/repos/community-any/bs4-port.patch
    (from rev 418505, gourmet/trunk/bs4-port.patch)
  gourmet/repos/community-any/gourmet-pillow.patch
    (from rev 418505, gourmet/trunk/gourmet-pillow.patch)
Deleted:
  gourmet/repos/community-any/PKGBUILD
  gourmet/repos/community-any/bs4-port.patch
  gourmet/repos/community-any/gourmet-pillow.patch

----------------------------------------------+
 0001-Fix-AppStream-metadata-validation.patch |   66 +++
 PKGBUILD                                     |  110 +++---
 bs4-port.patch                               |  414 ++++++++++++-------------
 gourmet-pillow.patch                         |   74 ++--
 4 files changed, 368 insertions(+), 296 deletions(-)

Copied: gourmet/repos/community-any/0001-Fix-AppStream-metadata-validation.patch (from rev 418505, gourmet/trunk/0001-Fix-AppStream-metadata-validation.patch)
===================================================================
--- 0001-Fix-AppStream-metadata-validation.patch	                        (rev 0)
+++ 0001-Fix-AppStream-metadata-validation.patch	2018-12-27 15:13:36 UTC (rev 418506)
@@ -0,0 +1,66 @@
+From 129892080bf7f5ab3e45657ec36d58ae082a8638 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Ball=C3=B3=20Gy=C3=B6rgy?= <ballogyor at gmail.com>
+Date: Thu, 27 Dec 2018 15:42:41 +0100
+Subject: [PATCH] Fix AppStream metadata validation
+
+And don't use legacy path for metainfo file.
+---
+ gourmet.appdata.xml.in | 22 +++++++++++++++-------
+ setup.cfg              |  2 +-
+ 2 files changed, 16 insertions(+), 8 deletions(-)
+
+diff --git a/gourmet.appdata.xml.in b/gourmet.appdata.xml.in
+index 4c5191c4..4337208e 100644
+--- a/gourmet.appdata.xml.in
++++ b/gourmet.appdata.xml.in
+@@ -1,9 +1,11 @@
+ <?xml version="1.0" encoding="UTF-8"?>
+ <!-- Copyright 2014 Thomas Hinkle <Thomas_Hinkle at alumni.brown.edu> -->
+-<application>
+- <id type="desktop">gourmet.desktop</id>
++<component type="desktop-application">
++ <id>com.github.gourmet</id>
+  <metadata_license>CC0-1.0</metadata_license>
+  <project_license>GPL-2.0</project_license>
++ <name>Gourmet</name>
++ <summary>Organize recipes, create shopping lists, calculate nutritional information, and more</summary>
+  <description>
+   <_p>
+    Gourmet Recipe Manager is a recipe-organizer that allows you to collect,
+@@ -21,9 +23,15 @@
+   </_p>
+  </description>
+  <screenshots>
+-  <screenshot type="default">http://thinkle.github.io/gourmet/images/screenshots/SearchView.png</screenshot>
+-  <screenshot>http://thinkle.github.io/gourmet/images/screenshots/CardView.png</screenshot>
++  <screenshot type="default">
++   <image>https://thinkle.github.io/gourmet/images/screenshots/SearchView.png</image>
++  </screenshot>
++  <screenshot>
++   <image>https://thinkle.github.io/gourmet/images/screenshots/CardView.png</image>
++  </screenshot>
+  </screenshots>
+- <url type="homepage">http://thinkle.github.io/gourmet/</url>
+- <updatecontact>https://github.com/thinkle/gourmet/issues</updatecontact>
+-</application>
++ <launchable type="desktop-id">gourmet.desktop</launchable>
++ <url type="homepage">https://thinkle.github.io/gourmet/</url>
++ <url type="bugtracker">https://github.com/thinkle/gourmet/issues</url>
++ <update_contact>Thomas_Hinkle at alumni.brown.edu</update_contact>
++</component>
+diff --git a/setup.cfg b/setup.cfg
+index 647f9660..880c7fed 100644
+--- a/setup.cfg
++++ b/setup.cfg
+@@ -17,7 +17,7 @@ desktop_files=[
+ 	("share/gourmet/plugins/import_export", glob.glob("gourmet/plugins/import_export/*.gourmet-plugin.in"))
+ 	]
+ xml_files=[
+-	("share/appdata", ("gourmet.appdata.xml.in",)),
++	("share/metainfo", ("gourmet.appdata.xml.in",)),
+ 	]
+ 
+ [build_icons]
+-- 
+2.20.1
+

Deleted: PKGBUILD
===================================================================
--- PKGBUILD	2018-12-27 15:13:30 UTC (rev 418505)
+++ PKGBUILD	2018-12-27 15:13:36 UTC (rev 418506)
@@ -1,52 +0,0 @@
-# Maintainer: Balló György <ballogyor+arch at gmail dot com>
-# Contributor: Ray Rashif <schiv at archlinux.org>
-# Contributor: Corrado Primier <bardo at aur.archlinux.org>
-# Contributor: Eric Belanger <belanger at astro.umontreal.ca>
-# Contributor: Andrew Conkling <andrewski at fr.st>
-
-pkgname=gourmet
-pkgver=0.17.4
-pkgrel=7
-pkgdesc="A simple but powerful recipe-managing application"
-arch=('any')
-url="https://thinkle.github.io/gourmet/"
-license=('GPL')
-depends=('pygtk' 'python2-elib-intl' 'python2-pillow' 'python2-sqlalchemy')
-makedepends=('python2-distutils-extra')
-optdepends=('ipython2: Python Shell plugin'
-            'python2-pyrtf: RTF support'
-            'python2-beautifulsoup4: Webpage import plugin'
-            'python2-gtkspell: Spell Checking plugin'
-            'python2-poppler: Printing and PDF Export plugin'
-            'python2-reportlab: Printing and PDF Export plugin')
-source=("$pkgname-$pkgver.tar.gz::https://github.com/thinkle/$pkgname/archive/$pkgver.tar.gz"
-        "gourmet-pillow.patch"
-        "bs4-port.patch")
-sha256sums=('13edd3b9c3a3507d20b80cff0f88183ac7979b720e7577290815ffacca097fe3'
-            '3680663b09fc61e5797990c378597eeb5db6915b4db987ac2d1a55c7f2636047'
-            '815b0fb735d6b581fba0cec713a9ad963f842c969db9fef3e3b0d66ef11bd3b0')
-
-prepare() {
-  cd $pkgname-$pkgver
-
-  # python2 fix
-  find . -type f | xargs sed -i 's@^#!.*python$@#!/usr/bin/python2@'
-
-  # Fix for pillow 3
-  # https://github.com/thinkle/gourmet/commit/4d88788a
-  patch -Np1 -i ../gourmet-pillow.patch
-
-  # Port to Beautiful Soup 4
-  # https://github.com/thinkle/gourmet/commit/fdd0f10a
-  patch -Np1 -i ../bs4-port.patch
-}
-
-build() {
-  cd $pkgname-$pkgver
-  python2 setup.py build
-}
-
-package() {
-  cd $pkgname-$pkgver
-  python2 setup.py install --root="$pkgdir" --optimize=1
-}

Copied: gourmet/repos/community-any/PKGBUILD (from rev 418505, gourmet/trunk/PKGBUILD)
===================================================================
--- PKGBUILD	                        (rev 0)
+++ PKGBUILD	2018-12-27 15:13:36 UTC (rev 418506)
@@ -0,0 +1,58 @@
+# Maintainer: Balló György <ballogyor+arch at gmail dot com>
+# Contributor: Ray Rashif <schiv at archlinux.org>
+# Contributor: Corrado Primier <bardo at aur.archlinux.org>
+# Contributor: Eric Belanger <belanger at astro.umontreal.ca>
+# Contributor: Andrew Conkling <andrewski at fr.st>
+
+pkgname=gourmet
+pkgver=0.17.4
+pkgrel=8
+pkgdesc="A simple but powerful recipe-managing application"
+arch=('any')
+url="https://thinkle.github.io/gourmet/"
+license=('GPL')
+depends=('pygtk' 'python2-elib-intl' 'python2-pillow' 'python2-sqlalchemy')
+makedepends=('python2-distutils-extra')
+optdepends=('ipython2: Python Shell plugin'
+            'python2-pyrtf: RTF support'
+            'python2-beautifulsoup4: Webpage import plugin'
+            'python2-gtkspell: Spell Checking plugin'
+            'python2-poppler: Printing and PDF Export plugin'
+            'python2-reportlab: Printing and PDF Export plugin')
+source=("$pkgname-$pkgver.tar.gz::https://github.com/thinkle/$pkgname/archive/$pkgver.tar.gz"
+        "gourmet-pillow.patch"
+        "bs4-port.patch"
+        "0001-Fix-AppStream-metadata-validation.patch")
+sha256sums=('13edd3b9c3a3507d20b80cff0f88183ac7979b720e7577290815ffacca097fe3'
+            '3680663b09fc61e5797990c378597eeb5db6915b4db987ac2d1a55c7f2636047'
+            '815b0fb735d6b581fba0cec713a9ad963f842c969db9fef3e3b0d66ef11bd3b0'
+            '010ba6616751a87854d0fefdf6f26cfa6b6d20ea908b46250bbfc6bea04bab35')
+
+prepare() {
+  cd $pkgname-$pkgver
+
+  # python2 fix
+  find . -type f | xargs sed -i 's@^#!.*python$@#!/usr/bin/python2@'
+
+  # Fix for pillow 3
+  # https://github.com/thinkle/gourmet/commit/4d88788a
+  patch -Np1 -i ../gourmet-pillow.patch
+
+  # Port to Beautiful Soup 4
+  # https://github.com/thinkle/gourmet/commit/fdd0f10a
+  patch -Np1 -i ../bs4-port.patch
+
+  # Fix AppStream metadata validation
+  # https://github.com/thinkle/gourmet/pull/928
+  patch -Np1 -i ../0001-Fix-AppStream-metadata-validation.patch
+}
+
+build() {
+  cd $pkgname-$pkgver
+  python2 setup.py build
+}
+
+package() {
+  cd $pkgname-$pkgver
+  python2 setup.py install --root="$pkgdir" --optimize=1
+}

Deleted: bs4-port.patch
===================================================================
--- bs4-port.patch	2018-12-27 15:13:30 UTC (rev 418505)
+++ bs4-port.patch	2018-12-27 15:13:36 UTC (rev 418506)
@@ -1,207 +0,0 @@
-From fdd0f10a91d633d4f271ce9548bdf4866c688ae7 Mon Sep 17 00:00:00 2001
-From: Bernhard Reiter <ockham at raz.or.at>
-Date: Sat, 9 Mar 2013 18:09:26 +0100
-Subject: [PATCH] Upgrade BeautifulSoup dependency to version 4.
-
-This involves using the plain BeautifulSoup class instead of
-ICantBelieveItsBeautifulSoup, and dropping the convertEntities
-argument to the BeautifulSoup constructor.
-
-See http://www.crummy.com/software/BeautifulSoup/bs4/doc/#porting-code-to-bs4
-
-Note that we required at least version 4.3.0, as previous 4.x versions
-contain a bug that messes up its input HTML under certain circumstances,
-see https://bugs.launchpad.net/beautifulsoup/+bug/972466
-
-Fixes #707.
----
- INSTALL.md                                         | 42 +++++++++++-----------
- gourmet/importers/html_importer.py                 |  6 ++--
- .../web_import_plugin/webpage_importer.py          | 16 ++++-----
- gourmet/test/test_foodnetwork_plugin.py            |  8 ++---
- gourmet/test/test_ica_se_plugin.py                 |  6 ++--
- 5 files changed, 36 insertions(+), 42 deletions(-)
-
-diff --git a/INSTALL.md b/INSTALL.md
-index e0a43085..42f8636e 100644
---- a/INSTALL.md
-+++ b/INSTALL.md
-@@ -111,25 +111,25 @@ To sign your installer, run
- 
- from the source directory.
- 
--Requirements                               |Debian                |MacPorts            |Windows
---------------------------------------------|----------------------|--------------------|---------------
--Python 2.7                                 |python                |python27            |http://www.python.org/
--PyGTK                                      |python-gtk2           |py27-gtk            |[all-in-one installer](http://ftp.gnome.org/pub/GNOME/binaries/win32/pygtk/). Make sure to install PyGTK, PyGObject, PyCairo, and intltool.
--SQLAlchemy                                 |python-sqlalchemy     |py27-sqlalchemy     |http://www.sqlalchemy.org/download.html
--Pillow 2.x (Python Imaging Library Fork)   |python-imaging        |py27-Pillow         |https://pypi.python.org/pypi/Pillow/
--elib.intl                                  |python-elib.intl      |py27-elib.intl      |http://github.com/dieterv/elib.intl/zipball/master
--*Build Requirements*                       |                      |                    |
--setuptools (*Windows only!*)               |                      |                    |
--intltool                                   |intltool              |intltool            |*included in PyGTK installer*
--python-distutils-extra                     |python-distutils-extra|py27-distutils-extra|https://launchpad.net/python-distutils-extra/
--*Extra Requirements*                       |                      |
--Python Reportlab (for printing/PDF export) |python-reportlab      |py27-reportlab      |http://www.reportlab.com/ftp/
--pypoppler (for printing and PDF export)    |python-poppler        |py27-poppler        |
--PyGTKSpell (for the spell checking plugin) |python-gtkspell       |py27-gtkspell       |(N/A)
--python-gst0.10 (for sound)                 |python-gst0.10        |py27-gst-python     |*not required*
--BeautifulSoup (for the Web import plugin)  |python-beautifulsoup  |py27-beautifulsoup  |http://www.crummy.com/software/BeautifulSoup/#Download
--IPython 0.12.1 (interactive shell plugin)  |ipython               |py27-ipython        |https://pypi.python.org/pypi/ipython/0.12.1#downloads
--*Windows only*                             |                      |                    |
--Perl (needed to run intltool)              |                      |                    |http://strawberryperl.com/
--cx_Freeze (only needed to build installer) |                      |                    |http://cx-freeze.sourceforge.net/
-+Requirements                                      |Debian                |MacPorts            |Windows
-+--------------------------------------------------|----------------------|--------------------|---------------
-+Python 2.7                                        |python                |python27            |http://www.python.org/
-+PyGTK                                             |python-gtk2           |py27-gtk            |[all-in-one installer](http://ftp.gnome.org/pub/GNOME/binaries/win32/pygtk/). Make sure to install PyGTK, PyGObject, PyCairo, and intltool.
-+SQLAlchemy                                        |python-sqlalchemy     |py27-sqlalchemy     |http://www.sqlalchemy.org/download.html
-+Pillow 2.x (Python Imaging Library Fork)          |python-imaging        |py27-Pillow         |https://pypi.python.org/pypi/Pillow/
-+elib.intl                                         |python-elib.intl      |py27-elib.intl      |http://github.com/dieterv/elib.intl/zipball/master
-+*Build Requirements*                              |                      |                    |
-+setuptools (*Windows only!*)                      |                      |                    |
-+intltool                                          |intltool              |intltool            |*included in PyGTK installer*
-+python-distutils-extra                            |python-distutils-extra|py27-distutils-extra|https://launchpad.net/python-distutils-extra/
-+*Extra Requirements*                              |                      |
-+Python Reportlab (for printing/PDF export)        |python-reportlab      |py27-reportlab      |http://www.reportlab.com/ftp/
-+pypoppler (for printing and PDF export)           |python-poppler        |py27-poppler        |
-+PyGTKSpell (for the spell checking plugin)        |python-gtkspell       |py27-gtkspell       |(N/A)
-+python-gst0.10 (for sound)                        |python-gst0.10        |py27-gst-python     |*not required*
-+BeautifulSoup>=4.3.0 (for the Web import plugin)  |python-bs4            |py27-beautifulsoup4 |http://www.crummy.com/software/BeautifulSoup/bs4/download/
-+IPython 0.12.1 (interactive shell plugin)         |ipython               |py27-ipython        |https://pypi.python.org/pypi/ipython/0.12.1#downloads
-+*Windows only*                                    |                      |                    |
-+Perl (needed to run intltool)                     |                      |                    |http://strawberryperl.com/
-+cx_Freeze (only needed to build installer)        |                      |                    |http://cx-freeze.sourceforge.net/
- 
-diff --git a/gourmet/importers/html_importer.py b/gourmet/importers/html_importer.py
-index 07bab60a..0729f399 100644
---- a/gourmet/importers/html_importer.py
-+++ b/gourmet/importers/html_importer.py
-@@ -1,6 +1,6 @@
- import urllib, re, tempfile, os.path
- import importer
--import BeautifulSoup
-+from bs4 import BeautifulSoup
- import socket
- from gourmet.gdebug import debug
- from gettext import gettext as _
-@@ -43,7 +43,7 @@ def get_url (url, progress):
-         sock = url
-         return read_socket_w_progress(sock,progress,_('Retrieving file'))
- 
--class MyBeautifulSoup (BeautifulSoup.ICantBelieveItsBeautifulSoup):
-+class MyBeautifulSoup (BeautifulSoup):
- 
-     def __init__ (self, *args, **kwargs):
-         # Avoid invalid doctype decls of the type
-@@ -56,7 +56,7 @@ def __init__ (self, *args, **kwargs):
-              )
-             )
-         kwargs['avoidParserProblems']=True
--        BeautifulSoup.ICantBelieveItsBeautifulSoup.__init__(self,*args,**kwargs)
-+        BeautifulSoup.__init__(self,*args,**kwargs)
- 
-     
-     def handle_comment (self, text): pass
-diff --git a/gourmet/plugins/import_export/web_import_plugin/webpage_importer.py b/gourmet/plugins/import_export/web_import_plugin/webpage_importer.py
-index aff9a157..8b10693c 100644
---- a/gourmet/plugins/import_export/web_import_plugin/webpage_importer.py
-+++ b/gourmet/plugins/import_export/web_import_plugin/webpage_importer.py
-@@ -1,5 +1,5 @@
- # This is a basic
--import BeautifulSoup
-+import bs4
- from gourmet.importers.generic_recipe_parser import RecipeParser
- from gourmet.importers.interactive_importer import InteractiveImporter
- import gourmet.importers.importer
-@@ -20,10 +20,10 @@ class WebParser (InteractiveImporter):
-     TAB = '  '
-     JOINABLE = ['instructions','notes','recipe','ignore','ingredients','include',None]
-     INVISIBLE_TYPES = [
--        BeautifulSoup.CData,
--        BeautifulSoup.Comment,
--        BeautifulSoup.Declaration,
--        BeautifulSoup.ProcessingInstruction]
-+        bs4.CData,
-+        bs4.Comment,
-+        bs4.Declaration,
-+        bs4.ProcessingInstruction]
- 
-     do_postparse = True
-     imageexcluders = None # This could be a list of compiled regexps which would
-@@ -35,9 +35,7 @@ def __init__ (self, url, data, content_type):
-         #self.name = 'Web Parser'
-         print "HERE's the data we got:", data
-         print "END DATA"
--        self.soup = BeautifulSoup.BeautifulSoup(data,
--                                                convertEntities=BeautifulSoup.BeautifulStoneSoup.XHTML_ENTITIES,
--                                                )
-+        self.soup = bs4.BeautifulSoup(data)
-         InteractiveImporter.__init__(self)
-         #self.generic_parser = RecipeParser()
-         self.preparse()
-@@ -150,7 +148,7 @@ def add_buffer_to_parsed (self):
-             to_add = to_add[lws:]
-             self.parsed.append((pre_add,None))
-         # Do extra substitution of MS Characters -- shouldn't be necessary...
--        for char,tup in BeautifulSoup.UnicodeDammit.MS_CHARS.items():
-+        for char,tup in bs4.UnicodeDammit.MS_CHARS.items():
-             char = char.decode('iso-8859-1').encode('utf-8')
-             if to_add.find(char) >= 0:
-                 to_add = to_add.replace(char,unichr(long(tup[1],16)))
-diff --git a/gourmet/test/test_foodnetwork_plugin.py b/gourmet/test/test_foodnetwork_plugin.py
-index 3bafb414..1385524e 100644
---- a/gourmet/test/test_foodnetwork_plugin.py
-+++ b/gourmet/test/test_foodnetwork_plugin.py
-@@ -1,7 +1,7 @@
- # encoding: utf-8
- import os.path
- import unittest
--import BeautifulSoup
-+import bs4
- 
- from gourmet.plugins.import_export.website_import_plugins import foodnetwork_plugin
- 
-@@ -36,16 +36,14 @@ def test_url(self):
-     def test_parse(self):
-         # Setup
-         parser = self.plugin.get_importer(DummyImporter)()
--        parser.soup = BeautifulSoup.BeautifulSoup(self.text,
--                            convertEntities=BeautifulSoup.BeautifulStoneSoup.XHTML_ENTITIES,
--                        )
-+        parser.soup = bs4.BeautifulSoup(self.text)
-         # Do the parsing
-         parser.preparse()
-         # Pick apart results
-         result = parser.preparsed_elements
- 
-         ingredients = [r for r in result if r[1] == "ingredients"][0][0]
--        ingredients = [i for i in ingredients if type(i) == BeautifulSoup.Tag]
-+        ingredients = [i for i in ingredients if type(i) == bs4.Tag]
-         name = [r for r in result if r[1] == "title"][0][0][0].text
-         instructions = [r for r in result if r[1] == "recipe"][0][0].text
- 
-diff --git a/gourmet/test/test_ica_se_plugin.py b/gourmet/test/test_ica_se_plugin.py
-index 43b6ec21..b7e96ce3 100644
---- a/gourmet/test/test_ica_se_plugin.py
-+++ b/gourmet/test/test_ica_se_plugin.py
-@@ -1,7 +1,7 @@
- # encoding: utf-8
- import os.path
- import unittest
--import BeautifulSoup
-+import bs4
- 
- from gourmet.plugins.import_export.website_import_plugins import ica_se_plugin
- 
-@@ -43,9 +43,7 @@ def test_url(self):
-     def test_parse(self):
-         # Setup
-         parser = self.plugin.get_importer(DummyImporter)()
--        parser.soup = BeautifulSoup.BeautifulSoup(self.text,
--                            convertEntities=BeautifulSoup.BeautifulStoneSoup.XHTML_ENTITIES,
--                        )
-+        parser.soup = bs4.BeautifulSoup(self.text)
-         # Do the parsing
-         parser.preparse()
-         # Pick apart results

Copied: gourmet/repos/community-any/bs4-port.patch (from rev 418505, gourmet/trunk/bs4-port.patch)
===================================================================
--- bs4-port.patch	                        (rev 0)
+++ bs4-port.patch	2018-12-27 15:13:36 UTC (rev 418506)
@@ -0,0 +1,207 @@
+From fdd0f10a91d633d4f271ce9548bdf4866c688ae7 Mon Sep 17 00:00:00 2001
+From: Bernhard Reiter <ockham at raz.or.at>
+Date: Sat, 9 Mar 2013 18:09:26 +0100
+Subject: [PATCH] Upgrade BeautifulSoup dependency to version 4.
+
+This involves using the plain BeautifulSoup class instead of
+ICantBelieveItsBeautifulSoup, and dropping the convertEntities
+argument to the BeautifulSoup constructor.
+
+See http://www.crummy.com/software/BeautifulSoup/bs4/doc/#porting-code-to-bs4
+
+Note that we required at least version 4.3.0, as previous 4.x versions
+contain a bug that messes up its input HTML under certain circumstances,
+see https://bugs.launchpad.net/beautifulsoup/+bug/972466
+
+Fixes #707.
+---
+ INSTALL.md                                         | 42 +++++++++++-----------
+ gourmet/importers/html_importer.py                 |  6 ++--
+ .../web_import_plugin/webpage_importer.py          | 16 ++++-----
+ gourmet/test/test_foodnetwork_plugin.py            |  8 ++---
+ gourmet/test/test_ica_se_plugin.py                 |  6 ++--
+ 5 files changed, 36 insertions(+), 42 deletions(-)
+
+diff --git a/INSTALL.md b/INSTALL.md
+index e0a43085..42f8636e 100644
+--- a/INSTALL.md
++++ b/INSTALL.md
+@@ -111,25 +111,25 @@ To sign your installer, run
+ 
+ from the source directory.
+ 
+-Requirements                               |Debian                |MacPorts            |Windows
+--------------------------------------------|----------------------|--------------------|---------------
+-Python 2.7                                 |python                |python27            |http://www.python.org/
+-PyGTK                                      |python-gtk2           |py27-gtk            |[all-in-one installer](http://ftp.gnome.org/pub/GNOME/binaries/win32/pygtk/). Make sure to install PyGTK, PyGObject, PyCairo, and intltool.
+-SQLAlchemy                                 |python-sqlalchemy     |py27-sqlalchemy     |http://www.sqlalchemy.org/download.html
+-Pillow 2.x (Python Imaging Library Fork)   |python-imaging        |py27-Pillow         |https://pypi.python.org/pypi/Pillow/
+-elib.intl                                  |python-elib.intl      |py27-elib.intl      |http://github.com/dieterv/elib.intl/zipball/master
+-*Build Requirements*                       |                      |                    |
+-setuptools (*Windows only!*)               |                      |                    |
+-intltool                                   |intltool              |intltool            |*included in PyGTK installer*
+-python-distutils-extra                     |python-distutils-extra|py27-distutils-extra|https://launchpad.net/python-distutils-extra/
+-*Extra Requirements*                       |                      |
+-Python Reportlab (for printing/PDF export) |python-reportlab      |py27-reportlab      |http://www.reportlab.com/ftp/
+-pypoppler (for printing and PDF export)    |python-poppler        |py27-poppler        |
+-PyGTKSpell (for the spell checking plugin) |python-gtkspell       |py27-gtkspell       |(N/A)
+-python-gst0.10 (for sound)                 |python-gst0.10        |py27-gst-python     |*not required*
+-BeautifulSoup (for the Web import plugin)  |python-beautifulsoup  |py27-beautifulsoup  |http://www.crummy.com/software/BeautifulSoup/#Download
+-IPython 0.12.1 (interactive shell plugin)  |ipython               |py27-ipython        |https://pypi.python.org/pypi/ipython/0.12.1#downloads
+-*Windows only*                             |                      |                    |
+-Perl (needed to run intltool)              |                      |                    |http://strawberryperl.com/
+-cx_Freeze (only needed to build installer) |                      |                    |http://cx-freeze.sourceforge.net/
++Requirements                                      |Debian                |MacPorts            |Windows
++--------------------------------------------------|----------------------|--------------------|---------------
++Python 2.7                                        |python                |python27            |http://www.python.org/
++PyGTK                                             |python-gtk2           |py27-gtk            |[all-in-one installer](http://ftp.gnome.org/pub/GNOME/binaries/win32/pygtk/). Make sure to install PyGTK, PyGObject, PyCairo, and intltool.
++SQLAlchemy                                        |python-sqlalchemy     |py27-sqlalchemy     |http://www.sqlalchemy.org/download.html
++Pillow 2.x (Python Imaging Library Fork)          |python-imaging        |py27-Pillow         |https://pypi.python.org/pypi/Pillow/
++elib.intl                                         |python-elib.intl      |py27-elib.intl      |http://github.com/dieterv/elib.intl/zipball/master
++*Build Requirements*                              |                      |                    |
++setuptools (*Windows only!*)                      |                      |                    |
++intltool                                          |intltool              |intltool            |*included in PyGTK installer*
++python-distutils-extra                            |python-distutils-extra|py27-distutils-extra|https://launchpad.net/python-distutils-extra/
++*Extra Requirements*                              |                      |
++Python Reportlab (for printing/PDF export)        |python-reportlab      |py27-reportlab      |http://www.reportlab.com/ftp/
++pypoppler (for printing and PDF export)           |python-poppler        |py27-poppler        |
++PyGTKSpell (for the spell checking plugin)        |python-gtkspell       |py27-gtkspell       |(N/A)
++python-gst0.10 (for sound)                        |python-gst0.10        |py27-gst-python     |*not required*
++BeautifulSoup>=4.3.0 (for the Web import plugin)  |python-bs4            |py27-beautifulsoup4 |http://www.crummy.com/software/BeautifulSoup/bs4/download/
++IPython 0.12.1 (interactive shell plugin)         |ipython               |py27-ipython        |https://pypi.python.org/pypi/ipython/0.12.1#downloads
++*Windows only*                                    |                      |                    |
++Perl (needed to run intltool)                     |                      |                    |http://strawberryperl.com/
++cx_Freeze (only needed to build installer)        |                      |                    |http://cx-freeze.sourceforge.net/
+ 
+diff --git a/gourmet/importers/html_importer.py b/gourmet/importers/html_importer.py
+index 07bab60a..0729f399 100644
+--- a/gourmet/importers/html_importer.py
++++ b/gourmet/importers/html_importer.py
+@@ -1,6 +1,6 @@
+ import urllib, re, tempfile, os.path
+ import importer
+-import BeautifulSoup
++from bs4 import BeautifulSoup
+ import socket
+ from gourmet.gdebug import debug
+ from gettext import gettext as _
+@@ -43,7 +43,7 @@ def get_url (url, progress):
+         sock = url
+         return read_socket_w_progress(sock,progress,_('Retrieving file'))
+ 
+-class MyBeautifulSoup (BeautifulSoup.ICantBelieveItsBeautifulSoup):
++class MyBeautifulSoup (BeautifulSoup):
+ 
+     def __init__ (self, *args, **kwargs):
+         # Avoid invalid doctype decls of the type
+@@ -56,7 +56,7 @@ def __init__ (self, *args, **kwargs):
+              )
+             )
+         kwargs['avoidParserProblems']=True
+-        BeautifulSoup.ICantBelieveItsBeautifulSoup.__init__(self,*args,**kwargs)
++        BeautifulSoup.__init__(self,*args,**kwargs)
+ 
+     
+     def handle_comment (self, text): pass
+diff --git a/gourmet/plugins/import_export/web_import_plugin/webpage_importer.py b/gourmet/plugins/import_export/web_import_plugin/webpage_importer.py
+index aff9a157..8b10693c 100644
+--- a/gourmet/plugins/import_export/web_import_plugin/webpage_importer.py
++++ b/gourmet/plugins/import_export/web_import_plugin/webpage_importer.py
+@@ -1,5 +1,5 @@
+ # This is a basic
+-import BeautifulSoup
++import bs4
+ from gourmet.importers.generic_recipe_parser import RecipeParser
+ from gourmet.importers.interactive_importer import InteractiveImporter
+ import gourmet.importers.importer
+@@ -20,10 +20,10 @@ class WebParser (InteractiveImporter):
+     TAB = '  '
+     JOINABLE = ['instructions','notes','recipe','ignore','ingredients','include',None]
+     INVISIBLE_TYPES = [
+-        BeautifulSoup.CData,
+-        BeautifulSoup.Comment,
+-        BeautifulSoup.Declaration,
+-        BeautifulSoup.ProcessingInstruction]
++        bs4.CData,
++        bs4.Comment,
++        bs4.Declaration,
++        bs4.ProcessingInstruction]
+ 
+     do_postparse = True
+     imageexcluders = None # This could be a list of compiled regexps which would
+@@ -35,9 +35,7 @@ def __init__ (self, url, data, content_type):
+         #self.name = 'Web Parser'
+         print "HERE's the data we got:", data
+         print "END DATA"
+-        self.soup = BeautifulSoup.BeautifulSoup(data,
+-                                                convertEntities=BeautifulSoup.BeautifulStoneSoup.XHTML_ENTITIES,
+-                                                )
++        self.soup = bs4.BeautifulSoup(data)
+         InteractiveImporter.__init__(self)
+         #self.generic_parser = RecipeParser()
+         self.preparse()
+@@ -150,7 +148,7 @@ def add_buffer_to_parsed (self):
+             to_add = to_add[lws:]
+             self.parsed.append((pre_add,None))
+         # Do extra substitution of MS Characters -- shouldn't be necessary...
+-        for char,tup in BeautifulSoup.UnicodeDammit.MS_CHARS.items():
++        for char,tup in bs4.UnicodeDammit.MS_CHARS.items():
+             char = char.decode('iso-8859-1').encode('utf-8')
+             if to_add.find(char) >= 0:
+                 to_add = to_add.replace(char,unichr(long(tup[1],16)))
+diff --git a/gourmet/test/test_foodnetwork_plugin.py b/gourmet/test/test_foodnetwork_plugin.py
+index 3bafb414..1385524e 100644
+--- a/gourmet/test/test_foodnetwork_plugin.py
++++ b/gourmet/test/test_foodnetwork_plugin.py
+@@ -1,7 +1,7 @@
+ # encoding: utf-8
+ import os.path
+ import unittest
+-import BeautifulSoup
++import bs4
+ 
+ from gourmet.plugins.import_export.website_import_plugins import foodnetwork_plugin
+ 
+@@ -36,16 +36,14 @@ def test_url(self):
+     def test_parse(self):
+         # Setup
+         parser = self.plugin.get_importer(DummyImporter)()
+-        parser.soup = BeautifulSoup.BeautifulSoup(self.text,
+-                            convertEntities=BeautifulSoup.BeautifulStoneSoup.XHTML_ENTITIES,
+-                        )
++        parser.soup = bs4.BeautifulSoup(self.text)
+         # Do the parsing
+         parser.preparse()
+         # Pick apart results
+         result = parser.preparsed_elements
+ 
+         ingredients = [r for r in result if r[1] == "ingredients"][0][0]
+-        ingredients = [i for i in ingredients if type(i) == BeautifulSoup.Tag]
++        ingredients = [i for i in ingredients if type(i) == bs4.Tag]
+         name = [r for r in result if r[1] == "title"][0][0][0].text
+         instructions = [r for r in result if r[1] == "recipe"][0][0].text
+ 
+diff --git a/gourmet/test/test_ica_se_plugin.py b/gourmet/test/test_ica_se_plugin.py
+index 43b6ec21..b7e96ce3 100644
+--- a/gourmet/test/test_ica_se_plugin.py
++++ b/gourmet/test/test_ica_se_plugin.py
+@@ -1,7 +1,7 @@
+ # encoding: utf-8
+ import os.path
+ import unittest
+-import BeautifulSoup
++import bs4
+ 
+ from gourmet.plugins.import_export.website_import_plugins import ica_se_plugin
+ 
+@@ -43,9 +43,7 @@ def test_url(self):
+     def test_parse(self):
+         # Setup
+         parser = self.plugin.get_importer(DummyImporter)()
+-        parser.soup = BeautifulSoup.BeautifulSoup(self.text,
+-                            convertEntities=BeautifulSoup.BeautifulStoneSoup.XHTML_ENTITIES,
+-                        )
++        parser.soup = bs4.BeautifulSoup(self.text)
+         # Do the parsing
+         parser.preparse()
+         # Pick apart results

Deleted: gourmet-pillow.patch
===================================================================
--- gourmet-pillow.patch	2018-12-27 15:13:30 UTC (rev 418505)
+++ gourmet-pillow.patch	2018-12-27 15:13:36 UTC (rev 418506)
@@ -1,37 +0,0 @@
-From 4d88788a6efc68acf243a1a33d854f76b2f26dfd Mon Sep 17 00:00:00 2001
-From: Joe Sapp <joe at babyjoe>
-Date: Tue, 3 Nov 2015 21:23:05 -0500
-Subject: [PATCH] Use Image.tobytes() instead of tostring()
-
-tostring() was deprecated (in Pillow at least) in version 2.0.  See https://github.com/python-pillow/Pillow/commit/baa5143394708704328dcd46b0387f36a276a762
----
- gourmet/gtk_extras/ratingWidget.py             | 2 +-
- gourmet/plugins/browse_recipes/icon_helpers.py | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/gourmet/gtk_extras/ratingWidget.py b/gourmet/gtk_extras/ratingWidget.py
-index 0e01735..efa6463 100644
---- a/gourmet/gtk_extras/ratingWidget.py
-+++ b/gourmet/gtk_extras/ratingWidget.py
-@@ -135,7 +135,7 @@ def get_pixbuf_from_image (self, image, make_white_opaque=True):
-         if is_rgba: rowstride = 4
-         else: rowstride = 3
-         pb=gtk.gdk.pixbuf_new_from_data(
--            image.tostring(),
-+            image.tobytes(),
-             gtk.gdk.COLORSPACE_RGB,
-             is_rgba,
-             8,
-diff --git a/gourmet/plugins/browse_recipes/icon_helpers.py b/gourmet/plugins/browse_recipes/icon_helpers.py
-index 61c772c..2e7b08b 100644
---- a/gourmet/plugins/browse_recipes/icon_helpers.py
-+++ b/gourmet/plugins/browse_recipes/icon_helpers.py
-@@ -38,7 +38,7 @@ def get_pixbuf_from_image (image):
-     if is_rgba: rowstride = 4
-     else: rowstride = 3
-     pb=gtk.gdk.pixbuf_new_from_data(
--        image.tostring(),
-+        image.tobytes(),
-         gtk.gdk.COLORSPACE_RGB,
-         is_rgba,
-         8,

Copied: gourmet/repos/community-any/gourmet-pillow.patch (from rev 418505, gourmet/trunk/gourmet-pillow.patch)
===================================================================
--- gourmet-pillow.patch	                        (rev 0)
+++ gourmet-pillow.patch	2018-12-27 15:13:36 UTC (rev 418506)
@@ -0,0 +1,37 @@
+From 4d88788a6efc68acf243a1a33d854f76b2f26dfd Mon Sep 17 00:00:00 2001
+From: Joe Sapp <joe at babyjoe>
+Date: Tue, 3 Nov 2015 21:23:05 -0500
+Subject: [PATCH] Use Image.tobytes() instead of tostring()
+
+tostring() was deprecated (in Pillow at least) in version 2.0.  See https://github.com/python-pillow/Pillow/commit/baa5143394708704328dcd46b0387f36a276a762
+---
+ gourmet/gtk_extras/ratingWidget.py             | 2 +-
+ gourmet/plugins/browse_recipes/icon_helpers.py | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/gourmet/gtk_extras/ratingWidget.py b/gourmet/gtk_extras/ratingWidget.py
+index 0e01735..efa6463 100644
+--- a/gourmet/gtk_extras/ratingWidget.py
++++ b/gourmet/gtk_extras/ratingWidget.py
+@@ -135,7 +135,7 @@ def get_pixbuf_from_image (self, image, make_white_opaque=True):
+         if is_rgba: rowstride = 4
+         else: rowstride = 3
+         pb=gtk.gdk.pixbuf_new_from_data(
+-            image.tostring(),
++            image.tobytes(),
+             gtk.gdk.COLORSPACE_RGB,
+             is_rgba,
+             8,
+diff --git a/gourmet/plugins/browse_recipes/icon_helpers.py b/gourmet/plugins/browse_recipes/icon_helpers.py
+index 61c772c..2e7b08b 100644
+--- a/gourmet/plugins/browse_recipes/icon_helpers.py
++++ b/gourmet/plugins/browse_recipes/icon_helpers.py
+@@ -38,7 +38,7 @@ def get_pixbuf_from_image (image):
+     if is_rgba: rowstride = 4
+     else: rowstride = 3
+     pb=gtk.gdk.pixbuf_new_from_data(
+-        image.tostring(),
++        image.tobytes(),
+         gtk.gdk.COLORSPACE_RGB,
+         is_rgba,
+         8,



More information about the arch-commits mailing list