Modify

Opened 16 years ago

Closed 16 years ago

#4435 closed defect (fixed)

error creating a release

Reported by: anonymous Owned by: Joao Alexandre de Toledo
Priority: normal Component: TracReleasePlugin
Severity: normal Keywords:
Cc: Trac Release: 0.11

Description

When I am try to create a release, the following error appears: ................................................................

Oops… Trac detected an internal error:

AttributeError: 'list' object has no attribute 'split'

If you think this should work you can reproduce the problem, you should consider reporting this to the Trac team.

Before you do that, though, please first try searching for similar issues, as it is quite likely that this problem has been reported before. For questions about installation and configuration of Trac, please try the mailing list instead of filing a ticket.

Otherwise, please ==== How to Reproduce ==== While doing a POST operation on /release/add, Trac issued an internal error. (please provide additional details here) Request parameters: {'__FORM_TOKEN': u'9146e52b427ef05e7bebc65a', 'action': 'add', 'hiddenReleaseSignatures': u'', 'hiddenReleaseStep': u'2', 'hiddenReleaseTickets': u'6,108,278,334,336,337,635,639,664,816,819,820,831,851,875,888,910,911,916,917,918,926,937,959,960,961,966,980,983,989,1008,1009,1021,1025,1026,1056,1065,1066,1067,1068,1069,1070,1071,1072,1073,1074,1086,1088,1089,1090,1091,1092,1093,1094,1097,1101,1102,1111,1116,1117,1118,1122,1131,1132,1133,1138,1146,1148,1150,1153,1154,1155,1156,1158,1159,1161,1165,1184,1185,1186,1187,1188,1189,1192,1193,1194,1195,1196,1201,1202,1207,1208,1209,1217,1218,1219,1220,1221,1222,1228,1229,1230,1231,1232,1233,1234,1235,1236,1237,1238,1239,1240,1242,1243,1244,1247,1248,1249,1250,1278,1279,1282,1283,1284,1287,1289,1290,1291,1294,1295,1296,1297,1298,1299,1300,1303,1304,1305,1306,1307,1308,1309,1310,1311,1312,1313,1314,1315,1316,1317,1318,1321,1322,1323,1324,1325,1326,1327,1328,1329,1330,1331,1332,1333,1334,1335,1336,1337,1338,1339,1340,1341,1342,1343,1344,1345,1346,1347,1348,1349,1350,1351,1352,1353,1354,1355,1356,1357,1358,1359,1360,1361,1362,1363,1364,1365,1366,1367,1368,1369,1370,1371,1372,1375,1376,', 'selectReleaseVersion': u'', 'submit': u'Create Release', 'txtPlannedDate': u'2008-12-12 14:10:57-03:00', 'txtReleaseDescription': u'Version baseline de 1.9.1 con funcionalidades basicas y bugs no blockeantes.', 'txtReleaseName': u'1.9.1'} User Agent was: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.5) Gecko/2008120122 Firefox/3.0.5 ==== System Information ====
Trac 0.11.1 Python 2.5.2 (r252:60911, Feb 21 2008, 13:11:45) [MSC v.1310 32 bit (Intel)] setuptools 0.6c9 Genshi 0.5.1 mod_python 3.3.1 Subversion 1.5.3 (r33570) MySQL server: "5.0.51b-community-nt", client: "5.0.27", thread-safe: 1 MySQLdb 1.2.2 jQuery: 1.2.6 ==== Python Traceback ==== Traceback (most recent call last): File "main.py", line 423, in _dispatch_request File "main.py", line 197, in dispatch File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 109, in process_request ret = self._add_release(req, templateData) File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 166, in _add_release return self._add_step_2(req, templateData) File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 253, in _add_step_2 release.install_procedures) File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\data.py", line 123, in createRelease for ticket in tickets.split(","): AttributeError: 'list' object has no attribute 'split' a new ticket at the Trac project site, where you can describe the problem and explain how to reproduce it.

Python Traceback Most recent call last:

  • File "main.py", line 423, in _dispatch_request Local variables: Name Value after () before () dispatcher <trac.web.main.RequestDispatcher object at 0x02251E90> e AttributeError("'list' object has no attribute 'split'",) env <trac.env.Environment object at 0x01D5A730> env_error None exc_info (<type 'exceptions.AttributeError'>, AttributeError("'list' object has no ... filename 'main.py' frames [{'function': '_dispatch_request', 'lines_before': (), 'vars': {'req': ... has_admin True line None lineno 422 message u"AttributeError: 'list' object has no attribute 'split'" req <Request "POST u'/release/add'"> resp [] tb <traceback object at 0x0274A210> tb_hide None traceback 'Traceback (most recent call last):\n File "main.py", line 423, in ...
  • File "main.py", line 197, in dispatch Local variables: Name Value chosen_handler <tracrelease.core.ReleaseCore object at 0x02251DF0> chrome <trac.web.chrome.Chrome object at 0x02251E50> ctype 'application/x-www-form-urlencoded' err (<type 'exceptions.AttributeError'>, AttributeError("'list' object has no ... handler <tracrelease.core.ReleaseCore object at 0x02251DF0> options {} req <Request "POST u'/release/add'"> self <trac.web.main.RequestDispatcher object at 0x02251E90>
  • File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 109, in process_request Code fragment:
    1. req.write("You can't edit an existing Release for now") 105.
    2. if req.argsaction? == 'add':
    3. if req.method == "POST":
    4. self.log.debug("Adding: POST")
    5. ret = self._add_release(req, templateData)
    6. self.log.debug(templateData)
    7. self.log.debug(ret)
    8. return ret[0], ret[1], ret[2]
    9. else:
    10. self.log.debug("Adding: GET")
    Local variables: Name Value req <Request "POST u'/release/add'"> self <tracrelease.core.ReleaseCore object at 0x02251DF0> templateData {'releaseTickets': ...
  • File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 166, in _add_release Code fragment:

161.

  1. if step == "1":
  2. return self._add_step_1(req, templateData) 164.
  3. elif step == "2":
  4. return self._add_step_2(req, templateData)
  5. def _add_step_1(self, req, templateData):
  6. release = model.Release()

Local variables: Name Value req <Request "POST u'/release/add'"> self <tracrelease.core.ReleaseCore object at 0x02251DF0> step u'2' templateData {'releaseTickets': ...

  • File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 253, in _add_step_2 Code fragment:
    1. self.log.debug("_add_step_2: Submit")
    2. resp = data.createRelease(self, templateDatareleaseName?, release.description,
    3. req.authname, None,
    4. release.tickets,
    5. release.signatures,
    6. release.install_procedures)
    7. if resp:
    8. req.redirect(req.href.release() + '/view/' + str(resp))
    9. else:
    10. return None, None, None 258.
    Local variables: Name Value procs [] release <tracrelease.model.Release object at 0x027534B0> req <Request "POST u'/release/add'"> self <tracrelease.core.ReleaseCore object at 0x02251DF0> signee u templateData {'releaseTickets': ...
  • File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\data.py", line 123, in createRelease Code fragment:
    1. db.rollback() 119.
    2. if flag:
    3. relId = db.get_last_id(cur, 'releases')
    4. if relId:
    5. for ticket in tickets.split(","):
    6. ticket = ticket.strip()
    7. try:
    8. ticket = int(ticket)
    9. except:
    10. ticket = 0
    Local variables: Name Value author 'jorge.churio@…' com <tracrelease.core.ReleaseCore object at 0x02251DF0> cur <trac.db.util.IterableCursor object at 0x02753A90> db <trac.db.pool.PooledConnection object at 0x02709F58> description u'Version baseline de 1.9.1 con funcionalidades basicas y bugs no ... flag True install_procedures [] name u'1.9.1' now 1231783928 planned None relId 1L signatures [] sql 'INSERT INTO releases (version, description, author, creation_date, ... sqlInstallFiles 'INSERT INTO release_files (release_id, install_id, file_order, file_name) ... sqlInstallProcedures 'INSERT INTO release_installs (release_id, install_id) VALUES (%s, %s)' sqlSignatures 'INSERT INTO release_signatures (release_id, signature) VALUES (%s, %s)' sqlTickets 'INSERT INTO release_tickets (release_id, ticket_id) VALUES (%s, %s)' tickets []

File "main.py", line 423, in _dispatch_requestFile "main.py", line 197, in dispatchFile "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 109, in process_request

ret = self._add_release(req, templateData)

File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 166, in _add_release

return self._add_step_2(req, templateData)

File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 253, in _add_step_2

release.install_procedures)

File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\data.py", line 123, in createRelease

for ticket in tickets.split(","):

System Information:

User Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.5) Gecko/2008120122 Firefox/3.0.5 Trac: 0.11.1 Python: 2.5.2 (r252:60911, Feb 21 2008, 13:11:45) [MSC v.1310 32 bit (Intel)] setuptools: 0.6c9 Genshi: 0.5.1 mod_python: 3.3.1 Subversion: 1.5.3 (r33570) MySQL: server: "5.0.51b-community-nt", client: "5.0.27", thread-safe: 1 MySQLdb: 1.2.2 jQuery: 1.2.6

Attachments (0)

Change History (3)

comment:1 Changed 16 years ago by jorge.churio@…

Summary: error cerating a releaseerror creating a release

I forgot to quote all code text, fixed below: .................................................

Oops…
Trac detected an internal error:

AttributeError: 'list' object has no attribute 'split'

If you think this should work you can reproduce the problem, you should consider reporting this to the Trac team.

Before you do that, though, please first try searching for similar issues, as it is quite likely that this problem has been reported before. For questions about installation and configuration of Trac, please try the mailing list instead of filing a ticket.

Otherwise, please ==== How to Reproduce ==== While doing a POST operation on `/release/add`, Trac issued an internal error. ''(please provide additional details here)'' Request parameters: {{{ {'__FORM_TOKEN': u'9146e52b427ef05e7bebc65a', 'action': 'add', 'hiddenReleaseSignatures': u'', 'hiddenReleaseStep': u'2', 'hiddenReleaseTickets': u'6,108,278,334,336,337,635,639,664,816,819,820,831,851,875,888,910,911,916,917,918,926,937,959,960,961,966,980,983,989,1008,1009,1021,1025,1026,1056,1065,1066,1067,1068,1069,1070,1071,1072,1073,1074,1086,1088,1089,1090,1091,1092,1093,1094,1097,1101,1102,1111,1116,1117,1118,1122,1131,1132,1133,1138,1146,1148,1150,1153,1154,1155,1156,1158,1159,1161,1165,1184,1185,1186,1187,1188,1189,1192,1193,1194,1195,1196,1201,1202,1207,1208,1209,1217,1218,1219,1220,1221,1222,1228,1229,1230,1231,1232,1233,1234,1235,1236,1237,1238,1239,1240,1242,1243,1244,1247,1248,1249,1250,1278,1279,1282,1283,1284,1287,1289,1290,1291,1294,1295,1296,1297,1298,1299,1300,1303,1304,1305,1306,1307,1308,1309,1310,1311,1312,1313,1314,1315,1316,1317,1318,1321,1322,1323,1324,1325,1326,1327,1328,1329,1330,1331,1332,1333,1334,1335,1336,1337,1338,1339,1340,1341,1342,1343,1344,1345,1346,1347,1348,1349,1350,1351,1352,1353,1354,1355,1356,1357,1358,1359,1360,1361,1362,1363,1364,1365,1366,1367,1368,1369,1370,1371,1372,1375,1376,', 'selectReleaseVersion': u'', 'submit': u'Create Release', 'txtPlannedDate': u'2008-12-12 14:10:57-03:00', 'txtReleaseDescription': u'Version baseline de 1.9.1 con funcionalidades basicas y bugs no blockeantes.', 'txtReleaseName': u'1.9.1'} }}} User Agent was: `Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.5) Gecko/2008120122 Firefox/3.0.5` ==== System Information ==== || '''Trac''' || `0.11.1` || || '''Python''' || `2.5.2 (r252:60911, Feb 21 2008, 13:11:45) [MSC v.1310 32 bit (Intel)]` || || '''setuptools''' || `0.6c9` || || '''Genshi''' || `0.5.1` || || '''mod_python''' || `3.3.1` || || '''Subversion''' || `1.5.3 (r33570)` || || '''MySQL''' || `server: "5.0.51b-community-nt", client: "5.0.27", thread-safe: 1` || || '''MySQLdb''' || `1.2.2` || || '''jQuery:''' || `1.2.6` || ==== Python Traceback ==== {{{ Traceback (most recent call last): File "main.py", line 423, in _dispatch_request File "main.py", line 197, in dispatch File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 109, in process_request ret = self._add_release(req, templateData) File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 166, in _add_release return self._add_step_2(req, templateData) File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 253, in _add_step_2 release.install_procedures) File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\data.py", line 123, in createRelease for ticket in tickets.split(","): AttributeError: 'list' object has no attribute 'split' }}} a new ticket at the Trac project site, where you can describe the problem and explain how to reproduce it.
Python Traceback
Most recent call last:

    * File "main.py", line 423, in _dispatch_request
      Local variables:
      Name	Value
      after 	()
      before 	()
      dispatcher 	<trac.web.main.RequestDispatcher object at 0x02251E90>
      e 	AttributeError("'list' object has no attribute 'split'",)
      env 	<trac.env.Environment object at 0x01D5A730>
      env_error 	None
      exc_info 	(<type 'exceptions.AttributeError'>, AttributeError("'list' object has no ...
      filename 	'main.py'
      frames 	[{'function': '_dispatch_request', 'lines_before': (), 'vars': {'req': ...
      has_admin 	True
      line 	None
      lineno 	422
      message 	u"AttributeError: 'list' object has no attribute 'split'"
      req 	<Request "POST u'/release/add'">
      resp 	[]
      tb 	<traceback object at 0x0274A210>
      tb_hide 	None
      traceback 	'Traceback (most recent call last):\n File "main.py", line 423, in ...
    * File "main.py", line 197, in dispatch
      Local variables:
      Name	Value
      chosen_handler 	<tracrelease.core.ReleaseCore object at 0x02251DF0>
      chrome 	<trac.web.chrome.Chrome object at 0x02251E50>
      ctype 	'application/x-www-form-urlencoded'
      err 	(<type 'exceptions.AttributeError'>, AttributeError("'list' object has no ...
      handler 	<tracrelease.core.ReleaseCore object at 0x02251DF0>
      options 	{}
      req 	<Request "POST u'/release/add'">
      self 	<trac.web.main.RequestDispatcher object at 0x02251E90>
    * File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 109, in process_request
      Code fragment:
       104. req.write("You can't edit an existing Release for now")
       105.
       106. if req.args['action'] == 'add':
       107. if req.method == "POST":
       108. self.log.debug("Adding: POST")
       109. ret = self._add_release(req, templateData)
       110. self.log.debug(templateData)
       111. self.log.debug(ret)
       112. return ret[0], ret[1], ret[2]
       113. else:
       114. self.log.debug("Adding: GET")
      Local variables:
      Name	Value
      req 	<Request "POST u'/release/add'">
      self 	<tracrelease.core.ReleaseCore object at 0x02251DF0>
      templateData 	{'releaseTickets': ...
    * File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 166, in _add_release
      Code fragment:
       161.
       162. if step == "1":
       163. return self._add_step_1(req, templateData)
       164.
       165. elif step == "2":
       166. return self._add_step_2(req, templateData)
       167.  
       168.  
       169.  
       170. def _add_step_1(self, req, templateData):
       171. release = model.Release()
      Local variables:
      Name	Value
      req 	<Request "POST u'/release/add'">
      self 	<tracrelease.core.ReleaseCore object at 0x02251DF0>
      step 	u'2'
      templateData 	{'releaseTickets': ...
    * File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 253, in _add_step_2
      Code fragment:
       248. self.log.debug("_add_step_2: Submit")
       249. resp = data.createRelease(self, templateData['releaseName'], release.description,
       250. req.authname, None,
       251. release.tickets,
       252. release.signatures,
       253. release.install_procedures)
       254. if resp:
       255. req.redirect(req.href.release() + '/view/' + str(resp))
       256. else:
       257. return None, None, None
       258.
      Local variables:
      Name	Value
      procs 	[]
      release 	<tracrelease.model.Release object at 0x027534B0>
      req 	<Request "POST u'/release/add'">
      self 	<tracrelease.core.ReleaseCore object at 0x02251DF0>
      signee 	u''
      templateData 	{'releaseTickets': ...
    * File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\data.py", line 123, in createRelease
      Code fragment:
       118. db.rollback()
       119.
       120. if flag:
       121. relId = db.get_last_id(cur, 'releases')
       122. if relId:
       123. for ticket in tickets.split(","):
       124. ticket = ticket.strip()
       125. try:
       126. ticket = int(ticket)
       127. except:
       128. ticket = 0
      Local variables:
      Name	Value
      author 	'jorge.churio@cheffsolutions.com'
      com 	<tracrelease.core.ReleaseCore object at 0x02251DF0>
      cur 	<trac.db.util.IterableCursor object at 0x02753A90>
      db 	<trac.db.pool.PooledConnection object at 0x02709F58>
      description 	u'Version baseline de 1.9.1 con funcionalidades basicas y bugs no ...
      flag 	True
      install_procedures 	[]
      name 	u'1.9.1'
      now 	1231783928
      planned 	None
      relId 	1L
      signatures 	[]
      sql 	'INSERT INTO releases (version, description, author, creation_date, ...
      sqlInstallFiles 	'INSERT INTO release_files (release_id, install_id, file_order, file_name) ...
      sqlInstallProcedures 	'INSERT INTO release_installs (release_id, install_id) VALUES (%s, %s)'
      sqlSignatures 	'INSERT INTO release_signatures (release_id, signature) VALUES (%s, %s)'
      sqlTickets 	'INSERT INTO release_tickets (release_id, ticket_id) VALUES (%s, %s)'
      tickets 	[]

File "main.py", line 423, in _dispatch_requestFile "main.py", line 197, in dispatchFile "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 109, in process_request
  ret = self._add_release(req, templateData)
File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 166, in _add_release
  return self._add_step_2(req, templateData)
File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\core.py", line 253, in _add_step_2
  release.install_procedures)
File "c:\python25\lib\site-packages\tracreleaseplugin-0.2-py2.5.egg\tracrelease\data.py", line 123, in createRelease
  for ticket in tickets.split(","):

System Information:

User Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.5) Gecko/2008120122 Firefox/3.0.5
Trac: 	0.11.1
Python: 	2.5.2 (r252:60911, Feb 21 2008, 13:11:45) [MSC v.1310 32 bit (Intel)]
setuptools: 	0.6c9
Genshi: 	0.5.1
mod_python: 	3.3.1
Subversion: 	1.5.3 (r33570)
MySQL: 	server: "5.0.51b-community-nt", client: "5.0.27", thread-safe: 1
MySQLdb: 	1.2.2
jQuery:	1.2.6

comment:2 Changed 16 years ago by Joao Alexandre de Toledo

Thanks for point the error. I'm too busy for now, but I'll return to this as soon as possible.

Thansk again,

João.

comment:3 Changed 16 years ago by Joao Alexandre de Toledo

Resolution: fixed
Status: newclosed

It's corrected now.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Joao Alexandre de Toledo.
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.