StaticTest.test_unicode fails on codeanywhere
See original GitHub issue____________________________________________________________________________________________ StaticTest.test_unicode _____________________________________________________________________________________________
self = <cherrypy.test.test_static.StaticTest testMethod=test_unicode>
@pytest.mark.xfail(py27_on_windows, reason="#1544")
def test_unicode(self):
> with self.unicode_file():
cherrypy/test/test_static.py:379:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/usr/lib/python2.7/contextlib.py:17: in __enter__
return self.gen.next()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
@staticmethod
@contextlib.contextmanager
def unicode_file():
filename = ntou('Слава Україні.html', 'utf-8')
filepath = os.path.join(curdir, 'static', filename)
> with io.open(filepath, 'w', encoding='utf-8') as strm:
E UnicodeEncodeError: 'ascii' codec can't encode characters in position 43-47: ordinal not in range(128)
cherrypy/test/test_static.py:366: UnicodeEncodeError
===================================================================== 1 failed, 252 passed, 4 skipped, 2 xfailed, 5 xpassed in 80.13 seconds =====================================================================
ERROR: InvocationError: '/home/cabox/workspace/.tox/python/bin/pytest'
____________________________________________________________________________________________________ summary _____________________________________________________________________________________________________
ERROR: python: commands failed
Running tox on codeanywhere causes this test to fail.
- I’m submitting a … [x ] bug report [ ] feature request [ ] question about the decisions made in the repository
Issue Analytics
- State:
- Created 7 years ago
- Comments:13 (13 by maintainers)
Top Results From Across the Web
Support - Codeanywhere Docs
Detailed description of the issue; Provide any error messages you are receiving; Was it working previously for you? Attach print screens (where applicable)...
Read more >Terms of Service - Codeanywhere
Codeanywhere.com does not warrant that the Service will meet your specific requirements; the Service will be uninterrupted, timely, secure, or error-free.
Read more >Invalid verify · Codeanywhere
Account Not Verified · Invalid verification code · Languages & Frameworks · Databases.
Read more >Frequently Asked Questions - Codeanywhere Docs
How to access the IDE after I've created an account? Codeanywhere has introduced a new and improved VS Code based editor with a...
Read more >Cloud IDE · Online Code Editor - Codeanywhere
Save time by deploying a development environment in seconds. Collaborate, code, learn, build, and run your projects directly from your browser.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Setting
LC_LANG
orLANG
has no effect either.Non-support of fixtures is a known limitation of the unittest compatibility.