Edgewall Software
Modify

Opened 10 years ago

Last modified 5 years ago

#9091 new enhancement

Use RawConfigParser instead of ConfigParser in the Configuration component

Reported by: John Hampton Owned by:
Priority: normal Milestone: next-major-releases
Component: general Version: 0.12dev
Severity: normal Keywords: config needmajor
Cc: Branch:
Release Notes:
API Changes:

Description

The use of ConfigParser in the configuration layer causes issues when using %(foo)s values in the config file. The th:IrcLogsPlugin does this and causes a traceback when trying to write the sample config during upgrade.

Trac itself doesn't use the interpolation feature of the ConfigParser nor do we advertize the interpolation feature of the ConfigParser.

As the interpolation feature is of dubious value, I think that we should replace ConfigParser with RawConfigParser. This should also give us case sensitivity in the section fields.

Attachments (0)

Change History (7)

comment:1 by Remy Blank, 10 years ago

Making the configuration file keys case-sensitive could break many configurations out there. Typically in the [components] section, if individual classes are specified.

comment:2 by John Hampton, 10 years ago

I have to look at the details of the raw config parser, but it won't be hard to make it either case sensitive or case insensitive.

[OT] BTW, the iPhone keyboard sucks due to lack of back-ticks

comment:3 by Remy Blank, 10 years ago

Shouldn't you be on your plane? :)

comment:4 by John Hampton, 10 years ago

Owner: set to John Hampton
Status: newassigned

Now that I'm on my plane, I was able to play around with RawConfigParser a bit. It appears that section values are case sensitive, but not options. So [Components] and [components] are different sections, but

trac.web.web_ui = Enabled

and

Trac.WeB.web_ui = Enabled

are the same.

Next question is: Do we want section names to be case-sensitive?

Last edited 10 years ago by Remy Blank (previous) (diff)

comment:5 by Christian Boos, 10 years ago

Keywords: config needmajor added
Milestone: 0.12next-major-0.1X
Version: 0.12dev

You're welcome to move back the milestone to 0.12 if you finish this earlier, but this ticket is not necessary for the release.

(it probably needs to be done for a major release though, because of the potential breakage)

comment:6 by Thijs Triemstra, 9 years ago

Type: defectenhancement

comment:7 by Ryan J Ollos, 5 years ago

Owner: John Hampton removed
Status: assignednew

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The ticket will remain with no owner.
The ticket will be disowned. Next status will be 'new'.
as The resolution will be set. Next status will be 'closed'.
The owner will be changed from (none) to anonymous. Next status will be 'assigned'.

Add Comment


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