Bug #490
Scope() with unicode argument fails (at least) for remote server calls (always)
Status: | Closed | Start date: | 08/09/2011 | |
---|---|---|---|---|
Priority: | Normal | Due date: | ||
Assignee: | J. Moringen | % Done: | 100% | |
Category: | Python | |||
Target version: | 0.4 |
Description
Working code:
server = createRemoteServer(Scope('/example/server'))
server.methodOne('blabla')
Failing code:
server = createRemoteServer(Scope(u'/example/server'))
server.methodOne('blabla')
Program fails on the methodOne
line with error:
rsb.patterns.RemoteCallError: failed to call method "methodOne" on remote server with scope Scope[/example/server/]: TypeError("u'/example/server/request/methodOne/' has type <type 'unicode'>, but expected one of: (<type 'str'>,)",)
Associated revisions
Fixed handling of unicode objects in Scope constructor in rsb/__init__.py
fixes #490
fixes #490
- rsb/__init__.py: convert unicode objects to str objects using ASCII
encoding in Scope constructor; raise a ValueError if this conversion
is impossible - test/coretest.py: test handling of unicode objects as string
representation of scopes
History
#1 Updated by J. Wienke almost 13 years ago
- Assignee changed from J. Wienke to J. Moringen
- Target version set to 0.4
#2 Updated by J. Moringen almost 13 years ago
- Status changed from New to Resolved
- % Done changed from 0 to 100
Applied in changeset r2328.
#3 Updated by J. Moringen almost 13 years ago
- Description updated (diff)
- Status changed from Resolved to Feedback
#4 Updated by J. Moringen almost 13 years ago
- Status changed from Feedback to Closed
Seems to be fixed.