code logs -> 2020 -> Thu, 26 Nov 2020< code.20201125.log - code.20201127.log >
--- Log opened Thu Nov 26 00:00:38 2020
00:29 catalyst [catalyst@Nightstar-ejd4sd.cable.virginm.net] has quit [[NS] Quit: -a- Connection Timed Out]
00:30 catalyst [catalyst@Nightstar-ejd4sd.cable.virginm.net] has joined #code
01:51 Degi [Degi@Nightstar-qi2tn6.pool.telefonica.de] has quit [Ping timeout: 121 seconds]
01:52 Degi [Degi@Nightstar-lnt37e.pool.telefonica.de] has joined #code
02:22
<&ToxicFrog>
Gesture selection now works!
02:22
<&ToxicFrog>
The game is now actually interactive
02:23
<&ToxicFrog>
The rules engine isn't up and running yet, though, so the game is a real-time match of "first to surrender loses"
02:38
<&Reiver>
hahah
02:38
<&Reiver>
nice one!
02:41
<&ToxicFrog>
And I have now added server-side validation so that players cannot set their gestures to special values like :unseen or :antispell, and cannot knife with both hands.
02:43
<&ToxicFrog>
I now only have one more UI element to wire up (the SUBMIT button) and then I can actually start implementing the rules engine.
03:13 Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has quit [Connection closed]
05:40 celticminstrel [celticminst@Nightstar-5pqf1t.dsl.bell.ca] has quit [[NS] Quit: And lo! The computer falls into a deep sleep, to awake again some other day!]
08:49 Kindamoody[zZz] is now known as Kindamoody
09:31 Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has joined #code
09:31 mode/#code [+qo Vornicus Vornicus] by ChanServ
09:36 ErikMesoy [Bruker@Nightstar-hcpkod.bb.online.no] has left #code []
11:10 ErikMesoy [Bruker@Nightstar-hcpkod.bb.online.no] has joined #code
12:39 Kindamoody is now known as Kindamoody|afk
13:00 catalyst [catalyst@Nightstar-ejd4sd.cable.virginm.net] has quit [[NS] Quit: -a- Connection Timed Out]
13:01 catalyst [catalyst@Nightstar-ejd4sd.cable.virginm.net] has joined #code
13:17 VirusJTG [VirusJTG@Nightstar-42s.jso.104.208.IP] has quit [Connection closed]
13:18 VirusJTG [VirusJTG@Nightstar-42s.jso.104.208.IP] has joined #code
13:18 mode/#code [+ao VirusJTG VirusJTG] by ChanServ
13:37 Emmy [Emmy@Nightstar-l49opt.fixed.kpn.net] has joined #code
13:40
< ErikMesoy>
Have You Heard The Joy Of Split()?
13:42
< ErikMesoy>
Coworker was parsing a line of text in Python with "while line[i] != ';' : some_txt += line[i]", incrementing i at each step, incrementing i once more after the while loop ends, then starting a new while loop that string-builds character by character to a different output variable, then another i increment, then five more while-loops of the same condition.
13:45
< ErikMesoy>
He was happy to learn that split(';') works much more easily for this. I'm not sure how far I got with trying to enlighten him on the more general principle that there's usually an easier way to do it if he's doing something very repetitive (for example, seven while-loops in a row with the same condition).
13:50 FLHerne [flh@Nightstar-6tv.748.10.86.IP] has joined #code
13:50
<&[R]>
:/
13:51
<~Vornicus>
seven -- what?
13:54
< ErikMesoy>
there's seven text items to a line in a CSV file (technically Semicolon Separated Values) that he was parsing with seven While Character Is Not Semicolon, Output Character, Next Character loops.
13:54
<~Vornicus>
13:54
< ErikMesoy>
I mean, it *worked*, gotta give him credit for that
13:55
<~Vornicus>
if you have an ssv you can probably hand things to the `csv` module to handle all that for you
14:00
< ErikMesoy>
Module would probably be a good idea when we try to generalize this for other people's use, yes, thank you. :)
14:01
<&jeroud>
The `csv` module is great for anything that has consistent and unambiguous quoting rules.
14:02
<&jeroud>
Well, anything in the rows-containing-delimited-data family.
14:02
<&jeroud>
But if you have inconsistent or ambiguous quoting, woe. For in that case, nothing will work.
14:05
<&jeroud>
Things to be aware of: If you want to read rows as dicts, you need to provide an ordered list of column headers to the reader. You might have to manually read and parse this from the front of the file if it's in the file.
14:06
<&jeroud>
Also, know your encodings.
14:11
< ErikMesoy>
Nørwegiåns know their encodings very well, thank you, had that one repeatedly in the past. :)
14:14
< Emmy>
did i hear something about CSVs?
14:17
<&jeroud>
I love how some people talk about "CSV" as if it's a single well-defined format.
14:18
<&jeroud>
And by "love", I mean "sob quietly into my keyboard".
14:30
<@abudhabi>
I once implemented CSV parsing (couldn't use an existing library because [REDACTED]) using https://tools.ietf.org/html/rfc4180 as a guide.
14:32
<&jerith>
That describes the most common *sensible* variant, and the one I use when I have to emit "CSV".
14:33
< ErikMesoy>
jeroud: good for you. you know what they say, the penitent man shall parse.
15:07 catalyst [catalyst@Nightstar-ejd4sd.cable.virginm.net] has quit [Ping timeout: 121 seconds]
15:14 catalyst [catalyst@Nightstar-ejd4sd.cable.virginm.net] has joined #code
15:16 celticminstrel [celticminst@Nightstar-5pqf1t.dsl.bell.ca] has joined #code
15:16 mode/#code [+o celticminstrel] by ChanServ
15:24 FLHerne [flh@Nightstar-6tv.748.10.86.IP] has quit [Ping timeout: 121 seconds]
15:36 * TheWatcher sets Erik on fire for that one
16:02 * Emmy snerks
16:02
< Emmy>
yea, csv's are a fun 'format'
16:03
< Emmy>
in the past i did sin and simply used excel as parser XD
16:03
< Emmy>
slightly easier
16:03
< Emmy>
...well, until you factor in various culture data formats, that is.
16:16 FLHerne [flh@Nightstar-6tv.748.10.86.IP] has joined #code
16:27 Kindamoody|afk is now known as Kindamoody
17:33 FLHerne [flh@Nightstar-6tv.748.10.86.IP] has quit [Ping timeout: 121 seconds]
18:05 catalyst_ [catalyst@Nightstar-ejd4sd.cable.virginm.net] has joined #code
18:05 catalyst [catalyst@Nightstar-ejd4sd.cable.virginm.net] has quit [Connection closed]
18:44
<&[R]>
Or excel deciding something that isn't a date is a date and destroying the data
19:20 FLHerne [flh@Nightstar-6tv.748.10.86.IP] has joined #code
19:51 Pink [uid208117@Nightstar-h2b233.irccloud.com] has joined #code
21:28
< Emmy>
oh yes, excel == incel in that regard
22:09 FLHerne [flh@Nightstar-6tv.748.10.86.IP] has quit [[NS] Quit: There's a real world out here!]
23:30 Emmy [Emmy@Nightstar-l49opt.fixed.kpn.net] has quit [Ping timeout: 121 seconds]
23:43 Syloq [Syloq@NetworkAdministrator.Nightstar.Net] has quit [Operation timed out]
23:47 Syloq [Syloq@NetworkAdministrator.Nightstar.Net] has joined #code
23:47 mode/#code [+o Syloq] by ChanServ
--- Log closed Fri Nov 27 00:00:39 2020
code logs -> 2020 -> Thu, 26 Nov 2020< code.20201125.log - code.20201127.log >

[ Latest log file ]