Opened 3 years ago

Closed 3 years ago

#9150 closed defect (fixed)

AttributeError happens with deleting a wiki page or a version of wiki page

Reported by: jun66j5 Owned by: saigon
Priority: normal Component: WikiCreateTicketPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.12


Traceback (most recent call last):
  File "build\bdist.win32\egg\trac\web\", line 511, in _dispatch_request
  File "build\bdist.win32\egg\trac\web\", line 237, in dispatch
    resp = chosen_handler.process_request(req)
  File "build\bdist.win32\egg\trac\wiki\", line 148, in process_request
    self._do_delete(req, versioned_page)
  File "build\bdist.win32\egg\trac\wiki\", line 255, in _do_delete
  File "build\bdist.win32\egg\trac\db\", line 77, in transaction_wrapper
  File "build\bdist.win32\egg\trac\wiki\", line 263, in do_delete
    page.delete(version, db)
  File "build\bdist.win32\egg\trac\wiki\", line 114, in delete
AttributeError: 'WikiCreateTicket' object has no attribute 'wiki_page_deleted'

I think WikiCreateTicket module should have the following methods.

  • wikicreateticket/

    2020    def wiki_page_changed(self, page, version, t, comment, author, ipnr): 
    2121        self.__parse_wiki_and_create_ticket(page, version) 
     23    def wiki_page_deleted(self, page): 
     24        pass 
     26    def wiki_page_version_deleted(self, page): 
     27        pass 
     29    def wiki_page_renamed(self, page, old_name):  
     30        pass 
    2332    def __parse_wiki_and_create_ticket(self, page, version): 
    2433        page = WikiPage(self.env,, version) 

Attachments (0)

Change History (1)

comment:1 Changed 3 years ago by jun66j5

  • Resolution set to fixed
  • Status changed from new to closed

(In [10641]) Adds wiki_page_deleted, wiki_page_version_deleted and wiki_page_renamed. AttributeError happens when deleting a wiki page without these methods (fixed #9150).

Add Comment

Modify Ticket

as closed .
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from saigon. Next status will be 'closed'.
The resolution will be deleted. Next status will be 'reopened'.

E-mail address and user name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.