Version 27 of The Next Generation Tcl Chatroom

Updated 2008-01-17 23:43:06 by dkf

10Nov2004 Pascal Scheffers

We need a new chatroom. There have been discussions of replacing the CGI version in the past, but the current effort by Reinhard Max and me seems to come closest to actually providing all we need.

How?

We are using a Jabber server as the chatserver. We have also added jabber client support to TkChat, this means that you can keep on using tkchat, including all of its features.


15Nov2004 The New Room Is Now Connected To IRC and the WebChat

Pat Thoyts has created a Tcl version of ijchain, which is currently connecting the Jabber Room and the IRC channel together. This means anything said in the new room is instantly visible on the IRC channel and vice versa. Because (irc|az)bridge relays these messages to the webchat, all three rooms are now connected together.

Thank you Pat! What can I say but Join the new chat now! You can talk to everyone from the jabber side with little noticable difference (except for the fact that the jabber based chat is much more responsive, of course).


Using the new chat

Just use the latest tkchat.kit from sdarchive [L1 ] and on the login screen select 'use jabber server (experimental)', hit logon and you will be prompted to create an account (first time only...).

Alternatively, if you want to use the CVS version, grab http://tclers.tk/conferences/tcl/jlib.tar.gz and extract that in your under the tckhat directory.

For other jabber clients like tkabber and coccinella:

 Server: all.tclers.tk, port 5222
 Conference Room: [email protected]

Please go and try it out! We need feedback.

Connecting through a proxy

Configure tkchat to use your proxy server, if you were already using a proxy with tkchat, you do not need to change anything.

When you are behind a proxy/firewall which does not allow CONNECTing to port 5222, you should use a different chat server to connect to. You also need to download the TLS kit from sdarchive, [L2 ] has support for Linux, MacOSX, OpenBSD, Solaris and Windows, [L3 ] has support for windows only, [L4 ] has support for Linux only. Just save the tls(-*).kit to the same folder/directory as tkchat.kit.

Set the jabber server:port to:

 Server: all.tclers.tk
 Port: 443

And enable 'Use Jabber SSL'.

That is it. You'll be asked for a jabber username, don't worry too much if your prefered nick is not available anymore - your nick in the conference room/chat does not need to be the same as your login name - and tkchat will remember it for you! Just do a '/nick somename' once you are connected.


LV Question about the Tls support. Has the tls support been tested on SPARC Solaris? I ask because when I try it, on a SPARC Solaris 8 machine, I get this error:

 $ tkchat.kit           
 couldn't load library "/volws/lwv28/ldatae/bin/tls.kit/lib/tls/SunOS-sparc/tls.so": no such file or directory
    while executing
 "load /volws/lwv28/ldatae/bin/tls.kit/lib/tls/SunOS-sparc/tls.so "
    ("package ifneeded" script)
    invoked from within
 "package require tls"
    ("foreach" body line 4)
    invoked from within
 "foreach tlsname {tls.kit tls-win.kit tls-lin.kit} {    
    if { [file exists [file join $kitdir $tlsname]] } {
        source [file join $kitdir $tls..."
    (file "/volws/lwv28/ldatae/bin/tkchat.kit/main.tcl" line 5)
    invoked from within
 "source /volws/lwv28/ldatae/bin/tkchat.kit/main.tcl"
    ("uplevel" body line 1)
    invoked from within
 "uplevel [list source [file join $self main.tcl]]"

Interestingly enough - when I do an sdx.kit lsk tls.kit , I notice there is no SunOS-sparc directory but instead a Solaris-sparc directory...

So, I rename the Solaris-sparc directory to SunOS-sparc, and discover that this isn't the end of the tls.kit problems, because tls.so has a dependency on libssl . So, I locate my local tls.so file, replace the one in the kit with that, add in the libssl (and libcrypt , which apparently also is needed), rewrap the tls.kit and now the tkchat starts up.


Requirements for the new chat

We set ourselves a number of basic requirements for the new chat:

  • Must work for people with really nasty firewalls/proxies (only CONNECT on port 443, or worse, only HTTP)
  • Must have a log of what has been said, kept for a few days
  • Must work with tkchat and its commonly used features
  • Must allow the irc.freenode.net#Tcl chatters to join us
  • Preferably have a web interface from day one
  • It should allow us to extend tkchat to do interesting things, like the World-wide whiteboard, without visual noise for other chatters.
  • Scale better: during the 2004 Tcl Conference, the chat almost died from having 30 chatters at the same time.

Why Jabber?

We chose jabber for a number of reasons. The obvious other choice would have been IRC, but jabber seemed to match our requirements better.

Reasons (in no particular order):

  • Network admins are not as hostile to jabber as they are to IRC; a lot more firewalls let jabber pass through.
  • The jabber protocols are IETF standards (yes, IRC too)
  • jabberd/mu-conference has built in chat logging capabilities
  • jabber allows us to keep nick coloring
  • the jabber protocol allows messages of arbitrary length (IRC is line oriented)

What about the IRC people?

You come next - we have ijchain, which is similar to irc/azbridge, we will be running this from day 1. The next step is to make jabber users appear as true IRC users and vice-versa. We have some ideas, it will be done. Nobody will come second in the Tcl community! Jabber and IRC are a much closer match to one and another than chat.cgi and IRC were, so we can solve this rather elegantly.

DG If ijchain is found to "not cut it", I can help with a new xmpp->IRC gateway using my irc_engine client extension for my XiRCON-II client.


Known issues in tkchat (1.216)

  • Userinfo doesn't work yet.
  • Warning: /me actions ARE LOGGED! There is a menu option and a /log /nolog command pair to prevent your words from entering the logs. The menu allows you to set the old default where /me actions are not logged. Use /nolog/me for a single, not logged action - please suggest a good alternative command name for that (someone suggested /snide, I'd like something more positive...)
           whisper?
           [ps] hmm. /msg is called a whisper at the moment too... 

As of 1.216 logout works correctly, and history only loads once during a session.


davidw - I would not ever assume that you aren't being logged. Anyone connected to the chat could be logging what you say. You might even end up on http://bash.org ;-)


LV I have a problem trying to use the experimental jabber code. I select the login menu. I get the dialog box. I selected jabber experimental. This gave me a jabber server site of Scheffers.net . I left that, selected logon and get this error:

 couldn't open socket: connection refused
 couldn't open socket: connection refused
   ...

PS Whups! No, that is the wrong server - which would have still worked had my server not crashed today. The right servername for the jabber server is 'all.tclers.tk', same port (5222).


LV Looks like the current tkchat.kit has the server name fixed. Thanks! Any chance that the tkchat.kit has code in place so the user can update the kit when tkchat.tcl is updated in the CVS?

PT The "Debug->Retrieve script" menu item should be working fine. This grabs the code from the web front-end to the pserver cvs and so can lag slightly behind the developer cvs. But not usually by more than a day.

LV I'm a bit confused. I download the tkchat.kit . I start it. I select Debug->Retrieve. I get a dialog box asking me where to save the new version of tkchat. I indicate I want it saved as /var/tmp/tk . A file called /var/tmp/tk.tcl is created. It is tkchat.tcl - the script from the cvs. Does the .kit then read that file and write it into the tkchat.kit ? Or does the user have to do the step of updating the kit his/herself manually?

jcw - Don't know about the above, but if tkchat.kit on sdarchive is the latest revision, then "sdx update tkchat.kit" will update your local copy.


Suggestions?

Document what we can do about the lines of stdout like:

 <A HREF="([0-9\-%d]+\.tcl)">.*\s([0-9]+) bytes 

that the new tkchat.kit keeps spitting out to stdout.


Ruffy Got myself a 2003 PocketPC running eTcl - but I can't get the unicodes to appear - I tried Hebrew "\u5d0". Anybody?