summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDongHun Kwak <dh0128.kwak@samsung.com>2017-07-12 08:38:56 +0900
committerDongHun Kwak <dh0128.kwak@samsung.com>2017-07-12 08:38:59 +0900
commit705bf16f6a14a07ccdc0c1a5fe1b31d92c3bd96e (patch)
treedd6f9f0e2056cdcf69380c9a0771deb6c5b49c78
parent44cf7615f8b29c5a41b4f8232f423683bebf2111 (diff)
downloadpygobject2-705bf16f6a14a07ccdc0c1a5fe1b31d92c3bd96e.tar.gz
pygobject2-705bf16f6a14a07ccdc0c1a5fe1b31d92c3bd96e.tar.bz2
pygobject2-705bf16f6a14a07ccdc0c1a5fe1b31d92c3bd96e.zip
Imported Upstream version 3.1.93
Change-Id: I1c47911211b99284d57c2547ee7e938f95483dec Signed-off-by: DongHun Kwak <dh0128.kwak@samsung.com>
-rw-r--r--ChangeLog103
-rw-r--r--NEWS8
-rw-r--r--PKG-INFO4
-rwxr-xr-xconfigure26
-rw-r--r--configure.ac2
-rw-r--r--gi/overrides/Gtk.py26
-rw-r--r--gi/pygi-marshal-from-py.c3
-rw-r--r--gi/pygi-marshal-to-py.c3
-rw-r--r--tests/test_overrides.py14
-rw-r--r--tests/test_pygtkcompat.py3
10 files changed, 157 insertions, 35 deletions
diff --git a/ChangeLog b/ChangeLog
index 35d69d6..cbcf9c2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,106 @@
+commit ab0ee3c606b89a0db03f34256efbebae3c1886a0
+Author: Martin Pitt <martin.pitt@ubuntu.com>
+Date: Thu Mar 22 10:58:04 2012 +0100
+
+ Release 3.1.93
+
+ NEWS | 8 ++++++++
+ 1 files changed, 8 insertions(+), 0 deletions(-)
+
+commit a43992fc3ecdcdd28024980bd9e98e5d21ede37f
+Author: Martin Pitt <martin.pitt@ubuntu.com>
+Date: Wed Mar 21 15:21:02 2012 +0100
+
+ pygtkcompat test: Properly clean up PixbufLoader
+
+ Tests currently give
+
+ (runtests.py:15072): GdkPixbuf-WARNING **: GdkPixbufLoader finalized
+ without calling gdk_pixbuf_loader_close() - this is not allowed. You
+ must explicitly end the data stream to the loader before dropping
+ the last reference.
+
+ Fix this by calling close().
+
+ tests/test_pygtkcompat.py | 3 ++-
+ 1 files changed, 2 insertions(+), 1 deletions(-)
+
+commit df44fdd3f8bcb285dc6abfe7b32ee816077f95eb
+Author: Martin Pitt <martin.pitt@ubuntu.com>
+Date: Thu Mar 22 09:58:21 2012 +0100
+
+ test_overrides: Find local gsettings schema with current glib
+
+ With current glib, gsettings now fails to find the gschemas.compiled
+ during the
+ tests. Move the setting of $GSETTINGS_SCHEMA_DIR before the module
+ import,
+ which makes this work again.
+
+ tests/test_overrides.py | 9 +++++----
+ 1 files changed, 5 insertions(+), 4 deletions(-)
+
+commit d931b26ac1ee8a36c5daef933720982a3f31c116
+Author: Alberto Mardegan <alberto.mardegan@canonical.com>
+Date: Tue Mar 20 14:55:07 2012 +0400
+
+ Support marshalling GI_TYPE_TAG_INTERFACE
+
+ Marshalling of interfaces got broken with commit
+ 7746d2188ac4933c2c9011d84525d1e62fc18953.
+
+ Also, do not abort on unsupported types, but log a critical failure
+ and
+ continue.
+
+ https://bugzilla.gnome.org/show_bug.cgi?id=668903
+
+ gi/pygi-marshal-from-py.c | 3 ++-
+ gi/pygi-marshal-to-py.c | 3 ++-
+ 2 files changed, 4 insertions(+), 2 deletions(-)
+
+commit 1b3f8b1fde2ba25592eb038341eabf6157f12c25
+Author: Martin Pitt <martin.pitt@ubuntu.com>
+Date: Wed Mar 21 14:34:36 2012 +0100
+
+ Fix warnings on None values in added tree/list store rows
+
+ Commit bf8c95836e1c changed the List/TreeStore overrides to use
+ insert_with_valuesv(), but supplied all columns instead of just
+ those which are
+ not None. With this, None values cause warnings like
+
+ (runtests.py:12375): Gtk-WARNING **:
+ /build/buildd/gtk+3.0-3.3.20/./gtk/gtkliststore.c:851: Unable to
+ convert from (null) to gboolean
+
+ Update the tests to make warnings fatal, to catch this better.
+
+ Change _convert_row() to skip the None entries and return the list
+ of not-None
+ columns, and use the latter instead of a simple range(n_columns). This
+ matches
+ the behaviour before bf8c95836e1c, where columns with None values
+ were skipped
+ as well.
+
+ https://bugzilla.gnome.org/show_bug.cgi?id=672463
+
+ gi/overrides/Gtk.py | 26 ++++++++++++++------------
+ tests/test_overrides.py | 5 +++++
+ 2 files changed, 19 insertions(+), 12 deletions(-)
+
+commit 5e0e5e72a4436badd09f0aa07f62960afcdca8c6
+Author: Martin Pitt <martin.pitt@ubuntu.com>
+Date: Mon Mar 19 16:58:22 2012 +0100
+
+ post-release bump
+
+ Use 3.1.93 for now, this will most likely become 3.2.0 as it is.
+
+ configure.ac | 2 +-
+ 1 files changed, 1 insertions(+), 1 deletions(-)
+
commit 88924e399d7ccf7af2e9a78720e0c508cd6080d8
Author: Martin Pitt <martin.pitt@ubuntu.com>
Date: Mon Mar 19 16:41:17 2012 +0100
diff --git a/NEWS b/NEWS
index a6aa6c0..a90c7d0 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,11 @@
+3.1.93 22-Mar-2012
+ - Fix warnings on None values in added tree/list store rows.
+ (#672463, Martin Pitt)
+ - Support marshalling GI_TYPE_TAG_INTERFACE (#668903, Alberto Mardegan)
+ - test_overrides: Find local gsettings schema with current glib
+ (Martin Pitt)
+ - pygtkcompat test: Properly clean up PixbufLoader (Martin Pitt)
+
3.1.92 19-Mar-2012
- Correct Gtk.TreePath.__iter__ to work with Python 3 (Johan Dahlin)
- Fix test_everything.TestSignals.test_object_param_signal test case
diff --git a/PKG-INFO b/PKG-INFO
index eec3e96..64c2f50 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
Metadata-Version: 1.0
Name: PyGObject
-Version: 3.1.92
+Version: 3.1.93
Summary: Python bindings for GObject
Home-page: http://www.pygtk.org/
Author: James Henstridge
@@ -8,7 +8,7 @@ Author-email: james@daa.com.au
Maintainer: Johan Dahlin
Maintainer-email: johan@gnome.org
License: GNU LGPL
-Download-url: ftp://ftp.gnome.org/pub/GNOME/sources/pygobject/3.1/pygobject-3.1.92.tar.gz
+Download-url: ftp://ftp.gnome.org/pub/GNOME/sources/pygobject/3.1/pygobject-3.1.93.tar.gz
Description: Python bindings for GLib and GObject
Platform: POSIX, Windows
Classifier: Development Status :: 5 - Production/Stable
diff --git a/configure b/configure
index 82ec51f..2a67bdf 100755
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.68 for pygobject 3.1.92.
+# Generated by GNU Autoconf 2.68 for pygobject 3.1.93.
#
# Report bugs to <http://bugzilla.gnome.org/enter_bug.cgi?product=pygobject>.
#
@@ -571,8 +571,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='pygobject'
PACKAGE_TARNAME='pygobject'
-PACKAGE_VERSION='3.1.92'
-PACKAGE_STRING='pygobject 3.1.92'
+PACKAGE_VERSION='3.1.93'
+PACKAGE_STRING='pygobject 3.1.93'
PACKAGE_BUGREPORT='http://bugzilla.gnome.org/enter_bug.cgi?product=pygobject'
PACKAGE_URL=''
@@ -1363,7 +1363,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures pygobject 3.1.92 to adapt to many kinds of systems.
+\`configure' configures pygobject 3.1.93 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1433,7 +1433,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of pygobject 3.1.92:";;
+ short | recursive ) echo "Configuration of pygobject 3.1.93:";;
esac
cat <<\_ACEOF
@@ -1559,7 +1559,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-pygobject configure 3.1.92
+pygobject configure 3.1.93
generated by GNU Autoconf 2.68
Copyright (C) 2010 Free Software Foundation, Inc.
@@ -1837,7 +1837,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by pygobject $as_me 3.1.92, which was
+It was created by pygobject $as_me 3.1.93, which was
generated by GNU Autoconf 2.68. Invocation command line was
$ $0 $@
@@ -2201,9 +2201,9 @@ $as_echo "#define PYGOBJECT_MINOR_VERSION 1" >>confdefs.h
PYGOBJECT_MINOR_VERSION=1
-$as_echo "#define PYGOBJECT_MICRO_VERSION 92" >>confdefs.h
+$as_echo "#define PYGOBJECT_MICRO_VERSION 93" >>confdefs.h
-PYGOBJECT_MICRO_VERSION=92
+PYGOBJECT_MICRO_VERSION=93
ac_config_headers="$ac_config_headers config.h"
@@ -2714,7 +2714,7 @@ fi
# Define the identity of the package.
PACKAGE='pygobject'
- VERSION='3.1.92'
+ VERSION='3.1.93'
cat >>confdefs.h <<_ACEOF
@@ -12118,7 +12118,7 @@ Usage: $0 [OPTIONS]
Report bugs to <bug-libtool@gnu.org>."
lt_cl_version="\
-pygobject config.lt 3.1.92
+pygobject config.lt 3.1.93
configured by $0, generated by GNU Autoconf 2.68.
Copyright (C) 2011 Free Software Foundation, Inc.
@@ -16828,7 +16828,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by pygobject $as_me 3.1.92, which was
+This file was extended by pygobject $as_me 3.1.93, which was
generated by GNU Autoconf 2.68. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -16894,7 +16894,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
-pygobject config.status 3.1.92
+pygobject config.status 3.1.93
configured by $0, generated by GNU Autoconf 2.68,
with options \\"\$ac_cs_config\\"
diff --git a/configure.ac b/configure.ac
index 3582566..9a7401c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -12,7 +12,7 @@ m4_define(python3_min_ver, 3.1)
dnl the pygobject version number
m4_define(pygobject_major_version, 3)
m4_define(pygobject_minor_version, 1)
-m4_define(pygobject_micro_version, 92)
+m4_define(pygobject_micro_version, 93)
m4_define(pygobject_version, pygobject_major_version.pygobject_minor_version.pygobject_micro_version)
dnl versions of packages we require ...
diff --git a/gi/overrides/Gtk.py b/gi/overrides/Gtk.py
index 9d3ba0a..4018b32 100644
--- a/gi/overrides/Gtk.py
+++ b/gi/overrides/Gtk.py
@@ -809,19 +809,23 @@ class TreeModel(Gtk.TreeModel):
raise ValueError('row sequence has the incorrect number of elements')
result = []
- for i in range(n_columns):
- value = row[i]
- result.append(self._convert_value(i, value))
- return result
+ columns = []
+ for cur_col, value in enumerate(row):
+ # do not try to set None values, they are causing warnings
+ if value is None:
+ continue
+ result.append(self._convert_value(cur_col, value))
+ columns.append(cur_col)
+ return (result, columns)
def set_row(self, treeiter, row):
- converted_row = self._convert_row(row)
- for i in range(self.get_n_columns()):
- value = row[i]
+ converted_row, columns = self._convert_row(row)
+ for column in columns:
+ value = row[column]
if value is None:
continue # None means skip this row
- self.set_value(treeiter, i, value)
+ self.set_value(treeiter, column, value)
def _convert_value(self, column, value):
if value is None:
@@ -949,8 +953,7 @@ class ListStore(Gtk.ListStore, TreeModel, TreeSortable):
def _do_insert(self, position, row):
if row is not None:
- row = self._convert_row(row)
- columns = range(len(row))
+ row, columns = self._convert_row(row)
treeiter = self.insert_with_valuesv(position, columns, row)
else:
treeiter = Gtk.ListStore.insert(self, position)
@@ -1179,8 +1182,7 @@ class TreeStore(Gtk.TreeStore, TreeModel, TreeSortable):
def _do_insert(self, parent, position, row):
if row is not None:
- row = self._convert_row(row)
- columns = range(len(row))
+ row, columns = self._convert_row(row)
treeiter = self.insert_with_values(parent, position, columns, row)
else:
treeiter = Gtk.TreeStore.insert(self, parent, position)
diff --git a/gi/pygi-marshal-from-py.c b/gi/pygi-marshal-from-py.c
index 962747f..c789d1d 100644
--- a/gi/pygi-marshal-from-py.c
+++ b/gi/pygi-marshal-from-py.c
@@ -1066,9 +1066,10 @@ _pygi_arg_to_hash_pointer (const GIArgument *arg,
return GINT_TO_POINTER(arg->v_int32);
case GI_TYPE_TAG_UTF8:
case GI_TYPE_TAG_FILENAME:
+ case GI_TYPE_TAG_INTERFACE:
return arg->v_pointer;
default:
- g_assert_not_reached();
+ g_critical("Unsupported type %s", g_type_tag_to_string(type_tag));
return arg->v_pointer;
}
}
diff --git a/gi/pygi-marshal-to-py.c b/gi/pygi-marshal-to-py.c
index ce93257..3af443d 100644
--- a/gi/pygi-marshal-to-py.c
+++ b/gi/pygi-marshal-to-py.c
@@ -521,9 +521,10 @@ _pygi_hash_pointer_to_arg (GIArgument *arg,
break;
case GI_TYPE_TAG_UTF8:
case GI_TYPE_TAG_FILENAME:
+ case GI_TYPE_TAG_INTERFACE:
break;
default:
- g_assert_not_reached();
+ g_critical("Unsupported type %s", g_type_tag_to_string(type_tag));
}
}
diff --git a/tests/test_overrides.py b/tests/test_overrides.py
index 58c77bf..78e589f 100644
--- a/tests/test_overrides.py
+++ b/tests/test_overrides.py
@@ -9,6 +9,11 @@ sys.path.insert(0, "../")
from compathelper import _long, _unicode, _bytes
+os.environ['GSETTINGS_BACKEND'] = 'memory'
+# support a separate build tree, so look in build dir first
+os.environ['GSETTINGS_SCHEMA_DIR'] = os.environ.get('TESTS_BUILDDIR',
+ os.path.dirname(__file__))
+
from gi.repository import GLib
from gi.repository import GObject
from gi.repository import Gdk
@@ -19,6 +24,11 @@ from gi.repository import GdkPixbuf
import gi.overrides as overrides
import gi.types
+# in general we don't want tests to raise warnings, except when explicitly
+# testing with bad values; in those cases it will temporarily be set back to
+# ERROR
+GLib.log_set_always_fatal(GLib.LogLevelFlags.LEVEL_WARNING)
+
class TestGLib(unittest.TestCase):
def test_gvariant_create(self):
@@ -1859,10 +1869,6 @@ class TestGtk(unittest.TestCase):
class TestGio(unittest.TestCase):
def setUp(self):
- os.environ['GSETTINGS_BACKEND'] = 'memory'
- # support a separate build tree, so look in build dir first
- os.environ['GSETTINGS_SCHEMA_DIR'] = os.environ.get('TESTS_BUILDDIR',
- os.path.dirname(__file__))
self.settings = Gio.Settings('org.gnome.test')
# we change the values in the tests, so set them to predictable start
# value
diff --git a/tests/test_pygtkcompat.py b/tests/test_pygtkcompat.py
index 2567f68..b9765c3 100644
--- a/tests/test_pygtkcompat.py
+++ b/tests/test_pygtkcompat.py
@@ -74,7 +74,8 @@ class TestGTKCompat(unittest.TestCase):
gtk.gdk.Pixbuf()
def testPixbufLoader(self):
- gtk.gdk.PixbufLoader('png')
+ loader = gtk.gdk.PixbufLoader('png')
+ loader.close()
def testGdkWindow(self):
w = gtk.Window()