Edgewall Software
Modify

Opened 20 years ago

Closed 20 years ago

#1700 closed defect (fixed)

Errors with the "component" commands from trac-admin

Reported by: Emmanuel Blot Owned by: Matthew Good
Priority: high Milestone: 0.9
Component: admin/console Version: devel
Severity: major Keywords:
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description

'NoneType' object has no attribute 'get_db_cnx'

This happens (at least) with component list and component rename commands

w/ Trac trunk [1833]

Attachments (0)

Change History (7)

comment:1 by Emmanuel Blot, 20 years ago

In trac/scripts/admin.py

_do_component_* methods do not seem to have a valid environment self.__env instance

comment:2 by Emmanuel Blot, 20 years ago

However, if another module is invoked, such as permission list, the environment is successfully created, then the next calls to the component module, such as component list do work.

comment:3 by Matthew Good, 20 years ago

Owner: changed from daniel to Matthew Good

I'll check it out.

comment:4 by Emmanuel Blot, 20 years ago

Owner: changed from Matthew Good to Christopher Lenz
Summary: Erros with the "component" commands from trac-adminErrors with the "component" commands from trac-admin

I think it comes from a regression introduced in [1831]:
Component management has been refactored, but the db_open() method is not called anymore.

comment:5 by Emmanuel Blot, 20 years ago

Owner: changed from Christopher Lenz to Matthew Good

Oops, I thought Chris. was in charge of this one, I missed the new assignation you've made while I was updating the ticket.

comment:6 by xris <xris*siliconmechanics*com>, 20 years ago

I backported to [1830] and still get the error.

comment:7 by Matthew Good, 20 years ago

Resolution: fixed
Status: newclosed

This should be fixed in [1842]

However, we should probably take a look at trac-admin to see if there's a cleaner way to handle the opening of the environment so the individual methods don't need to do the checking.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Matthew Good.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Matthew Good to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.