Opened 16 years ago
Closed 12 years ago
#3671 closed defect (worksforme)
Redirect not working when using a Ticket-URL
Reported by: | anonymous | Owned by: | Noah Kantrowitz |
---|---|---|---|
Priority: | high | Component: | PermRedirectPlugin |
Severity: | normal | Keywords: | |
Cc: | gammelmark@… | Trac Release: | 0.11 |
Description
When directly calling a Ticket-URL where the Ticket-View-Permission is only given after login, the Redirect is not done and the error is printed on the screen. For example: http://tracserver/project/ticket/3
Attachments (1)
Change History (8)
comment:1 Changed 16 years ago by
Resolution: | → worksforme |
---|---|
Status: | new → closed |
comment:2 Changed 16 years ago by
Resolution: | worksforme |
---|---|
Status: | closed → reopened |
Same behaviour here with 0.11 The PermRedirectPlugin works in any area except on a direct ticket-link like http://tracserver/project/ticket/3
comment:3 Changed 16 years ago by
Resolution: | → worksforme |
---|---|
Status: | reopened → closed |
Solution is still the same.
comment:4 Changed 16 years ago by
Resolution: | worksforme |
---|---|
Status: | closed → reopened |
No, it is not an installation issue. The redirect is working fine in every other area, except for ticket-links. For ticket-links Trac says that "TICKET_VIEW privileges are required" (Anonymous users have no right to view Tickets).
comment:5 Changed 16 years ago by
Cc: | gammelmark@… added; anonymous removed |
---|
I can confirm the same behaviour on Trac 0.11.2.
I tried to modify your code by always doing a redirect as the first line of the "post_process_request" method. It seems the code is not even triggered, when the url is /ticket/X. Reports, wiki pages etc. works just fine.
Granted that I am an absolute beginner to Python, I see nowhere that you specify which URLs you are interested in filtering, so maybe this is in fact a general Trac issue, and not an issue with the plugin.
Do you know this to be working in a specific 0.11 release? If so, which one?
Changed 16 years ago by
Attachment: | permredirect-always-auth.diff added |
---|
Workaround. Always redirects when not authed
comment:6 Changed 16 years ago by
I just added a patch that works for my purposes. However, it ALWAYS redirects if the user is not logged in, no matter if there is a permission error or not. In my concrete scenario that does not matter, since anonymous users are not allowed at all.
Although it does not solve the general problem, maybe someone else can benefit from it.
comment:7 Changed 12 years ago by
Resolution: | → worksforme |
---|---|
Status: | reopened → closed |
I can't reproduce this using the trunk of the plugin and Trac 1.0; if anyone is still seeing this issue, please leave a comment and I'll follow up to try to figure out how to reproduce the bug. Closing as "worksforme" in the meantime.
Most likely an installation issue. Please ask for assistance installing plugins in the IRC channel.