From dxpublica at telefonica.net Sun Nov 1 10:11:11 2009 From: dxpublica at telefonica.net (Xan) Date: Sun Nov 1 10:13:00 2009 Subject: [Sputnik-list] Debian installation Message-ID: <4AED88EF.7080202@telefonica.net> Hi, Can you say me how to install sputnik in debian lenny? I donwloaded sputnik-9.03.16-kaio and when I run "bash install.sh /home/xan/sputnik" I received: ~/sputnik-9.03.16-kaio ~/sputnik-9.03.16-kaio Kepler Installer version 0.4. The name of the Lua executable is lua Lua installation prefix: /home/xan/sputnik Include files: /home/xan/sputnik/include Proceed with setup? [Y/n] Installing Kepler from current directory... ========================================================= Installing Lua 5.1.4 on /home/xan/sputnik ========================================================= kepler-install-1.1.1-2: line 478: make: command not found kepler-install-1.1.1-2: line 480: make: command not found Done. Lua is installed on /home/xan/sputnik. ========================================================= Now installing LuaRocks 1.0.1 in /home/xan/sputnik. ========================================================= luarocks-1.0.1/ luarocks-1.0.1/src/ luarocks-1.0.1/src/bin/ luarocks-1.0.1/src/bin/luarocks luarocks-1.0.1/src/bin/luarocks-admin luarocks-1.0.1/src/luarocks/ luarocks-1.0.1/src/luarocks/fs/ luarocks-1.0.1/src/luarocks/fs/unix.lua luarocks-1.0.1/src/luarocks/fs/win32.lua luarocks-1.0.1/src/luarocks/persist.lua luarocks-1.0.1/src/luarocks/list.lua luarocks-1.0.1/src/luarocks/require.lua luarocks-1.0.1/src/luarocks/rep.lua luarocks-1.0.1/src/luarocks/make_manifest.lua luarocks-1.0.1/src/luarocks/command_line.lua luarocks-1.0.1/src/luarocks/install.lua luarocks-1.0.1/src/luarocks/build/ luarocks-1.0.1/src/luarocks/build/command.lua luarocks-1.0.1/src/luarocks/build/cmake.lua luarocks-1.0.1/src/luarocks/build/make.lua luarocks-1.0.1/src/luarocks/build/builtin.lua luarocks-1.0.1/src/luarocks/fetch/ luarocks-1.0.1/src/luarocks/fetch/cvs.lua luarocks-1.0.1/src/luarocks/fetch/git.lua luarocks-1.0.1/src/luarocks/fetch/sscm.lua luarocks-1.0.1/src/luarocks/pack.lua luarocks-1.0.1/src/luarocks/type_check.lua luarocks-1.0.1/src/luarocks/make.lua luarocks-1.0.1/src/luarocks/path.lua luarocks-1.0.1/src/luarocks/remove.lua luarocks-1.0.1/src/luarocks/fs.lua luarocks-1.0.1/src/luarocks/manif.lua luarocks-1.0.1/src/luarocks/deps.lua luarocks-1.0.1/src/luarocks/build.lua luarocks-1.0.1/src/luarocks/search.lua luarocks-1.0.1/src/luarocks/fetch.lua luarocks-1.0.1/src/luarocks/unpack.lua luarocks-1.0.1/src/luarocks/cfg.lua luarocks-1.0.1/src/luarocks/help.lua luarocks-1.0.1/src/luarocks/util.lua luarocks-1.0.1/test/ luarocks-1.0.1/test/run_tests.sh luarocks-1.0.1/test/test_deps.lua luarocks-1.0.1/test/test_require.lua luarocks-1.0.1/Makefile luarocks-1.0.1/configure luarocks-1.0.1/COPYING Checking Lua includes... lua.h not found (looked in /home/xan/sputnik/include/lua.h) You may want to use the flag --with-lua-include. See --help. Cleaning up... install.sh: line 6: /home/xan/sputnik/bin/luarocks: El fitxer o directori no existeix install.sh: line 7: /home/xan/sputnik/bin/luarocks: El fitxer o directori no existeix install.sh: line 8: /home/xan/sputnik/bin/luarocks: El fitxer o directori no existeix install.sh: line 9: /home/xan/sputnik/bin/luarocks: El fitxer o directori no existeix mkdir: no s?ha pogut crear el directori ?/home/xan/sputnik/wiki-data?: El fitxer ja existeix ~/sputnik ~/sputnik-9.03.16-kaio install.sh: line 17: ./bin/sputnik.lua: El fitxer o directori no existeix ~/sputnik-9.03.16-kaio xan@caixa:~/sputnik-9.03.16-kaio$ Any hints? Xan. From mascarenhas at gmail.com Sun Nov 1 11:56:29 2009 From: mascarenhas at gmail.com (Fabio Mascarenhas) Date: Sun Nov 1 11:58:13 2009 Subject: [Sputnik-list] Debian installation In-Reply-To: <4AED88EF.7080202@telefonica.net> References: <4AED88EF.7080202@telefonica.net> Message-ID: <7913df4d0911010656m4174c611ia2a8b3d69528356a@mail.gmail.com> It was Ubuntu that used to not install development tools in a regular install. :-) Do an "apt-get install build-essential" and you should be good to go. -- Fabio Mascarenhas On Sun, Nov 1, 2009 at 11:11 AM, Xan wrote: > Hi, > > Can you say me how to install sputnik in debian lenny? > I donwloaded sputnik-9.03.16-kaio and when I run "bash install.sh > /home/xan/sputnik" I received: > > > ~/sputnik-9.03.16-kaio ~/sputnik-9.03.16-kaio > Kepler Installer version 0.4. > > The name of the Lua executable is lua > Lua installation prefix: /home/xan/sputnik > Include files: /home/xan/sputnik/include > > Proceed with setup? [Y/n] > Installing Kepler from current directory... > > > ========================================================= > Installing Lua 5.1.4 on /home/xan/sputnik > ========================================================= > > > kepler-install-1.1.1-2: line 478: make: command not found > kepler-install-1.1.1-2: line 480: make: command not found > > Done. Lua is installed on /home/xan/sputnik. > > > > ========================================================= > Now installing LuaRocks 1.0.1 in /home/xan/sputnik. > ========================================================= > > > luarocks-1.0.1/ > luarocks-1.0.1/src/ > luarocks-1.0.1/src/bin/ > luarocks-1.0.1/src/bin/luarocks > luarocks-1.0.1/src/bin/luarocks-admin > luarocks-1.0.1/src/luarocks/ > luarocks-1.0.1/src/luarocks/fs/ > luarocks-1.0.1/src/luarocks/fs/unix.lua > luarocks-1.0.1/src/luarocks/fs/win32.lua > luarocks-1.0.1/src/luarocks/persist.lua > luarocks-1.0.1/src/luarocks/list.lua > luarocks-1.0.1/src/luarocks/require.lua > luarocks-1.0.1/src/luarocks/rep.lua > luarocks-1.0.1/src/luarocks/make_manifest.lua > luarocks-1.0.1/src/luarocks/command_line.lua > luarocks-1.0.1/src/luarocks/install.lua > luarocks-1.0.1/src/luarocks/build/ > luarocks-1.0.1/src/luarocks/build/command.lua > luarocks-1.0.1/src/luarocks/build/cmake.lua > luarocks-1.0.1/src/luarocks/build/make.lua > luarocks-1.0.1/src/luarocks/build/builtin.lua > luarocks-1.0.1/src/luarocks/fetch/ > luarocks-1.0.1/src/luarocks/fetch/cvs.lua > luarocks-1.0.1/src/luarocks/fetch/git.lua > luarocks-1.0.1/src/luarocks/fetch/sscm.lua > luarocks-1.0.1/src/luarocks/pack.lua > luarocks-1.0.1/src/luarocks/type_check.lua > luarocks-1.0.1/src/luarocks/make.lua > luarocks-1.0.1/src/luarocks/path.lua > luarocks-1.0.1/src/luarocks/remove.lua > luarocks-1.0.1/src/luarocks/fs.lua > luarocks-1.0.1/src/luarocks/manif.lua > luarocks-1.0.1/src/luarocks/deps.lua > luarocks-1.0.1/src/luarocks/build.lua > luarocks-1.0.1/src/luarocks/search.lua > luarocks-1.0.1/src/luarocks/fetch.lua > luarocks-1.0.1/src/luarocks/unpack.lua > luarocks-1.0.1/src/luarocks/cfg.lua > luarocks-1.0.1/src/luarocks/help.lua > luarocks-1.0.1/src/luarocks/util.lua > luarocks-1.0.1/test/ > luarocks-1.0.1/test/run_tests.sh > luarocks-1.0.1/test/test_deps.lua > luarocks-1.0.1/test/test_require.lua > luarocks-1.0.1/Makefile > luarocks-1.0.1/configure > luarocks-1.0.1/COPYING > Checking Lua includes... lua.h not found (looked in > /home/xan/sputnik/include/lua.h) > You may want to use the flag --with-lua-include. See --help. > > Cleaning up... > > install.sh: line 6: /home/xan/sputnik/bin/luarocks: El fitxer o directori > no existeix > install.sh: line 7: /home/xan/sputnik/bin/luarocks: El fitxer o directori > no existeix > install.sh: line 8: /home/xan/sputnik/bin/luarocks: El fitxer o directori > no existeix > install.sh: line 9: /home/xan/sputnik/bin/luarocks: El fitxer o directori > no existeix > mkdir: no s?ha pogut crear el directori ?/home/xan/sputnik/wiki-data?: El > fitxer ja existeix > ~/sputnik ~/sputnik-9.03.16-kaio > install.sh: line 17: ./bin/sputnik.lua: El fitxer o directori no existeix > ~/sputnik-9.03.16-kaio > xan@caixa:~/sputnik-9.03.16-kaio$ > > Any hints? > > Xan. > > > _______________________________________________ > Sputnik-list mailing list > Sputnik-list@lists.luaforge.net > http://lists.luaforge.net/cgi-bin/mailman/listinfo/sputnik-list > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.luaforge.net/pipermail/sputnik-list/attachments/20091101/37392cc0/attachment-0001.htm From yuri at sims.berkeley.edu Sun Nov 1 11:56:35 2009 From: yuri at sims.berkeley.edu (Yuri Takhteyev) Date: Sun Nov 1 11:58:49 2009 Subject: [Sputnik-list] Debian installation In-Reply-To: <4AED88EF.7080202@telefonica.net> References: <4AED88EF.7080202@telefonica.net> Message-ID: > kepler-install-1.1.1-2: line 478: make: command not found > kepler-install-1.1.1-2: line 480: make: command not found You do not have "make" installed on your system. On Ubuntu you can get this and all other build tools with "apt-get install build-essential". I am not sure about Debian, but it likely is the same. - yuri From dxpublica at telefonica.net Sun Nov 1 14:25:23 2009 From: dxpublica at telefonica.net (Xan) Date: Sun Nov 1 14:27:17 2009 Subject: [Sputnik-list] Debian installation In-Reply-To: References: <4AED88EF.7080202@telefonica.net> Message-ID: <4AEDC483.5000101@telefonica.net> En/na Yuri Takhteyev ha escrit: >> kepler-install-1.1.1-2: line 478: make: command not found >> kepler-install-1.1.1-2: line 480: make: command not found >> > > You do not have "make" installed on your system. On Ubuntu you can get > this and all other build tools with "apt-get install build-essential". > I am not sure about Debian, but it likely is the same. > > - yuri > > So, the Installation page in web is not correct at all: > In particular, you do *not* need to have Lua installed and you do > *not* need root access to the machine. It has been known to work on > Windows too because I need root access to install build-essential. Can you put the dependencies in linux? (at least make) Yes, build-essential is the same in debian and in ubuntu. And it's the only dependence it has. Thanks a lot, Xan. From steve.j.donovan at gmail.com Mon Nov 2 07:36:12 2009 From: steve.j.donovan at gmail.com (steve donovan) Date: Mon Nov 2 07:38:32 2009 Subject: [Sputnik-list] Search broken on http://sputnik.freewisdom.org Message-ID: <560972290911020236j55530708o662772b1c55b200f@mail.gmail.com> And it says: "...sputnik/rocks//versium/cvs-1/lua/versium/filedir.lua:256: Empty history for node 'sputnik/_uid:Tickets'." So clearly something has gone wrong in the Tickets applet. The question I was trying to ask is the rationale behind the definition of new node fields: ... fields = [[ author = {1.1} creation_time = {1.2} ]], ... Now I would assume that this is to give some order to the fields. Are the numbers themselves particularly important? steve d. From steve.j.donovan at gmail.com Tue Nov 3 07:55:22 2009 From: steve.j.donovan at gmail.com (steve donovan) Date: Tue Nov 3 07:57:16 2009 Subject: [Sputnik-list] Keeping Track of Page Views? Message-ID: <560972290911030255t6a39295fra34fef2228f0a506@mail.gmail.com> Hi all, I was thinking of the problem of tracking page views. It would obviously be a bad idea to put this in the node, and cause very many versions with trivial diffs. But using Saci-style versioned storage would seem to always lead to this issue. Now, naively, I would use something like GDBM for this - fast persistent hash lookup. But am I missing something? Is there a way to use Saci document storage in a way that doesn't automatically create new versions? steve d. From jnwhiteh at gmail.com Tue Nov 3 08:03:33 2009 From: jnwhiteh at gmail.com (Jim Whitehead II) Date: Tue Nov 3 08:06:17 2009 Subject: [Sputnik-list] Keeping Track of Page Views? In-Reply-To: <560972290911030255t6a39295fra34fef2228f0a506@mail.gmail.com> References: <560972290911030255t6a39295fra34fef2228f0a506@mail.gmail.com> Message-ID: <5fe281d40911030303y3a895fb1sfbd84762a28aa28f@mail.gmail.com> On Tue, Nov 3, 2009 at 10:55 AM, steve donovan wrote: > Hi all, > > I was thinking of the problem of tracking page views. It would > obviously be a bad idea to put this in the node, and cause very many > versions with trivial diffs. ?But using Saci-style versioned storage > would seem to always lead to this issue. > > Now, naively, I would use something like GDBM for this - fast > persistent hash lookup. > > But am I missing something? Is there a way to use Saci document > storage in a way that doesn't automatically create new versions? No. I've twice proposed now a non-versioned persistent data store (i.e. versium without the versions ;-)) that would be useful in a number of places. For something like this, you could get this from your web server logs or through a process like that. You can also hook your node accesses to see how often a node is being pulled through inheritance, etc. I have something that could do this, if that helps. - Jim From steve.j.donovan at gmail.com Tue Nov 3 08:08:41 2009 From: steve.j.donovan at gmail.com (steve donovan) Date: Tue Nov 3 08:11:05 2009 Subject: [Sputnik-list] Keeping Track of Page Views? In-Reply-To: <5fe281d40911030303y3a895fb1sfbd84762a28aa28f@mail.gmail.com> References: <560972290911030255t6a39295fra34fef2228f0a506@mail.gmail.com> <5fe281d40911030303y3a895fb1sfbd84762a28aa28f@mail.gmail.com> Message-ID: <560972290911030308qff15240u1a3476bff0d3aefa@mail.gmail.com> On Tue, Nov 3, 2009 at 1:03 PM, Jim Whitehead II wrote: > No. ?I've twice proposed now a non-versioned persistent data store > (i.e. versium without the versions ;-)) that would be useful in a > number of places. Well, it seems like a fairly _logical_ thing to want! >You can also > hook your node accesses to see how often a node is being pulled > through inheritance, etc. Hooking is no problem, it's just where to keep the numbers ;) steve d. From jnwhiteh at gmail.com Tue Nov 3 08:14:55 2009 From: jnwhiteh at gmail.com (Jim Whitehead II) Date: Tue Nov 3 08:17:08 2009 Subject: [Sputnik-list] Keeping Track of Page Views? In-Reply-To: <560972290911030308qff15240u1a3476bff0d3aefa@mail.gmail.com> References: <560972290911030255t6a39295fra34fef2228f0a506@mail.gmail.com> <5fe281d40911030303y3a895fb1sfbd84762a28aa28f@mail.gmail.com> <560972290911030308qff15240u1a3476bff0d3aefa@mail.gmail.com> Message-ID: <5fe281d40911030314j2127967as24e19a7ec829a76e@mail.gmail.com> On Tue, Nov 3, 2009 at 11:08 AM, steve donovan wrote: > On Tue, Nov 3, 2009 at 1:03 PM, Jim Whitehead II wrote: >> No. ?I've twice proposed now a non-versioned persistent data store >> (i.e. versium without the versions ;-)) that would be useful in a >> number of places. > > Well, it seems like a fairly _logical_ thing to want! > >>You can also >> hook your node accesses to see how often a node is being pulled >> through inheritance, etc. > > Hooking is no problem, it's just where to keep the numbers ;) Database, file, wherever. In your sputnik.lua (or sputnik.ws) you can get the new sputnik object and hook the get_node function, and then shove the data into any storage system you want =). - Jim From yuri at sims.berkeley.edu Tue Nov 3 11:40:46 2009 From: yuri at sims.berkeley.edu (Yuri Takhteyev) Date: Tue Nov 3 11:43:09 2009 Subject: [Sputnik-list] Debian installation In-Reply-To: <4AEDC483.5000101@telefonica.net> References: <4AED88EF.7080202@telefonica.net> <4AEDC483.5000101@telefonica.net> Message-ID: > So, the Installation page in web is not correct at all: >> >> In particular, you do *not* need to have Lua installed and you do *not* >> need root access to the machine. It has been known to work on Windows too > > because I need root access to install build-essential. Can you put the > dependencies in linux? (at least make) Shared hosting Linux systems usually have with "make" available for non-root users. So, if one's system does not have "make", that's probably because they configured it themselves (and thus do have root access). But I agree that a note on dependencies is needed. It actually used to be there but got removed somehow. I put it back. If someone wanted to install Sputnik without root access and without "make", Steve's "Lua4Linux" would probably be the way to go. - yuri From yuri at sims.berkeley.edu Tue Nov 3 11:52:14 2009 From: yuri at sims.berkeley.edu (Yuri Takhteyev) Date: Tue Nov 3 11:54:41 2009 Subject: [Sputnik-list] Search broken on http://sputnik.freewisdom.org In-Reply-To: <560972290911020236j55530708o662772b1c55b200f@mail.gmail.com> References: <560972290911020236j55530708o662772b1c55b200f@mail.gmail.com> Message-ID: > "...sputnik/rocks//versium/cvs-1/lua/versium/filedir.lua:256: Empty > history for node 'sputnik/_uid:Tickets'." > > So clearly something has gone wrong in the Tickets applet. It turns out that this has nothing to do with Tickets per se. Rather, I've ran out of disk space on the server, which has caused all sorts of problems. > ? ? ? ?fields = [[ > ? ? ? ? ? ? ?author = {1.1} > creation_time = {1.2} > ? ? ? ? ... > > Now I would assume that this is to give some order to the fields. Are > the numbers themselves particularly important? This first numeric parameter is optional, but if it's specified it controls the order in which the fields are serialized. (So, in this example, the "author" field would come before "creation_time" in the string representation of the node. Considering that people rarely care in what order the fields are serialized and the number of times this question has been asked, I am wondering if I should just get remove this from all the default nodes, sorting all fields without this parameter alphabetically. Any thoughts? - yuri From jnwhiteh at gmail.com Tue Nov 3 12:00:01 2009 From: jnwhiteh at gmail.com (Jim Whitehead II) Date: Tue Nov 3 12:02:45 2009 Subject: [Sputnik-list] Search broken on http://sputnik.freewisdom.org In-Reply-To: References: <560972290911020236j55530708o662772b1c55b200f@mail.gmail.com> Message-ID: <5fe281d40911030700w46aaa6d4i38d64d1050a6e903@mail.gmail.com> On Tue, Nov 3, 2009 at 2:52 PM, Yuri Takhteyev wrote: >> "...sputnik/rocks//versium/cvs-1/lua/versium/filedir.lua:256: Empty >> history for node 'sputnik/_uid:Tickets'." >> >> So clearly something has gone wrong in the Tickets applet. > > It turns out that this has nothing to do with Tickets per se. Rather, > I've ran out of disk space on the server, which has caused all sorts > of problems. > >> ? ? ? ?fields = [[ >> ? ? ? ? ? ? ?author = {1.1} >> ? ? ? ? ? ? ?creation_time = {1.2} >> ? ? ? ? ... >> >> Now I would assume that this is to give some order to the fields. Are >> the numbers themselves particularly important? > > This first numeric parameter is optional, but if it's specified it > controls the order in which the fields are serialized. (So, in this > example, the "author" field would come before "creation_time" in the > string representation of the node. Considering that people rarely care > in what order the fields are serialized and the number of times this > question has been asked, I am wondering if I should just get remove > this from all the default nodes, sorting all fields without this > parameter alphabetically. Any thoughts? Yes, I think we should document it, but not use it explicitly in the code we've written. The alphabetic default seems to work quite well and gives us mostly everything we need. - Jim From yuri at sims.berkeley.edu Tue Nov 3 12:10:58 2009 From: yuri at sims.berkeley.edu (Yuri Takhteyev) Date: Tue Nov 3 12:12:53 2009 Subject: [Sputnik-list] Keeping Track of Page Views? In-Reply-To: <5fe281d40911030314j2127967as24e19a7ec829a76e@mail.gmail.com> References: <560972290911030255t6a39295fra34fef2228f0a506@mail.gmail.com> <5fe281d40911030303y3a895fb1sfbd84762a28aa28f@mail.gmail.com> <560972290911030308qff15240u1a3476bff0d3aefa@mail.gmail.com> <5fe281d40911030314j2127967as24e19a7ec829a76e@mail.gmail.com> Message-ID: > Database, file, wherever. ?In your sputnik.lua (or sputnik.ws) you can > get the new sputnik object and hook the get_node function, and then > shove the data into any storage system you want =). One thing to add: Sputnik doesn't use an RDBMS by default, but if a particular sputnik-based app wants to use a DB for its purposes, there is no problem with this. And if your app wants to call GDBM directly, that's ok too. Jim is right, though, that a simple version-less versium implementation would a nice thing to offer. It could be based on GDBM. Another thing to consider, though, would be using LuaLogging API. - yuri From dxpublica at telefonica.net Tue Nov 3 12:15:20 2009 From: dxpublica at telefonica.net (Xan) Date: Tue Nov 3 12:17:18 2009 Subject: [Sputnik-list] Debian installation In-Reply-To: References: <4AED88EF.7080202@telefonica.net> <4AEDC483.5000101@telefonica.net> Message-ID: <4AF04908.8090809@telefonica.net> En/na Yuri Takhteyev ha escrit: > Shared hosting Linux systems usually have with "make" available for > non-root users. So, if one's system does not have "make", that's > probably because they configured it themselves (and thus do have root > access). But I agree that a note on dependencies is needed. It > actually used to be there but got removed somehow. I put it back. > Thanks for doing that. Xan. > If someone wanted to install Sputnik without root access and without > "make", Steve's "Lua4Linux" would probably be the way to go. > > - yuri > > _______________________________________________ > Sputnik-list mailing list > Sputnik-list@lists.luaforge.net > http://lists.luaforge.net/cgi-bin/mailman/listinfo/sputnik-list > From jnwhiteh at gmail.com Tue Nov 3 12:35:41 2009 From: jnwhiteh at gmail.com (Jim Whitehead II) Date: Tue Nov 3 12:38:09 2009 Subject: [Sputnik-list] Keeping Track of Page Views? In-Reply-To: References: <560972290911030255t6a39295fra34fef2228f0a506@mail.gmail.com> <5fe281d40911030303y3a895fb1sfbd84762a28aa28f@mail.gmail.com> <560972290911030308qff15240u1a3476bff0d3aefa@mail.gmail.com> <5fe281d40911030314j2127967as24e19a7ec829a76e@mail.gmail.com> Message-ID: <5fe281d40911030735q4b554fb1lbe28334764089500@mail.gmail.com> Logs with post-analysis don't give you much when you want to be able to easily access the data, but if you don't need that, it certainly works. On Nov 3, 2009 4:10 PM, "Yuri Takhteyev" wrote: > Database, file, wherever. In your sputnik.lua (or sputnik.ws) you can > get the new sputnik objec... One thing to add: Sputnik doesn't use an RDBMS by default, but if a particular sputnik-based app wants to use a DB for its purposes, there is no problem with this. And if your app wants to call GDBM directly, that's ok too. Jim is right, though, that a simple version-less versium implementation would a nice thing to offer. It could be based on GDBM. Another thing to consider, though, would be using LuaLogging API. - yuri -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.luaforge.net/pipermail/sputnik-list/attachments/20091103/79dfdf45/attachment.htm From yuri at sims.berkeley.edu Tue Nov 3 12:51:41 2009 From: yuri at sims.berkeley.edu (Yuri Takhteyev) Date: Tue Nov 3 12:54:05 2009 Subject: [Sputnik-list] Keeping Track of Page Views? In-Reply-To: <5fe281d40911030735q4b554fb1lbe28334764089500@mail.gmail.com> References: <560972290911030255t6a39295fra34fef2228f0a506@mail.gmail.com> <5fe281d40911030303y3a895fb1sfbd84762a28aa28f@mail.gmail.com> <560972290911030308qff15240u1a3476bff0d3aefa@mail.gmail.com> <5fe281d40911030314j2127967as24e19a7ec829a76e@mail.gmail.com> <5fe281d40911030735q4b554fb1lbe28334764089500@mail.gmail.com> Message-ID: > Logs with post-analysis don't give you much when you want to be able to > easily access the data, but if you don't need that, it certainly works. I am not suggesting post-analysis. I was suggesting that one way to do this is to write a LuaLogging "appender" that would keep a real-time count of page views. http://www.keplerproject.org/lualogging/manual.html#appenders The advantage of this approach is that we could add logging calls for page views into Sputnik itself and let the application developer decide how to handle them. By default, those calls to logger:info() would do nothing. However, the application developer can choose to either write them to a file and post-process them _or_ to use an appender that keeps a real-time count. LuaLogging is already fully integrated with Sputnik and the logging is configurable through LOGGER_PARAMS and LOGGER_LEVEL parameters. We currently only log at the debug level, but it would make sense to add a small number of "info" log messages for things such as page access. - yuri From steve.j.donovan at gmail.com Tue Nov 3 13:31:00 2009 From: steve.j.donovan at gmail.com (steve donovan) Date: Tue Nov 3 13:33:26 2009 Subject: [Sputnik-list] Search broken on http://sputnik.freewisdom.org In-Reply-To: <5fe281d40911030700w46aaa6d4i38d64d1050a6e903@mail.gmail.com> References: <560972290911020236j55530708o662772b1c55b200f@mail.gmail.com> <5fe281d40911030700w46aaa6d4i38d64d1050a6e903@mail.gmail.com> Message-ID: <560972290911030831x5cf7c242v22a442e36fd48cfa@mail.gmail.com> > Yes, I think we should document it, but not use it explicitly in the > code we've written. ?The alphabetic default seems to work quite well > and gives us mostly everything we need. We are accustomed to Lua tables not preserving order anyway, and any situation where order would matter there would be the option of saving a field called 'fields'. I suppose the 'natural' Lua way is something like: NODE.fields = {'author','creation_time'} which is ordered. But I understand that sometimes there is extra information needed for field definition. steve d. From steve.j.donovan at gmail.com Tue Nov 3 14:40:27 2009 From: steve.j.donovan at gmail.com (steve donovan) Date: Tue Nov 3 14:42:22 2009 Subject: [Sputnik-list] Small bug in Windows installation (Kaio) Message-ID: <560972290911030940o756906dbw6ffcf9282f24b900@mail.gmail.com> This is a little thing, but it can cause some serious confusion ;) sputnik/installer.lua has this template: WS_SCRIPT_TEMPLATE = [[ require('sputnik.wsapi_app') return sputnik.wsapi_app.new{ VERSIUM_PARAMS = { '$dir/wiki-data/' }, BASE_URL = '/sputnik.ws', PASSWORD_SALT = '$password_salt', TOKEN_SALT = '$token_salt', } ]] Fair enough, but $dir is going to expand into something with backslashes, and cause unhappiness. An easy fix is to use [[..]] as the string delimiters here. Otherwise, works just as well as on the other side, starting with Lua for Windows as a base. Perhaps a little install.bat that could do the necessary steps? steve d. PS. Some mention was made of 'Steve's Lua4Linux' which made me feel vaguely guilty. However, it's been useful taking a break since L4L was always meant to be a LuaRocks-centric distribution, and now we have LR 2, which will embed even more easily. From yuri at sims.berkeley.edu Tue Nov 3 22:42:17 2009 From: yuri at sims.berkeley.edu (Yuri Takhteyev) Date: Tue Nov 3 22:44:43 2009 Subject: [Sputnik-list] Small bug in Windows installation (Kaio) In-Reply-To: <560972290911030940o756906dbw6ffcf9282f24b900@mail.gmail.com> References: <560972290911030940o756906dbw6ffcf9282f24b900@mail.gmail.com> Message-ID: > Fair enough, but $dir is going to expand into something with > backslashes, and cause unhappiness. An easy fix is to use [[..]] as > the string delimiters here. Good point. I made this change and committed it. > Otherwise, works just as well as on the other side, starting with Lua > for Windows as a base. Perhaps a little install.bat that could do the > necessary steps? That would be nice, but we would need a volunteer who uses Windows. I don't. - yuri From steve.j.donovan at gmail.com Wed Nov 4 03:08:32 2009 From: steve.j.donovan at gmail.com (steve donovan) Date: Wed Nov 4 03:10:59 2009 Subject: [Sputnik-list] Small bug in Windows installation (Kaio) In-Reply-To: References: <560972290911030940o756906dbw6ffcf9282f24b900@mail.gmail.com> Message-ID: <560972290911032208j31d6bb32s874aa16e8740f289@mail.gmail.com> On Wed, Nov 4, 2009 at 3:42 AM, Yuri Takhteyev wrote: >> for Windows as a base. Perhaps a little install.bat that could do the >> necessary steps? > > That would be nice, but we would need a volunteer who uses Windows. I don't. Well, circumstances force me to be amphibious (if that's the word) so I can do a simple .bat no problem. A bit like going back to the 80s, and not in a good way, but ok if kept simple. (The install.bat for LuaRocks is nasty; it has an entertaining comment at the top) steve d. From steve.j.donovan at gmail.com Wed Nov 4 09:06:39 2009 From: steve.j.donovan at gmail.com (steve donovan) Date: Wed Nov 4 09:09:09 2009 Subject: [Sputnik-list] An install script for Windows Message-ID: <560972290911040406t13267cf9sa5bc247e4927a84e@mail.gmail.com> I considered doing a bat but that seemed like unnecessary nonsense when we have a perfectly good scripting language available. The idea is that it sits in the root dir of the archive, next to the license files. Does some basic sanity checks (like whether it is in the correct directory) and then does the steps, including patching sputnik.ws. (sputnik.cgi is probably basically broken on Windows) Then creates a little 'run.bat' for running with Xavante. Worked on two machines with Lua for Windows so far! A generalization would cope with any Windows Lua installation - (a) would deduce the Lua executable name from what was used to run install-win.lua and (b) would do pcall(require) for all the external modules needed, and bitch if not found. steve d. -------------- next part -------------- A non-text attachment was scrubbed... Name: install-win.lua Type: application/octet-stream Size: 2148 bytes Desc: not available Url : http://lists.luaforge.net/pipermail/sputnik-list/attachments/20091104/1ab888d5/install-win-0001.obj From dm.lua at math2.org Thu Nov 5 00:06:06 2009 From: dm.lua at math2.org (David Manura) Date: Thu Nov 5 00:08:37 2009 Subject: [Sputnik-list] An install script for Windows In-Reply-To: <560972290911040406t13267cf9sa5bc247e4927a84e@mail.gmail.com> References: <560972290911040406t13267cf9sa5bc247e4927a84e@mail.gmail.com> Message-ID: On Wed, Nov 4, 2009 at 7:06 AM, steve donovan wrote: > I considered doing a bat but that seemed like unnecessary nonsense > when we have a perfectly good scripting language available. Just a comment: there's a recurring need for many of the utility shell functions in that. Some are in penlight [1], while many others, including the .bat wrapping, are in LuaDist [2], LuaRocks libraries and [3]. The hard-coded path in the .bat may be replaced with code to detect this inside the .bat itself as done in [2]; that would permit the files to be relocatable. Perhaps running apps from the LUA_PATH [4] may avoid the need for that though. [1] http://penlight.luaforge.net/api/modules/pl.utils.html#readfile [2] http://luadist.svn.sourceforge.net/viewvc/luadist/trunk/dists/luadist-1.0.0/lmod/dist/sys.lua [3] http://lua-users.org/lists/lua-l/2008-09/msg00312.html [4] http://lua-users.org/wiki/ModuleExecutionProposal From steve.j.donovan at gmail.com Thu Nov 5 04:05:32 2009 From: steve.j.donovan at gmail.com (steve donovan) Date: Thu Nov 5 04:08:05 2009 Subject: [Sputnik-list] An install script for Windows In-Reply-To: References: <560972290911040406t13267cf9sa5bc247e4927a84e@mail.gmail.com> Message-ID: <560972290911042305p85f218ekae6457bb336853e6@mail.gmail.com> On Thu, Nov 5, 2009 at 5:06 AM, David Manura wrote: > Just a comment: there's a recurring need for many of the utility shell > functions in that. I could have used Cosmo to do the batch file, since it is guaranteed to be available at this point in the script, but it's such a simple substitution. There is a gotcha in that batch file; it isn't quite right. It does not account for the batch file being run from a different drive, due to the silly limitations of the cd command. There needs to be a first line that has the drive letter, that is, dir:sub(1,2) to switch to the drive. Actually, the script is not very Windows-specific, except for the file copy (file copies are awkward to do just with lfs) steve d. From dm.lua at math2.org Thu Nov 5 12:05:18 2009 From: dm.lua at math2.org (David Manura) Date: Thu Nov 5 12:07:53 2009 Subject: [Sputnik-list] An install script for Windows In-Reply-To: <560972290911042305p85f218ekae6457bb336853e6@mail.gmail.com> References: <560972290911040406t13267cf9sa5bc247e4927a84e@mail.gmail.com> <560972290911042305p85f218ekae6457bb336853e6@mail.gmail.com> Message-ID: On Thu, Nov 5, 2009 at 2:05 AM, steve donovan wrote: > There is a gotcha in that batch file; it isn't quite right. It does > not account for the batch file being run from a different drive, due > to the silly limitations of the cd command. Use "cd /d". From steve.j.donovan at gmail.com Fri Nov 6 02:11:43 2009 From: steve.j.donovan at gmail.com (steve donovan) Date: Fri Nov 6 02:14:21 2009 Subject: [Sputnik-list] An install script for Windows In-Reply-To: References: <560972290911040406t13267cf9sa5bc247e4927a84e@mail.gmail.com> <560972290911042305p85f218ekae6457bb336853e6@mail.gmail.com> Message-ID: <560972290911052111k4c926a0eu955d68ac7097847c@mail.gmail.com> On Thu, Nov 5, 2009 at 5:05 PM, David Manura wrote: > Use "cd /d". Hah, can live with a beast for years without discovering all its possibilities ;) From fw at deneb.enyo.de Sun Nov 8 13:56:23 2009 From: fw at deneb.enyo.de (Florian Weimer) Date: Sun Nov 8 13:59:13 2009 Subject: [Sputnik-list] Cosmo suggestion Message-ID: <87my2xx8eg.fsf@mid.deneb.enyo.de> Would it be possible to extend Cosmo with the following characteristics: * template application results in an array, and not in a string * template parameters appear as-is in the result, without being converted to strings * optionally, a function is applied to template parameters which are not literal strings in the template (another function which is applied to literals could be useful as well) The last item allows the caller to mark data which came from templates, as opposed to template literals. This means that it's possible to implement automatic escaping for creating well-formed XML output, no matter what the template parameters are. From yuri at sims.berkeley.edu Mon Nov 9 13:44:47 2009 From: yuri at sims.berkeley.edu (Yuri Takhteyev) Date: Mon Nov 9 13:47:43 2009 Subject: [Sputnik-list] Cosmo suggestion In-Reply-To: <87my2xx8eg.fsf@mid.deneb.enyo.de> References: <87my2xx8eg.fsf@mid.deneb.enyo.de> Message-ID: Hi, Florian, > Would it be possible to extend Cosmo with the following > characteristics: Can you give an example of what you are trying to achieve? Though, the questions about what can be done would mostly need to be answered by Fabio at this point. - yuri From mascarenhas at gmail.com Mon Nov 9 13:56:52 2009 From: mascarenhas at gmail.com (Fabio Mascarenhas) Date: Mon Nov 9 13:59:17 2009 Subject: [Sputnik-list] Cosmo suggestion In-Reply-To: References: <87my2xx8eg.fsf@mid.deneb.enyo.de> Message-ID: <7913df4d0911090856o3250e567r290cc884b5ae641a@mail.gmail.com> On Mon, Nov 9, 2009 at 2:44 PM, Yuri Takhteyev wrote: > Hi, Florian, > > > Would it be possible to extend Cosmo with the following > > characteristics: > > Can you give an example of what you are trying to achieve? > > Though, the questions about what can be done would mostly need to be > answered by Fabio at this point. > > I can answer, but I have to understand what exactly Florian wants to achieve, too. :-) > - yuri > > -- Fabio Mascarenhas -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.luaforge.net/pipermail/sputnik-list/attachments/20091109/d0d6883d/attachment.html From yuri at sims.berkeley.edu Mon Nov 9 14:40:57 2009 From: yuri at sims.berkeley.edu (Yuri Takhteyev) Date: Mon Nov 9 14:43:56 2009 Subject: [Sputnik-list] Keeping Track of Page Views? In-Reply-To: <5fe281d40911030812p5a211e68s5832d2a4ac2371f7@mail.gmail.com> References: <560972290911030255t6a39295fra34fef2228f0a506@mail.gmail.com> <5fe281d40911030303y3a895fb1sfbd84762a28aa28f@mail.gmail.com> <560972290911030308qff15240u1a3476bff0d3aefa@mail.gmail.com> <5fe281d40911030314j2127967as24e19a7ec829a76e@mail.gmail.com> <5fe281d40911030735q4b554fb1lbe28334764089500@mail.gmail.com> <5fe281d40911030812p5a211e68s5832d2a4ac2371f7@mail.gmail.com> Message-ID: > I see what you're suggestion now, it just doesn't taste right to me I > guess. ?Speaking of logging tho, that reminds me that I really would > like to go through and remove almost all of the (useless) messages > that are there now, and put some actually useful debug messages in > place. If you want to do this, this sounds like a great idea. > The reason it doesn't taste right to me is that you can't have two > loggers in your system.. there's only one. Is this true? It seems to me that one should be able to tee the logs to two appenders. local logger1 = logging.file("/tmp/out.txt") local logger2 = logging.console() logger = logging.new(function(self, level, message) logger1:log(level, message) logger2:log(level, message) end) > Hooking feels dirty.. but can always be altered to do precisely what > you want. We should leave this option for those who want it. I am just wondering if this method would seem too complicated for many people. Another option: we could record stats through a new function Sputnik:record_stats(), have it log the info by default, but allow the user to override it with their own implementation. - yuri From fw at deneb.enyo.de Mon Nov 9 15:25:26 2009 From: fw at deneb.enyo.de (Florian Weimer) Date: Mon Nov 9 15:28:23 2009 Subject: [Sputnik-list] Cosmo suggestion In-Reply-To: (Yuri Takhteyev's message of "Mon, 9 Nov 2009 11:44:47 -0500") References: <87my2xx8eg.fsf@mid.deneb.enyo.de> Message-ID: <87pr7ra73d.fsf@mid.deneb.enyo.de> * Yuri Takhteyev: > Hi, Florian, > >> Would it be possible to extend Cosmo with the following >> characteristics: > > Can you give an example of what you are trying to achieve? Using the basic example, template = [==[

$list_name

    $do_items[=[
  • $item
  • ]=]
]==] local out = cosmo.fill(template, { list_name = "My List", do_items = function() for i=1,3 do cosmo.yield { item = i } end end } ) I would like that out is the table {"

", "My List", "

\n
    \n", "
  • ", 1, "
  • ", "
  • ", 2, "
  • ", "
  • ", 3, "
  • ", "\n
\n"} Adjacent strings could be merged, but the parameter values should not be turned into strings. I also would like to specify a function f such that the result turns into {"

", f("My List"), "

\n
    \n", "
  • ", f(1), "
  • ", "
  • ", f(2), "
  • ", "
  • ", f(3), "
  • ", "\n
\n"} That is, it is applied to all parameters which end up in the output, but not the strings which are copied from the template. (In practice, f could be a HTML escaping function.) From yuri at sims.berkeley.edu Mon Nov 9 15:28:29 2009 From: yuri at sims.berkeley.edu (Yuri Takhteyev) Date: Mon Nov 9 15:31:26 2009 Subject: [Sputnik-list] An install script for Windows In-Reply-To: <560972290911040406t13267cf9sa5bc247e4927a84e@mail.gmail.com> References: <560972290911040406t13267cf9sa5bc247e4927a84e@mail.gmail.com> Message-ID: I added this script to the repository. I think it needs a little documentation, though, in terms of what is assumed to already be available and what is installed. Also, perhaps it can be refactored to not be windows specific. I think a script like this might be more useful for Windows, but having it be mostly platform independent would make it easier to keep it up to date(since one won't need a windows machine to test simple changes). > the correct directory) and then does the steps, including patching > sputnik.ws. This particular step is problematic. Of the three changes you make to sputnik.ws, two are good but are already done in the git and will be included in the next release. The third is questionable. ws = ws:gsub("/sputnik.ws","/") -- nicer root URL This has already been fixed in git, so it will be taken care of on the next release. ws = ws:gsub("'([^']+)'","[[%1]]") -- use long strings so we won't be bothered by path backslashes Same here. ws = ws:gsub('%,%s}',',\n SHOW_STACK_TRACE=true,\n}') -- this will make Sputnik tell us about any Lua problems This is what we used to have, but I was convinced (I think by David) that stack traces present a security vulnerability and should not be enabled by default. Basically, showing stack traces to anonymous users gives them a lot of information about the code we are running and thus opens opportunities for exploits. If an administrator wants to open this door, that's fine, but we shouldn't do it for them. > (sputnik.cgi is probably basically broken on Windows) Why would it be? - yuri From mascarenhas at gmail.com Mon Nov 9 15:56:11 2009 From: mascarenhas at gmail.com (Fabio Mascarenhas) Date: Mon Nov 9 15:59:07 2009 Subject: [Sputnik-list] Cosmo suggestion In-Reply-To: <87pr7ra73d.fsf@mid.deneb.enyo.de> References: <87my2xx8eg.fsf@mid.deneb.enyo.de> <87pr7ra73d.fsf@mid.deneb.enyo.de> Message-ID: <7913df4d0911091056u503c48fag453345e3e2e2b5c4@mail.gmail.com> On Mon, Nov 9, 2009 at 4:25 PM, Florian Weimer wrote: > * Yuri Takhteyev: > > > > > Can you give an example of what you are trying to achieve? > > Using the basic example, > > template = [==[ >

$list_name

>
    > $do_items[=[
  • $item
  • ]=] >
> ]==] > > local out = cosmo.fill(template, > { list_name = "My List", > do_items = function() > for i=1,3 do > cosmo.yield { item = i } > end > end > } > ) > > I would like that out is the table > > {"

", "My List", "

\n
    \n", > "
  • ", 1, "
  • ", "
  • ", 2, "
  • ", "
  • ", 3, "
  • ", > "\n
\n"} > > Adjacent strings could be merged, but the parameter values should not > be turned into strings. > > This is certainly doable with some refactoring Cosmo's innards (it already kind of builds the response by making a table and doing a concat), but I wouldn't like to expose this implementation detail without have a compelling use for this feature, can you give one? > I also would like to specify a function f such that the result turns > into > > {"

", f("My List"), "

\n
    \n", > "
  • ", f(1), "
  • ", "
  • ", f(2), "
  • ", "
  • ", f(3), "
  • ", > "\n
\n"} > > That is, it is applied to all parameters which end up in the output, > but not the strings which are copied from the template. (In practice, > f could be a HTML escaping function.) > > Try this: local function wrap_env(env, f) return setmetatable({}, { __index = function (t, name) local item = env[name] if type(item) == "string" or type(item) == "number" then item = f(item) end t[name] = item return item end }) end local f = my_html_escape_function local my_fill = function (template, env) return cosmo.fill(template, wrap_env(env, f)) end local my_yield = function (env) cosmo.yield(wrap_env(env, f)) end local out = my_fill(template, { list_name = "My List", do_items = function() for i=1,3 do my_yield { item = i } end end }) http://c2.com/cgi/wiki/wiki?OneMoreLevelOfIndirection :-) -- Fabio Mascarenhas _______________________________________________ > Sputnik-list mailing list > Sputnik-list@lists.luaforge.net > http://lists.luaforge.net/cgi-bin/mailman/listinfo/sputnik-list > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.luaforge.net/pipermail/sputnik-list/attachments/20091109/b2f231bf/attachment.htm From fw at deneb.enyo.de Mon Nov 9 17:51:08 2009 From: fw at deneb.enyo.de (Florian Weimer) Date: Mon Nov 9 17:54:07 2009 Subject: [Sputnik-list] Cosmo suggestion In-Reply-To: <7913df4d0911091056u503c48fag453345e3e2e2b5c4@mail.gmail.com> (Fabio Mascarenhas's message of "Mon, 9 Nov 2009 16:56:11 -0200") References: <87my2xx8eg.fsf@mid.deneb.enyo.de> <87pr7ra73d.fsf@mid.deneb.enyo.de> <7913df4d0911091056u503c48fag453345e3e2e2b5c4@mail.gmail.com> Message-ID: <87skcn2zib.fsf@mid.deneb.enyo.de> * Fabio Mascarenhas: >> Adjacent strings could be merged, but the parameter values should not >> be turned into strings. > This is certainly doable with some refactoring Cosmo's innards (it > already kind of builds the response by making a table and doing a > concat), but I wouldn't like to expose this implementation detail > without have a compelling use for this feature, can you give one? It's the only way I know to get rid of cross-site scripting issue. For me, that's a compelling reason, but your priorites might be different, of course. > Try this: Interesting, thanks. I need to thimk a bit about it to see if it is actualy safe. From yuri at sims.berkeley.edu Mon Nov 9 18:10:37 2009 From: yuri at sims.berkeley.edu (Yuri Takhteyev) Date: Mon Nov 9 18:13:36 2009 Subject: [Sputnik-list] Cosmo suggestion In-Reply-To: <87skcn2zib.fsf@mid.deneb.enyo.de> References: <87my2xx8eg.fsf@mid.deneb.enyo.de> <87pr7ra73d.fsf@mid.deneb.enyo.de> <7913df4d0911091056u503c48fag453345e3e2e2b5c4@mail.gmail.com> <87skcn2zib.fsf@mid.deneb.enyo.de> Message-ID: > It's the only way I know to get rid of cross-site scripting issue. > For me, that's a compelling reason, but your priorites might be > different, of course. Have you considered using the XSSFilter module: http://sputnik.freewisdom.org/lib/xssfilter/ - yuri From fw at deneb.enyo.de Mon Nov 9 18:19:56 2009 From: fw at deneb.enyo.de (Florian Weimer) Date: Mon Nov 9 18:22:54 2009 Subject: [Sputnik-list] Cosmo suggestion In-Reply-To: (Yuri Takhteyev's message of "Mon, 9 Nov 2009 16:10:37 -0500") References: <87my2xx8eg.fsf@mid.deneb.enyo.de> <87pr7ra73d.fsf@mid.deneb.enyo.de> <7913df4d0911091056u503c48fag453345e3e2e2b5c4@mail.gmail.com> <87skcn2zib.fsf@mid.deneb.enyo.de> Message-ID: <87y6mf1jlv.fsf@mid.deneb.enyo.de> * Yuri Takhteyev: >> It's the only way I know to get rid of cross-site scripting issue. >> For me, that's a compelling reason, but your priorites might be >> different, of course. > > Have you considered using the XSSFilter module: > > http://sputnik.freewisdom.org/lib/xssfilter/ Anybody who has tried to build such a thing has failed. For instance, the "style" attribute is unsafe even on tags because most browser offer (incompatible) means for embedding Javascript into CSS. Even that "url" filter can be bypassed using entities. The filter is likely to break any CSS-based layout because you often need "id" attributes. It will also strip scripts which you intend to be present. From yuri at sims.berkeley.edu Mon Nov 9 18:28:17 2009 From: yuri at sims.berkeley.edu (Yuri Takhteyev) Date: Mon Nov 9 18:31:15 2009 Subject: [Sputnik-list] Cosmo suggestion In-Reply-To: <87y6mf1jlv.fsf@mid.deneb.enyo.de> References: <87my2xx8eg.fsf@mid.deneb.enyo.de> <87pr7ra73d.fsf@mid.deneb.enyo.de> <7913df4d0911091056u503c48fag453345e3e2e2b5c4@mail.gmail.com> <87skcn2zib.fsf@mid.deneb.enyo.de> <87y6mf1jlv.fsf@mid.deneb.enyo.de> Message-ID: > Anybody who has tried to build such a thing has failed. ?For instance, > the "style" attribute is unsafe even on tags because most > browser offer (incompatible) means for embedding Javascript into CSS. So, disallow "style" attributes. > The filter is likely to break any CSS-based layout because you often > need "id" attributes. ?It will also strip scripts which you intend to > be present. Allow "id" attributes if you need them. Put scripts outside the section of the page that is run through the filter. - yuri