Edgewall Software
Modify

Opened 9 years ago

Closed 9 years ago

Last modified 7 years ago

#11849 closed enhancement (fixed)

Move some repository-related configuration options

Reported by: Ryan J Ollos Owned by: Ryan J Ollos
Priority: normal Milestone: 1.1.4
Component: version control Version:
Severity: normal Keywords:
Cc: Branch:
Release Notes:

Moved repository-related configuration options to new sections.

  • [trac] repository_type[versioncontrol] default_repository_type
  • [trac] authz_file[svn] authz_file
  • [trac] authz_module_name[svn] authz_module_name
API Changes:

Renamed RepositoryManager.repository_type to RepositoryManager.default_repository_type.

Internal Changes:

Description (last modified by Ryan J Ollos)

It might make sense to move the following configuration options:

  • [trac] repository_type[versioncontrol] default_repository_type
  • [trac] authz_file[svn] authz_file
  • [trac] authz_module_name[svn] authz_module_name

This was previously discussed starting in comment:1:ticket:11703.

Attachments (0)

Change History (12)

comment:1 by Ryan J Ollos, 9 years ago

Description: modified (diff)

comment:2 by Ryan J Ollos, 9 years ago

Milestone: next-dev-1.1.x1.1.5
Owner: set to Ryan J Ollos
Status: newassigned

Proposed changes in log:rjollos.git:t11849.

comment:3 by Ryan J Ollos, 9 years ago

Milestone: 1.1.51.1.4

comment:4 by Ryan J Ollos, 9 years ago

Release Notes: modified (diff)
Resolution: fixed
Status: assignedclosed

Committed to trunk in [13846:13847].

Last edited 9 years ago by Ryan J Ollos (previous) (diff)

comment:5 by Jun Omae, 9 years ago

API Changes: modified (diff)

comment:6 by Christian Boos, 9 years ago

Just got hit by this on one system…

After an upgrade, I ended up with:

[versioncontrol]
default_repository_type = 

and the corresponding "'' version control system not supported" error, with no access to any svn repositories possible.

I think that as we used to have svn as an implicit default, my config.get('trac', 'repository_type') was ''… Now if we're going to write that unconditionally, we end up with the above excert in the trac.ini, and the default from the option doesn't kick in.

So maybe we can only write that entry if it has an non-empty value?

Last edited 9 years ago by Christian Boos (previous) (diff)

in reply to:  6 comment:7 by Ryan J Ollos, 9 years ago

Replying to cboos:

So maybe we can only write that entry if it has an non-empty value?

I discovered similar behavior when working on db41.py. Another option would be to just put the default value in db39.py: config.get('trac', 'repository_type', 'svn').

comment:8 by Ryan J Ollos, 9 years ago

Issue from comment:6 fixed in [14152].

comment:9 by Ryan J Ollos, 8 years ago

Tests added in r14152 weren't being executed when upgrade package tests executed. Fixed in [14862:14863].

Last edited 8 years ago by Ryan J Ollos (previous) (diff)

comment:10 by Jun Omae, 8 years ago

I think we could use EnvironmentStub.reset_db_and_disk instead of env.shutdown in [14863].

  • trac/upgrades/tests/db39.py

    diff --git a/trac/upgrades/tests/db39.py b/trac/upgrades/tests/db39.py
    index 4269a4a..40e151a 100644
    a b class UpgradeTestCase(unittest.TestCase):  
    3838        RepositoryManager(self.env)
    3939
    4040    def tearDown(self):
    41         self.env.shutdown()
    42         shutil.rmtree(self.env.path)
     41        self.env.reset_db_and_disk()
    4342
    4443    def test_saves_backup(self):
    4544        """Backup file is saved during upgrade."""

comment:11 by Ryan J Ollos, 8 years ago

Thanks, fixed in [14872].

comment:12 by Ryan J Ollos, 7 years ago

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Ryan J Ollos.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Ryan J Ollos 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.