Bug 745255

Summary: Import CSV file for Install Options to beaker causes a 500 error.
Product: [Retired] Beaker Reporter: andrew <alemay>
Component: inventoryAssignee: Dan Callaghan <dcallagh>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 0.7CC: bpeck, jhutar, mbrodeur, mcsontos, mgrigull, rmancy, stl
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-01-04 01:43:43 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description andrew 2011-10-11 19:39:18 UTC
Description of problem:
Attempting to Import CSV file for Install Options to beaker causes a 500 error.

Version-Release number of selected component (if applicable):


How reproducible: For uploading "Install Options" it happens every time.


Steps to Reproduce:
1.Admin >> Export System Install Options >> Download CSV
2.Edit CSV file >> Upload
3.See Error
  
Actual results:
"500 Internal error"
"The server encountered an unexpected condition which prevented it from fulfilling the request."
Expected results:


Additional info:

I have downloaded a clean version of “System Install Options”  “. csv” and took out all other data except for two machines. And when uploading it with no other changes it returns with the same “500 error”.

Comment 1 Marco Grigull 2011-10-12 01:20:39 UTC
11/Oct/2011:15:22:04 HTTP INFO Page handler: <bound method CSV.action_import of <bkr.server.CSV_import_export.CSV obje
ct at 0x2ab6c22e4f10>>
Traceback (most recent call last):
  File "/usr/lib/python2.4/site-packages/cherrypy/_cphttptools.py", line 121, in _run
    self.main()
  File "/usr/lib/python2.4/site-packages/cherrypy/_cphttptools.py", line 264, in main
    body = page_handler(*virtual_path, **self.params)
  File "<string>", line 3, in action_import
  File "/usr/lib/python2.4/site-packages/turbogears/controllers.py", line 358, in expose
    output = database.run_with_transaction(
  File "<string>", line 5, in run_with_transaction
  File "/usr/lib/python2.4/site-packages/turbogears/database.py", line 407, in sa_rwt
    retval = func(*args, **kw)
  File "<string>", line 5, in _expose
  File "/usr/lib/python2.4/site-packages/turbogears/controllers.py", line 373, in <lambda>
    mapping, fragment, args, kw)))
  File "/usr/lib/python2.4/site-packages/turbogears/controllers.py", line 410, in _execute_func
    output = errorhandling.try_call(func, *args, **kw)
  File "/usr/lib/python2.4/site-packages/turbogears/errorhandling.py", line 77, in try_call
    return func(self, *args, **kw)
  File "<string>", line 3, in action_import
  File "/usr/lib/python2.4/site-packages/turbogears/identity/conditions.py", line 207, in require
    return fn(self, *args, **kwargs)
  File "/usr/lib/python2.4/site-packages/bkr/server/CSV_import_export.py", line 121, in action_import
    session.expire(system)
  File "/usr/lib/python2.4/site-packages/sqlalchemy/orm/scoping.py", line 98, in do
    return getattr(self.registry(), name)(*args, **kwargs)
  File "/usr/lib/python2.4/site-packages/sqlalchemy/orm/session.py", line 863, in expire
    _expire_state(instance._state, None)
  File "/usr/lib/python2.4/site-packages/sqlalchemy/orm/session.py", line 1245, in _expire_state
    state.expire_attributes(attribute_names)
  File "/usr/lib/python2.4/site-packages/sqlalchemy/orm/attributes.py", line 866, in expire_attributes
    if attr.impl.accepts_scalar_loader:
AttributeError: 'DynamicAttributeImpl' object has no attribute 'accepts_scalar_loader'

Comment 2 Dan Callaghan 2011-10-21 00:43:53 UTC
This is an issue with sqlalchemy 0.4. As of Beaker 0.8.0 we are switching to sqlalchemy 0.6, which does not exhibit this problem.

Comment 3 Dan Callaghan 2012-01-04 01:43:43 UTC
Beaker 0.8 has been released.