View | Details | Raw Unified | Return to bug 229911
Collapse All | Expand All

(-)graphics/mypaint/Makefile (-2 / +1 lines)
Lines 2-9 Link Here
2
# $FreeBSD$
2
# $FreeBSD$
3
3
4
PORTNAME=	mypaint
4
PORTNAME=	mypaint
5
PORTVERSION=	1.2.0
5
PORTVERSION=	1.2.1
6
PORTREVISION=	7
7
CATEGORIES=	graphics
6
CATEGORIES=	graphics
8
MASTER_SITES=	https://github.com/mypaint/mypaint/releases/download/${PORTVERSION:S/^/v/}/
7
MASTER_SITES=	https://github.com/mypaint/mypaint/releases/download/${PORTVERSION:S/^/v/}/
9
8
(-)graphics/mypaint/distinfo (-2 / +3 lines)
Lines 1-2 Link Here
1
SHA256 (mypaint-1.2.0.tar.xz) = cdab33dd0c146cf678c97bcdd44e561f97a0aec40421b8c6785a74b33b9728e2
1
TIMESTAMP = 1531831434
2
SIZE (mypaint-1.2.0.tar.xz) = 37895196
2
SHA256 (mypaint-1.2.1.tar.xz) = ed2349382f6a0c583d7defae06427e97ac7d14acb77b9e2c0fc7171ddd96d3c7
3
SIZE (mypaint-1.2.1.tar.xz) = 37897196
(-)graphics/mypaint/files/patch-lib_glib.py (-46 lines)
Lines 1-46 Link Here
1
--- lib/glib.py.orig	2016-01-15 19:42:55 UTC
2
+++ lib/glib.py
3
@@ -1,5 +1,5 @@
4
 # This file is part of MyPaint.
5
-# Copyright (C) 2015 by Andrew Chadwick <a.t.chadwick@gmail.com>
6
+# Copyright (C) 2015-2016 by the MyPaint Development Team.
7
 #
8
 # This program is free software; you can redistribute it and/or modify
9
 # it under the terms of the GNU General Public License as published by
10
@@ -19,11 +19,12 @@ unicode, and may not even be UTF-8). Thi
11
 ## Imports
12
 
13
 import sys
14
-from logging import getLogger
15
-logger = getLogger(__name__)
16
+import logging
17
 
18
 from gi.repository import GLib
19
 
20
+logger = logging.getLogger(__name__)
21
+
22
 
23
 ## File path getter functions
24
 
25
@@ -35,7 +36,6 @@ def filename_to_unicode(opsysstring):
26
     :returns: the converted filename
27
     :rtype: unicode
28
 
29
-    >>> from gi.repository import GLib
30
     >>> filename_to_unicode('/ascii/only/path')
31
     u'/ascii/only/path'
32
     >>> filename_to_unicode(None) is None
33
@@ -54,7 +54,12 @@ def filename_to_unicode(opsysstring):
34
     # Other systems are dependent in opaque ways on the environment.
35
     if not isinstance(opsysstring, str):
36
         raise TypeError("Argument must be bytes")
37
-    ustring = GLib.filename_to_utf8(opsysstring, -1, 0, 0)
38
+    # This function's annotation seems to vary quite a bit.
39
+    # See https://github.com/mypaint/mypaint/issues/634
40
+    try:
41
+        ustring, _, _ = GLib.filename_to_utf8(opsysstring, -1)
42
+    except TypeError:
43
+        ustring = GLib.filename_to_utf8(opsysstring, -1, 0, 0)
44
     if ustring is None:
45
         raise UnicodeDecodeError(
46
             "GLib failed to convert %r to a UTF-8 string. "

Return to bug 229911