Forum OpenACS Q&A: Status of Wiki Package?

Collapse
Posted by Frank Bergmann on
Hi,

I've tried to install the openacs-4/packages/wiki package on a Win2k/Postgres 7.3 OpenACS system and I get the following error right during installing:

invalid command name "content::folder::new"

I'm not sure if this is due to the Win2k platform, but I really don't think so. Did somebody else get the same issue?

Bests,
Frank

mailto:frank-dot-bergmann-at-project-dash-open-dot-com
http://www.project-open.com/

Collapse
Posted by Dave Bauer on
The wiki package will only work with OpenACS 5.1.4 or greater.
Collapse
Posted by Frank Bergmann on
Hi Dave,

I managed to get the wiki package running after a "dirty" upgrade from 5.1.0 to 5.1.4 (just copied in the tcl pages and randomly executed some update scripts...).

Thanks a lot for your work. The code looks clean and easy.

However, I'd probably need some extensions for the wiki that I'm planning (about "Localization Project Management"), because I want it to be completely publicly editable, but with the option to reverse changes and to block certain specific pages (such as the index):

- Publicly editable pages
- Change history and the option to reverse changes
- Email notification on changes

Any plans to advance with these?

I'm probably going to add them myself if there are no plans from your side. Do you have any preference how I should return the code to you?

Bests,
Frank

Collapse
4: Re: Status of Wiki Package (response to 1)
Posted by Dave Bauer on
These sound like good plans. As long as you make the public or registration required feature a configuration option, I think you can just go ahead and make these changes.

One thing I really wanted to do with this package is write a parser for the MediaWiki syxtax used at Wikipedia since the Wikit syntax is quite limited.

Collapse
Posted by Frank Bergmann on
Hi Dave,

I think I will very soon need an admin screen for the Wiki with the following features:

- Lists all currently available pages with basic information such as title, last modified and permissions by group (Public, Registered Users, Wiki Admins)

- Show the list of recent (~10?) modifications/revisions for each page. This would result in a matrix structure with variable length but fixed width.

- Add an "activate" button or something similar to each revision from the list to revert the content of a page to a previous one if a user did some strange editing...

Shouldn't really be that difficult... It's only that I'm not too familiar with the CR.

Anyway, the first results are available at http://projop.dnsalias.com/l10n-pm/

Bests,
Frank

Collapse
6: Wiki Permissions Design (response to 1)
Posted by Frank Bergmann on
Hi Dave,

I'm now going to start with the "Recent Changes" page (to reverse changes) and with introducing permissions.

Concerning permissions: I'm probably going to simplify this and to add all content items with a context of the "package" or the "cr_folder". Any preferences? I guess there is only one cr_folder?

Bests,
Frank

Collapse
Posted by Dave Bauer on
Sure. I would think the items for each page already have the cr_folder as the context_id. A wiki is usually a flat url space so one folder should do the trick.
Collapse
Posted by Frank Bergmann on
Hi,

yes, worked out like you said, cr_folders is the way to go.

However, I've got an issue with the "Recent Changes" page. I would like to avoid showing several (intermediate) cr_revisions ans instead say something like: "Look, here is the lastes approved version of the content. And here is the most recent one". However, there is no status field available for cr_revisions or an additional "latest_approved" version at cr_items.

Not sure what I should do.
- Maybe sacrifice usability and go for ease of implementation (just show the latest version and a link to the CMS item editing screen)?
- Maybe add a column to cr_items (ugly, ugly...)?
- Use an extension table to add the status information to cr_items?
- ... any idea?

I've found one bug in the Wiki package so far. I'll send you the stuff once I'm ready, ok?

Bests,
Frank

Collapse
Posted by Dave Bauer on
Frank

cr_items.latest_revision is the most recent edit.
cr_items.live_revision is the "approved" revision.

This should do what you need, I think, should the currently displayed version, and the most recently edited version.

Collapse
Posted by Frank Bergmann on
Sure, correct, but:

I believe that modified Wiki contents should go live immediately, as you have implemented it.

So the latest version is always approved. That's how I find it in the DB...

Maybe we could modify the way your Wiki code works, show always the latest version and use the live_version for approval?

That sounds reasonable, I'll check.

Frank

Collapse
Posted by Dave Bauer on
I think you can add a parameter, and check that to see if the new entries go live immediately or not.
Collapse
Posted by Frank Bergmann on
Hi Dave,

I have finally used the CR "live_version" as a kind of "confirmed version" while always showing the CR "latest_version" in the Wiki "page.tcl". That's not exactly the semantics you would expect from the CR, but I guess it's ok. Atleast it's convenient and avoids adding columns or extension tables.

I've added:

- /packages/wiki/admin/index*: A admin page that lists all Wiki pages of the specified folder. This page shows you the "diff" between the latest confirmed version ("live_version") and the latest changes ("latest_version") and allows you to "confirm" or "revert".

- /packages/wiki/lib/footer*: Added a few more links

- /packages/wiki/lib/page.tcl: Modified according to the semantics above and fixed a bug (no item_id when creating a new item leads to SQL error when linking items).

You maybe have to cleanup the template setting before commiting to CVS.

Please find my tarball at: http://projop.dnsalias.com/wiki.050415.tgz

You can check the new Wiki version working at: http://projop.dnsalias.com/l10n-pm/

Bests,
Frank

Collapse
Posted by Dave Bauer on
Frank

Hmmm.

Ok, i thought you were proposing a sort of "moderation" feature where changes to the wiki did not go live immediately, and some sort of editor needed to approve them before they were visible. Is this not the case?

Collapse
Posted by Frank Bergmann on
Yes, correct.

It's just that I'm doing it the other way around: The updates go live immeditately (latest_version), but may be reversed to the latest approved version (live_version).

So the code behaves exactly like your original version.

Bests,
Frank

Collapse
Posted by Frank Bergmann on
Hi Dave,

I have just started to writeup some documentation on installing "wiki" and integrating it into Project/Open, when I'm falling over some code in ::content::revision::new in content-revision-procs.tcl:

set table_name "${table_name}i"

The procedure gives me an error when I try to mount the wiki package on /wiki/: "cr_revisionsi doesn't exist" or similar. How should that work?

I'm with OpenACS 5.1.4., but maybe there is a mismatch between the DB-model and the TCL code?

Bests,
Frank

Collapse
Posted by Frank Bergmann on
Ok, this was just an update issue from a 5.1.0 data model.
I'm now trying to install the Wiki on another system and I'm running in a few issues, so maybe I'll introduce some changes in the wiki module code.

Bests,
Frank

Collapse
Posted by David Kuczek on
Is there available code for displaying differences between revisions?

Example: http://en.wikipedia.org/w/index.php?title=Windows_XP&diff=0&oldid=14735625

Collapse
Posted by Frank Bergmann on
Hi,

no, there is no "diff" yet. However, we have added an interface package for Project/Open ("intranet-wiki") that shows you the wiki pages have been modified in the past and that allows you to confirm or reject changes.

In order to get the latest code please use:

cvs -d :pserver:mailto:anonymous@berlin.dnsalias.com:/home/cvsroot checkout wiki

and

cvs -d :pserver:mailto:anonymous@berlin.dnsalias.com:/home/cvsroot checkout intranet-wiki

You can see both packages in action at http://pcdemo.dnsalias.com/ (check the "Wiki" main menu and/or go to a specific project and check the wiki option). However, the administration (confirm/reject) option is only available for administrators. Please send me a private email in order to get access to an administrator's account.

Bests,
Frank