code logs -> 2009 -> Sat, 06 Jun 2009< code.20090605.log - code.20090607.log >
--- Log opened Sat Jun 06 00:00:01 2009
--- Day changed Sat Jun 06 2009
00:00
<@TheWatcher[zZzZ]>
yeah, that probably wouldn't work on my code
00:00
<@Derakon>
Too many mixed code-and-comment lines?
00:03
<@TheWatcher[zZzZ]>
fair number. But right now, `find . -iname '*.cgi' -or -iname '*.pm' | xargs wc -l` sets me at 5375 and `.. | xargs grep -c '#'` totals 1982.. so about 37%
00:04
<@Derakon>
I'm at 4714 total, counting dynamic modules (some of which are purely data).
00:04
< simontwo>
do any ircds today allow NUL characters to be sent?
00:05
<@Vornicus>
simontwo: Some may, I don't know hwo they behave but it can't possibly be catastrophic.
00:06
< simontwo>
Vornicus, yes it could. if IRC clients built in C aren't robust, they'll scan input as if they were internally represented strings and not binary data (minus newline).
00:07
<@TheWatcher[zZzZ]>
simontwo: RFC1459 states that "The NUL character is not special in message framing, and basically could end up inside a parameter, but as it would cause extra complexities in normal C string handling. Therefore NUL is not allowed within messages."
00:07
< simontwo>
right. thanks.
00:08
<@TheWatcher[zZzZ]>
Anyway, really slep now
00:08
<@Vornicus>
What I mean is, if you send a NUL, you shouldn't expect the thing to crash.
00:10 UndeadAnno [AnnoDomini@Nightstar-29230.neoplus.adsl.tpnet.pl] has quit [Quit: Faerie gold... it is always illusion in the end.]
00:28
<@Derakon>
Hm. Doxygen takes awhile to build.
00:37
<@Derakon>
...and the default config file is 1514 lines long. O_o
00:39
< simontwo>
Vornicus, I'm talking about receiving a NUL. if I stop processing input lines based on sudden NULs, people are able to inject commands as if they were sent from the server.
00:41
<@ToxicFrog>
How do you figure?
00:41
<@ToxicFrog>
The origin goes at the start of the message.
00:42
< Namegduf>
Maybe if it handles NUL like a line break and keeps reading after...
00:46
< Alek>
discard everything after the NUL?
00:57
<@ToxicFrog>
If it handles NUL like a linebreak then yes, you could fake server messages, but the client would have to be pathological to do that!
00:59
<@Vornicus>
No sane IRCD is going to do it that way.
01:06 * Derakon eyes the documentation he's writing for the Map class.
01:06
<@Derakon>
Map creation is currently an 11-step process.
01:08
<@Derakon>
'Scuse me, 12 steps.
01:45
<@Derakon>
Okay! First pass on Map documentation done. http://derakon.dyndns.org/~chriswei/temp2/html/classmap_1_1_map.html
01:58 * ToxicFrog bonks his head against the desk repeatedly
01:58
<@ToxicFrog>
"I feel like working on Spellcast today."
01:59
<@ToxicFrog>
"Hmm, I don't quite remember how this part of the GTK bindings works. To the website!"
01:59
<@ToxicFrog>
WEBSITE: "Hi. We've completely rewritten the gtk bindings as part of our new lgob library; lgui is deprecated and no longer maintained."
01:59
<@Derakon>
And naturally they've deleted all the old documentation?
02:00
< SmithKurosaki>
gaaaaah!!!
02:00 * SmithKurosaki hugs ToxicFrog
02:03
<@ToxicFrog>
Derakon: no, they haven't
02:03
<@ToxicFrog>
But I don't want to keep using a deprecated library
02:03
<@ToxicFrog>
I hope they haven't significantly changed the API.
02:03
<@Derakon>
Ahh.
02:03
<@Derakon>
Idly, I'm quite impressed with Doxygen.
02:04
<@Derakon>
Didn't take long to set up and it doesn't require much in the way of magic markup in the comments themselves.
02:15 GeekSoldier [~Rob@Nightstar-8573.midstate.ip.cablemo.net] has joined #code
02:15 mode/#code [+o GeekSoldier] by ChanServ
02:15 Derakon is now known as Derakon[AFK]
02:54 * Vornicus ponders. Now that he's got map rendering working.
02:55
<@Vornicus>
I need to do something else.
03:15 * ToxicFrog bonks his head against the wall
03:15
<@ToxicFrog>
Maybe I should stick with lgui after all
03:16
<@ToxicFrog>
lgob is behaving oddly WRT interface builders and some of its submodules require GTK+ 2.16
03:17
<@ToxicFrog>
Which is kind of problematic when the latest version in the repos is 2.14
03:18
< SmithKurosaki>
:(\
03:23
<@ToxicFrog>
Actually, yes
03:23
<@ToxicFrog>
I want other people to be able to run this
03:23
<@ToxicFrog>
Most people won't have GTK 2.16+, since it's very recent
03:23
<@ToxicFrog>
So, for now, I'm sticking with lgui.
03:42
< SmithKurosaki>
but then you will have a patch? also what is this for tf?
03:45
<@ToxicFrog>
Spellcast.
03:45
<@ToxicFrog>
And what do you mean, then I will have a patch?
03:45
< SmithKurosaki>
right
03:45
< SmithKurosaki>
when 2.16 is more available
03:46
<@ToxicFrog>
Oh.
03:46
<@ToxicFrog>
Possibly.
03:46
<@ToxicFrog>
Looking at the two libs, all the function names have changed
03:46
<@ToxicFrog>
So, ;.;
03:46
< SmithKurosaki>
ahh
03:46 * SmithKurosaki hugs
03:58 * Vornicus pokes at his scaler. Whyyyyyy do you insist on getting it wrong?
04:33 * ToxicFrog gnaws on his main loop/event dispatcher code
04:34
<@McMartin>
VICTORY
04:34
<@McMartin>
Now I can go home
04:36
<@ToxicFrog>
\o/
04:42
< SmithKurosaki>
w00to/
04:42
< SmithKurosaki>
w00t o/
05:05
<@Vornicus>
yay
05:17
<@McMartin>
Good times.
05:17
<@McMartin>
Now I don't have to go to the office on Sunday
05:17
<@Vornicus>
Yaaaaaay
05:17
<@McMartin>
And I also now have a new work-related toy to play with
05:17
<@McMartin>
I may in fact do some work from home on Sunday just to see if I can pad my feature list for free~
05:20 Consul [~dmlandrum@Nightstar-2808.dsl.sfldmi.ameritech.net] has quit [Quit: Leaving]
05:30
<@ToxicFrog>
Event (de)serialization, transmission, reciept, and dispatching is now working, as is the core event loop.
05:31
<@ToxicFrog>
I now have all the tools I need to start writing the actual game logic.
05:31
<@ToxicFrog>
I think I will start with a completely trivial server that permits chat and discards all other events.
05:32
< simontwo>
which library do you use for event handling? and is this C or C++?
05:32
<@ToxicFrog>
My own coroutine/socket.select() based dispatcher, and neither, it's Lua.
05:34
< simontwo>
how much do you implement in Lua, and how much is just the foundation?
05:35
<@ToxicFrog>
The whole thing is lua, apart from the network and UI libraries, which are C (luasocket and lgui respectively).
05:35
<@ToxicFrog>
Note that this is not a realtime game.
05:36
< simontwo>
ah, didn't know there was a thing called luasocket.
05:37
<@ToxicFrog>
Blocking and nonblocking TCP, UDP, HTTP and FTP support, linux/windows/OSX.
05:37
<@ToxicFrog>
And lgui is a GTK/Glade binding.
05:37
<@ToxicFrog>
(it's been superceded by lgob.gtk, but that requires a very recent version of GTK+, so I'm sticking with lgui)
06:05 Syloqs-AFH [Syloq@ServicesAdmin.Nightstar.Net] has quit [Connection reset by peer]
08:18 Derakon[AFK] is now known as Derakon
08:23 * Derakon looks up. "Vorn: IMO you have three important things to work on: input, physics for the ball, and the fluid sim. Pick one -- I'd go with the fluid sim, personally -- and work on it."
08:30 * Vornicus has declared fluid sim unnecessary creep.
08:31
<@Vornicus>
I'm looking at ball physics right now, boning up on kinetics and rotational stuff.
08:36
<@Derakon>
Fair enough.
08:36
<@Derakon>
The aspects of fluid sim that you could actually use (explosions being volumetric) you can do without actual fluids anyway.
08:37
<@Derakon>
Or at least without high-res ones.
08:37
<@Vornicus>
I figured out how high-res and fast my fluid sim would have to be and I went "fucksticks" and left it.
08:37
<@Derakon>
Heh.
08:38
<@Vornicus>
Also I looked at some of the fluid dynamics shit and went "further fucksticks"
08:39
<@McMartin>
Liquids are hard.
08:39
<@McMartin>
Liquids are even hard in text.
08:42 Derakon is now known as Derakon[AFK]
08:43
<@Vornicus>
From what I can tell, I have to make at /least/ left and right work before I can really have a look at ball physics.
08:48 crem [~moo@Nightstar-28703.adsl.mgts.by] has quit [Connection reset by peer]
08:48
<@Vornicus>
Actually before I get into even /that/ I need to go osmose Harvey Cartel's collision tutorial.
08:51 UndeadAnno [AnnoDomini@Nightstar-29230.neoplus.adsl.tpnet.pl] has joined #Code
08:51 mode/#code [+o UndeadAnno] by ChanServ
09:05
<@Vornicus>
So let me see. First things fisrt I need collisions and left/right; after that I need the rest of physics.
09:06
<@UndeadAnno>
Implement Newton's laws. :P
09:10
<@Vornicus>
Oh. And before I can do /that/ I need to populate the ball, and that means more art, of a ball, that I can tell which direction it's pointed.
09:18 * TheWatcher[zZzZ] readsup
09:18 You're now known as TheWatcher
09:20
<@McMartin>
Put a face on it.
09:20
<@McMartin>
Worked for Nyfflas
09:20
<@Vornicus>
It did, at that.
09:21
<@TheWatcher>
Dera: a lot of the doxygen config can generally be left as-is, and chunks of it only become relevant once you enable non-default output formats. you can also install 'doxywizard' which helps with configuring it quite a lot.
09:26 * Vornicus should set up doxygen and actually figure out source control. Always gets bogged down when trying to structure the source tree, because so damn often it's a pain to change.
09:27
<@UndeadAnno>
Oh, speaking of documentation, how do I make Javadoc take the comments from a session bean and apply it to its remote interface?
09:27 * Vornicus first, though, declares bedtime.
09:37
<@TheWatcher>
Ni Vorn
09:37 Vornicus is now known as Vornicus-Latens
09:37
<@TheWatcher>
(and yeah, even svn with it's much-hyped ability to change the tree, is a pain in the arse if you actually need to do that most times)
09:38
<@McMartin>
(But at least it's *possible*.)
09:38
<@McMartin>
(CVS :argh:)
09:38
<@TheWatcher>
(true. Still far less sensible than it could be, though)
09:39 * Vornicus-Latens would really like to go "this is the folder. Everything in the folder? keep track of it."
09:41
<@Vornicus-Latens>
but now seriously bedtime yes
09:43
<@TheWatcher>
Tortoisesvn kinda does that on windows, but you still need to manually tell it when you're moving files or renaming things
09:43 * TheWatcher has occasionally pondered a VFS-level versioning system, but never has time to investigate the viability
09:44
<@Vornicus-Latens>
Meh. Windows and Mac both have event hooks for changes in a folder.
10:03 * UndeadAnno tries to understand how one would set off a managed bean method to load up stuff into variables so they could be used in a form in JSF.
10:40 Attilla [~The.Attil@Nightstar-9147.cdif.cable.ntl.com] has joined #code
10:40 mode/#code [+o Attilla] by ChanServ
11:04 UndeadAnno [AnnoDomini@Nightstar-29230.neoplus.adsl.tpnet.pl] has quit [Ping Timeout]
11:07 UndeadAnno [AnnoDomini@Nightstar-29033.neoplus.adsl.tpnet.pl] has joined #Code
11:07 mode/#code [+o UndeadAnno] by ChanServ
11:10 * TheWatcher idly <3 sed
11:53 * TheWatcher , out of curiosity, starts writing a perl code statistics calculator
12:05 Attilla is now known as Attilla_
12:05 Attilla_ is now known as Attilla
12:05 You're now known as TheWatcher[afk]
12:08 Rhamphoryncus [~rhamph@Nightstar-7168.ed.shawcable.net] has quit [Quit: Rhamphoryncus]
15:49
< Orthia>
These holidays, I think I shall learn to master regex. And... hm. Depending on how well Haskell manages that stuff, I may do it in there.
15:49
< Orthia>
Alternatively, Python could do it too.
15:50
< Orthia>
I want to be able to weild a regex to go through a couple thousand files, finding unique constants from specific lines. This would be a monster of a job without a regex. With it, though...
16:06 Syloqs_AFH [Syloq@Admin.Nightstar.Net] has joined #code
16:08 Syloqs_AFH is now known as Syloqs-AFH
16:23
< simontwo>
Orthia, it sounds like you should play the regex quiz at #regex@undernet.
16:23
< simontwo>
Orthia, it has 28 levels, but after 16-17 levels the regexes you build stop being practically useful compared to how hard they are to construct.
17:30 Consul [~dmlandrum@Nightstar-2808.dsl.sfldmi.ameritech.net] has joined #code
17:30 mode/#code [+o Consul] by ChanServ
17:32
< jerith>
Orthia: Depending on the nature of the thing, you may want a more explicit parser rather than a regex.
17:32
< jerith>
Also, Haskell apparently has spectacularly awesome parsing stuff.
18:02 Attilla [~The.Attil@Nightstar-9147.cdif.cable.ntl.com] has quit [Ping Timeout]
18:03 Attilla [~The.Attil@Nightstar-9147.cdif.cable.ntl.com] has joined #code
18:03 mode/#code [+o Attilla] by ChanServ
18:04
<@ToxicFrog>
Parsec. Yes.
18:07 Derakon[AFK] is now known as Derakon
18:13 jess_ [~jess@Nightstar-6870.dsl.teksavvy.com] has joined #code
18:14 ToxicFrog` [~ToxicFrog@Admin.Nightstar.Net] has joined #code
18:14 SmithKurosaki [~jess@Nightstar-14421.dsl.teksavvy.com] has quit [Operation timed out]
18:15 ToxicFrog [~ToxicFrog@Admin.Nightstar.Net] has quit [Ping Timeout]
18:16 jess_ is now known as SmithKurisaki
18:16 SmithKurisaki is now known as SmithKurosaki
18:54
<@Vornicus-Latens>
Wait, didn't McM write Parsec?
18:59 You're now known as TheWatcher
19:04
< ToxicFrog`>
No.
19:04
< ToxicFrog`>
Unless Daan Leijen is one of his aliases.
19:06
<@Vornicus-Latens>
Huh.
19:06 * Vornicus-Latens wonders where he got that impression.
19:14 Attilla [~The.Attil@Nightstar-9147.cdif.cable.ntl.com] has quit [Connection reset by peer]
19:15 Attilla [~The.Attil@Nightstar-9147.cdif.cable.ntl.com] has joined #code
19:15 mode/#code [+o Attilla] by ChanServ
19:39 Rhamphoryncus [~rhamph@Nightstar-7168.ed.shawcable.net] has joined #code
19:43 Attilla [~The.Attil@Nightstar-9147.cdif.cable.ntl.com] has quit [Connection reset by peer]
19:43 Attilla [~The.Attil@Nightstar-9147.cdif.cable.ntl.com] has joined #code
19:43 mode/#code [+o Attilla] by ChanServ
20:09
< gnolam>
... and my bank is /finally/ switching to a decent security solution.
20:09
< gnolam>
It's only taken them, what, 10 years? :P
20:19
< ToxicFrog`>
I'm still waiting for mine to start using asymkey authentication ;.;
20:29
< gnolam>
Note that this is the same bank that changed its password policy to require /two/ digits in each password. Because requiring two digits in an 8-12 character password makes it twice as hard to crack as requiring one, right? :P
20:30
< gnolam>
I'd given up hope that there was anyone there with a clue.
20:39
< simontwo>
my bank uses public-key cryptography. only, it's in a way where a state-sponsored company has all the "private" keys on a central server.
20:39
< simontwo>
and authentication happens through yet another certificate through their service. it's so horrible.
20:42
< jerith>
So, a gang of us have dramatically improved test coverage on elementtree in Python.
20:42
< jerith>
Uncovering (and fixing) several bugs in the process. :-)
20:50
<@McMartin>
That's the XML library?
20:57
<@UndeadAnno>
http://i43.tinypic.com/a3nr7t.jpg
21:00
<@McMartin>
That is both messed up and some of the worst use of generics I've ever seen.
21:01
<@McMartin>
Shouldn't l1 be a List<Authors>, given that you're doing a cast *anyway* and thus have to checkcast each element anyhow?
21:01
<@UndeadAnno>
I'm encountered this in the middle of converting Authors to Users.
21:02
<@UndeadAnno>
*I've
21:02
<@McMartin>
There's a Generic Cast, which checks each downcast internally, then another downcast (albeit one that checks zero elements), then the type is erased in an iterator whose results are downcast *again* to a *different* class.
21:02
<@McMartin>
That said, it's been awhile since I've used Java generics...
21:03
<@UndeadAnno>
I don't understand what I'm doing. I got the interator-using code from someone on IRC, and it works, and I'm happy. :P
21:03
<@McMartin>
Oh, it'll work.
21:03
<@McMartin>
It's just repeating a bunch of work and throwing it away.
21:04
<@McMartin>
... so... can't you instead replace List<Users> with List<Authors> in both places on the l1 line, define the Iterator to be an Iterator<Authors>, and thus have it.next() return you an Authors object directly without needing the cast?
21:04
<@UndeadAnno>
Er...
21:04
<@UndeadAnno>
s/Authors/Users
21:04
<@UndeadAnno>
EVERYWHERE.
21:05
<@UndeadAnno>
I had a method for Authors, now I'm changing it to Users.
21:05
<@UndeadAnno>
I screencapped in the middle.
21:05
<@McMartin>
oh.
21:05
<@McMartin>
OK, never mind~
21:05
<@McMartin>
In that case
21:05
<@McMartin>
Iterator can take <>s as well, and when you do, Iterator.next() doesn't return Objects, but instead the type you want.
21:06
<@McMartin>
So then you can just go Users usr = it.next();
21:07
<@UndeadAnno>
Cool.
21:07 * UndeadAnno goes eat.
21:33
< jerith>
McMartin: It is.
22:32 Attilla [~The.Attil@Nightstar-9147.cdif.cable.ntl.com] has quit [Ping Timeout]
22:48 Attilla [~The.Attil@Nightstar-9147.cdif.cable.ntl.com] has joined #code
22:48 mode/#code [+o Attilla] by ChanServ
23:18
<@Derakon>
I am greatly increasing the number of comments in my code...
23:18
< jerith>
The right kinds of comment, I hope?
23:18
<@Derakon>
(I'm writing Doxygen documentation, and since it's documentation, I kinda feel like all of the member fields should be commented even if their names make them mostly self-evident)
23:19
<@Derakon>
For example, Animation.updateFunc's purpose is clear if you know you're dealing with animations and are familiar with the Animation class...
23:21 * TheWatcher completely endorses this way of working
23:22 * TheWatcher also eyes this, wonders why it's not picking up the #! at the start of the file correctly
23:22 ToxicFrog` is now known as ToxicFrog
23:24
<@TheWatcher>
'open(CODE, $file) or die "ARGH: $!\n"; local $/; my $content = <CODE>; close(CODE); my @comments = $content =~ m{((?<!\\)\#.*?)$}gm;' seems to be utterly missing the '#!/usr/bin/perl -WT' in the first line
23:34 * ToxicFrog comes up with a horrible Haskell solution to PE #5
23:35
< ToxicFrog>
head [ x | x <- [1..], [] == [ y | y <- [11..20], mod x y /= 0]]
23:35
< ToxicFrog>
I'm not sure what the performance characteristics are, it's still running~
23:36 * TheWatcher facepalms, remembers to reset pos
23:46
< ToxicFrog>
Still running.
--- Log closed Sun Jun 07 00:00:49 2009
code logs -> 2009 -> Sat, 06 Jun 2009< code.20090605.log - code.20090607.log >