On Fri, Jul 31, 2009 at 01:01:21PM -0500, Olemis Lang wrote: > > Is there any helper function in Trac I can use to clone an HTTP > Request object (i.e. instances of trac.web.api.Request) ? > > I already have a «real» request object provided by Trac and what I > really need is to obtain a Request object identical to that one, in > order to modify it later on. I could implement something from scratch > but I'm asking because perhaps there's something I'm missing. > > Thnx very much in advance ! > > -- > Regards, > > Olemis.
Hah! I had need of this very thing recently. I ended up just making a generic object and then setting the attrs I needed from the real request, but admittedly its a cheap hack and I'd much prefer a better solution. You can see what I did here: http://trac-hacks.org/browser/sharedcookieauthplugin/0.11/sharedcookieauth/sharedcookieauth.py#L22 Jeff --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Trac Users" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/trac-users?hl=en -~----------~----~----~----~------~----~------~--~---
