Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#11635 closed defect (fixed)

Extra character at end of line

Reported by: palmerb@… Owned by: Odd Simon Simonsen
Priority: normal Component: XmlRpcPlugin
Severity: normal Keywords:
Cc: Olemis Lang Trac Release: 1.0


An extra character is added after the cr/lf of text. This causes problems when pulling the wiki pages as well in viewing and editing tickets in Mylyn. My ssystem

System Information

Genshi0.6 (without speedups)
Python2.7.3 (default, Apr 10 2012, 23:31:26) [MSC v.1500 32 bit (Intel)]

Installed Plugins


Attachments (0)

Change History (9)

comment:1 Changed 3 years ago by Odd Simon Simonsen

It causes "problems"? Care to explain the issue in more detail?

Following [6053] all line endings for strings from RPC should be \r\n, and it is not clear to me either what the extra character is or how it appears.

Have you tried to use something like curl to make a request and compare the content you receive (see the API docs for examples)? Does it happen for both JSON and XML? Could it be an issue with your client interface and not the server?

comment:2 Changed 3 years ago by Odd Simon Simonsen

Ah, [6053] fixed input of strings only.

Perhaps you better review #2482, and then follow the actual string output to see where it changes to something unexpected - using raw requests and alternative clients if possible.

comment:3 Changed 3 years ago by palmerb@…

At first I thought it was just my code. I updated Trac and then XMLRPCplugin to make it work with Mylyn in Eclipse. Then I updated my documentation which uses Java to get the wiki pages and create a set of HTML pages in documentation. When I ran it there appeared these strange characters that I finally was able to replace using the following code:

char c[] = new char[1];
pageHtml = pageHtml.replaceAll(new String(c), "");

It also appears in Mylyn when viewing any text field with cr/lf.

I agree that this is weird but I am using the org.lustin.trac library and Mylyn is using something else for getting the data. This leads back to the plugin.

comment:4 Changed 3 years ago by Odd Simon Simonsen

Oh, perhaps a regression from [13728:13729]? What if you revert RPC to revisions preceeding these changes?

comment:5 Changed 3 years ago by palmerb@…

I traced this through the request and looked at the raw data being returned. For whatever reason the \r is coming back as \ufffd rather than as \u000d.

Doesn't trigger any thoughts at this time. I fixed it for my documentation using the code above but can't do anything about Mylyn. It is not the end of the world as it goes back into the database correctly without any problems.

comment:6 Changed 3 years ago by Odd Simon Simonsen

I've reopened #11050. We'll get this fixed.

comment:7 Changed 3 years ago by Odd Simon Simonsen

Resolution: fixed
Status: newclosed

In 13776:

XmlRpcPlugin: Tweak [13728] fix again to let carriage return pass through. Closes #11050 again. Also closes #11635.

comment:8 Changed 3 years ago by Odd Simon Simonsen

Please update to latest trunk from repository. The issue should be fixed now. Reopen ticket if not.

comment:9 Changed 3 years ago by anonymous

It works. Thanks for making this all work together and for making something that really helps my work. Also the speed with which this was fixed was impressive.

Modify Ticket

as closed The owner will remain Odd Simon Simonsen.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment

E-mail address and name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.