Edgewall Software

Ticket #5945 (closed defect: duplicate)

Opened 13 months ago

Last modified 9 months ago

upgrading to 0.11dev breaks attachment access

Reported by: richard.musil@… Owned by: cboos
Priority: normal Milestone:
Component: wiki system Version: devel
Severity: normal Keywords:
Cc:

Description

I have been running 0.10.4 on my setup. After upgrading to 0.11dev I cannot see attachments on wiki pages. If there is direct link to an attachment and I click on that link I got "you do not have sufficient permission". Also buttons for Add Attachment at the bottom of the page are gone. I guess it is related to new ATTACHMENT_* permission, however there is still some quirk there, because I have TRAC_ADMIN permision myself.

Also documentation or Admin module do not mention any ATTACHMENT_* type.

Attachments

attachment.py.patch (465 bytes) - added by jonathan.needle@… 12 months ago.

Change History

follow-up: ↓ 2   Changed 12 months ago by jonathan.needle@…

Looks like the problem is in source:/trunk/trac/attachment.py@5981#L700

It never actually returns 'decision' to the caller. Making the following change fixes it for me.

  self.env.log.debug('LegacyAttachmentPolicy denied %s '
                     'access to %s. User needs %s' %
                     (username, context, legacy_action))
else:
  return decision

fixes it for me.

Regards,

Jon.

Changed 12 months ago by jonathan.needle@…

in reply to: ↑ 1   Changed 12 months ago by richard.musil@…

Replying to jonathan.needle@adare.com:

Looks like the problem is in source:/trunk/trac/attachment.py@5981#L700 It never actually returns 'decision' to the caller. Making the following change fixes it for me.

Yep, if fixes it for me as well. Thanks for patch :). Now if anyone just check it in.

  Changed 12 months ago by athomas

  • status changed from new to closed
  • resolution set to duplicate

Duplicate of #5956, fixed in r5983.

follow-up: ↓ 5   Changed 9 months ago by dekimsey@…

  • keywords attachment button added
  • status changed from closed to reopened
  • resolution duplicate deleted

In revision 6255 of 0.11dev, we have run into a similiar problem. Specifically with respect to the "Add attachment" button not being displayed on wiki pages. After reviewing this bug, we enabled logging and saw the following:

2007-11-30 13:09:08,335 Trac[__init__] DEBUG: Prepare chrome data for request
2007-11-30 13:09:08,345 Trac[__init__] DEBUG: Updating wiki page index
2007-11-30 13:09:08,350 Trac[__init__] DEBUG: DefaultPermissionPolicy denies dekimsey performing ATTACHMENT_CREATE on <Resource u'wiki:WikiFormatting, attachment'>
2007-11-30 13:09:08,452 Trac[__init__] DEBUG: Retrieving session for ID 'dekimsey'
2007-11-30 13:09:08,873 Trac[__init__] DEBUG: Executing Wiki macro TracGuideToc by provider <trac.wiki.macros.TracGuideTocMacro object at 0xb794eccc>

The user 'dekimsey' is part of the TRAC_ADMIN group.

URL: https://svn.edgewall.org/repos/trac/trunk
Repository Root: https://svn.edgewall.org/repos/trac
Repository UUID: af82e41b-90c4-0310-8c96-b1721e28e2e2
Revision: 6255
Node Kind: directory
Schedule: normal
Last Changed Author: athomas
Last Changed Rev: 6254
Last Changed Date: 2007-11-29 08:40:58 -0500 (Thu, 29 Nov 2007)

in reply to: ↑ 4 ; follow-up: ↓ 6   Changed 9 months ago by osimons

  • keywords attachment button removed
  • status changed from reopened to closed
  • resolution set to duplicate

Replying to dekimsey@gmail.com:

In revision 6255 of 0.11dev, we have run into a similiar problem. Specifically with respect to the "Add attachment" button not being displayed on wiki pages.

That was fixed in [6259]. Please update and verify.

Resetting to last closed status.

in reply to: ↑ 5   Changed 9 months ago by anonymous

Replying to osimons:

Replying to dekimsey@gmail.com:

In revision 6255 of 0.11dev, we have run into a similiar problem. Specifically with respect to the "Add attachment" button not being displayed on wiki pages.

That was fixed in [6259]. Please update and verify. Resetting to last closed status.

Yup, that was the issue, we had just found the solution ourselves a moment ago, thanks for the help!

Add/Change #5945 (upgrading to 0.11dev breaks attachment access)

Author



Change Properties
<Author field>
Action
as closed
Next status will be 'reopened'
 
Note: See TracTickets for help on using tickets.