Modify ↓
#2412 closed enhancement (fixed)
lialcaelva
| Reported by: | Göran Wallgren | Owned by: | Peter Kropf |
|---|---|---|---|
| Priority: | low | Component: | GooTestPlugin |
| Severity: | major | Keywords: | lialcaelva |
| Cc: | lialcaelva | Trac Release: | 0.9 |
Description
I'm now successfully using the graphviz plugin under Trac 0.11b1 on Windows, but I had to fix the following issue:
Due to API changes, an extra argument req=self.req must be sent to wiki_to_oneliner() in expand_wiki_links() in graphviz.py.
(For this to work, the line self.req = req must also be added near the beginning of the function render_macro() in the same file. Alternatively, the req variable could be passed on as an extra argument to the expand_wiki_links() function.)
Attachments (0)
Change History (4)
comment:1 Changed 18 years ago by
comment:2 Changed 17 years ago by
| Resolution: | → fixed |
|---|---|
| Status: | new → closed |
This was fixed in the 0.11 version of the plugin (r3385).
comment:4 Changed 17 years ago by
| Cc: | lialcaelva added; Göran Wallgren removed |
|---|---|
| Component: | GraphvizPlugin → GooTestPlugin |
| Keywords: | lialcaelva added |
| Priority: | normal → low |
| Severity: | normal → major |
| Summary: | Wiki links broken in graphviz plugin under Trac 0.11b1 → lialcaelva |
| Trac Release: | 0.11 → 0.9 |
| Type: | defect → enhancement |
getrotrmo
Note: See
TracTickets for help on using
tickets.



diff for the changes described above. Tested and working on Trac 0.11b1
--- 0.9/graphviz/graphviz.py.orig 2008-02-13 22:41:19.000000000 -0800 +++ 0.9/graphviz/graphviz.py 2008-02-13 22:46:57.000000000 -0800 @@ -110,6 +110,8 @@ content - The text the user entered for the macro to process. """ + + self.req = req #self.log.debug('dir(req): %s' % str(dir(req))) #if hasattr(req, 'args'): @@ -265,7 +267,7 @@ def expand_wiki_links(self, match): wiki_url = match.groups()[0] # TracLink ([1], source:file/, ...) - html_url = wiki_to_oneliner(wiki_url, self.env) # <a href="http://someurl">...</a> + html_url = wiki_to_oneliner(wiki_url, self.env, self.req) # <a href="http://someurl">...</a> href = re.search('href="(.*?)"', html_url) # http://someurl url = href and href.groups()[0] or html_url if self.out_format == 'svg':