Skip to content
This repository has been archived by the owner on Jun 18, 2020. It is now read-only.

Umlauts break submission page #39

Closed
moschlar opened this issue May 8, 2012 · 3 comments
Closed

Umlauts break submission page #39

moschlar opened this issue May 8, 2012 · 3 comments
Assignees
Milestone

Comments

@moschlar
Copy link
Owner

moschlar commented May 8, 2012

When using umlauts in a submission or uploading an utf-8 file, SAUCE gets broken.

Module weberror.errormiddleware:162 in __call__
>>  app_iter = self.application(environ, sr_checker)
Module tg.configuration:877 in remover
>>  return app(environ, start_response)
Module repoze.tm:24 in __call__
>>  result = self.application(environ, save_status_and_headers)
Module repoze.who.middleware:107 in __call__
>>  app_iter = app(environ, wrapper.wrap_start_response)
Module tw.core.middleware:46 in __call__
>>  return self.wsgi_app(environ, start_response)
Module tw.core.middleware:72 in wsgi_app
>>  resp = req.get_response(self.application)
Module webob.request:1053 in get_response
>>  application, catch_exc_info=False)
Module webob.request:1022 in call_application
>>  app_iter = application(self.environ, start_response)
Module tw.core.resource_injector:70 in _injector
>>  resp = req.get_response(app)
Module webob.request:1053 in get_response
>>  application, catch_exc_info=False)
Module webob.request:1022 in call_application
>>  app_iter = application(self.environ, start_response)
Module beaker.middleware:73 in __call__
>>  return self.app(environ, start_response)
Module beaker.middleware:152 in __call__
>>  return self.wrap_app(environ, session_start_response)
Module routes.middleware:131 in __call__
>>  response = self.app(environ, start_response)
Module pylons.wsgiapp:107 in __call__
>>  response = self.dispatch(controller, environ, start_response)
Module pylons.wsgiapp:312 in dispatch
>>  return controller(environ, start_response)
Module sauce.lib.base:61 in __call__
>>  return TGController.__call__(self, environ, start_response)
Module pylons.controllers.core:211 in __call__
>>  response = self._dispatch_call()
Module pylons.controllers.core:162 in _dispatch_call
>>  response = self._inspect_call(func)
Module pylons.controllers.core:105 in _inspect_call
>>  result = self._perform_call(func, args)
Module tg.controllers.dispatcher:258 in _perform_call
>>  r = self._call(func, params, remainder=remainder)
Module tg.controllers.decoratedcontroller:120 in _call
>>  output = controller_callable(*remainder, **dict(params))
Module sauce.controllers.submissions:289 in edit
>>  (compilation, testruns, submitted, result) = self.submission.run_tests(submit)
Module sauce.model.submission:65 in run_tests
>>  with Runner(self) as r:
Module sauce.lib.runner:233 in __init__
>>  srcfd.write(submission.source)
UnicodeEncodeError: 'ascii' codec can't encode character u'\xdf' in position 237: ordinal not in range(128)

and

Module weberror.errormiddleware:162 in __call__
>>  app_iter = self.application(environ, sr_checker)
Module tg.configuration:877 in remover
>>  return app(environ, start_response)
Module repoze.tm:24 in __call__
>>  result = self.application(environ, save_status_and_headers)
Module repoze.who.middleware:107 in __call__
>>  app_iter = app(environ, wrapper.wrap_start_response)
Module tw.core.middleware:46 in __call__
>>  return self.wsgi_app(environ, start_response)
Module tw.core.middleware:72 in wsgi_app
>>  resp = req.get_response(self.application)
Module webob.request:1053 in get_response
>>  application, catch_exc_info=False)
Module webob.request:1022 in call_application
>>  app_iter = application(self.environ, start_response)
Module tw.core.resource_injector:70 in _injector
>>  resp = req.get_response(app)
Module webob.request:1053 in get_response
>>  application, catch_exc_info=False)
Module webob.request:1022 in call_application
>>  app_iter = application(self.environ, start_response)
Module beaker.middleware:73 in __call__
>>  return self.app(environ, start_response)
Module beaker.middleware:152 in __call__
>>  return self.wrap_app(environ, session_start_response)
Module routes.middleware:131 in __call__
>>  response = self.app(environ, start_response)
Module pylons.wsgiapp:107 in __call__
>>  response = self.dispatch(controller, environ, start_response)
Module pylons.wsgiapp:312 in dispatch
>>  return controller(environ, start_response)
Module sauce.lib.base:61 in __call__
>>  return TGController.__call__(self, environ, start_response)
Module pylons.controllers.core:211 in __call__
>>  response = self._dispatch_call()
Module pylons.controllers.core:162 in _dispatch_call
>>  response = self._inspect_call(func)
Module pylons.controllers.core:105 in _inspect_call
>>  result = self._perform_call(func, args)
Module tg.controllers.dispatcher:258 in _perform_call
>>  r = self._call(func, params, remainder=remainder)
Module tg.controllers.decoratedcontroller:142 in _call
>>  response = self._render_response(controller, output)
Module tg.controllers.decoratedcontroller:331 in _render_response
>>  **render_params)
Module tg.render:188 in render
>>  kwargs['result'] = render_function(template_name, tg_vars, **kwargs)
Module tg.render:428 in render_mako
>>  cache_type=cache_type, cache_expire=cache_expire)
Module tg.render:253 in cached_template
>>  return render_func()
Module tg.render:425 in render_template
>>  return literal(template.render_unicode(**globs))
Module mako.template:406 in render_unicode
>>  as_unicode=True)
Module mako.runtime:764 in _render
>>  **_kwargs_for_callable(callable_, data))
Module mako.runtime:796 in _render_context
>>  _exec_template(inherit, lclcontext, args=args, kwargs=kwargs)
Module mako.runtime:822 in _exec_template
>>  callable_(context, *args, **kwargs)
Module _home_paster_tg2env_SAUCE_sauce_templates_master_mak:100 in render_body
>>  __M_writer(escape(self.body()))
Module _home_paster_tg2env_SAUCE_sauce_templates_submission_edit_mak:71 in render_body
>>  __M_writer(c.form(c.options, child_args=c.child_args) )
Module tw.core.base:544 in __call__
>>  return self.display(value, **kw)
Module tw.core.base:541 in display
>>  return super(Widget, self).display(**kw)
Module tw.core.view:243 in display
>>  return tw.framework.engines.display(self, **kw)
Module tw.core.view:36 in _renderer
>>  output = renderer(info=kw, template=template)
Module tw.core.view:160 in _render_xhtml
>>  return engine.render(**kw)
Module mako.ext.turbogears:56 in render
>>  return template.render(**info)
Module mako.template:397 in render
>>  return runtime._render(self, self.callable_, args, data)
Module mako.runtime:764 in _render
>>  **_kwargs_for_callable(callable_, data))
Module mako.runtime:796 in _render_context
>>  _exec_template(inherit, lclcontext, args=args, kwargs=kwargs)
Module mako.runtime:822 in _exec_template
>>  callable_(context, *args, **kwargs)
Module _tw_forms_templates_table_form_mak:141 in render_body
Module tw.core.base:541 in display
>>  return super(Widget, self).display(**kw)
Module tw.core.view:243 in display
>>  return tw.framework.engines.display(self, **kw)
Module tw.core.view:36 in _renderer
>>  output = renderer(info=kw, template=template)
Module tw.core.view:160 in _render_xhtml
>>  return engine.render(**kw)
Module mako.ext.turbogears:56 in render
>>  return template.render(**info)
Module mako.template:397 in render
>>  return runtime._render(self, self.callable_, args, data)
Module mako.runtime:764 in _render
>>  **_kwargs_for_callable(callable_, data))
Module mako.runtime:796 in _render_context
>>  _exec_template(inherit, lclcontext, args=args, kwargs=kwargs)
Module mako.runtime:822 in _exec_template
>>  callable_(context, *args, **kwargs)
Module _tw_forms_templates_textarea_mak:46 in render_body
Module tw.core.mako_util:37 in content
>>  return escape(unicode(value))
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 228: ordinal not in range(128)
@ghost ghost assigned moschlar May 8, 2012
@moschlar
Copy link
Owner Author

moschlar commented May 8, 2012

The first Part is fixed in aab2c71, regarding the plain submission testing.

@moschlar
Copy link
Owner Author

moschlar commented May 8, 2012

(This is related to Issue #1)

@moschlar
Copy link
Owner Author

moschlar commented May 8, 2012

Both parts fixed in 8666478.

@moschlar moschlar closed this as completed May 8, 2012
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant