Did I find the right examples for you? yes no

All Samples(21)  |  Call(0)  |  Derive(0)  |  Import(21)

src/p/l/plexnet-HEAD/third_party/generic/pypy/pypy/module/_codecs/app_codecs.py   plexnet(Download)
def _register_existing_errors():
    import _codecs
    _codecs.register_error("strict", strict_errors)
    _codecs.register_error("ignore", ignore_errors)
    _codecs.register_error("replace", replace_errors)
def unicode_call_errorhandler(errors,  encoding, 
                reason, input, startinpos, endinpos, decode=True):
 
    import _codecs
    errorHandler = _codecs.lookup_error(errors)
#    /* Default to Latin-1 */
    if mapping == None:
        import _codecs
        return _codecs.latin_1_encode(p, errors)[0]
    size = len(p)
##    /* Default to Latin-1 */
    if mapping is None:
        import _codecs
        return _codecs.latin_1_decode(s, errors)[0]
 

src/s/y/Sypy-HEAD/module/_codecs/test/test_codecs.py   Sypy(Download)
    def test_register_noncallable(self):
        import _codecs
        raises(TypeError, _codecs.register, 1)
 
    def test_bigU_codecs(self):
    def test_partial_utf8(self):
        import _codecs
        encoding = 'utf-8'
        check_partial = [
                u"\x00",
    def test_partial_utf16(self):
        import _codecs
        encoding = 'utf-16'
        check_partial = [
                    u"", # first byte of BOM read
    def test_codec_wrong_result(self):
        import _codecs
        def search_function(encoding):
            def f(input, errors="strict"):
                return 42
    def test_array(self):
        import _codecs, array
        _codecs.readbuffer_encode(array.array('c', 'spam')) == ('spam', 4)
 
    def test_utf8sig(self):

src/p/l/plexnet-HEAD/third_party/generic/pypy/pypy/module/_codecs/test/test_codecs.py   plexnet(Download)
    def test_register_noncallable(self):
        import _codecs
        raises(TypeError, _codecs.register, 1)
 
    def test_bigU_codecs(self):
    def test_partial_utf8(self):
        import _codecs
        encoding = 'utf-8'
        check_partial = [
                u"\x00",
    def test_partial_utf16(self):
        import _codecs
        encoding = 'utf-16'
        check_partial = [
                    u"", # first byte of BOM read
    def test_codec_wrong_result(self):
        import _codecs
        def search_function(encoding):
            def f(input, errors="strict"):
                return 42
    def test_array(self):
        import _codecs, array
        _codecs.readbuffer_encode(array.array('c', 'spam')) == ('spam', 4)
 
    def test_utf8sig(self):

src/m/a/main-HEAD/Languages/IronPython/Tests/modules/io_related/codecs_test.py   main(Download)
 
if is_cli or is_silverlight:
    import _codecs as codecs
else:
    import codecs
def test_cp20302():
    import _codecs
    for encoding in ip_supported_encodings:
        if encoding.lower() in ['cp1252']: #http://ironpython.codeplex.com/WorkItem/View.aspx?WorkItemId=20302
            continue

src/i/r/ironpython3-HEAD/Tests/modules/io_related/codecs_test.py   ironpython3(Download)
 
if is_cli or is_silverlight:
    import _codecs as codecs
else:
    import codecs
def test_cp20302():
    import _codecs
    for encoding in ip_supported_encodings:
        if encoding.lower() in ['cp1252']: #http://ironpython.codeplex.com/WorkItem/View.aspx?WorkItemId=20302
            continue