Quantcast
Channel: YouTrackYouTrack (JT) - Bug and Issue Tracker
Viewing all articles
Browse latest Browse all 74845

JT-18980: Executing command "comment" with large comment gives an error

$
0
0
Reporter Michael Zarnitsa (mz) Michael Zarnitsa (mz)
Created Mar 8, 2013 1:35:29 AM
Updated Mar 8, 2013 1:51:48 AM
Priority Normal
Type Bug
State Open
Assignee Anna Zhdan (Anna.Zhdan)
Subsystem REST API
Fix versions No Fix versions
Fixed in builds No Fixed in build
Affected versions 4.2
Browser Any Browser
OS Any OS
Verified in build Not verified
Verified by Nobody
Reviewed by No reviewed by
Severity Routine
Since permittedGroup is not available for comments in import API (JT-18922) we were trying to import comments with command "comment" while providing comment text and permittedGroup. To assure right comment time we were also changing system time of the computer running import.

Everything worked out just fine, except we ran into a problem while adding large comments. Here is a script you can use to replicate the problem:
from youtrack.connection import Connection, httplib2

yt = Connection('http://localhost', 'user', 'pwd')
print('connected\n')

a = '1234567890'
comment = ''

# still works with range 0..565 or smaller
for i in range(0,566):
	comment += a

print( 'comment length: {0}\n'.format(len(comment)) )

print( yt.executeCommand('acc-62522', 'comment', comment) )

Comments of such a length still work in Youtrack interface. Which is a bit disconcerting that Youtrack is not using its own API

Viewing all articles
Browse latest Browse all 74845

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>