Opened 9 years ago

Closed 9 years ago

#3559 closed defect (fixed)

Error for non trac-projects in the project dir

Reported by: Russ Tyndall Owned by: Álvaro Iradier
Priority: normal Component: SearchAllPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.10


I have a few directories in my trac project dir which are not tracs (such as .egg-cache).

To get the search all to succeed I simply added a try/except continue around opening the environment. I think that overall this makes the plugin more robust without it losing any capability.

  • tracsearchall/

    5858            project_path = os.path.join(search_path,project)
    5959            if not os.path.isdir( project_path ):
    6060                continue
    62             env = open_environment(project_path)
     61            try:
     62                env = open_environment(project_path)
     63            except:
     64                continue
    6567            self.env.log.debug("Searching project %s" % project )

HTH and thanks for the plugin, Russ

Attachments (0)

Change History (2)

comment:1 Changed 9 years ago by Russ Tyndall

PS. airadier

If you want to give me commit access to this plugin, I would be more than happy to apply the outstanding patches and work on this occasionally. I run a couple of other plugins, so I know a bit about how they should work. Up to you, but I thought I would make the offer as there are some outstanding patches, which I have tested.

comment:2 Changed 9 years ago by Álvaro Iradier

Resolution: fixed
Status: newclosed

(In [4343]) Fix search with non-environment folders. Closes #3559, thanks to bobbysmith007

Modify Ticket

Change Properties
Set your email in Preferences
as closed The owner will remain Álvaro Iradier.
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.