[arch-commits] Commit in ibus-typing-booster/trunk (2 files)

Jan Steffens heftig at archlinux.org
Fri Jan 13 18:41:17 UTC 2017


    Date: Friday, January 13, 2017 @ 18:41:16
  Author: heftig
Revision: 286202

1.5.17-1

Modified:
  ibus-typing-booster/trunk/PKGBUILD
Deleted:
  ibus-typing-booster/trunk/0001-Unbreak-sqlite-on-Python-3.6.patch

-----------------------------------------+
 0001-Unbreak-sqlite-on-Python-3.6.patch |  108 ------------------------------
 PKGBUILD                                |   13 +--
 2 files changed, 5 insertions(+), 116 deletions(-)

Deleted: 0001-Unbreak-sqlite-on-Python-3.6.patch
===================================================================
--- 0001-Unbreak-sqlite-on-Python-3.6.patch	2017-01-13 18:06:46 UTC (rev 286201)
+++ 0001-Unbreak-sqlite-on-Python-3.6.patch	2017-01-13 18:41:16 UTC (rev 286202)
@@ -1,108 +0,0 @@
-From 2e665e9f51e44808a472a8e7fd13edb205ba5ba7 Mon Sep 17 00:00:00 2001
-From: "Jan Alexander Steffens (heftig)" <jan.steffens at gmail.com>
-Date: Fri, 13 Jan 2017 00:21:52 +0100
-Subject: [PATCH] Unbreak sqlite on Python 3.6
-
-Py3.6 changed the transaction behavior; DDL commands like PRAGMA do not
-commit open transactions anymore, and since the default for execute() is
-to auto-open a transaction, setting the journal_mode fails.
-
-Changing the isolation_level to None so that transactions aren't opened
-anymore is a possible workaround. However, using executescript() seems
-like a better idea; it always commits any open transaction first.
----
- engine/tabsqlitedb.py | 60 +++++++++++++++++++++++++++------------------------
- 1 file changed, 32 insertions(+), 28 deletions(-)
-
-diff --git a/engine/tabsqlitedb.py b/engine/tabsqlitedb.py
-index 4ff7f020ecf9dd40..9d3b576ba84723d1 100755
---- a/engine/tabsqlitedb.py
-+++ b/engine/tabsqlitedb.py
-@@ -205,16 +205,17 @@ class tabsqlitedb:
-                 "Connect to the database %(name)s.\n"
-                 %{'name': self.user_db_file})
-             self.db = sqlite3.connect(self.user_db_file)
--            self.db.execute('PRAGMA encoding = "UTF-8";')
--            self.db.execute('PRAGMA case_sensitive_like = true;')
--            self.db.execute('PRAGMA page_size = 4096; ')
--            self.db.execute('PRAGMA cache_size = 20000;')
--            self.db.execute('PRAGMA temp_store = MEMORY;')
--            self.db.execute('PRAGMA journal_mode = WAL;')
--            self.db.execute('PRAGMA journal_size_limit = 1000000;')
--            self.db.execute('PRAGMA synchronous = NORMAL;')
--            self.db.execute('ATTACH DATABASE "%s" AS user_db;'
--                            % self.user_db_file)
-+            self.db.executescript('''
-+                PRAGMA encoding = "UTF-8";
-+                PRAGMA case_sensitive_like = true;
-+                PRAGMA page_size = 4096;
-+                PRAGMA cache_size = 20000;
-+                PRAGMA temp_store = MEMORY;
-+                PRAGMA journal_mode = WAL;
-+                PRAGMA journal_size_limit = 1000000;
-+                PRAGMA synchronous = NORMAL;
-+                ATTACH DATABASE "%s" AS user_db;
-+            ''' % self.user_db_file)
-         except:
-             sys.stderr.write(
-                 "Could not open the database %(name)s.\n"
-@@ -236,16 +237,17 @@ class tabsqlitedb:
-                 %{'name': self.user_db_file})
-             self.init_user_db()
-             self.db = sqlite3.connect(self.user_db_file)
--            self.db.execute('PRAGMA encoding = "UTF-8";')
--            self.db.execute('PRAGMA case_sensitive_like = true;')
--            self.db.execute('PRAGMA page_size = 4096; ')
--            self.db.execute('PRAGMA cache_size = 20000;')
--            self.db.execute('PRAGMA temp_store = MEMORY;')
--            self.db.execute('PRAGMA journal_mode = WAL;')
--            self.db.execute('PRAGMA journal_size_limit = 1000000;')
--            self.db.execute('PRAGMA synchronous = NORMAL;')
--            self.db.execute('ATTACH DATABASE "%s" AS user_db;'
--                            % self.user_db_file)
-+            self.db.executescript('''
-+                PRAGMA encoding = "UTF-8";
-+                PRAGMA case_sensitive_like = true;
-+                PRAGMA page_size = 4096;
-+                PRAGMA cache_size = 20000;
-+                PRAGMA temp_store = MEMORY;
-+                PRAGMA journal_mode = WAL;
-+                PRAGMA journal_size_limit = 1000000;
-+                PRAGMA synchronous = NORMAL;
-+                ATTACH DATABASE "%s" AS user_db;
-+            ''' % self.user_db_file)
-         self.create_tables()
-         if self.old_phrases:
-             sqlargs = []
-@@ -657,18 +659,20 @@ class tabsqlitedb:
-             return
-         if not path.exists(self.user_db_file):
-             db = sqlite3.connect(self.user_db_file)
--            db.execute('PRAGMA encoding = "UTF-8";')
--            db.execute('PRAGMA case_sensitive_like = true;')
--            db.execute('PRAGMA page_size = 4096;')
-             # a database containing the complete German Hunspell
-             # dictionary has less then 6000 pages. 20000 pages
-             # should be enough to cache the complete database
-             # in most cases.
--            db.execute('PRAGMA cache_size = 20000;')
--            db.execute('PRAGMA temp_store = MEMORY; ')
--            db.execute('PRAGMA journal_mode = WAL;')
--            db.execute('PRAGMA journal_size_limit = 1000000;')
--            db.execute('PRAGMA synchronous = NORMAL;')
-+            self.db.executescript('''
-+                PRAGMA encoding = "UTF-8";
-+                PRAGMA case_sensitive_like = true;
-+                PRAGMA page_size = 4096;
-+                PRAGMA cache_size = 20000;
-+                PRAGMA temp_store = MEMORY;
-+                PRAGMA journal_mode = WAL;
-+                PRAGMA journal_size_limit = 1000000;
-+                PRAGMA synchronous = NORMAL;
-+            ''')
-             db.commit()
- 
-     def get_database_desc(self, db_file):
--- 
-2.11.0
-

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2017-01-13 18:06:46 UTC (rev 286201)
+++ PKGBUILD	2017-01-13 18:41:16 UTC (rev 286202)
@@ -2,8 +2,8 @@
 # Maintainer: Jan Alexander Steffens (heftig) <jan.steffens at gmail.com>
 
 pkgname=ibus-typing-booster
-pkgver=1.5.16
-pkgrel=2
+pkgver=1.5.17
+pkgrel=1
 pkgdesc="Predictive input method for the IBus platform"
 url="https://fedorahosted.org/ibus-typing-booster/"
 arch=(any)
@@ -10,11 +10,9 @@
 license=(GPL3)
 depends=(ibus python-gobject python-dbus python-pyenchant m17n-lib sqlite)
 makedepends=(git m17n-db hunspell hunspell-{de,el,en,es,fr,he,hu,it,nl,pl,ro})
-_commit=1127c43096d0c267d7b18cf9c86417b78d7ae61c  # master
-source=("git+https://git.fedorahosted.org/git/ibus-typing-booster#commit=$_commit"
-        0001-Unbreak-sqlite-on-Python-3.6.patch)
-sha512sums=('SKIP'
-            '86a0a24baa2f55a3140bcd98e5d442ec823e4032cc5069357d7be76b2d1bf58eb73ea4b464fdc92bf2b98f42e3f12559da715374e06de8173da0f5dc6c02b15d')
+_commit=97fd8c961d0f9ff1695fcd43527d2b9441ca7f41  # master
+source=("git+https://git.fedorahosted.org/git/ibus-typing-booster#commit=$_commit")
+sha512sums=('SKIP')
 
 pkgver() {
   cd $pkgname
@@ -23,7 +21,6 @@
 
 prepare() {
   cd $pkgname
-  patch -Np1 -i ../0001-Unbreak-sqlite-on-Python-3.6.patch
   autoreconf -fvi
 }
 



More information about the arch-commits mailing list