r354 - 02 Jul 2008 - 18:26:10 - VickiBrownYou are here: TWiki >  Plugins Web > ActionTrackerPluginDev
Tags:
, create new tag

ActionTrackerPluginDev Discussion: Page for developer collaboration, enhancement requests, patches and improved versions on ActionTrackerPlugin contributed by the TWikiCommunity.
• Please let us know what you think of this extension.
• For support, check the existing questions, or ask a new support question in the Support web!
• Please file bug reports in the ActionTrackerPlugin bug database.
• See ActionTrackerPluginDevArchive for discussions pre - 10 May 2003
• See ActionTrackerPluginHistory for discussions pre - 2 Jan 2004
PLEASE DO NOT REPORT BUGS IN THIS TOPIC. USE THE BUGS WEB INSTEAD.

Feedback on ActionTrackerPlugin

Nice to haves

Who Idea
MarkusMay I find the suggestion from RichardBaar? really cool. I tried to install this, but there seems to be too much errors. But especially the Add-Action is really cool. Probably someone is going to implement this?
NielsKoldso Oct 26 2006: Apply Patches: Allow normal TWiki rendering / RegExp search for state DONE
LynnwoodBrown Automatic recognition of unambigous fields, such as "due date", "who" and "state"
MartinCleaver Repeating tasks (e.g. due="every thursday")
  an 'Add Action' button at the bottom of the table.
  A Demo URL
  Eliminate the chance of PluginBinNameClashes - Move bin/actionnotify to lib/TWiki/Plugins/ActionTrackerPlugin/bin/notify; add a hook in MorePluginHooks? that calls all plugins on an hourly batch
  Make the notification schedule definable from the plugin page. e.g. Have crontab call actionnotify (preferably indirectly via my previous suggestion) periodically and with no parameters, but then have a table in ActionTrackerPlugin that specifies the parameters.
VickiBrown SECOND: an 'Add Action' button at the bottom of the table!
CrawfordCurrie Relative date entries when action first entered e.g. due="tuesday"
  Make the go to action link in action text a button image.
  Fix the "close subwindow on save" functionality.
  Move action change notification to where it belongs; in the beforeSaveHandler.
  Constrained state transitions
  Make it work for a PC server
MikeBoone For Action Search, allow $text format to display text without (go to action) link. DONE
AndyPryke "Move Action" button - to move an action from one topic (e.g. meeting minutes) to a another topic (e.g. a topic to which the action refers).
JosMaccabiani A 'Quiet Save' functionality for small typo changes
JosMaccabiani A hidden field that writes the last modification timestamp, and part of actionsearch, useful in TwikiApps? because change notification is per topic instead of per action
JosMaccabiani TWiki has made a graphical shift from 3 to 4, and because of that the action skin looks a bit dated. It would be nice if someone could at some point beautify the skin
JosMaccabiani The popup window not closing is freaking out the casual users, especially since some of them use the largest font available in IE on a 15" monitor. They don't get the new window filling up their screen :-). Would it be possible to explain how to modify something to allow 'unsafe' window closing?
JosMaccabiani Most actions are defined in weekly meeting A, are monitored in meetings B and C and then closed in meeting D. The nice thing about this plugin is that progress can be reported in the action description. However, since this action is stored in the topic where it is created, users can only know which action changed by reading old meeting minutes. Also, when a few actions are modified in a meeting, users get notification reports from several meeting minutes topics. I don't really have a solution to this. Perhaps storing the actions in separate numbered topics and only saving the changes in the minutes topics would be some workaround to this...
JosMaccabiani The action descriptions can get quite large, and this can yield the topic hard to view. Would it be possible to add some kind of Twisty functionality to the action template?
JacekZapotoczny We use prio attribute in actions to specify priority. It could be a standard attribute as it's very usefull in real life. All our actions are divided on Prio1(urgent work) Prio2(normal work) and Prio3(longterm work)
JacekZapotoczny For Prio3(longterm work) actions we don't specify exact due date which currently is not possible in the plugin. It would be very useful to have default due date as undef insted of BAD DATE FORMAT see ActionTrackerPlugin#DateFormats
JacekZapotoczny Annoying long msg when malformed date found or not specified at all BAD DATE FORMAT see ActionTrackerPlugin#DateFormats. Could be BAD DATE or ERROR.
RichardVinke Define a set of actions on one topic with only relative dates. On command, set only one date (the last one) and copy the whole set to another topic. Why this is a wish for me? I have the same set of actions for several small projects. Now I type the list of actions each time or copy it from a previous project when I create a new project. This looks more like a planning tool, with the e-mail notification.
ScottWBlack - 01 Feb 2007 Is there a way to mass change action items? Currently I do an actionsearch to see 30 action items on 30 pages. It takes ~ 15 seconds to load a page. I start at a main page that shows all action items via a actionsearch command. I click on the first action item edit button, edit it and it redirects me to the action items parent page. I then go back to the main page that has the action search command. Thats a total of 2 to 3 pages I had to load. Thats now 30 action items x 15 seconds per page load x 3 page loads per action items = 22.5 minutes to update all the action items.

If there were a super action item search button where we could modify all the action items assigned to this user at once and then hit super submit where it goes and updates all the action items at once, that would save the user 30 minutes in this example.

-- CrawfordCurrie

Hi - If anyone is interested, I am beginning to make some interesting progress on simplifying ActionTracker input. I posted a support question, SimplifyingActionTrackerInput, with where I got stuck. Any feedback is appreciated.

-- SamAbrams - 02 Jan 2004

Let me first tell you guys how wonderful it is to have this action tracker plugin. We are using it extravagantly and filling up out twiki pages with actions :-). Not too many people are closing theirs, but thats another story.

I have had to make more-or-less the same changes that EdMcGuigan above had listed. My SMTP server requires that the from address be listed with it as a registered user. So cant use TWiki/toolname or any derivative of it. On top of that most of our actions were in an authenticated web, so had to force the readTopicText change to ignore authentication.

-- VamsidharJuvvigunta - 21 Jan 2004

You can combine this plugin with the CommentPlugin to create action items (see attached comment-action.txt). However, there are two problems:

  • The CommentPlugin is limited because it only provides three variables plus the username and current date. So, you can create an initial Action Item, but you have to edit it later to fill the remaining fields.
  • It is very difficult to put the template in CommentTemplates. When you save the page CommentTemplates, the ActionTrackerPlugin interprets the %ACTION, cannot understand the variables {COMMENT}{URL}{LINK} of CommentPlugin, and fills default values when saving the page. Is there any way to prevent the ActionTrackerPlugin from interpreting the page? I can turn off the plugin on the whole TWiki web, but this has other side effects.

-- JoaquimBaptista - 29 Jan 2004

I've been messing with ActionTrackerPlugin and I like the concept but (and not knocking Crawford) but I am not enamored with the implementation. The parts that make me feel uncomfortable are:

  1. Creating action items requires going into editmode and creating using the plugin syntax
  2. Doing the above renders a nice looking table in view mode but in edit mode it is quite ugly
  3. Not everyone is comfortable with Twiki and TML. Everyone appears to be quite enamored with plugins like EditTablePlugin which hides TML behind a "gui" editing view.
  4. Adding new action items is cumbersome for TWiki neophytes (and most people are)
  5. The pop-up window for editing an existing action item is nice but as we have seen in Crawford's notes (and in practice) the resulting save is munged by Netscape/Mozilla/derivative browsers (yes, even the latest Firebird).

What I have been rolling around in my mind is a marriage between EditTablePlugin and ActionTrackerPlugin such that the Action table is truly a table created with a particular format and the actions are edited/added/deleted/etc. through what I call the "inline" edit capabilities of EditTablePlugin. The new plugin would be able to leverage such things as the popup calendar, pick lists for people performing actions, etc and present a highly portable edit interface for those running non-IE based web clients.

I'm looking for some input/discussion. I would like to play around with this but for me it will be a huge learning experience as I am just getting my feet wet and this would appear to be quite an ambitious undertaking.

-- SteveRJones - 29 Jan 2004

Joaquim, the WIKITOOLNAME -> WIKIWEBMASTER issue is fixed in the latest code (beta today). I'll have a look at the QBE. See notes below for comments on the "create action item" user story. The QBE can be made to work using the "default" attribute in URLPARAM, setting it to ".*" or another appropriate value (e.g. 1000 for within). I've fixed this in CVS. It just shows how often this is used that no-one has reported it before!

Steve, I sympathise. I thought long and hard about how best to handle action edits. Capturing actions after the minutes are already taken is closing the gate after the horse has bolted. The driving user story is this:

  1. Actions are captured in the minutes while the meeting is in progress.
  2. At the end of the meeting the topic is saved, and all the actions immediately go live.
  3. Actions are embedded in the minutes at the point of maximum context.
  4. Subsequent edits to actions are ALL done through the 'edit' link on the published action.

A number of people are using the action tracker for things it wasn't designed for (e.g. personal task lists, bug reports etc.). The design is not addressing these uses, I guess. However, if you want to change/enhance the modes of operation, I would suggest you write a similar user story (stories) that illustrate how you want to use it, and make absolutely sure you don't break the master user story. Some notes:

  1. The action syntax was chosen for consistency with other plugins and with TWiki in general. The code that parses/writes an action is very simple, and pretty well-contained. Changing the syntax would be quite straightforward.
  2. However. because the action tracker has an after-edit handler, it is quite simple to add an alternative syntax for action entry. The after-edit handler would simply translate this syntax to standard action syntax on save.
  3. One mode of operation I considered is an "Action Form" at the bottom (top) of the edit page that would let you fill in the fields and click an "Add" button to add it to the edit window. I think this would require javascript. The form could be populated with pull-downs etc. I didn't do it because it seemed a lot of work. Of course, if you want to pay me....
  4. Any proposals for artistic/usability improvements to the edit window are welcome.
  5. The fix for Mozilla pup-ups has gone into the latest code, which I hope to release for beta today. Please test and let me know how it behaves in Mozilla.
  6. Several times I've considered mergeing this plugin with the FormQueryPlugin, which has heavily overlapping functionality.

-- CrawfordCurrie - 02 Feb 2004

Release candidate ActionTrackerPlugin.zip attached to this topic. Please download and thrash! This release contains bugfixes as described in this topic and in the archive topics.

-- CrawfordCurrie - 02 Feb 2004

You point out something that I never really considered - creating actions in the middle of meeting minutes (which are therefore "sprinkled" throughout the minutes) then using the query feature to basically pull them all together. Is that it? Never thought of it that way.

I'll test the latest code to see if it is operational under Mozilla derivatives. Perhaps this will work and provide time to work on some of the features that I discussed above.

WRT the issue of payment - uh, my pockets seem to be lined with lint. Perhaps a gift certificate to half.com?? big grin

-- SteveRJones - 02 Feb 2004

The pop-up edit window in Mozilla-Firebird now behaves as expected. What was the fix?

-- SteveRJones - 02 Feb 2004

Steve, yes, that's the use model. Of course that doesn't preclude other models, such as the one you allude to.

Have you encountered the donation system on sourceforge yet? Helps maintain all us charity workers wink

Glad to hear the window is fixed; the fix was donated by RichardBaar and is documented in the history topic. Note that this is a bug in Mozilla-derived browsers, and the action tracker simply works around it

-- CrawfordCurrie - 03 Feb 2004

OK, that's enough time, I'm releasing. Note that there is one changed behaviour; "within" is now absolute, so "within=7" means "within a 14 day window, seven days either side of today". I leave you to work out the impacts of this.

-- CrawfordCurrie - 06 Feb 2004

Following your request to use the support web for bug reports, I created and answered my onw bug report with a corresponding patch. I am not certain that it makes much sense: will you read the answered bug reports? smile Oh well...

-- JoaquimBaptista - 06 Feb 2004

Joaquim, your patch broke loads of stuff - as you would have seen if you'd run the tests! I've corrected the change, updated the tests and uploaded a revised zip to ActionTrackerPlugin. How's that for service!

-- CrawfordCurrie - 06 Feb 2004

You were right that I failed to make use of the provided tests; no excuse for that. Thanks for the fine service!

-- JoaquimBaptista - 08 Mar 2004

Hmm, may be we should open a BugReport? tracking here in the Plugins web, for all to use? This could be similar to the Codev.BugReport system, but with one additional "Package" field to categorize by package (Plugin/Skin/Add-On)

-- PeterThoeny - 08 Feb 2004

Yes, please. I got no response to this request previously.....

-- CrawfordCurrie - 08 Feb 2004

Hi, in topic ActionTrackerPluginModified I put my version of ActionTrackerPlugin. I don't think that anyone else can use it without big modifications but I put it there because I implemented many features which are in 'Nice to have' section and maybe someone can use part of my code and put it into nowadays ActionTrackerPlugin. wink

-- RichardBaar - 18 Feb 2004

Or alternatively, Richard, you can propose patches to the code that I can consider for inclusion. Certainly I'm not going to attempt to reverse engineer what you have done, though I'm sure much of it would benefit the community. Consider it as an opportunity for you to re-invest something back into TWiki!

-- CrawfordCurrie - 18 Feb 2004

I have posted a nice solution to the ActionTracker input problem. See Plugins.ActionTrackerInput.

-- AlainMivilleDeChene - 12 Mar 2004

Just checking to see if this plugin is still suported. There are a couple of bug questions in the Support area that remain untouched.

-- SteveRJones - 22 Apr 2004

The plugin is definitely supported, but as I'm sure you appreciate time is limited and paying work has to take precedence. If you have solutions to problems in the form of patches, and post them here, I'm usually fairly quick at incoporating them. I was holding off doing too much until the "Cairo Crunch" hits us.

-- CrawfordCurrie - 23 Apr 2004

I modified this plug in slightly to enable directed notifications and allow AR to be passed from one person to the next, and to allow a person to immediately notify the list of interested people (managers, etc.). Rather than using cron to cull for changes overnight, I used a lookup by UID (ActionNotifyUID? .pm) to find and format the AR and send out mail. I also modified the script to add a short AR description to the email subject, rather than getting a general 'item on twiki requiring your action', you get 'AR: Thing to do, due 15 May 04". I put this in a HTML form with the ACTION and a button that calls the script. i also CGI'ified the actionnotify script so I could call it from a page.

When a person is finished with their part of an action item, they update the AR then hit the 'notify' button. As a manager I don't have to bug people for status - I get notified when each person finishes there step. Also, I can notify people when I schedule/assign them a task.

-- GeorgePeden - 15 May 2004

Interesting, George. Do you intend to contribute this back to the community?

-- CrawfordCurrie - 12 Jun 2004

A problem with the latest code related to parsing of query-by-example action searches has been highlighted to me - specifically, when you have a quoted expression in the action search, the SharedCode attributes parser fails. This only applies to the CVS head. I have checked this on my checkout and it works fine, so I guess I must have found it and fixed it; anyway, I checked it in, and the CVS head code works for me. MarkKoch, please check it out and try again, and let me know how you get on.

-- CrawfordCurrie - 12 Jun 2004

Crawford,your changes fixed it. Thanks, TWiki is now happily informing my co-workers that their action items are several days late. wink

-- MarkKoch - 14 Jun 2004

We have a simple solution to the ActionTrackerPlugin input problem. We put together a template, like the one in TWikiTemplates#Template_Topics_in_Action, except that we use the save script rather than the edit script:

<form name="new" action="%SCRIPTURLPATH%/save%SCRIPTSUFFIX%/%INTURLENCODE{"%WEB%"}%/">

We chose to have the user specify only the topic name and parent in the HTML form. That way, they're using the same interface for any and all edits to the action.

-- SaraYurman - 04 Dec 2004

Potential problems with "after edit" callback

With the introduction of SavemultiCgiScript? potential problems with the "after edit" handler can be occur, by doing a direct save

There is a potential problem with this approach: any plugins using the "after edit" handler, TWiki::Plugins::afterEditHandler will not be called. At the time of this writing (16 Apr 2004), that means ActionTrackerPlugin & TranslateTagPlugin. The action tracker only uses the AfterEditHandler? because at the time there was no BeforeSaveHandler? . The plugin author, CrawfordCurrie, says afterEditHandler can easily be eliminated from this plugin which leaves only one usage.

The "after edit" callback needs to be called also if preview is skipped, that is TWiki::Plugins::afterEditHandler needs to be called

The plugin hook mentioned is only needed by ActionTrackerPlugin & TranslateTagPlugin. This of course should be solved, but it is not relevant for the skin on twiki.org. The author of the action tracker plugin has said that eliminating the afterEditHandler is not a problem for him (see SingleStepSave? ).

[...] from my reading of the code, if you preview an empty topic, the afterEditHandler will be called even though the topic will not be saved.

The action tracker only uses the AfterEditHandler? because at the time there was no BeforeSaveHandler? . The afterEditHandler can easily be eliminated.

-- CrawfordCurrie - 15 Apr 2004

Problem with ISO-8859-1 TWikiNames

First, I have to say that I like this plugin very much, and use it a lot. My twiki is mostly in french, so I use TWikiNames with accented letters, which works fine. But when editting an action, the popup seems to use utf-8 in any way, because when the action is on a page whose name is accented, this results in the creation of a new page, with the name in utf-8. Any hint about this?

-- LaurentBurgbacher - 06 Aug 2004

There doesn't seem to be any problem with the handlers; it all works nicely with PatternSkin.

Laurent, I don't know, but I would guess that it's something to do with what is in edit.action.tmpl, which is the template for the edit popup. There may be some UTF support that has to go in there?

I'm going to release a version that has been tested against Cairo in the next few days, I also changed the within= to allow directional searches, so if you say within="-7" it means "within the last 7 days". This allows you to search for actions that are still open but were due within the last 7 days i.e. exclude very old actions from the search.

-- CrawfordCurrie - 06 Aug 2004

I checked edit.action.tmpl, but it's the same meta as in view.tmpl. There must be a point when saving the action where a utf-8 string is used instead of the iso-8859-1 one. I'll try to have a look, but I'm not very familiar with perl...

News, after some inspection, I found out that in the file actionform.tmpl, there's a line:

<FORM METHOD="post" ACTION="%SCRIPTURLPATH%/%SUBMITCOMMAND%%SCRIPTSUFFIX%/%WEB%/%TOPIC%%SUBMITCMDOPT%" ENCTYPE="application/x-www-form-urlencoded">

By comparaison with edit.tmpl, I added the part that encodes the web and topic name correctly:

<FORM METHOD="post" ACTION="%SCRIPTURLPATH%/%SUBMITCOMMAND%%SCRIPTSUFFIX%/%INTURLENCODE{"%WEB%/%TOPIC%"}%%SUBMITCMDOPT%" ENCTYPE="application/x-www-form-urlencoded">

Now it works! Thanks for your help and for this great plugin!

-- LaurentBurgbacher - 06 Aug 2004

It would be really nice if you updated the change history when you release a new version of a plugin. The version from September 18 has no information on what has been changed at all. Not even on this page. What did you change?

-- KennethLavrsen - 20 Sep 2004

As far as I recall, nothing except the installer code. Watch the version number, not the dates. But point taken, Ill try and be more explicit.

-- CrawfordCurrie - 27 Sep 2004

If you compare the version from 16th of August and the latest then there is only one file with perl code that has not been modified. Most seems to be the same kind of change but there are many real code lines that have been changed or added. There are 4 files uploaded since last change history update. It is easy to forget what you change if you do not write it right away.

I just posted a problem with submitting a new action item using the CommentPlugin. See also CommentPluginDev. The result when submitting an action using Saumitra, sorry for the delay in noticing this, it sounds very interesting. It would be cool to have the edittable type functionality built into the action tracker plugin; I'm not sure why you wanted to have another plugin rather than just enhancing the action tracker? Anyway, why don't you just create SaumitraBhaumikWouldLikeToCheckIn? and check in to subversion yourself? The action tracker has a test suite, so it should be easy to check if you have broken anything when you do make changes. It would be great if I wasn't the only person working on this plugin!

-- CrawfordCurrie - 03 Jan 2006

%COMMENT{type="action"}% is that instead of creating the %ACTION... it creates 20+ lines of scripting and HTML code. It looks right afterwards but naturally the action tracking does not work by creating an HTML tables that looks the same.

I also tried writing an action item in a "normal" type COMMENT and that produces the same error. It would really be cool if this could be made to work. I have tried adding code here and there but I could not find a workaround.

-- KennethLavrsen - 29 Sep 2004

Argh I'm sorry, Kenneth, I have shot myself on your behalf. I will discipline myself to update the change histories in future.

I'll look into action submission from COMMENT as soon as I can. I suspect it's because of the way I call expandCommonVariables when instantiating the template. This is how things like DATE and TIME and TWIKIWEB get expanded. Unfortunately I can't stop it from expanding plugin tags as well.

Any debugging you can help with is most welcome (too much to do, too little time frown )

-- CrawfordCurrie - 29 Sep 2004

i've updated the zip (and CVS) to use $TWiki::egrepCmd, an unpublished twiki global variable, which although not "correct", is better than the hardcoded path (/bin/egrep) that was always failing on my mac.

-- WillNorris - 13 Nov 2004

And I fixed CVS and the zip so the tests pass again (grr!) and added support for conditions in date searches.

-- CrawfordCurrie - 19 Nov 2004

Edit randomly reorders the tags

This is a very annoying habit due to non-sorted keys: when you edit a page with action items, the action item gets regenerated. Since the keys are in an array, they get rewritten in random order. The result is that the page history shows action item changes where there are no visible changes (the keys were simply shuffled).

The fix is extremely simple: sort the keys before writing them out so that they always appear in the same order and thus don't randomly reorder themselves.

Patch for the file lib/TWiki/Plugins/ActionTrackerPlugin/Action.pm

# rcsdiff -c -r1.1 ./Action.pm
===================================================================
RCS file: ./RCS/Action.pm,v
retrieving revision 1.1
diff -c -r1.1 ./Action.pm
*** ./Action.pm 2004/12/08 20:48:05     1.1
--- ./Action.pm 2004/12/08 21:50:16
***************
*** 319,325 ****
      my $this = shift;
      my $attrs = "";
      my $descr = "";
!     foreach my $key ( keys %$this ) {
        my $type = $types{$key};
        if ( $key eq 'text') {
        $descr = $this->{text};
--- 319,325 ----
      my $this = shift;
      my $attrs = "";
      my $descr = "";
!     foreach my $key ( sort ( keys %$this ) ) {
        my $type = $types{$key};
        if ( $key eq 'text') {
        $descr = $this->{text};

-- JerryVanBaren - 08 Dec 2004

Bug when executing grep -- with possible security implications!

%ACTIONSEARCH was failing miserably while grep complained of a "syntax error". It turns out that the web had pages named Slide 12 -opportunities.txt and grep was seeing -opportunities.txt as a switch!

This actually means that the file arguments to grep are not being quoted, which may have security implications (for example, create a page named bug; rm *.txt and you may succeed in removing all text from the relevant TWiki!)

The fix below seems to fix the issue at my installation; I was running version 2.013:

--- ActionSet.pm-orig   2005-02-04 18:44:18.000000000 +0000
+++ ActionSet.pm        2005-02-04 18:44:46.000000000 +0000
@@ -277,7 +277,7 @@
                $cnt = 512;
          }
          $cnt--;
-         $group .= " $dd/$web/$topic.txt";
+         $group .= " '$dd/$web/$topic.txt'";
        }
        push( @groups, $group ) if ( $group );

--- ActionNotify.pm-orig        2005-02-04 18:54:23.000000000 +0000
+++ ActionNotify.pm     2005-02-04 18:55:24.000000000 +0000
@@ -487,7 +487,7 @@
             $cnt = 512;
         }
         $cnt--;
-        $group .= " $dd/$theWeb/$topic.txt";
+        $group .= " '$dd/$theWeb/$topic.txt'";
        }
        push( @groups, $group ) if ( $group );

-- JoaquimBaptista - 04 Feb 2005

I just uploaded a version with the JSCalendar fixes in. Joaquim, yes, I have known about that for a while but haven't done anything about it for a number of reasons, not least of which was lack of time. I will shortly be porting ActionTrackerPlugin to the DakarRelease codebase, at which time I will be converting it to use the TWiki sandbox for command invocation, instead of the current DIY.

-- CrawfordCurrie - 26 Mar 2005

Base URL fails with JSCalendar

I've just ran into a problem with ActionTrackerPlugin.pm when JSCalendar is installed. When opening the edit window on an action, the base URL is set to http://machine:port/bin/view... instead of http://machine.domain.com:port/bin/view... which leads to some problems with Firefox using automated NTLM login (because only machine.domain.com is allowed to automatically send the NTLM authentication credentials).
As a fix, I just edited ActionTrackerPlugin.pm on lines 80 and down so that it uses %SCRIPTURLPATH% and %PUBURLPATH% instead of %SCRIPTURL% and %PUBURL%, and it does work like a charm. Now, I don't understand why these last two miss the domain part of the hostname (this does work properly in TwikiVariables? , though)... confused But since all the templates are using xxxPATH variables, I find it coherent to update ActionTrackerPlugin.pm too, don't you think?

And this is a damned cool plugin, by the way!

-- PascalDavoust - 04 Apr 2005 I tried to fix two little bugs and added a little feature. (ActionTrackerPlugin 26 Mar 2005)

This is not really a "Question" as the SupportStatus? shows, but I don't know where else to put this sort of message (I'm a newbie here).

1) Fixed typo (or something like that) in the bottom line with the "<== This is your signature for easy copy & paste operation"

    templates
    ---------
    # diff actionform.tmpl.20050408 actionform.tmpl
    10c10
    < <br /> <b>-- <nop>%WIKIUSERNAME% - %DATE% &lt;br /&gt;</b> &nbsp;&nbsp;<code>&lt;==</code>
    ---
    > <br /> <b>-- <nop>%WIKIUSERNAME% - %DATE% </b> &nbsp;&nbsp;<code>&lt;==</code>
  • There will be a new actionform.tmpl that leverages pattern skin in the next release (CC)

2) Fixed empty table data field (e.g. "Notify") which was displayed not nice after an edit session.

    lib/TWiki/Plugins/ActionTrackerPlugin
    -------------------------------------

    # diff Format.pm.20050408 Format.pm
    255a256,258
    >           if ( $entry eq "  " ) {
    >             $entry = " &nbsp; ";
    >           }
  • OK, thanks (CC)

3) Added a state "all" to be able to select all actions with QueryActionItems?

Perhaps that could be done with the original code too, but I didn't found out how.

    lib/TWiki/Plugins/ActionTrackerPlugin
    -------------------------------------

    # diff Action.pm.20050408 Action.pm
    518c518,522
    <       return ( $this->{state} eq $val );
    ---
    >       if ( $val eq "all" ) {
    >         return ( 1 );
    >       } else {
    >         return ( $this->{state} eq $val );
    >       }
  • Just don't put a "state" condition in the action search.... (CC)

-- ChristianZiemski - 08 Apr 2005

actionnotify: uninitialized value in substitution

When I run actionnotify I get this error message

# ./actionnotify "state=\"late\""
Use of uninitialized value in substitution (s///) at /usr/local/apache2/twiki/lib/TWiki/Prefs.pm line 636.
Use of uninitialized value in substitution (s///) at /usr/local/apache2/twiki/lib/TWiki/Prefs.pm line 636.

My TWiki is 24 Oct 2004 $Rev: 1780 $ with the security patches SecurityAlertExecuteCommandsWithSearch and UncoordinatedSecurityAlert23Feb2005.

My ActionTrackerPlugin is 2.020.

The code that fails in Prefs.pm is

sub formatAsFlag {
    my( $value ) = @_;

    $value =~ s/^\s*(.*?)\s*$/$1/gi;
    $value =~ s/off//gi;
    $value =~ s/no//gi;
    if( $value ) {
        return 1;
    } else {
        return 0;
    }
}

-- KennethLavrsen - 20 Apr 2005

Found two problems while editing the actions on the SVN version.

  • There is a conflict between the action parameter of the edit script and the action parameter that the plugin expects.
  • If the previous conflict is solved, then the resulting page has the "bare" HTML for the form shown, as the entities in the text are encoded before it's inserted into the template.

-- RafaelAlvarez - 08 Jul 2005

Patches: Allow normal TWiki rendering / RegExp search for state

If possible I would like the following patches to make it to the next release.

I have updated ActionTrackerPlugin.pm and Action.pm so that:

  1. TWiki administrator may choose whether actions show \n as a <br> or whether =\n='s are preserved (and normal TWiki rendering applies).
    Motivation: My users are confused about why normal TWiki markup (e.g. bullets) cease to work within actions.
  2. User may search states by mean of regexp
    Motivation: Need to mathc say 2 out of 5 states (non-closed is not sufficiently)

Documentation updates

Doc 1: Last in ActionTrackerPlugin Settings
   * If you disable newline translation, action bodytext will be formatted as normal twiki data; e.g. you may use bullet-lists etc. 
     (Default is 0 - normal action-tracker behaviour).
      * Set DISABLE_NEWLINE_TRANSLATION = 0
      * Below is an action showing bullets if newline translation is disabled
%ACTION{state="closed" who="Main.TWikiGuest"}% <<EOF
Action showing the impact of =DISABLE_NEWLINE_TRANSLATION=  
   A. Bullet A  
      a. Bullet A.a
   A. Bullet B  
EOF

Doc 2: After the Set EXTRAS = |state,select,1,"open","fried","boiled","poached","closed"| example add
%T% For state you may enter a regexp when searching, e.g. =state="(fried|boiled)"= will find the fried or boiled actions.

Patches:

Cairo Dakar r11560 NEW

-- NielsKoldso - 19 Jul 2005

Allowing relative dates

I wanted to be able to search for actions completed within the last 7 days. In my install, I changed line 55 in Action.pm from
# Options for parsedate my %pdopt = ( NO_RELATIVE => 1, DATE_REQUIRED => 1, WHOLE => 1 );
to
# Options for parsedate my %pdopt = ( NO_RELATIVE => 0, DATE_REQUIRED => 1, WHOLE => 1 );

This doesn't seem to have caused any problems, and I can now use searches such as:

%ACTIONSEARCH{closed=">now - 7 days" sort="$closed,$topic" state="closed" format="| $topic | $closed | $text|$edit|" header="|Topic| closed |  Description | |" }%

Any reason not to change this option in the main version?

-- AndyPryke - 09 Aug 2005

Action Tracker Inputs

Like some of you had mentioned, we also have been looking for some way to develop something (or enhance the existing ActionTrackerPlugin) such that we could input the actions using some kind of an editable table. Here is what we have done so far in our TWiki installation:
  • Added a new plugin called EditActionTrackerPlugin
  • Added the below text as part of our default site-level WebTopicEditTemplate:
%EDITACTIONTRACKER{ header="| Assigned to | Due date | Description | State |*Notify*|* *|*" format="| text, 30 | text, 30 | textarea, 3X40 | select, 1,open | text, 20 " changerows="add" }%

  • This gives a "Add-ActionItem" button in every new page created & saved. Clicking on this button (w/o going to "edit" mode), shows up a editable table with fields similar to the ones in the action tracker table.Once the fields are filled and the table is saved, it creates the action tracker table. The attached doc has the screenshots that would demonstarte the above steps.

As you can make out, like the %ACTION{ }% tag of the ActionTrackerPlugin, the %EDITACTIONTRACKER{...} tag is the key here, providing the "Add-ActionItem" button in the "view" mode & then creating the %ACTION{ }% tags for each rows (i.e. actions) added (& saved) using the editable table. Users here are finding this very useful, as they can simply create a new page, save it & then start adding actions.

I could contribute the plugin module to the TWiki community, but before that wanted to get some feedback from you all to see if this is what you guys are also looking for.

-- SaumitraBhaumik - 02 Dec 2005

Great Saumitra, but why didn't you use the %COMMENT{type="action"}% approach (see CommentsTmpl#action)?

-- FranzJosefSilli - 02 Dec 2005

I think Saumitra's plugin looks very interesting. Can you also edit the actions afterwards like it is an edit table? Then it is really interesting. My colleagues likes the action tracker but they often complain about the fact that you have to click a link, a new page opens, you edit, you submit, and you have to close the resulting page and refresh the original. Eliminating some of these steps is a big wish.

It will probably be hard to get an edit table type editing in an action search but even it is only possible where you have the actual actions it is still interesting. Especially when you have a "Do Done List" type topic. So you should publish your plugin. Maybe somebody else will improve it. You can only win by sharing.

-- KennethLavrsen - 02 Dec 2005

Thanks Saumitra for bringing this up here. The screenshots look a lot like the EditTablePlugin. In fact, a simple alternative to the ActionTrackerPlugin can be done by using the EditTablePlugin and CommentPlugin. I made an example at Sandbox.EditActionItems which makes it easier to edit action items, but does not support e-mail notification and query capabilities (which could be added by a FormattedSearch and a supporting Plugin).

-- PeterThoeny - 03 Dec 2005

We tried using the comments plugin, but as mentioned earlier the issue was you could only create a new but incomplete action item with this and needed to edit the new action to fill in all the details; this is a pain (for the users).

In case of our plugin, by clicking on the "Add-ActionItem" button (which is on every page once you put the %EDITACTIONTRACKER{...} tag in the default template), you get an editable table with fields identical to the ones in the action tracker. Once you save the table after adding one or more rows, the resulting table would be the normal action tracker table (with the same %ACTION{ }% tag in the edit mode). Now, you can either edit an existing action using the "edit action" link (in the normal action item table) or you can add some more actions using the "Add-ActionItem" button at the bottom of the action item table.

In summary, this is exactly what our users wanted i.e. a way to create/add new action item w/o having to go to the "edit" mode. Action tracker already allows users to edit existing actions from the view mode. So now with this, users can both add & edit actions from the view mode and this is what users wanted. As I understood, most users hate to remember & type in any twiki variables/ tags to create something.

One other point: action tracker plugin has got great features like action searches, action reminders, ....(thanks to CrawfordCurrie & other contributors) and we didn't want to spend any time on creating a new plugin for this purpose. All we needed was a supplement i.e. a simple way to input the action item details which in turn would call the action tracker scripts to create the action items (& do all the other stuff like searches, reminders, ...). This also ensures that we can adopt all changes/updates done by Crawford in the future versions, w/o having to worry too much about the changes & their impact.

One small issue that we are currently facing is that some of the actions created with this plugin are not getting picked up by action searches. Once we figure out the issue & resolve this, I'll surely upload this in TWiki.

BTW, Peter & others: I work for Texas Instruments (Bangalore, India office). TWiki has been very popular here & I did my bit to spread its usage. Maybe someday I'll find time to write a success story on this ...

-- SaumitraBhaumik - 06 Dec 2005

Sorry Saumitra for me not fully understanding your enhancement, and an enhancement to the ActionTrackerPlugin this definitely is. Did you ask Crawford and the others working on and with the ActionTrackerPlugin to incorporate your enhancement into the standard version of the plugin? I'm sure many users would appreciate the better usability. Thanks for sharing this! (Hoping for more such 'returns' to the community wink )

-- FranzJosefSilli - 06 Dec 2005

Saumitra: I was wishing for an easier way to add action items in the ActionTrackerPlugin. Since your Plugin extends this Plugin it might be better to fold your Plugin into this Plugin. Crawford, what do you think?

Yes, a TWiki Success Story by TI would be very helpful to spread the word of TWiki. If you find time, please do so! I think readers are mainly interested in learning what kind of problems TWiki solved, what kind of value TWiki brings to the teams, timeline of adoption, and TWikiApplications you built.

-- PeterThoeny - 07 Dec 2005

Peter: I agree with you. Since the plugin I have mentioned about here, merely extends the capability of the action tracker plugin by adding the fetaure of adding/creating new actions from the view mode, it is best that this is integrated with the next version of the action tracker plugin itself.

As you would appreciate, many users in my group were not willing to use this plugin only because they were upset with this limitation (of having to go the edit mode for adding actions) and that is why I had asked the web support guy in my group to create this supplement. In summary, I didn't want the existing TWiki users (in my group) to look at other alternatives for managing their action tracking needs.

BTW, I have managed to put together a successs story, finally. Will add more details later ...

-- SaumitraBhaumik - 08 Dec 2005

Thank you very much Saumitra for submitting a success story!

-- PeterThoeny - 08 Dec 2005

I have uploaded the EditActionTracker perl module. The issue with action searches is resolved. As Peter suggested, it would be great if Crawford updates the ActionTracker? plugin with inputs from this so that actions can be created/added from the view mode.

-- SaumitraBhaumik - 08 Dec 2005

Sorry for taking so long to notice this! I have been deluged with other things. I understand what you have done; sounds hoopy. I will try it as soon as I get a few minutes breathing space!

Saumitra, why don't you just complete SaumitraBhaumikWouldLikeToCheckIn? and then you can check into the action tracker directly, without having to wait for me? It has a test suite, so as long as you run the tests and they pass, then you can't break anything (or if you do break something and the tests still pass, it's then my fault wink )

What you are doing sounds great, though I really don't want to have to be in the loop for your changes....

(Also note that the ActionTrackerPlugin has had quite a few changes for DakarRelease? )

-- CrawfordCurrie - 03 Jan 2006

Hi all who love ActionTrackerPlugin,

we use TWiki for a long time in our company and we can't imagine our TWiki without ActionTrackerPlugin. We used for long time TWiki version from year 2003 and I made a lot of modifications during the time to ActionTrackerPlugin but I never had time to patch the latest version. frown But now I am prepared latest TWiki for company production release and I used the latest ActionTrackerPlugin sources and try to modify it again. And now I have patches against these sources. wink

Here is the list what is new:

  1. Possibility of DB backend
    • Well, for now it works only with MySQL? but I hope that it could work with any database. You can specify if you want to use DB backend in ATP preferences. All the code for storing info is situated in afterSaveHandler of ATP. I use than this DB for matching actions and also for generating UIDs for actions. Now the uids are checked against whole TWiki and not only in the topic where the actions is situated.
  2. Immediate notification
    • We use ActionTrackerPlugin as task management system and for approval processes and we need immediate notifications. This feature works only when DB backend is 'on'. You can specify what fields should be checked (IMMEDIATE_NOTIFICATION_CHANGES) and from which fields emails should be taken (IMMEDIATE_NOTIFICATION_FIELDS).
  3. Date format
    • You can now specify the date format (DATE_FORMAT) which is than used accross whole ATP (also in popup Calendar)
  4. 'Go to link' in actions searches can be displayed as image
    • you can now specify if you want graphical 'go to link' button
  5. if you put in the topic text '%ACTION%' variable there will be text 'Create new actions set'
    • if you specify in the topic text variable %ACTION% you will be able to create new actions with one click wink
  6. you can now remove actions with one click
    • you can now decide to have remove actions button to remove actions with one click
  7. you can now close/reopen action with one click
    • you can now choose to show state as graphical image with ability to change the state with one click
  8. new field type in actions called 'area'
    • you can now specify new extra fields as 'area' and the edit action will show as TEAXTAREA
  9. new possibility to format the Edit screen for editing actions
    • you can now add in the EDITHEADER variable '*' character before the heading title and force it to create new row
  10. there is now 'Add action' link at the bottom of each actions set
    • in each action set is now at the bottom link 'Add action' for simple adding
  11. new field type 'bugs' for adding links to bugs
    • new field 'bugs' is defined in action field types; it is rendered as simple text field in edit window and you can fill it with comma separated bugs; they are then rendered as links in topic view
  12. CSS based output from ATP
    • all output from ATP is now CSS based and you can change it to your needs

Maybe there are some other improvements which I didn't mention but I hope that they are not so important as those mentioned above. wink

Here is the screenshot from our TWiki as the actions look like:
Screenshot for Richard Baar's modifications

I attached (http://twiki.org/p/pub/Plugins/ActionTrackerPluginDev/ATP_modifications.zip) all modifications with original, new and patch files and you can try it. If it will not work for you, let me know and I will try to solve the problem.

IMPORTANT CHANGES Because of problems which arise during these modifications I changed the save behavior of descriptios. They are stored again as HTML and not with 'EOF'. Maybe for someone it will be big disadvatage but for me it is very minor change because I don't know anybode who change actions in topic texts. I also change 'description (text)' field in actions specifications to 'area' from 'noload'. Now the 'text' property is taken as any other property of action because I really don;t understand why the ATP works with 'description' as with something special.

What is missing

  1. script for filling database with current actions (in a week I should create one)
  2. DB based search (this is problem, because it will be very fast but also very time consuming to implement and I have a lot of work on new TWiki ;-( ) But maybe once...

-- RichardBaar - 19 Jan 2006

This plugin exists in a newer version on SVN which works for Dakar.

It would be nice - now that Dakar is released - if the latest plugin would be made available to the general public instead of living in hiding on SVN only.

-- KennethLavrsen - 12 Feb 2006

At least put the ZIP here on the "Dev" page ??

-- AviYagodnick - 12 Feb 2006

I noticed that when people add comments - the comment always ends far up the topic. I think it ends before a COMMENT tag which is NOPed out. I have put some more nops around and it seems to help.

-- KennethLavrsen - 12 Feb 2006

The additions by RichardBaar and SaumitraBhaumik sound like exactly the things I'm looking for to allow my team to use TWiki easily for action tracking. Thanks for the work and for giving back to the community.

I'm slightly confused as to what I should install - There's a "newer version on SVN which works for Dakar" plus these two other packages.

Has anyone investigated compatability between these 3 varients?

-- AndyPryke - 16 Feb 2006

I just uploaded the Dakar version. It does not have any Richard or Saumitras recent work.

-- CrawfordCurrie - 16 Feb 2006

Here's a few quick bits of feedback on installing RichardBaar's ATP_modifications.zip

  1. If you're not going to use a database backend (MySQL? ), you should set the value of the variable USE_DB in the file data/TWik/ActionTrackerPlugin.txt to false. Otherwise you will not be able to save topics in TWiki. To clarify, you can't install the modifications and then use TWiki to edit the value of USE_DB in TWiki.ActionTrackerPlugin because save will fail.
  2. I didn't get the pretty table formatting shown in the screenshot (above). I believe this is because I'm missing a CSS definition for "actions_table". Richard - am I right on this? Do you have an example file?
  3. If you wish to remove some of the fields (e.g. the bug-tracking), you can do this by editing the variables in the topic TWiki.ActionTrackerPlugin.
  4. Pre-existing actions didn't have values for the "Start Date" field and this missing value is treated as a "bad date format". I believe this is the behaviour in the standard ATP too. Perhaps missing values should be allowed for dates? But maybe there are disadvantages to this too?

Aside from these minor points, it all worked fine for me. I would of course advise people to backup their original TWiki files before installing.

Thanks Richard, for writing and sharing your code. smile

-- AndyPryke - 20 Feb 2006

Well, you can find the CSS I use in ActionTrackerPlugin topic (file atp.css). You can link it directly in twiki.{skin}.tmpl and edit.action.tmpl or you can copy/paste the content of this CSS to the skin's CSS...

-- RichardBaar - 20 Feb 2006

Thanks Richard. It works fine for me now - much prettier smile

I added the CSS variable to my ActionTrackerPlugin page as below

I also modified twiki.pattern.tmpl as this appears to be where other css files are included.

Diffs for twiki.pattern.tmpl

*** 30,35 ****
--- 30,37 ----
        @import url("/p/pub/TWiki04x01/PatternSkin/style.css");
        /* Custom overriding layout per web or per topic */
        @import url("");
+       /* Add ActionTrackerPlugin CSS to format tables containing actions */
+       @import url("%ACTIONTRACKERPLUGIN_CSS%");
        /* Custom overriding style per web or per topic */
        @import url("");
        .twikiToc li {

-- AndyPryke - 27 Feb 2006

Suggestions:

  • Heading level issue (use level one only once on top)
  • TextFormattingRules link is broken (just above SHORTDESCRIPTION)
  • Left & right cell align problem in Info table
  • Missing Appraisal row

-- PeterThoeny - 28 Feb 2006

I'm try the ActionTrackerPlugin under TWiki4.0.1 and the actionnotify script as follows:

%ACTION{due="20-Mar-2006" creator="Main.RudiRose" uid="000005" state="open" created="21-Mar-2006" who="Main.RudiRose" closer="" notify="Main.GregorSchortmann" }% Planung für Wartung .....

After changing some one I run the actionnotify script but the User in the field notify="Main.GregorSchortmann" not informed via mail. Look at this.

server:/srv/www/twiki/bin # ../tools/actionnotify changedsince="now" DEBUG | grep To:
To: rose@gutenberg-rz.de

Any idea?

-- RudiRose - 27 Mar 2006

So, i'm confised... will Richard's version work on Dakar? If not, will it be likely that some of the new things will make it into the standard release?

-- JosMaccabiani - 26 Apr 2006

Not unless someone does the work. Quite simply, I don't have time, unless someone is paying me to do it. Here's my changes policy:

  1. I will fix bugs, when I have the time
  2. I will code any enhahncements required by paying clients, and release these into the public domain if possible
  3. I will happily apply minor patches, as long as the unit tests are updated, and pass, and the changes are adequately documented
  4. I would be delighted to accept changes checked into Subversion (on branch TWikiRelease04x00? ), as long as the unit tests are updated, and pass, and the changes are adequately documented
    • Coders working in Subversion who observe these constraints are welcome to release new versions
    • I will revert any changes that do not observe these constraints
Just in case that isn't quite clear,
  1. I will ignore new versions posted here a.k.a "Thrown over the wall"
  2. I will ignore changes that are not supported by tests a.k.a "russian roulette"
  3. I will ignore inadequately documented changes ("To device activate, press nipple beyond point of travel")

Does that sound fair?

-- CrawfordCurrie - 27 Apr 2006

Fair enough wink
Thanks for (sharing) all your work so far!

-- JosMaccabiani - 05 May 2006

I've come up with a version of ActionTrackerPluginQBE? which generates a form which handles the selected options better (using %IF{}%). It also works around some of the features in the current version of the ActionTracker? plugin. It works with 4.0.2. I've attached it here: Bugs:Item2307

-- DiabJerius - 17 May 2006

Diab, thanks a lot, this form now works perfectly!

-- JosMaccabiani - 18 May 2006

Anyone have a clue why my none of my %ACTIONSEARCH{}% statments match any actions in dakar, with the latest (28th Feb 2006) version of this plugin ?

The plugin has installed OK, all my old actions still exist, and I can create and edit actions without problems, but all my action searches return no results.

Any clues for debugging would be appreciated.

-- SteveJonesST - 19 May 2006

We've been using this Plugin for a while now in a meeting minutes application. Overall, we're very pleased at what it does - keeping track of actions used to be a pain for one person responsible, now it's more of a distributed effort.

By using it, we've come across some WIBNIFs:

  • Twiki has made a graphical shift from 3 to 4, and because of that the action skin looks a bit dated. It would be nice if someone could at some point beautify the skin
  • The popup window not closing is freaking out the casual users, especially since some of them use the largest font available in IE on a 15" monitor. They don't get the new window filling up their screen :-). Would it be possible to explain how to modify something to allow 'unsafe' window closing?
  • A more fundamental issue is this: most actions are defined in weekly meeting A, are monitored in meetings B and C and then closed in meeting D. The nice thing about this plugin is that progress can be reported in the action description. However, since this action is stored in the topic where it is created, users can only know which action changed by reading old meeting minutes. Also, when a few actions are modified in a meeting, users get notification reports from several meeting minutes topics. I don't really have a solution to this. Perhaps storing the actions in separate numbered topics and only saving the changes in the minutes topics would be some workaround to this...
  • the action descriptions can get quite large, and this can yield the topic hard to view. Would it be possible to add some kind of Twisty functionality to the action template?

Anyway, lots of wishes which are much easier to express than they are to grant. I hope this helps in some way, somewhere along the line though.

-- JosMaccabiani - 24 May 2006

The doco about notification says this:

0 * * * * cd /home/twiki/bin && ../tools/actionnotify "state=\"late\""

You can avoid all that backslashing by using single quotes:

0 * * * * cd /home/twiki/bin && ../tools/actionnotify 'state="late"'

-- MartinGregory - 30 May 2006

Demanding that contributors write unit tests for the plugin is the same as cutting off the major bulk of possible future contributions. I just looked at the test case and you have to be pretty strong in object oriented perl to write even the smallest enhancements.

You do not have to be very skilled programmer to modifying existing code or make a template look nicer. But if it is required to write the very advanced test cases in perl to do modifications of this plugin then I think it is better that someone branches off a FreeActionTrackerPlugin? or OpenActionTrackerPlugin? . There are so many good enhancements piling up on this dev topic which are not being integrated and implemented and released. I encourage the contributors to not be put down by the very tough development requirements setup for this plugin and instead just create a new.

I would hope it will still be possible to write plugins for TWiki without having to be a full time, 15 years experience, professionel programmer with 1000s of hour experience in the TWiki code. It is however reasonable that you test your contributions carefully and document the enhancements properly. Anyone has the skills to do that.

-- KennethLavrsen - 22 Jun 2006

I'm with you there, Kenneth. I don't have a clue how to write a unit test. I suspect there are very few people who have a clue, even among the core developers.

-- MeredithLesly - 22 Jun 2006

I am having the hardest time writing a line in apache's crontab to have actionnotify e-mail users in the 'notify' field when an action item is CLOSED. (idealy it would check every hour for items that have been closed in the last hour.)

I've tried numerous different ways of writing it, including:

  • 0 * * * * _wikisite_/tools/actionnotify 'web=".*" state="closed" closed="1 hour ago"'
  • 0 0,6,12,18 * * * _wikisite_/tools/actionnotify 'web=".*" changedsince="now - 6 hours"'
  • plus numerous other ways to describe time in changedsince or closed.

I have another line in my crontab that alerts users of open items, and that one works fine. Also, in my settings, I have Set NOTIFYCHANGES = $state so that it only emails when the state changes.

Thanks for your hints/help.

-- EricVlach - 23 Jun 2006

Kenneth, Meredith, I'm sorry you feel that the time and effort I invested in writing a comprehensive set of unit tests for this plugin was wasted. Because as soon as people start making aribitrary changes without updating the tests, that's exactly what that effort will have been. Wasted. Of course it is possible to write plugins for TWiki with limited experience, and without writing unit tests; but this is a complex plugin, and I for one don't want untested changes hacked into it, thank you very much.

Eric, to check and notify items that made the transition to closed state in the last hour, you should be able to use the following:

0 * * * * _wikisite_/tools/actionnotify 'web=".*" state="closed" closed=">1 hour ago"'
Date matches support a limited range of conditions: >, <, >=,<=; all relative to now

-- CrawfordCurrie - 25 Jun 2006

I have tried now for 3 hours. I cannot make actionnotify do what the docs says should work.

actionnotify 'created="> 1 hour ago"'

What my users want is an email when someone have created an actionitem with their name in the "who" field. So my plan was to run a cron job once per hour sending emails to people when a new action is created and the email should go to the person the action is assigned to.

-- KennethLavrsen - 17 Jul 2006

I can't get ACTIONSEARCH to work. I have 2 actions

%ACTION{ state="open" creator="Main.WayneDahl" notify="Main.WayneDahl" closer="" closed="10-Aug-2006" due="9-Aug-2006" who="Main.WayneDahl" created="10-Aug-2006" uid="000001" }% An action for Wayne

and %ACTION{ state="open" creator="Main.WayneDahl" due="12-Aug-2006" created="11-Aug-2006" who="Main.WayneDahl" uid="000002" }% An action for Wayne

and a search that looks like

%ACTIONSEARCH{who="WayneDahl"}%

The ACTIONSEARCH shows the table headers but no actions are listed.

-- WayneDahl - 11 Aug 2006

In the documentation for this plugin, perhaps you should document %COMMENT{mode="action"}%, which allows a non-edit way of creating actions using this template http://twiki.org/cgi-bin/view/TWiki/CommentPluginTemplate#action.

-- BrendanDoherty - 13 Aug 2006

Are there some detail guides on how to configure Richard'ATP_modifications.zip? I unzip it in twiki and override other version, It does not work.

-- QinglongXie - 01 Sep 2006

Hi. Can't seem to get actionnotify to work on 4.0.4. I'm trying to debug on the command line (not cron), typing : cd ../tools/actionnotify state="late"

and all I get is :

<H1>Software error:</H1>
<CODE>Can't use string (&quot;1&quot;) as an ARRAY ref while &quot;strict refs&quot; in use at /design/TWiki/twiki/lib/TWiki/Func.pm line 1620.
</CODE>
<P>
For help, please send mail to this site's webmaster, giving this error message 
and the time and date of the error.

[Fri Sep  8 12:50:57 2006] actionnotify: Can't use string ("1") as an ARRAY ref while "strict refs" in use at /design/TWiki/twiki/lib/TWiki/Func.pm line 1620.

Please can someone (Crawford ?) help me debug this. The install is live, and users on three continents are moaning. Thanks, Steve.

-- SteveJonesST - 08 Sep 2006

Not sure if this is related, but the actionnotify script must be run from the bin directory (so that it can find the libs). Try this:
cd twiki/bin; ../tools/actionnotify state="late"

-- PeterThoeny - 10 Sep 2006

Steve, the error comes about because you have at least one user with no email address - worse, the method that recovers emails for a user is returning a non-email, suggesting that you might be using a broken user handler. What is your login/password/usermapping setup?

-- CrawfordCurrie - 10 Sep 2006

Hi Crawford. Login scheme is TWiki::Client::ApacheLogin, and passwords are TWiki::Users::HtPasswdUser. There's no usermapping setup. After your hints, I corrected the .htpasswd file and added some missing email addresses, after this, the error is very slightly different :

actionnotify: Can't use string ("0") as an ARRAY ref etc...

Notice '0' instead of '1' above. Any clues really appreciated.

-- SteveJonesST - 11 Sep 2006

Again, it's an indicator that a TWiki user doesn't have an email address for some reason.

You ought to have TWikiUserMapping selected I think.

-- CrawfordCurrie - 12 Sep 2006

Ok, I have TWikiUserMapping selected. I got the point about an unresolved email address, but I have over 400 users - what's the easiest way to find out who doesn't have an email address ? Everybody in the .htpasswd has some kind of email in the last field. Sorry if this is a stupid question. In what way has finding the correct email changed from cairo - I had no issues until I moved to dakar.

-- SteveJonesST - 12 Sep 2006

Sorry to bump this again, but can someone confirm where I should be looking for the user without an email address. Email addresses seem to be stored in one of three places :

  • in the .htpasswd file - all users seem to have one here.
  • pre-dakar, as a string in their home page.
  • post-dakar, as a formfield on their home page.

Which mechanism is this actionnotify using ? How can I get some more debug info to track down the source of the problem. C'mon I know somebody out there can help me...

-- SteveJonesST - 14 Sep 2006

ALERT! Bug: The leading white-space characters in an << description are being deleted, causing problems with formatting.

There are two aspects to that: (i) in Action::new the white spaces are stripped out, and also (ii) when saving an action.

It would help me understand why this is being done, and also, why newlines are being translated in Action::new into XHTML tags. Why can we not rely on standard TWiki processing to take care of these things?

-- ThomasWeigert - 20 Sep 2006

I have made adjustments to ActionTrackerPlugin to allow fields in the generated tables to have proper formatting such as bullet lists, etc. I still need to run the unit tests to make sure that there are no unpleasant side effects.

-- ThomasWeigert - 21 Sep 2006

Note that there are currently 5 unit tests that fail on the original ActionTrackerPlugin code.

-- ThomasWeigert - 21 Sep 2006

Thanks Thomas; I'll take a look. BTW can you report bugs in Bugs web, please; I'm rarely here.

-- CrawfordCurrie - 21 Sep 2006

Just to be clear, I have not checked in my updates as I first want to understand why the code is the way it is. Maybe there is a good reason.

Maybe this is not considered a bug, but a design, not to render bullet lists, etc., in the actions. This was not feasible in TWiki forms either earlier...

The failing test cases that I mentioned are with the existing system... unfortunately, these test cases are less than clear to me so I cannot quite make out what they are actually doing.

-- ThomasWeigert - 21 Sep 2006

Is there some way to search for an unspecified attribute? For example, I have a custom attribute defined named "priority", that's defined as "select,3,|high|medium|low|". I'd like to do a search that finds all the actions that do not have a "priority" field defined. Anybody have an idea?

-- AaronSher - 25 Sep 2006

Steve, I can't reproduce that problem any more. Are you still having issues?

Thomas, all the testcases now pass (subversion)

Aaron, no, I didn't code that. Someone may have worked out a trick, though.

-- CrawfordCurrie - 26 Sep 2006

Thanks, Crawford. Still have the same problem. I take your word that a user may be missing an email address somewhere, but I can't find it. All users in .htpasswd have an email address - where else should I be looking ? If you can help me debug, I'd appreciate it.

-- SteveJonesST - 26 Sep 2006

I noticed that fields in the generated tables do not have proper formatting such a bullet list, etc. Acction.diff - 5 out of 7 hunks FAILED.

-- AnnaPapierz - 27 Sep 2006

OK, alternate question - is there a way to make a custom attribute required, in the same way that the predefined attributes like "state" are required (i.e. it gets filled in automatically when you save the action tag)? Ideally, I'd also be able to select a default value for the attribute.

-- AaronSher - 27 Sep 2006

Any updates on the issue described by SteveJonesST? ? I am experiencing the same issue.

My TWiki Configuration is set to;

LoginManager: TWiki::Client::ApacheLogin

MapUserToWikieName: DONE

Cron jobs return the same error;

Can't use string ("1") as an ARRAY ref while "strict refs" in use at /home/twiki/html/lib/TWiki/Func.pm line 1620.

I have verified that all Wiki Users in the .htpasswd file have associated e-mail addresses. I manually added e-mail addresses for Twiki Users user pages for those that had not put one in (possible as I only have about 8 registered users)

Any ideas on what could be causing this issue? Could it be modified to ignore null/not found addresses, and continue on error?

-- JamesMontz - 10 Oct 2006

Without being able to reproduce it, I have no way to tell. I am reliant on one of you putting on your thinking caps and debugging it. At the very least you have to share what version of TWiki you are running, and what version of AT.

-- CrawfordCurrie - 11 Oct 2006

Is anybody able to update changes provided by NielsKoldso? We miss possibility to use TWiki ML in actions.

-- JacekZapotoczny - 11 Oct 2006

I am using TWiki 4.0.4, Build 10807. ActionTracker? : 11560.

-- JamesMontz - 11 Oct 2006

I can't get ACTIONSEARCH to work. I have 2 actions

%ACTION{ state="open" creator="Main.SandeepRao" notify="Main.SandeepRao" closer="" closed="10-Aug-2006" due="9-Aug-2006" who="Main.SandeepRao" created="10-Aug-2006" uid="000001" }% An action for Sandeep

and %ACTION{ state="open" creator="Main.SandeepRao" due="12-Aug-2006" created="11-Aug-2006" who="Main.SandeepRao" uid="000002" }% An action for Sandeep

and a search that looks like

%ACTIONSEARCH{who="SandeepRao"}%

The ACTIONSEARCH shows the table headers but no actions are listed.

Any tips on how to resolve this issue is appreciated!!!!!!!!

-- SandeepRao - 24 Oct 2006

If you do not specify in ACTIONSEARCH the webs to search the default is to search only the current web. So if your ACTIONSEARCH is on the other web than ACTIONS, the ACTIONS will not be found without specifying web to search.

-- AnnaPapierz - 25 Oct 2006

My search is in the same web, I also tried with adding webname to the filter but didn't help. It just doesn't work. I am wondering what could be the reason as I can see there are a bunch of other people listed here who have been using it effectively. Any ideas?

-- SandeepRao - 25 Oct 2006

Regarding allow TWiki rendering

  • I have provided new diffs for Dakar r11560
  • Any chance they will make it into next release?

TIA smile
-- NielsKoldso - 26 Oct 2006

I got the Action Search to work finally. My test environment is Win/PC. First, I had to install gnu grep programs. I used this one - http://gnuwin32.sourceforge.net/packages/grep.htm. Then, I changed search settings in Configure to use grep.exe instead of egrep and fgrep. This enabled TWiki search but Action Search still didn't work (Action Search uses TWiki search). Then, I changed code in ActionSet? .pm to use default search ('') instead of regex search ('regex'). Here is the change:

TWiki::Func::searchInWebContent( 'ACTION', $web, \@tops, { type => '', files_without_match => 1, casesensitive => 1 } );

This worked for me, and I can see all Action Items now (as specified in search criteria). I am not sure if this is the best way to get this to work, but at least one way to proceed. I will appreciate if someone knowledgable on this plugin can reflect on this. Thanks!

-- SandeepRao - 30 Oct 2006

We are running Dakar on two servers. Linux, apachefriends, Fedora5

We have on several pages some actions. Pressing the "edit" link gives the user the chance to edit the action. However if the "edit" link of the last action is used, all newlines from this action to the next text (ex: ---+ next heading) is deleted. The EditActionTracker button is then placed AFTER this text (ex: ---+ next heading). Pressing the EditActionTracker button creates a new actiontable in stead of adding the new action to the existing actiontable.

Can this be solved?

-- RichardVinke - 10 Nov 2006

I am having this problem also. Action edits (that come up in the window) when saved lose some of the other other actions from the page.

Running are running ActionTracker? on linux server

-Tandeep >>We have on several pages some actions. Pressing the "edit" link gives the user the chance to edit the action. However if the "edit" link of the last action is used, all newlines from this action to the next text (ex: ---+ next heading) is deleted. The EditActionTracker? button is then placed AFTER this text (ex: ---+ next heading). Pressing the EditActionTracker? button creates a new actiontable in stead of adding the new action to the existing actiontable.

-- TandeepSidhu - 23 Nov 2006

I am unable to reproduce this problem from the description above. Please provide more details, including what other plugins are installed and the full text of a topic that illustrates the problem, and please report it in Bugs web as requested at the top of the page. I rarely visit this topic.

-- CrawfordCurrie - 24 Nov 2006

Problem reported by SteveJonesST - 08 Sep 2006 is caused by a buggy return-statement in TWiki::Func::wikiToEmail in Dakar 4.04 - it is fixed in 4.05.

-- NielsKoldso - 26 Nov 2006

Sorry for the delay. I had my holiday. cool! I use Dakar 4.04. I will update to 4.05 as soon as I am at the office and report the results here. CrawfordCurrie? : I did report this in the bugs web. wink

Edit: The update did not solve my problem. It looks like the "edit" button calls a clean statement, which deletes the empty lines. I cannot find this. Does anyone know where and how to find this?

-- RichardVinke - 11 Dec 2006

Note that Richard's problem is with the EDITACTIONTRACKER feature, which is unreleased. Could the developer of this feature please answer Richard? Ta.

-- CrawfordCurrie - 13 Dec 2006

Non-standard Attributes not working in 4.0.5 I have added in WebPreferences of my WEB as * Set ACTIONTRACKERPLUGIN_TABLEHEADER = | Assigned to | Due date | Description | State | Notify | Priority | Update | Categories | Closed date || * Set ACTIONTRACKERPLUGIN_TABLEFORMAT = | $who | $due | $text | $state | $notify | $priority | $update | $categories | $closed | $edit | * Set ACTIONTRACKERPLUGIN_EXTRAS = | priority,select,1,"high","medium","low" | update,text,16 | categories,select,1,"Spec","Design","Sim","Layout","BA","Si Char","Si Debug" | It does not reflect the extra fields

-- ArunLuther - 14 Dec 2006

Is there anything else I have to do to get it work properly?

-- ArunLuther - 15 Dec 2006

As an alternative, I'm passing $web with TWiki::Func::getPreferencesValue( "ACTIONTRACKERPLUGIN_TABLEHEADER",$web ) under _lazyInit function of ActionTrackerPlugin.pm

-- ArunLuther - 15 Dec 2006

Arun, without knowing your configuration etc. it's impossible to guess what you have done wrong. Please follow the instructions in Support web and raise a question that provides sufficient info to let someone help you. This topic is really for dev discussions, not support.

-- CrawfordCurrie - 16 Dec 2006

I would like to notify my TWiki users everytime an action item is assigned to them. I tried to use the created parameter in my cron job and set it like this:

0 */1 * * * cd /var/www/twiki/bin && ../tools/actionnotify 'created="> 1 hour ago"'

But I did not achieve the desired result. A quick glance at the Action.pm script (see below) shows that the created parameter is automatically populated with the current system date, but without any time information. When the created parameter only stores date, how can the ActionTracker? find out if the action was created 'n' hour ago?

    if ( !defined( $this->{created} )) {
        $this->{created} = $now;
    }

-- AlokNarula - 02 Jan 2007

It can't. I made a concious design decision to use only the calendar date rather than the time for actions, because my team at the time was globally distributed and using the time was going to get really irritating. It would be perfectly feasible - though an awful lot of work - to convert it to use the time as well, should you wish to do so.

-- CrawfordCurrie - 03 Jan 2007

Crawford, thanks for clarifying. In order to notify TWiki users of action items created for them, I created another state "actioning" via the EXTRAS setting and I set the cron job as below:

0 */1 * * * cd /var/www/twiki/bin && ../tools/actionnotify state=\"actioning\"
Now, when I create any action item, it is set to actioning by default. The TWiki user gets a notification that an action item is set for him/her. The TWiki user changes the state to open. This sets the cron job off.

-- AlokNarula - 03 Jan 2007

I figured out a way of easily creating action items for people. Check UserCommentsTemplate#Add_action_items_with_ease? to see how it works. With this template you don't have to remember people's names. You can select the assignee's from a drop-down list. The example in Sandbox uses a sample. Customize this template for your TWiki server.

Here is a snapshot of my action tracking template: ActionTrackerPluginDev?rev=1;filename=action_tracking_example.JPG

Thanks to PeterThoeny for showing me how to store search results in a variable.

-- AlokNarula - 04 Jan 2007

Enchancements to improve the actionnotify operation:

  1. Generate the keys in sorted order so they don't re-order themselves randomly.
  2. Allow actionnotify be able to specify the "age=X" parameter
  3. Allow actionnotify be able to specify the "duedays=X" parameter

Example usage in a crontab:

#
# TWiki Action Tracker Notification Support
#
#     - Late AI, get notified 3 times per week, on Mon, Wed, and Fri
#     - AI due in 3 days, get notified once per day
#     - AI due in 7 days, get notified once per day
#     - When an AI gets created, get notified on that day
#
  21   23  *   * 1,3,5 (cd /var/www/twiki/tools; perl -I ../bin ./actionnotify state=late)
  22   01  *   *   *   (cd /var/www/twiki/tools; perl -I ../bin ./actionnotify state=open duedays=3)
  23   01  *   *   *   (cd /var/www/twiki/tools; perl -I ../bin ./actionnotify state=open duedays=7)
  24   23  *   *   *   (cd /var/www/twiki/tools; perl -I ../bin ./actionnotify state=open age=0)
  25   23  *   *   *   (cd /var/www/twiki/tools; perl -I ../bin ./actionnotify changedsince=yesterday)

--- lib/TWiki/Plugins/ActionTrackerPlugin/Action.pm   2007/01/10 17:00:08   1.1
+++ lib/TWiki/Plugins/ActionTrackerPlugin/Action.pm   2007/01/10 17:06:01
@@ -117,6 +117,10 @@
    new TWiki::Plugins::ActionTrackerPlugin::AttrDef( 'names', $nw, 1, 0, undef ),
    within       =>
    new TWiki::Plugins::ActionTrackerPlugin::AttrDef( 'noload', 0, 1, 0, undef ),
+   duedays      =>
+   new TWiki::Plugins::ActionTrackerPlugin::AttrDef( 'noload', 0, 1, 0, undef ),
+   age          =>
+   new TWiki::Plugins::ActionTrackerPlugin::AttrDef( 'noload', 0, 1, 0, undef ),
    ACTION_NUMBER=>
    new TWiki::Plugins::ActionTrackerPlugin::AttrDef( 'noload', 0, 0, 0, undef ),
   );
@@ -329,7 +333,7 @@
     my $this = shift;
     my $attrs = '';
     my $descr = '';
-    foreach my $key ( keys %$this ) {
+    foreach my $key ( sort ( keys %$this ) ) {
         my $type = $types{$key};
         if ( $key eq 'text') {
             $descr = $this->{text};
@@ -439,6 +443,15 @@
     }
 }
 
+# PUBLIC return how many days old the action item is.
+sub daysOld {
+    my $this = shift;
+    if ( defined ($this->{created} )) {
+   return ($now - $this->{created}) / 86400;
+    }
+    return -1;
+}
+
 # PUBLIC true if due time is before now and not closed
 sub isLate {
     my $this = shift;
@@ -495,6 +508,28 @@
     }
 }
 
+# PRIVATE match if there are at exactly $val duedays to go before
+# action falls due
+sub _matchField_duedays {
+    my ( $this, $val ) = @_;
+    my $slack = $this->secsToGo() - $val * 864