#1198 closed enhancement (fixed)
User filter for Timeline
Reported by: | Owned by: | Remy Blank | |
---|---|---|---|
Priority: | high | Milestone: | 0.12 |
Component: | timeline | Version: | 0.8 |
Severity: | normal | Keywords: | user patch |
Cc: | ijones@…, matthew.bassett@…, hshin@…, wfragg@…, pkou@…, s.lipnevich@…, ealtin@…, metajack@…, m.gilbert@…, hyugaricdeau@…, marcandre.lureau@…, rwargo@…, mat@…, a.a.vykhodtsev@…, tapted@… | Branch: | |
Release Notes: | |||
API Changes: | |||
Internal Changes: |
Description (last modified by )
The two attached patches (to files Timeline.py and timeline.cs) implement user filtering for the Timeline.
If user name is entered in input field, output only lines belonging to that user.
Attachments (5)
Change History (43)
by , 20 years ago
Attachment: | Timeline.py.diff added |
---|
comment:1 by , 19 years ago
Milestone: | → 1.0 |
---|---|
Owner: | changed from | to
#2487 has been marked as duplicate.
Note that the patches provided on this ticket are too old for Trac 0.9.
It's not possible to achieve that with
a plugin, either, because the ITimelineEventProvider
currently provide only checkbox filters,
which are only used to conditionally add all
the events provided by that provider.
What would be needed is a new ITimelineEventFilter
,
which would see all the events and filter out some of them.
comment:2 by , 19 years ago
Cc: | added |
---|
comment:3 by , 19 years ago
Cc: | added; removed |
---|
comment:4 by , 19 years ago
Cc: | added; removed |
---|
comment:5 by , 19 years ago
Cc: | added; removed |
---|
comment:6 by , 19 years ago
Cc: | added; removed |
---|
comment:8 by , 19 years ago
Cc: | added; removed |
---|
comment:9 by , 19 years ago
Cc: | added |
---|
We've just started to have to produce logs for what work we have done each work. The timeline filtered by each user seems like an ideal place for use to be able to look back and see what a user has done.
Thanks
Russell
comment:10 by , 19 years ago
Priority: | normal → high |
---|---|
Severity: | normal → minor |
Type: | defect → enhancement |
comment:12 by , 18 years ago
Cc: | added |
---|
comment:13 by , 18 years ago
Cc: | added |
---|
comment:14 by , 18 years ago
Description: | modified (diff) |
---|---|
Keywords: | user added |
Milestone: | 1.0 → 0.11 |
#4700 marked as duplicate… hm, looking at the CC: list, seems like this feature request is overdue ;)
comment:15 by , 18 years ago
Cc: | added |
---|
comment:16 by , 18 years ago
Cc: | added |
---|
comment:18 by , 18 years ago
Cc: | added |
---|
comment:19 by , 17 years ago
Cc: | added |
---|
comment:20 by , 17 years ago
Cc: | added |
---|
comment:21 by , 17 years ago
Cc: | added |
---|
comment:22 by , 17 years ago
Cc: | added |
---|
comment:24 by , 17 years ago
I've just implemented this for latest trac 0.11 svn - it changes the filters API, I'm not sure if this should go into 0.11, but at least I'll make the patch available here for people…
by , 17 years ago
Attachment: | trac-timeline-author-1198.patch added |
---|
Patch to r7176 (0.11 branch) to enable filtering attachments by author name
comment:25 by , 17 years ago
Cc: | removed |
---|
follow-up: 31 comment:26 by , 17 years ago
Note that the attached patch should handle filters in the previous format; still I'm not sure what the procedure for updating the API is.
Also, it seems that this could be implemented all inside the timeline code by simply looking at the generated author property that is part of the events tuple. Anyway, it seems to work :-)
comment:28 by , 16 years ago
Milestone: | 0.11.2 → 0.12 |
---|---|
Owner: | removed |
Severity: | minor → normal |
As it's not a minor improvement, this should rather be targeted for 0.12 (at least). People that really want the feature earlier could use the patch (attachment:trac-timeline-author-1198.patch), which still applies cleanly (with some fuzz).
The approach taken in the patch is interesting. Also, this would need some deeper changes (and maybe even a different approach) to allow for multiple user or even group filtering, which are natural extensions of this feature.
comment:29 by , 16 years ago
Cc: | added |
---|
comment:30 by , 16 years ago
Cc: | added |
---|
by , 16 years ago
Attachment: | 1198-timeline-author-filter-r7499.patch added |
---|
Patch against trunk adding author filtering to timeline
comment:31 by , 16 years ago
Keywords: | patch added |
---|---|
Owner: | set to |
Replying to davidf@…:
Also, it seems that this could be implemented all inside the timeline code by simply looking at the generated author property that is part of the events tuple.
You know, this is an excellent idea! The patch above does just that.
Please test the patch and report any problems. If there are no objections, I'll apply it to trunk.
follow-up: 35 comment:34 by , 16 years ago
Is this patch actual for the 0.11.2.1 build ? I try to apply this changes to my trac and get:
Trac detected an internal error: NameError: global name 'sorted' is not defined Python Traceback Most recent call last: File "/usr/lib/python2.3/site-packages/Trac-0.11.2.1-py2.3.egg/trac/web/main.py", line 433, in _dispatch_request Code fragment:
try: if not env and env_error: raise HTTPInternalError(env_error) try: dispatcher = RequestDispatcher(env)
dispatcher.dispatch(req)
except RequestDone: pass resp = req._response or [] except HTTPException, e:
Local variables:
Name Value after [u' except RequestDone:', u' pass', u' resp = … before [u' try:', u' if not env and env_error:', u' raise … dispatcher <trac.web.main.RequestDispatcher object at 0xb68c52cc> e <exceptions.NameError instance at 0xb688faec> env <trac.env.Environment object at 0xb6da4d0c> env_error None exc_info (<class exceptions.NameError at 0xb6e7e65c>, <exceptions.NameError … filename '/usr/lib/python2.3/site-packages/Trac-0.11.2.1-py2.3.egg/trac/web/main.py' … frames [{'function': '_dispatch_request', 'lines_before': [u' try:', u' … has_admin True line u' dispatcher.dispatch(req)' lineno 432 message u"NameError: global name 'sorted' is not defined" req <Request "GET u'/timeline'"> resp [] tb <traceback object at 0xb6887e3c> tb_hide None traceback 'Traceback (most recent call last):\n File …
File "/usr/lib/python2.3/site-packages/Trac-0.11.2.1-py2.3.egg/trac/web/main.py", line 204, in dispatch Code fragment:
req.args.get('FORM_TOKEN') != req.form_token: raise HTTPBadRequest('Missing or invalid form token. ' 'Do you have cookies enabled?') # Process the request and render the template
resp = chosen_handler.process_request(req)
if resp: if len(resp) == 2: # Clearsilver chrome.populate_hdf(req) template, content_type = \
Local variables:
Name Value chosen_handler <trac.timeline.web_ui.TimelineModule object at 0xb68c548c> chrome <trac.web.chrome.Chrome object at 0xb69843ec> err (<class exceptions.NameError at 0xb6e7e65c>, <exceptions.NameError … handler <trac.timeline.web_ui.TimelineModule object at 0xb68c548c> req <Request "GET u'/timeline'"> self <trac.web.main.RequestDispatcher object at 0xb68c52cc>
File "/usr/lib/python2.3/site-packages/Trac-0.11.2.1-py2.3.egg/trac/timeline/web_ui.py", line 172, in process_request
Trac: 0.11.2.1 Python: 2.3.4 (#1, Nov 4 2004, 14:06:56) [GCC 3.4.2 20041017 (Red Hat 3.4.2-6.fc3)] setuptools: 0.6c9 SQLite: 2.8.17 pysqlite: 1.0.1 Genshi: 0.5.1 mod_python: < 3.2 jQuery: 1.2.6
follow-up: 36 comment:35 by , 16 years ago
Replying to lmar:
Is this patch actual for the 0.11.2.1 build ?
No, the patch was applied to trunk. However, the error you get is due to sorted()
not being present in Python 2.3. Strangely, that function is called nowhere in the patch above, so the error is probably not due to the patch. Your best bet at this point is to upgrade to Python 2.4.
comment:36 by , 16 years ago
Replying to rblank:
No, the patch was applied to trunk. However, the error you get is due to
sorted()
not being present in Python 2.3. Strangely, that function is called nowhere in the patch above, so the error is probably not due to the patch. Your best bet at this point is to upgrade to Python 2.4.
Yes, it's work on my home system with trac 0.11.2.1 + python 2.5.
by , 16 years ago
Attachment: | 1198-timeline-author-filter-r7499-0.11.patch added |
---|
Added version of 0.12 patch that applies cleanly on 0.11
comment:37 by , 16 years ago
The latest patch seems not to work with trac 0.11.1. If I filter for my user name, I still see entries of other users, e.g. changed wiki pages or closed tickets.
comment:38 by , 16 years ago
Sorry, false alarm: The patch is OK, and I accidently messed with the code. This feature is really nice and should go into 0.11.[something] :~)
svn diff for ver 1238