-
Notifications
You must be signed in to change notification settings - Fork 637
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Jython 2.7 #1079
Comments
Smells like a Unicode encoding issue, maybe of your script file from above. # -*- coding: UTF-8 -*-
# — HINT: Same as above from here on.
import sys
… HINT: But the file needs to have also this encoding. |
Hello, adding For now, this is a very bad idea, as a workaround it seems to works. I replaced the file in def _compile_invalid_re():
# http://stackoverflow.com/questions/1707890/fast-way-to-filter-illegal-xml-unicode-chars-in-python
illegal_unichrs = [
(0x00, 0x08), (0x0B, 0x1F), (0x7F, 0x84), (0x86, 0x9F),
(0xD800, 0xDFFF), (0xFDD0, 0xFDDF), (0xFFFE, 0xFFFF),
(0x1FFFE, 0x1FFFF), (0x2FFFE, 0x2FFFF), (0x3FFFE, 0x3FFFF),
(0x4FFFE, 0x4FFFF), (0x5FFFE, 0x5FFFF), (0x6FFFE, 0x6FFFF),
(0x7FFFE, 0x7FFFF), (0x8FFFE, 0x8FFFF), (0x9FFFE, 0x9FFFF),
(0xAFFFE, 0xAFFFF), (0xBFFFE, 0xBFFFF), (0xCFFFE, 0xCFFFF),
(0xDFFFE, 0xDFFFF), (0xEFFFE, 0xEFFFF), (0xFFFFE, 0xFFFFF),
(0x10FFFE, 0x10FFFF),
]
############################################################################################################################
#This version of the function excludes the surrogate range from the list of invalid characters, which should resolve the "ValueError" error.
illegal_ranges = [
u"%s-%s" % (unichr(low), unichr(high))
for (low, high) in illegal_unichrs
if low < sys.maxunicode and (low < 0xD800 or high > 0xDFFF)]
############################################################################################################################
# illegal_ranges = [
# "%s-%s" % (unichr(low), unichr(high))
# for (low, high) in illegal_unichrs
# if low < sys.maxunicode]
return re.compile(u'[%s]' % u''.join(illegal_ranges)) |
Hello, I have run all tutorials in behave.github.io/behave.example with this workaround. Run all tutorials :
Run Data Types and User-defined Types
Run Step Matchers:
|
Hello,
I have something strange with Jython 2.7 (using sikuli IDE 2.0.5). Is it not possible to run behave with in Jython ?
will result with :
The text was updated successfully, but these errors were encountered: