Did I find the right examples for you? yes no

All Samples(164)  |  Call(122)  |  Derive(42)  |  Import(0)
Unicode encoding error.

src/p/l/plexnet-HEAD/third_party/generic/pypy/pypy/module/_codecs/app_codecs.py   plexnet(Download)
        exceptionObject = UnicodeDecodeError(encoding, input, startinpos, endinpos, reason)
    else:
        exceptionObject = UnicodeEncodeError(encoding, input, startinpos, endinpos, reason)
    res = errorHandler(exceptionObject)
    if isinstance(res, tuple) and len(res) == 2 and isinstance(res[0], unicode) and isinstance(res[1], int):
                res += [charmapencode_output(ord(y), mapping) for y in x[0]]
            except KeyError:
                raise UnicodeEncodeError("charmap", p, inpos, inpos+1,
                                        "character maps to <undefined>")
        inpos += 1

src/a/l/allmydata-tahoe-1.10.0/src/allmydata/util/encodingutil.py   allmydata-tahoe(Download)
        out = s.encode(io_encoding)
    except (UnicodeEncodeError, UnicodeDecodeError):
        raise UnicodeEncodeError(io_encoding, s, 0, 0,
                                 "A string could not be encoded as %s for output to the terminal:\n%r" %
                                 (io_encoding, repr(s)))
 
    if PRINTABLE_8BIT.search(out) is None:
        raise UnicodeEncodeError(io_encoding, s, 0, 0,

src/p/l/plexnet-HEAD/third_party/generic/pypy/pypy/rlib/runicode.py   plexnet(Download)
def raise_unicode_exception_encode(errors, encoding, msg, u,
                                   startingpos, endingpos):
    assert isinstance(u, unicode)
    raise UnicodeEncodeError(
            encoding, u[startingpos], startingpos, endingpos, msg)

src/t/a/tahoe-lafs-HEAD/src/allmydata/util/encodingutil.py   tahoe-lafs(Download)
        out = s.encode(io_encoding)
    except (UnicodeEncodeError, UnicodeDecodeError):
        raise UnicodeEncodeError(io_encoding, s, 0, 0,
                                 "A string could not be encoded as %s for output to the terminal:\n%r" %
                                 (io_encoding, repr(s)))
 
    if PRINTABLE_8BIT.search(out) is None:
        raise UnicodeEncodeError(io_encoding, s, 0, 0,

src/w/e/web2py-appreport-HEAD/modules/plugin_appreport/libs/appreport/libs/pisa/libs/pyPdf/pyPdf/generic.py   web2py-appreport(Download)
            retval += chr(_pdfDocEncoding_rev[c])
        except KeyError:
            raise UnicodeEncodeError("pdfdocencoding", c, -1, -1,
                    "does not exist in translation table")
    return retval

src/p/y/python-future-HEAD/future/utils/surrogateescape.py   python-future(Download)
                ch = bytes_chr(code - 0xDC00)
            else:
                raise UnicodeEncodeError(FS_ENCODING,
                    fn, index, index+1,
                    'ordinal not in range(128)')
                else:
                    raise UnicodeEncodeError(
                        FS_ENCODING,
                        fn, index, index+1, 'surrogates not allowed')
            else:

src/s/y/Sypy-HEAD/rlib/runicode.py   Sypy(Download)
def raise_unicode_exception_encode(errors, encoding, msg, u,
                                   startingpos, endingpos):
    assert isinstance(u, unicode)
    raise UnicodeEncodeError(encoding, u, startingpos, endingpos, msg)
 

src/f/n/fnord.safename-0.5/src/fnord/safename/codec.py   fnord.safename(Download)
    if scanned[1]:
        raise UnicodeEncodeError(
            "safename", u"", 0, len(string), "Can't encode string"
        )
    return u"".join(scanned[0])

src/o/p/openerp-core-7.0.406/openerp/report/pyPdf/generic.py   openerp-core(Download)
            retval += chr(_pdfDocEncoding_rev[c])
        except KeyError:
            raise UnicodeEncodeError("pdfdocencoding", c, -1, -1,
                    "does not exist in translation table")
    return retval

src/o/p/openerp-server-5.0.0-3/bin/report/pyPdf/generic.py   openerp-server(Download)
            retval += chr(_pdfDocEncoding_rev[c])
        except KeyError:
            raise UnicodeEncodeError("pdfdocencoding", c, -1, -1,
                    "does not exist in translation table")
    return retval

  1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9  Next