*** tpb has joined #tp | 00:00 | |
*** ChanServ sets mode: +o tpb | 00:00 | |
mithro | ezod: poke poke? | 00:08 |
---|---|---|
CIA-69 | mithro libtpclient-py-singleplayer * rd7e6101a92dc /tp/client/SinglePlayer.py: Make the code a little clearer. | 00:45 |
CIA-69 | mithro tpclient-pywx-singleplayer * r696226a0eabb /windows/winConnect.py: First steps towards cleaning up the single player code. | 00:45 |
*** Greywhind has quit IRC | 02:55 | |
*** peres has joined #tp | 04:32 | |
*** bdefreese2 has joined #tp | 10:56 | |
*** welterde has quit IRC | 10:57 | |
*** Demitar has quit IRC | 10:57 | |
*** ezod has quit IRC | 10:57 | |
*** gau_veldt has quit IRC | 10:57 | |
*** tuna-fish has quit IRC | 10:57 | |
*** shenki has quit IRC | 10:57 | |
*** mithro has quit IRC | 10:57 | |
*** DTRemenak has quit IRC | 10:57 | |
*** JLP has quit IRC | 10:57 | |
*** mithro has joined #tp | 10:57 | |
*** tuna-fish has joined #tp | 10:57 | |
*** JLP has joined #tp | 10:57 | |
*** DTRemenak has joined #tp | 10:57 | |
*** Demitar has joined #tp | 10:57 | |
*** welterde has joined #tp | 10:57 | |
*** ezod has joined #tp | 10:57 | |
*** gau_veldt has joined #tp | 10:57 | |
*** shenki has joined #tp | 10:57 | |
*** bddebian has quit IRC | 11:12 | |
*** gau_veldt has quit IRC | 11:33 | |
*** gau_veldt has joined #tp | 11:34 | |
*** Greywhind has joined #tp | 12:23 | |
*** zzorn has quit IRC | 15:06 | |
*** zzorn has joined #tp | 15:12 | |
*** peres has left #tp | 15:13 | |
*** Demitar has quit IRC | 15:46 | |
ezod | hackathon! | 18:01 |
*** Iwanowitch has joined #tp | 18:03 | |
ezod | mithro: ping | 18:11 |
mithro | hey | 18:32 |
mithro | sorry I'm late | 18:32 |
ezod | hi | 18:33 |
ezod | no worries | 18:34 |
mithro | so I'm getting errors all over the place | 18:34 |
mithro | hey Iwanowitch | 18:34 |
ezod | errors from what? | 18:34 |
Iwanowitch | Heya. | 18:35 |
mithro | ezod: single player stuff when running through the wizard | 18:35 |
mithro | dang - xdotx bailed :( | 18:37 |
mithro | ezod: do you want me to walk through them? | 18:38 |
ezod | sure | 18:39 |
ezod | oh, i see one now - this might be coming from the changes to SinglePlayer.py, it's possible i didn't catch everything | 18:40 |
mithro | http://pastebin.com/da15a4b8 | 18:41 |
tpb | Title: pastebin - collaborative debugging tool (at pastebin.com) | 18:41 |
mithro | thats the first one | 18:42 |
mithro | the next one is caused by the rinfo being none when selecting a ruleset | 18:42 |
Greywhind | hey guys - anything i can do to help? | 18:44 |
ezod | fixing #1 | 18:46 |
mithro | Greywhind: sure - check out the server, AI and client and see if you can play a game of risk locally | 18:47 |
Greywhind | ok | 18:47 |
mithro | ezod: a couple of other things | 18:48 |
mithro | 1) all strings should be wrapped in _() so they get translated | 18:49 |
mithro | 2) Where you have multiple substitutions it's better for translation to use the dictionary form of string interpolation | 18:51 |
mithro | ezod: did you see a little bit of the cleanup I did last night? | 18:52 |
ezod | yes | 18:52 |
mithro | I was thinking maybe we should rename these files .tpconfig rather then .xml | 18:53 |
mithro | I noticed that you are currently opening all the build.xml files :) | 18:54 |
mithro | do we have versioning on these files? | 18:54 |
ezod | no, we probably should | 18:56 |
mithro | IE If we change the file in a backwards incompatible way we should be able to tell | 18:56 |
mithro | Greywhind: are you still on a mac? | 18:56 |
ezod | SinglePlayer.py checks that the dtd is tpconfig, but yes it does open probably a lot of other files it doesn't need to | 18:57 |
mithro | I'm not sure if ET is opportunistic loading the file - hence a large .xml could hang the client for a long time | 19:00 |
Greywhind | mithro: nope | 19:01 |
Greywhind | mithro: i'm on Fedora 10 | 19:01 |
Greywhind | mithro: what should i do to start the server for single player? | 19:06 |
JLP | ahoy everyone, sorry for being late | 19:06 |
mithro | Greywhind: it should be started by the wizard | 19:08 |
mithro | if you check out everything in the same directory | 19:08 |
mithro | and then build it | 19:08 |
Greywhind | mithro: wizard? | 19:08 |
mithro | Greywhind: okay lets start from the beginning | 19:09 |
Greywhind | k | 19:09 |
mithro | 1) checkout tpclient-pywx | 19:09 |
Greywhind | done | 19:09 |
mithro | 2) switch to the singleplayer branch | 19:09 |
Greywhind | can't remember the command for that | 19:09 |
mithro | 3) python requirements.py | 19:09 |
ezod | hi JLP | 19:09 |
mithro | git checkout origin/singleplayer -b singleplayer | 19:10 |
mithro | give that a try | 19:10 |
Greywhind | ok, done | 19:10 |
Greywhind | requirements seem fine | 19:11 |
mithro | cd libtpclient-py | 19:11 |
mithro | and switch to the singleplayer branch | 19:11 |
Greywhind | check | 19:11 |
mithro | okay | 19:12 |
mithro | now if you run ./tpclient-pywx there should be a singleplayer button | 19:12 |
mithro | Greywhind: that work? | 19:13 |
ezod | mithro: winConnect.py line 553 - why did you change == to !=? | 19:14 |
mithro | ezod: in trying to fix the error | 19:15 |
Greywhind | yeah, the single-player button is there | 19:15 |
mithro | okay now you click it | 19:15 |
Greywhind | i did - says the server isn't htere | 19:15 |
Greywhind | *there | 19:16 |
ezod | mithro: ok, ill take care of that | 19:16 |
mithro | okay | 19:16 |
mithro | so if you go up a level | 19:16 |
Greywhind | Braga tells you, "(You're not even there, she understands me.)" | 19:16 |
Greywhind | err | 19:16 |
mithro | in that directory should should have tpserver-cpp directory | 19:17 |
Greywhind | yeah | 19:17 |
mithro | go into that and do a ./configure and a make (no need to make install) | 19:17 |
Greywhind | ok, configuring. | 19:17 |
mithro | you'll also want to checkout daneel-ai so that you have someone to play against | 19:18 |
ezod | hrm, something is wrong with the rulesets in the new SinglePlayer.py | 19:21 |
ezod | ruleset_info is not working | 19:25 |
mithro | :/ - any idea why? | 19:25 |
mithro | It didn't seem to find any of the ruleset xml files? | 19:25 |
mithro | Found single player xml file at ../tpserver-cpp/../tpserver-cpp/devserver.xml | 19:25 |
mithro | Found single player xml file at ../tpserver-cpp/../tpserver-cpp/tpserver-cpp.xml | 19:25 |
mithro | Found single player xml file at ../daneel-ai/../daneel-ai/devai.xml | 19:25 |
mithro | Found single player xml file at ../daneel-ai/../daneel-ai/daneel-ai.xml | 19:25 |
Greywhind | ok, hmm - it's still not seeing any servers | 19:26 |
ezod | looking into it, ill push the fix shortly | 19:26 |
Greywhind | the client is in /Programming/ThousandParsec/tpclient-pywx/ | 19:26 |
Greywhind | the server is in /Programming/ThousandParsec/tpserver-cpp/ | 19:26 |
Iwanowitch | Strangem it seems to check the parent folder fine here. | 19:27 |
Iwanowitch | *Strange, ... | 19:27 |
Iwanowitch | Is there a tpserver-cpp.xml in the tpserver-cpp dir? | 19:28 |
JLP | found my server installed systemwide, but didn't find ../daneel-ai after adding a couple of opponents | 19:29 |
Greywhind | Iwanowitch: yes | 19:29 |
CIA-69 | mavrinac libtpclient-py-singleplayer * r646b8ede4401 /tp/client/SinglePlayer.py: Show proper path in 'found XML file' message. | 19:30 |
ezod | looks like it isn't ruleset_info after all | 19:30 |
Greywhind | any ideas on what i might be doing wrong? | 19:34 |
Greywhind | do i need a specific branch of tpserver-cpp? | 19:35 |
CIA-69 | mithro libtpclient-py-singleplayer * r0eecbc201849 /tp/client/SinglePlayer.py: Make the searching log more. | 19:35 |
mithro | Greywhind: just pushing some stuff which should make it easier to figure out what is going on | 19:35 |
mithro | give that a try and pastebin the output | 19:35 |
Greywhind | [Greywhind@localhost tpclient-pywx]$ git pull | 19:36 |
Greywhind | Already up-to-date. | 19:36 |
mithro | libtpclient-py | 19:37 |
Greywhind | oh... maybe i have to do it in the libtpclient-py subdir | 19:37 |
Greywhind | right | 19:37 |
Greywhind | oh - now it seems to see the server | 19:37 |
Greywhind | odd | 19:37 |
ezod | always need to do git submodule update | 19:39 |
Greywhind | http://rafb.net/p/F1bBmc63.html | 19:39 |
tpb | Title: Nopaste - No description (at rafb.net) | 19:39 |
Greywhind | ^ it saw the server, but didn't seem to find an AI | 19:40 |
Iwanowitch | Hmm. Install path display would perhaps be kind of cool when selecting a server/AI client. And the last few windows of the wizard are a bit buggy it seems. | 19:40 |
mithro | Found single player xml file at ../daneel-ai/../daneel-ai/devai.xml - including | 19:40 |
Greywhind | yeah, but there were no options on the "add players" screen | 19:41 |
ezod | major storm here, hoping for no power outages | 19:41 |
mithro | yeah - that appears to be related to this bug | 19:41 |
Greywhind | ok | 19:41 |
mithro | Traceback (most recent call last): | 19:41 |
mithro | File "./windows/winConnect.py", line 242, in OnRuleset | 19:41 |
mithro | self.next.OnServer(None) | 19:41 |
mithro | File "./windows/winConnect.py", line 295, in OnServer | 19:41 |
mithro | self.ServerRulesetDesc.SetLabel(_("Implements %(longname)s version %(version)s.") % rinfo) | 19:41 |
mithro | TypeError: format requires a mapping | 19:41 |
mithro | ezod: no UPSes? | 19:41 |
ezod | mithro: negative | 19:41 |
mithro | ezod: any thoughts on that error? | 19:43 |
mithro | ezod: it means that rinfo is none rather then a dictionary | 19:43 |
ezod | yes, i haven't figured out why | 19:44 |
ezod | this is really strange | 19:44 |
ezod | anyway, its my focus right now | 19:44 |
mithro | rinfo = self.parent.game.ruleset_info() | 19:46 |
Iwanowitch | I'm also getting | 19:46 |
mithro | that is the problem function | 19:46 |
Iwanowitch | File "./windows/winConnect.py", line 250, in OnRuleset | 19:46 |
Iwanowitch | Configure options for the %(longname)s ruleset (leave blank to use default):""") % self.parent.game.ruleset_info(self.parent.game.rname)['longname']) | 19:46 |
Iwanowitch | TypeError: format requires a mapping | 19:46 |
Iwanowitch | A bit earlier. | 19:46 |
mithro | my guess is this | 19:47 |
mithro | try: | 19:47 |
mithro | return self.locallist['server'][sname]['ruleset'][rname] | 19:47 |
mithro | except KeyError: | 19:47 |
mithro | return None | 19:47 |
ezod | Iwanowitch: that's related | 19:47 |
ezod | mithro: i think i got it | 19:47 |
Iwanowitch | Kay. | 19:47 |
ezod | mithro: the server name is apparently not being set properly, fixing | 19:48 |
ezod | OnServer is being called at the wrong time it seems | 19:50 |
ezod | actually | 19:52 |
ezod | ah, now i have you | 19:52 |
mithro | so... | 19:59 |
ezod | still something wrong | 20:01 |
ezod | main problem is fixed though | 20:01 |
mithro | ezod: main enough problem that we can start a game? | 20:02 |
mithro | Iwanowitch: btw - did you need some help with the risk ruleset? | 20:05 |
mithro | s/risk/rfts/ | 20:05 |
mithro | JLP: where is the translation of tpclient-pywx at? | 20:07 |
CIA-69 | mavrinac tpclient-pywx-singleplayer * rcdabdccc78bb /windows/winConnect.py: Fix bugs related to server and ruleset info. | 20:08 |
Iwanowitch | mithro: Hmm, I haven't really thouht about it anymore. | 20:08 |
JLP | mithro: you mean in locale/sl? or the finished one? | 20:09 |
ezod | mithro: there were actually 2 separate bugs, hence the confusion | 20:09 |
mithro | ezod: ah | 20:09 |
ezod | with astonishingly similar effects | 20:09 |
mithro | Iwanowitch: do you think we could work to find the bug you where hitting before? | 20:09 |
mithro | Iwanowitch: also - could we add minisec support? | 20:09 |
mithro | (minisec support should be *really* trivial for you) | 20:09 |
CIA-69 | mithro daneel-ai * r4e4601d1b89e /debian/control: Fixed the dependency for daneel-ai deb packages. | 20:10 |
Iwanowitch | Right, that rfts bug, I'll take a look at it now. | 20:10 |
Iwanowitch | Minisec should be pretty possible yes. | 20:10 |
JLP | aha, ruleset options showed up and everything was found and the game started now | 20:12 |
mithro | ezod: | 20:12 |
mithro | Traceback (most recent call last): | 20:12 |
mithro | File "./windows/winConnect.py", line 558, in OnPageChanging | 20:12 |
mithro | event.GetPage().next.OnRuleset(None) | 20:12 |
mithro | File "./windows/winConnect.py", line 211, in OnRuleset | 20:12 |
mithro | self.parent.game.rname = self.parent.game.rulesets[self.Ruleset.GetSelection()] | 20:12 |
mithro | IndexError: list index out of range | 20:12 |
mithro | that occurs when no servers are installed | 20:12 |
CIA-69 | mavrinac libtpclient-py-singleplayer * r9d76ac1237fa /tp/client/SinglePlayer.py: Handle case in ruleset_info where rname is set but sname is not. | 20:12 |
*** pschulz01 has joined #tp | 20:13 | |
mithro | hey pschulz01 | 20:13 |
ezod | mithro: taking a look | 20:13 |
Iwanowitch | Woo. Seems to work fine. | 20:13 |
pschulz01 | mithro: Just poking my head in. | 20:14 |
Iwanowitch | The add opponent window could use some polish, but it functions, so okay for now. | 20:14 |
Greywhind | the wizard works fine now | 20:14 |
mithro | Greywhind: could you look at the problem with deleting all messages in the message window? | 20:15 |
Greywhind | which problem is that? | 20:16 |
ezod | Iwanowitch: no doubt, that window is extremely ugly atm | 20:16 |
Greywhind | is there a description of it somewhere? | 20:16 |
mithro | when you click the button you get the following error | 20:16 |
mithro | Traceback (most recent call last): | 20:16 |
mithro | File "./windows/main/panelMessage.py", line 422, in OnDelete | 20:16 |
mithro | self.application.Post(self.application.cache.apply("messages", "remove", self.bid, node, None), source=self) | 20:16 |
mithro | File "libtpclient-py/tp/client/cache.py", line 240, in apply | 20:16 |
mithro | evt = Cache.CacheDirtyEvent(*args, **kw) | 20:16 |
mithro | File "libtpclient-py/tp/client/cache.py", line 98, in __init__ | 20:16 |
mithro | assert node.inlist() | 20:16 |
mithro | AttributeError: 'NoneType' object has no attribute 'inlist' | 20:16 |
Iwanowitch | There's strange things in the output though... It looks as if the bot keeps on running and running again, but the turn doesn't advance? | 20:16 |
Greywhind | mithro: looking at it now | 20:18 |
mithro | if you start up a game | 20:18 |
mithro | and just delete all the messages you should get something like that | 20:18 |
Greywhind | yeah, i did it | 20:18 |
mithro | Greywhind: it have the same error? | 20:19 |
Iwanowitch | Hrmf. I can't end the turn now. | 20:19 |
mithro | ezod: can we make the list of rulesets sorted? | 20:20 |
Greywhind | mithro: yes | 20:20 |
mithro | Greywhind: great | 20:20 |
mithro | ezod: so a couple of problems | 20:21 |
mithro | 1) The default values should really be filled out | 20:21 |
mithro | 2) The map should have a "select file" dialogue | 20:21 |
mithro | ezod: which one do you want to tackle? I'll look at the other | 20:21 |
mithro | 3) The add-opponent panel doesn't reflow when the oponents names are added | 20:22 |
mithro | 4) there is no way to go back and change the current opponents | 20:22 |
mithro | I might look at 3 and 4? | 20:23 |
CIA-69 | mavrinac tpclient-pywx-singleplayer * r7cddc22ad018 /windows/winConnect.py: Fix bug in start page of single player wizard. | 20:23 |
mithro | Iwanowitch: poke me if you need any help | 20:24 |
JLP | 5) don't allow to add opponents with the same names | 20:24 |
Iwanowitch | Thre's definitely something broken in ending turns in singleplayer mode. | 20:24 |
Iwanowitch | Either with the server or the AI client or some settings used for single player stuff. | 20:25 |
ezod | mithro: comments on those 4 issues | 20:25 |
ezod | 1) default values come from the XML file - if they're in there, they're in the wizard, no? | 20:25 |
*** pschulz01 has quit IRC | 20:25 | |
mithro | hrm - daneel-ai is not starting up properly for me | 20:25 |
mithro | Iwanowitch: could that be your problem too? | 20:26 |
mithro | check "ps fax" | 20:26 |
mithro | mine looks like | 20:26 |
mithro | 26393 pts/1 Sl+ 0:09 | \_ python ./tpclient-pywx | 20:26 |
mithro | 26652 pts/1 S 0:00 | \_ /bin/sh -c ./tpserver-cpp -d --configure /dev/null --ruleset ../modules/games/risk/.libs/librisk --tp_port 54943 --game_load yes | 20:26 |
mithro | 26653 pts/1 S 0:00 | | \_ ./tpserver-cpp -d --configure /dev/null --ruleset ../modules/games/risk/.libs/librisk --tp_port 54943 --game_load yes --game | 20:26 |
mithro | 26654 pts/1 Z 0:00 | \_ [sh] <defunct> | 20:26 |
mithro | 26655 pts/1 Z 0:00 | \_ [sh] <defunct> | 20:26 |
ezod | 2) we can implement this by adding "file" to the parameter types in the XML files - i can do that, but will require a bit of work | 20:26 |
mithro | those two '[sh] <defunct>' should have been daneel-ai | 20:26 |
Iwanowitch | Yes, I also have that. | 20:27 |
ezod | 3) gui issue, my wx/xrc fu is weak, im sure there's a way to do this but i don't know it | 20:27 |
Iwanowitch | Thought I think previous time it worked fine because there was daneel-ai output being spewed in console. | 20:27 |
Iwanowitch | Then again, multiple times per turn, so that's also a bit off. :P | 20:27 |
mithro | ezod: yeah - how much work do you think? The file dialog is a stock widget - we should also make sure it provides a way to filter the input and a starting directory to look for it | 20:27 |
mithro | Iwanowitch: do you want to restart the game (close down tpclient-pywx and start again?) | 20:28 |
ezod | 4) the whole opponent window should actually be redone to have a listbox instead of the crappy way it works now | 20:28 |
ezod | wrt above, i just didn't know how to do it, and ran out of time at end of gsoc | 20:28 |
mithro | 2009-03-08 12:29:02 < Debug > Adding a file descriptor 10 | 20:29 |
mithro | /bin/sh: daneel-ai: not found | 20:29 |
mithro | Connecting to localhost <type 'unicode'> 58716 <type 'int'> | 20:29 |
mithro | ezod: well I can do 3/4 | 20:29 |
mithro | I'll do them right now as soon as we figure out the daneel-ai problem | 20:30 |
ezod | mithro: i shouldn't think too much, but i probably don't need help with it so i can do it another time (so we can get other stuff fixed now) | 20:30 |
ezod | although if im idle at any point in this hackathon ill start working on it | 20:31 |
mithro | ezod: I should only take me an hour or two to do 3/4 | 20:31 |
Iwanowitch | So it should probably use absolute path when starting a server/AI or something? | 20:31 |
mithro | probably quicker for me to do it | 20:31 |
ezod | mithro: so are you going to make a list or something for opponents? i really don't like the way it works now | 20:31 |
mithro | Iwanowitch: I think it's picking up the "installed" version rather then "devel" version | 20:32 |
mithro | ezod: yeah | 20:32 |
ezod | mithro, Iwanowitch: you need to pick "daneel-ai (Development)" - its probably seeing the other xml file that is intended for installed version | 20:33 |
ezod | which i mentioned the other day | 20:33 |
Iwanowitch | Yeah, I probably picked the wrong one. | 20:33 |
mithro | ezod: I think we should be checking that the files the XML says exist - actually exist? | 20:33 |
Greywhind | mithro: hmm... it seems like the ChangeList it's searching in to find the node to delete has a head with "none" as its _what | 20:33 |
Greywhind | when it should be something like TP03|New Player&New player lahtis has joined the game.¿½���� | 20:34 |
mithro | Greywhind: you mean a message frame? | 20:34 |
Greywhind | basically, this is returning "none": node = self.application.cache.messages[self.bid].find(self.node._what) | 20:35 |
ezod | mithro: i'll add that check in, doesn't cover every possible problem but it will help | 20:35 |
Greywhind | and printing out self.head._what inside that find call is showing "None" | 20:35 |
Greywhind | and self.head has no .right | 20:36 |
mithro | Greywhind: kind of makes sense - the list only has one element right? | 20:36 |
Iwanowitch | Hmm. Daneel-ai still seems to be calling his logic endlessly instead of once per turn, but I think that's my fault for not handling situations without an end-of-turn time specified. | 20:36 |
Greywhind | mithro: well, it makes sense that there's no second node | 20:37 |
mithro | Iwanowitch: did you try setting a timelimit in the client? | 20:37 |
Greywhind | mithro: but the head should then have the data to delete, but it doesn't seem to | 20:37 |
Iwanowitch | I still can't progress past turn 2, but that might be related. | 20:38 |
Greywhind | unfortunately, i have to go eat dinner soon so i can get to work on time | 20:38 |
Iwanowitch | The time limit option doesn't actually seem to work. I think. | 20:40 |
Iwanowitch | Turn length, that is. | 20:40 |
Iwanowitch | It still displays as EOT: Unknown if I set it to, say, 120. | 20:41 |
Iwanowitch | Ah, when sending end of turn myself, it starts counting down. | 20:42 |
Iwanowitch | That sounds like the wrong value is being set... | 20:42 |
JLP | yeah and it counts down if you clear the turn length field instead of leaving 0 | 20:43 |
Greywhind | mithro: ok, well, i have to go for now | 20:44 |
mithro | Greywhind: okay - if you get a chance later - can you see if you can fix that bug before I get to it? | 20:45 |
Greywhind | i might have time to look at it tomorrow | 20:45 |
Greywhind | but i have to work until 2:30 AM | 20:45 |
mithro | Greywhind: that would be great | 20:45 |
Greywhind | so not tonight | 20:45 |
Greywhind | mithro: ok, see you later | 20:45 |
mithro | ezod: can you help Iwanowitch? | 20:46 |
Iwanowitch | Anyway, I've just been beaten by my bot. | 20:47 |
mithro | ha :P | 20:47 |
Iwanowitch | Although I actually only played sitting duck, but well. It's something. :P | 20:47 |
CIA-69 | mavrinac libtpclient-py-singleplayer * r9dba9c96ee1d /tp/client/SinglePlayer.py: Verify that files pointed to in local list actual exist. | 20:49 |
ezod | mithro, Iwanowitch: what exactly is the problem? | 20:50 |
Iwanowitch | ezod: The turn length option in the wizard doesn't do what it's supposed to do. | 20:51 |
Iwanowitch | It only starts counting down after I send my turn completed frame. | 20:51 |
Iwanowitch | Which, I think, is another option in the server configuration. | 20:52 |
ezod | Iwanowitch: ok, i know what you're talking about, i ran into that as well | 20:52 |
ezod | Iwanowitch: the problem is evidently that i am not configuring tpserver-cpp properly, although i am not sure why | 20:53 |
ezod | i do: --turn_length_over_threshold %d | 20:53 |
ezod | and --turn_player_threshold 100 | 20:53 |
ezod | (where %d comes from the turn length setting in the wizard) | 20:54 |
ezod | i guess i should be doing something else? | 20:54 |
mithro | umm | 20:54 |
llnz | ummm... | 20:54 |
* llnz checks the docs | 20:54 | |
ezod | note that i do not have any recollection of why i did it that way :( | 20:55 |
Iwanowitch | I think it's better to use turn_player_under_treshold | 20:55 |
Iwanowitch | Or well, hmm. | 20:56 |
llnz | i think i know | 20:56 |
ezod | anyway, whatever should happen needs to be put in devserver.xml and tpserver-cpp.xml in the tpserver-cpp repo | 20:56 |
Iwanowitch | You also want to wait on AI players probably. | 20:56 |
llnz | basically, if you want the turn to finish when all the players say they are finished, set turn_length_over_threashold to 0 | 20:57 |
llnz | with the player_finished_threshold to 100 | 20:57 |
llnz | if you set turn_length_under_threshold, that will be the maximum turn length | 20:57 |
llnz | shall i fix the devserver.xml and tpserver-cpp.xml? | 20:58 |
ezod | llnz: by all means :) | 20:58 |
mithro | ezod: I think instead of "devserver" it would probably be better named "tpserver-cpp-inplace.xml" or similar? | 20:59 |
mithro | ezod: so how does this all work if the server and AI are all packaged with the client? | 20:59 |
ezod | mithro: re: devserver, agreed | 21:01 |
CIA-69 | llnz tpserver-cpp * r56b8575528c9 / (devserver.xml tpserver-cpp.xml.in): | 21:01 |
CIA-69 | Fixed xml files for setting turn length in SPM. | 21:01 |
CIA-69 | You will need to re-run configure and install before the installed version | 21:01 |
CIA-69 | is updated. | 21:01 |
ezod | mithro: i need to know how exactly they are packaged (directory structure) | 21:02 |
mithro | ezod: that depends on what is easyist, but all under the tpclient-pywx directory | 21:02 |
ezod | mithro: but it looks for all tpconfig xml files anywhere in the search path, so its just a matter of making sure those directories are in the search path, if they aren't already | 21:02 |
mithro | say for a Mac DMG | 21:03 |
mithro | everything would be in the DMG | 21:03 |
mithro | (same with a windows exe) | 21:03 |
ezod | well the xml files have to be somewhere, right? | 21:05 |
ezod | dmg is a fs image? | 21:05 |
mithro | yes | 21:06 |
ezod | well, before we do said packages, we need to make sure that the search path in SinglePlayer.py includes the proper directories | 21:07 |
ezod | everything else should work fine | 21:07 |
ezod | also the win32 registry stuff in SinglePlayer.py has not been fully tested | 21:09 |
ezod | by fully, i mean in an actual setup on windows with tpclient-pywx and some server/ai installed | 21:10 |
mithro | ezod: this is where I'm up to with the opponents page | 21:17 |
mithro | http://www.thousandparsec.net/~tim/sp.png | 21:17 |
llnz | mithro: looks good | 21:18 |
mithro | It doesn't actually work yet - but that is the UI I'm kinda working towards | 21:18 |
ezod | mithro: very nice | 21:18 |
ezod | mithro: thats precisely what i had in mind :D | 21:18 |
mithro | ezod: thoughts so :) - great minds think alike | 21:18 |
ezod | mithro: need a remove button though? | 21:18 |
mithro | Probably | 21:19 |
mithro | The Add should become an edit/save/change when you select an existing AI | 21:19 |
mithro | ezod: It would actually be really good to add "profile" support sometime in the distant future | 21:19 |
mithro | IE You just load a profile and it answers all these questions for you - gives you a standard set of AI, etc) | 21:20 |
ezod | mithro: cool idea - "load scenario" sort of thing | 21:20 |
mithro | yeah | 21:20 |
mithro | does daneel-ai have any options? | 21:23 |
mithro | Iwanowitch: poke? | 21:23 |
Iwanowitch | Err. Check daneel-ai -h | 21:23 |
Iwanowitch | Most are not very interesting. | 21:23 |
mithro | we should probably move daneel-ai to submodules sometime | 21:25 |
mithro | Iwanowitch: any luck with minisec or rfts probelm? | 21:25 |
Iwanowitch | mithro: No, not really. Not entirely sure what the bug was with RFTS. | 21:27 |
mithro | so ezod what you working on? | 21:28 |
ezod | looking into that file parameter thing | 21:28 |
mithro | Ah cool | 21:30 |
* mithro just put lunch on | 21:30 | |
mithro | ezod: where is the code to actually add the opponents? | 21:36 |
CIA-69 | mavrinac libtpclient-py-singleplayer * r056ca4dae56d /tp/client/SinglePlayer.py: Support formatting for file type parameters. | 21:37 |
Iwanowitch | Is there a way to reduce the server output? I'm slightly more interested in the daneel output... | 21:40 |
ezod | mithro: SinglePlayerGame.add_opponent() | 21:40 |
ezod | mithro: line 590 in winConnect.py | 21:41 |
mithro | ahh - it's in a totally different place | 21:41 |
ezod | yes, because it happens on page change in the current (crappy) design | 21:42 |
mithro | so how do I do the equivalent to this? | 21:43 |
mithro | # store server parameters | 21:43 |
mithro | self.game.sparams = {} | 21:43 |
mithro | for opt in self.game.list_sparams().keys(): | 21:43 |
mithro | self.game.sparams[opt] = str(event.GetPage().Params[opt].GetValue()) | 21:43 |
ezod | erm. | 21:45 |
mithro | well | 21:45 |
mithro | well - just the clear current opponents? | 21:45 |
ezod | well, you can touch the individual opponents in SinglePlayer.opponents (dict) | 21:45 |
ezod | s/dict/list | 21:46 |
mithro | I can just assign it a new list? | 21:46 |
ezod | yeah | 21:47 |
Iwanowitch | Mrmf. I'm off, getting too tired. | 21:47 |
ezod | all add_opponent() does is check for unique username, and add the appropriately formatted dict | 21:47 |
ezod | appended to SinglePlayerGame.opponents | 21:47 |
ezod | the items in SinglePlayerGame.opponents have to look like this | 21:48 |
JLP | Iwanowitch: for less server output you can use -l option set to 5 | 21:48 |
ezod | { 'name' : <name-of-aiclient>, 'user' : <some-unique-username>, 'parameters' : <parameters> } | 21:48 |
mithro | Iwanowitch: looking forward to Risk an minsec AI :) | 21:49 |
Iwanowitch | RFTS and minisec? :) | 21:49 |
Iwanowitch | Or is there something wrong with the Risk one too? | 21:50 |
Iwanowitch | (well, apart from slowness and the EOT stuff) | 21:50 |
Iwanowitch | (and being generally mediocre) | 21:50 |
mithro | well I think the Risk one works? | 21:50 |
Iwanowitch | Yeah, it seems to work. | 21:52 |
Iwanowitch | It manages to beat me anyway. | 21:52 |
mithro | a minisec AI should be trivial (and it would be a good "here is how to make a the AI work" type tutorial) | 21:52 |
Iwanowitch | Fulfilling at least some loose definition of working. :P | 21:52 |
mithro | well - now I just need to get the add/list interaction working and this should be set | 21:53 |
Iwanowitch | Mmm, I should probably combine minisec with a tutorial on the wiki indeed. | 21:53 |
Iwanowitch | Anyway. | 21:53 |
Iwanowitch | Later. | 21:53 |
Iwanowitch | Happy hacking. | 21:54 |
*** Iwanowitch has quit IRC | 21:54 | |
*** llnz has quit IRC | 21:55 | |
*** llnz2 has joined #tp | 21:55 | |
*** llnz2 is now known as llnz | 21:55 | |
mithro | wb llnz | 21:56 |
llnz | thanks, the wifi doesn't work too well here | 21:56 |
llnz | in this particular spot | 21:57 |
CIA-69 | mavrinac tpclient-pywx-singleplayer * ree2e156b8bf3 /windows/winConnect.py: Move population of parameter controls to a single function. | 22:13 |
ezod | mithro: that might conflict with what you're working on.. | 22:13 |
mithro | ezod: it appears that it would have been easier to do this the list way first :) | 22:15 |
ezod | mithro: btw, how does your new opponents page actually handle parameters? | 22:16 |
mithro | hrm? | 22:16 |
ezod | ai clients have parameters like servers and rulesets | 22:16 |
ezod | where do the input boxes for those go? | 22:16 |
ezod | oh, nm, i am blind | 22:17 |
ezod | ok, so i touched RefreshOpts() function in OpponentPage, that most likely conflicts | 22:18 |
mithro | yeah - I had not touched that function much | 22:19 |
ezod | it may be affected by the xrc layout, dunno what you're doing - have a quick look at the commitdiff | 22:19 |
mithro | how do you do the oposite of populateopts? | 22:19 |
mithro | yeah I pull and merged | 22:20 |
ezod | ok | 22:20 |
ezod | opposite? | 22:20 |
mithro | as in create a dictionary from the values shown | 22:21 |
ezod | for opt in self.game.locallist['aiclient'][ainame]['parameter'].keys(): | 22:22 |
ezod | aiparams[opt] = str(event.GetPage().Params[opt].GetValue()) | 22:22 |
ezod | and then aiparams gets passed to add_opponent | 22:22 |
ezod | if you're touching SinglePlayerGame.opponents directly, just set 'paramters' to aiparams | 22:25 |
mithro | okay | 22:29 |
ezod | 'parameters' even | 22:30 |
CIA-69 | mavrinac tpserver-cpp * ra702c5d4400f / (devserver.xml modules/games/risk/tpserver-cpp-risk.xml): Change risk_map parameter to F (file) type in SP XML files. | 22:42 |
mithro | daneel-ai test {} | 22:48 |
mithro | Traceback (most recent call last): | 22:48 |
mithro | File "./windows/winConnect.py", line 604, in OnPageChanging | 22:48 |
mithro | self.game.add_opponent(**opponent) | 22:48 |
mithro | File "libtpclient-py/tp/client/SinglePlayer.py", line 360, in add_opponent | 22:48 |
mithro | 'user' : aiuser.translate(''.join([chr(x) for x in range(256)]),' '), | 22:48 |
mithro | TypeError: translate() takes exactly one argument (2 given) | 22:48 |
mithro | whats the translate suppose to do? | 22:48 |
ezod | i am drawing a blank | 22:49 |
ezod | commenting failure on my part | 22:49 |
mithro | if I understand the code | 22:50 |
mithro | it replaces every character below 256 with a ' ' | 22:51 |
ezod | yes | 22:51 |
ezod | that doesn't seem right though | 22:51 |
mithro | yeah | 22:51 |
mithro | I can't see that ever working properly | 22:51 |
ezod | >>> aiuser = 'test' | 22:52 |
ezod | >>> aiuser.translate(''.join([chr(x) for x in range(256)]),' ') | 22:52 |
ezod | 'test' | 22:52 |
mithro | hrm | 22:52 |
mithro | translate(s, table, deletions='') | 22:52 |
mithro | translate(s,table [,deletions]) -> string | 22:52 |
mithro | 22:52 | |
mithro | Return a copy of the string s, where all characters occurring | 22:52 |
mithro | in the optional argument deletions are removed, and the | 22:52 |
mithro | remaining characters have been mapped through the given | 22:52 |
mithro | translation table, which must be a string of length 256. The | 22:52 |
mithro | deletions argument is not allowed for Unicode strings. | 22:52 |
mithro | maybe you are just trying to remove the space? | 22:52 |
ezod | i guess so :) | 22:53 |
ezod | doesn't seem like the least obfuscated way to go about that | 22:53 |
mithro | ezod: I think you should probably just reject something which doesn't match [A-Za-z0-9] | 22:53 |
ezod | mithro: agreed - there is potential for massive problems there | 22:54 |
mithro | ezod: you want to add that? | 22:54 |
ezod | i am envisioning your idea for loading scenarios, where someone downloads a scenario containing an aiuser named '; rm -rf ~/*' or something | 22:55 |
mithro | yeah | 22:55 |
mithro | I values should be restricted to 0-9+ | 22:55 |
mithro | I == type | 22:56 |
ezod | is there a way to force this on the gui end? | 22:56 |
mithro | yes - but I think you need to do it in the SinglePlayer to | 22:57 |
ezod | will do both | 22:58 |
mithro | I can do the client side | 22:58 |
mithro | you use validators which mean the person can't even type the wrong characters | 22:58 |
ezod | well actually i plan on testing for type in PopulateOpts and putting different controls accordingly - so i can just do that there | 22:59 |
mithro | okay | 22:59 |
mithro | do you have the wxDemos installed? | 22:59 |
ezod | somewhere, i think - which one should i look at? | 23:00 |
mithro | look for the "Validators" section | 23:00 |
ezod | btw, i promised a friend i'd meet him for birthday post-hackathon, so i have to get going soon | 23:00 |
ezod | ok | 23:01 |
mithro | what is with everyone having birthdays today? | 23:01 |
ezod | should have the different field types in PopulateOpts committed tomorrow | 23:01 |
mithro | xdotx and pshulz where both going to birthdays too | 23:02 |
ezod | really? | 23:02 |
mithro | hrm - I can't figure out why no opponents are being created | 23:02 |
mithro | how do I make tpserver-cpp quieter? | 23:02 |
ezod | theres a log_level option, you can put a <forced> tag in for it, 1 sec | 23:03 |
ezod | <forced>--log_level 5</forced> maybe? | 23:04 |
ezod | doesn't seem to work :( | 23:05 |
ezod | oh nm it does | 23:05 |
ezod | <forced>--log_level 4</forced> in devserver.xml will shut it up | 23:05 |
mithro | can we do that rename now before we get stuck with it? :P | 23:06 |
ezod | the nomenclature in the file itself is dev-tpserver-cpp | 23:06 |
ezod | is dev-*.xml acceptable? | 23:06 |
mithro | hrm I think we should call it "inplace" | 23:07 |
ezod | ok | 23:08 |
ezod | tpserver-cpp-inplace.xml? | 23:08 |
mithro | yeah - that sounds good | 23:08 |
mithro | I'll create a tpserver-py-inplace.xml sometime | 23:08 |
CIA-69 | mavrinac tpserver-cpp * r5cf06706743f / (devserver.xml tpserver-cpp-inplace.xml): Rename in-place SP XML file. | 23:09 |
mithro | thanks :P | 23:09 |
mithro | did you finish the only show executable stuff? | 23:09 |
CIA-69 | mavrinac daneel-ai * r81f43d46b5c2 / (daneel-ai-inplace.xml devai.xml): Rename in-place SP XML file. | 23:10 |
ezod | yes | 23:10 |
ezod | there are still some conceivable issues | 23:10 |
ezod | like, if you have one version of tpserver-cpp installed | 23:10 |
ezod | and a new one in the work dir | 23:11 |
mithro | yeah | 23:11 |
ezod | and the "normal" (to be installed) XML file has options in it that are new or something | 23:11 |
mithro | I think we should name the installed ones as something like "xxx.xml.template" | 23:11 |
ezod | they will still get added to the installed server's options | 23:11 |
mithro | and then the build system can install them | 23:11 |
ezod | mithro: that's fine with me | 23:11 |
mithro | ezod: not quite sure the best way to do that for daneel-ai | 23:12 |
ezod | nor i | 23:12 |
mithro | I'll look into it | 23:12 |
ezod | cool | 23:12 |
mithro | the daneel-ai xml doesn't really need any substitution | 23:13 |
ezod | alright, i have to get going | 23:15 |
ezod | new parameter stuff should be in the wizard soon | 23:15 |
mithro | okay cool | 23:15 |
mithro | I really need to write a style guideline :) | 23:16 |
ezod | thanks for the hackathon, i'm glad we got this stuff accomplished! :) | 23:16 |
mithro | got time to do another next week? | 23:16 |
ezod | likely | 23:18 |
ezod | ill let you know | 23:18 |
mithro | okay | 23:18 |
mithro | we should announce it again | 23:18 |
ezod | sounds good | 23:18 |
mithro | maybe we can get everyone along again | 23:18 |
mithro | might schedule it an hour earlier? | 23:18 |
ezod | works for me, earlier = better :) | 23:19 |
ezod | anyway, i am out, see ya | 23:19 |
llnz | it was good to see so many people | 23:19 |
* ezod & | 23:19 | |
llnz | cya ezod | 23:19 |
mithro | llnz: so what are the plans for tpserver-cpp? | 23:21 |
llnz | mithro: currently there isn't | 23:22 |
llnz | even though i know things that could be done | 23:22 |
mithro | so with GSoC coming up - we really need a plan? | 23:22 |
llnz | i think so | 23:23 |
mithro | so | 23:24 |
mithro | what are your thoughts | 23:24 |
mithro | I would like to get a couple of students working on the 3d client | 23:24 |
llnz | doing what on the 3d client? | 23:24 |
mithro | adding single player support to the client, add battlexml support, create a model designer ala spore, general graphic updates | 23:25 |
llnz | ok | 23:25 |
mithro | jmtan came up with a more specific list | 23:26 |
llnz | cool | 23:26 |
mithro | I would like us to get "demo" tpserver-cpp ruleset | 23:26 |
llnz | on the tpserver-cpp side, the only thing that would be without issue would be other persistence modules | 23:26 |
mithro | specifically design to be a "show how to create a ruleset" | 23:26 |
llnz | i don't really want any more games until 1.0 | 23:27 |
mithro | that seems fair | 23:27 |
mithro | what is missing from 1.0? | 23:27 |
mithro | mainly tp04 stuff (pending clients?) | 23:27 |
llnz | (or maybe one more that shows off the 1.0 things) | 23:27 |
llnz | tp04, research, deplomancy | 23:27 |
mithro | llnz: wern't you going to do a research proposal? | 23:29 |
mithro | I think tpserver-cpp could do with some serious cleanup and testing | 23:29 |
llnz | still has outstanding issues | 23:29 |
llnz | the core of the server is pretty solid | 23:31 |
llnz | if i had some documentation about the bugs in the rulesets, i might fix them | 23:31 |
mithro | does every method have a docstring? :P | 23:32 |
llnz | no, because it's not a priority | 23:33 |
llnz | (some do though) | 23:33 |
mithro | no tests either :/ | 23:34 |
llnz | i've been testing it as i go | 23:34 |
mithro | s/tests/unit tests/ | 23:34 |
llnz | using the clients, both tpclient-pywx and tpclient-cpptext | 23:34 |
llnz | unit tests are not worth it | 23:35 |
llnz | sorry, brb, talking in another channel | 23:35 |
mithro | but tpclient-pywx is full of bugs :P | 23:41 |
mithro | I wouldn't trust it as a good test :) | 23:41 |
llnz | so where are tpclient-pywx's unit tests and does every method have docstrings? | 23:42 |
llnz | libtpproto-cpp has a few tests and is almost completely documented | 23:43 |
mithro | nope - but if you can tell me how to unittest gui stuff I will | 23:51 |
mithro | I really need to unittest libtpclient and libtpproto | 23:51 |
mithro | if I only had time - it's such a boring task too :( | 23:52 |
Generated by irclog2html.py 2.17.2 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!