Sunday, 2009-07-26

*** tpb has joined #tp00:00
*** ChanServ sets mode: +o tpb00:00
*** Linkadmin has quit IRC00:14
*** Linkadmin has joined #tp01:02
mithrocherez: pong?01:44
cherezmithro: What is the Packet.__process__ method supposed to do?01:45
mithrothe __process__ method basically populates the class01:49
mithrohave a look at the method01:49
cherezI can't find the method.01:50
mithrotry looking in libtpproto-py01:51
cherezFound it.01:51
mithropack/unpack where static methods01:51
mithroso you could unpack the data and then give it to the constructor01:52
cherezSo it's the same as the unpack method, but it raises an exception if there is extra data.01:52
cherezI don't see how it would be necessary with the new library.01:53
mithrobecause you start off with a header object01:54
mithroand __process__ turns it into a full class01:54
mithroit also does more work when the object is descriable01:55
cherezLet me take a look at that.01:56
mithrodo a01:56
mithroack-grep __process__01:56
cherezI'm pretty sure that is the safe functionality as the unpack method.01:58
cherezSame functionality, rather.02:01
mithrocherez: __init__ method can do more then just set attributes02:02
*** llnz has quit IRC02:06
*** cherez has quit IRC02:06
*** shenki has quit IRC02:06
*** tuna-fish has quit IRC02:06
Greywhindoh, hey Mithro02:21
mithrohey Greywhind02:21
Greywhindhow's your weekend going?02:22
mithrookay02:23
mithroGreywhind: how goes the media stuff?02:23
Greywhindmithro: pretty well, i'd say02:23
Greywhindmithro: i've integrated the MediaLibrary stuff into libtpclient-py02:23
Greywhindmithro: and i have made media.py not care about threads02:23
Greywhindmithro: one question, though - is there a way to wrap a base class's function that isn't marked @thread_safe and have the new function be @thread_safe without re-writing the whole body?02:24
mithroGreywhind: yeah02:25
mithro@thread_safe02:25
mithrodef t(self, *args):02:25
mithro    return base_class.t(self, *args)02:25
mithroor similar02:25
Greywhindyeah, but then it gives me an error that the base class's .t isn't thread safe02:26
Greywhindand i'm calling it from another thread02:26
mithrooh?02:26
GreywhindAssertionError: <function get at 0x9d62454> can only be called by <MediaThread(Media, started -1287652496)> not <DownloaderThread(Thread-14, started -1300235408)>02:27
Greywhind File "libtpclient-py/tp/client/threads.py", line 526, in get02:27
Greywhind    return Media.get(self, file, callback)02:28
Greywhind File "libtpclient-py/tp/client/threads.py", line 526, in get02:28
Greywhind    return Media.get(self, file, callback)02:28
Greywhinderr02:28
Greywhind@thread_safe02:29
Greywhinddef get(self, file, callback=None):02:29
Greywhindself.gettingfileslock.acquire()02:29
Greywhindtry:02:29
Greywhindreturn Media.get(self, file, callback)02:29
mithroso that means that Media.get is inheriting from the thread checking module02:29
Greywhindshould i remove that?02:30
mithroyes, if the base class no longer cares about threads02:31
Greywhindok02:31
*** cherez has joined #tp02:32
*** shenki has joined #tp02:32
*** llnz has joined #tp02:32
*** tuna-fish has joined #tp02:32
Greywhindmithro: so i haven't solved the problem with multiple game clients downloading the same file yet02:34
Greywhindmithro: one solution might be to create a file like... <filename>.lock, that shows not to download that file on another client02:35
Greywhindmithro: but then i'm not sure what the second client would want to return while it waits, or how it would know to check again when the file was done02:36
*** mithro has quit IRC02:53
*** mithro has joined #tp03:13
Greywhindtansell: http://codereview.mithis.com/900103:13
tpbTitle: Issue 9001: Improved media support by centralizing media calls and adding a download manager. - Code Review (at codereview.mithis.com)03:13
Greywhindtansell: http://codereview.mithis.com/1000103:13
tpbTitle: Issue 10001: Updated to the TP04 xstruct. - Code Review (at codereview.mithis.com)03:13
Greywhindoh, never mind the second one03:14
Greywhindwrong link03:14
Greywhindhttp://codereview.mithis.com/10002/show03:14
tpbTitle: Issue 10002: Added threaded downloading, fixed up code in media.py - Code Review (at codereview.mithis.com)03:14
Greywhindthat one was what i meant03:14
*** mithro has quit IRC03:17
*** mithro has joined #tp03:39
*** tuna-fish has quit IRC04:07
*** peres has joined #tp04:39
alanpGreywhind: ping04:44
alanpgetting an error on connect: http://pastebin.com/m5d770d5f04:45
tpbTitle: pastebin - collaborative debugging tool (at pastebin.com)04:45
alanpany ruleset...04:45
alanplet me try a fresh clone & checkout04:47
*** mithro_ has joined #tp04:55
Greywhindalanp: any luck?05:00
*** mithro has quit IRC05:02
Greywhindalanp: well, i have to sleep, so i'll talk to you about it tomorrow if it's still a problem05:08
*** Greywhind has quit IRC05:08
*** peres has quit IRC05:35
Landonholy macaroly06:41
LandonI need to sleep now06:42
LandonI think I'm hallucinating06:42
Landona long complex bit of code worked the first time I ran it, what?06:42
Landonwell, maybe not complex, but prone to error06:42
Landon(aha, there's some bugs, darnit)06:45
CIA-26landon tpclient-pyogre * r3aa0d461e9c9 /src/move.py:06:47
CIA-26Collision responses added, everything works smooth until A) the object stops06:47
CIA-26moving and is pushed out of the way by drifters or B) new destinations can't be06:47
CIA-26added to the object because it's trying to drift to its location after being06:47
CIA-26pushed out of the way by drifters06:47
*** mithro_ has quit IRC07:22
*** mithro_ has joined #tp07:22
*** mithro_ has quit IRC08:40
CIA-26epyon tpserver-cpp-refactor * reb0c6ba4a392 /tpserver/ (common.h ordermanager.cpp ordermanager.h orderparameters.h): OrderManager cleanup08:49
*** jmtan has joined #tp08:58
*** mithro has joined #tp09:09
*** mithro_ has joined #tp09:22
*** mithro has quit IRC09:31
* llnz wanders off09:37
llnzlater all09:37
*** llnz has quit IRC09:37
*** shiftless has joined #tp10:55
*** shiftless has quit IRC11:29
*** bddebian has quit IRC11:55
*** jmtan has quit IRC11:55
*** Linkadmin has quit IRC12:03
*** tansell_ has joined #tp12:07
*** tansell has quit IRC12:09
*** Greywhind has joined #tp12:27
*** sluggo has joined #tp12:32
*** sluggo has quit IRC12:48
*** Linkadmin has joined #tp13:34
ezodGreywhind: ping?14:31
ezodGreywhind: your last libtpclient-py bump on tp04 branch of tpclient-pywx refers to a head that doesn't exist in libtpclient-py repository, did you forget to push?14:37
alanpi guess i could pull an older commit?14:38
ezodalanp: you could checkout back to 617924d47cd15dffb7b6f91ffd7c73c11feeb181 on tpclient-pywx-tp0414:38
ezodrequirements.py will set the submodules to the right heads (which will exist)14:39
*** JLP has joined #tp14:42
Greywhindezod: ... it did?14:57
alanp617924d47cd15dffb7b6f91ffd7c73c11feeb181 works for me14:57
ezodGreywhind: tp04 branch of tpclient-pywx currently specifies 7e53aa34ee760d28e2d3af903a01ef1cdab70611 as the libtpclient-py submodule head14:58
ezodGreywhind: that head doesn't exist on origin ;)14:58
Greywhindstrange14:59
Greywhindwhat's the latest commit message?14:59
ezodGreywhind: http://git.thousandparsec.net/gitweb/gitweb.cgi?p=tpclient-pywx.git;a=commit;h=a394bbadcaa2211cf059acadc94e1f701d4c45af14:59
tpb<http://ln-s.net/3h0n> (at git.thousandparsec.net)14:59
ezodthat's where you updated it14:59
alanpshit14:59
ezodUpdating libtpclient-py to fix errors with looking up empty files.15:00
Greywhindezod: i'll fix it soon.15:00
alanpARGH15:00
alanpi'm getting unbound variable errors in pyscheme15:00
ezodGreywhind: so it may just be that you're referring to a local commit you didn't push?15:00
Greywhindezod: it could be, let me check15:01
ezodare you making changes to libtpclient-py right in the submodule directory?15:01
Greywhindoh yeah. there it is.15:01
CIA-26Greywhind libtpclient-py-tp04 * r7e53aa34ee76 /tp/client/media.py: Fixed possible error with trying to look up empty files.15:01
Greywhindtry that15:01
ezod:)15:01
alanp2009-07-0615:01
alanpLee Begg15:01
alanpIn tpguile, set the property values to zero before...15:01
ezodGreywhind: perfect, thanks15:02
alanpi'm going ot have to manually create a design15:02
ezodalanp: latest head tp04 will work now15:02
alanpcool15:02
ezodalanp: which also appears to have some design window updates, so it might be relevant15:02
alanpnnice15:02
Greywhindsorry about that - didn't realize i hadn't pushed that one15:02
alanpnbd15:03
ezodnp, glad you were around to fix it so quick :)15:03
Greywhind:)15:03
*** mithro_ has quit IRC15:26
alanphmm15:29
alanpGreywhind: how do i tell what the resources are?15:29
alanpthere is a resource list, but no names15:30
Greywhindalanp: well, you can tell by comparing the relative amounts, or by selecting fewer resources to view15:33
Greywhindalanp: if i have time at some point, i'll see if i can add a key or something15:33
Greywhinddid you get that?15:35
Greywhindi lost my internet connection for a bit15:35
alanpyeah15:36
alanpbut I can't tell what they are :P15:37
Greywhindalanp: i recommend looking at a display of like... 2 resources at once15:37
Greywhindit's easier to compare that way15:38
alanpi have like 10 resources :(15:39
Greywhindyou know how to select which resources to view on the overlay, though, right?15:39
alanphow?15:40
Greywhindalanp: you see the "resource types" button next to the overlay selector?15:41
Greywhindalanp: click it, then check a couple of boxes, then deselect it15:41
alanpno?15:42
*** mithro_ has joined #tp15:42
Greywhindalanp: at the top of the starmap, there's a pulldown menu, right?15:42
Greywhindalanp: it allows you to select which overlay you're using?15:42
alanpdo any rulesets use inaccessable resources?15:42
alanpaahh15:42
Greywhindalanp: to the right of it, do you see the "resource types" button?15:43
alanpyeah15:43
Greywhindalanp: ok, good. does it work?15:43
alanpyeah, i like the list tho :(15:43
Greywhindalanp: the list?15:44
alanpthe list on the left that shows the resources on the current planet15:44
Greywhindalanp: oh. you should get a list still when you hover over the various icons15:44
alanpyeah... that's my problem... it doesn't have a name15:45
alanpStored: 2 Minable: 0 Inaccessible: 015:45
alanpno idea which resource that is :(15:45
alanpI like the "Factories" category though in that list15:45
Greywhindalanp: let me see if i can figure out what you're talking about15:46
alanpI can just send you a screencap15:46
alanpthe "Resource List" on the left pane15:46
alanpbrb, lunch15:47
Greywhindalanp: oh... you're right15:47
Greywhindalanp: mtsec doesn't seem to be giving me any names for the resources, perhaps?15:47
Greywhindalanp: on minisec, those have names next to them15:47
Greywhindalanp: you can still get resource lists with names by hovering over the icons on the starmap though15:48
Greywhindoh wait... maybe they don't have names on minisec15:49
Greywhindi'll need to fix that15:49
alanphehe15:53
Greywhindi cannot believe I never noticed this15:54
alanp=D15:54
CIA-26Greywhind tpclient-pywx-tp04 * r5eed583eafdc /windows/ (3 files in 2 dirs): Added a name to each resource in the resource list on panelInfo.16:03
Greywhindalanp: try that out :P16:03
alanpcooo16:03
alanpl16:03
*** llnz has joined #tp16:05
llnzepyon: did you see my note yesterday>16:17
llnz?16:17
llnzmorning all16:21
mhilmimorning llnz16:48
llnzhi mhilmi16:48
llnzhow is it going?16:50
alanpllnz: should i keep track of weapons as objects?16:53
alanpie: weapon class16:53
*** Greywhind has quit IRC16:53
llnzalanp: ?16:53
alanpwell right now i have an order to create a resource with the name of the missile/torp16:54
alanpand then the order adds to the resource16:54
alanpseems kind of hackish though16:54
llnzwhy? sounds fine to me16:55
alanpso when i add that to a ship16:55
alanpi'm just going to look for the design that matches the resource16:55
alanphow do i differentiate from other resources then16:55
alanpi guess i could make a list of allowed weapon resources based on weapon designs16:55
alanpif that sounds good for you, it works for me :-)16:56
llnzwell... what other resources are there? maybe you could use the mass and volume of the resource to tell them apart16:56
alanpyeah, i guess that would be okay16:57
alanpcool, then16:57
alanpso should i just add each component of the design to the ship?16:58
llnzhumm... no?17:00
llnzthe resources would be transfered from planet to ship17:01
llnzand used up in combat17:01
alanpresourceS?17:01
alanphow do we associate the resource to the missile design that way?17:01
alanpright now I make "alanp's missile" and drop a "alanp's missile" resource on the planet17:02
alanpalanp's missile is a design of a missile of course17:02
llnzresources == different missile types17:04
alanpright17:05
alanpso i have "alanp's one missile" and "alanp's two missile"17:05
alanpi can have 5 of each17:05
*** Linkadmin has quit IRC18:45
*** DTRemenak has quit IRC18:57
*** nash has joined #tp19:11
*** Linkadmin has joined #tp19:21
*** Greywhind has joined #tp19:51
*** Greywhind has quit IRC19:52
*** Greywhind has joined #tp19:56
mhilmillnz: it should be safe to call getAvailableGames() after the server connection is made right (ie statuslistener fires)? some reason getting an empty list, is it because the demo server doesn't support it?19:56
llnzit is safe to call, but the list won't be populated19:57
llnza one second delay should be enough19:58
mhilmihrm maybe its calling to soon19:58
llnzyeah20:05
*** mithro_ has quit IRC20:16
llnzmhilmi: would it be helpful to signal when a GameInfo is received?20:19
mhilmihrm ya I think so - that would make it easy. trying to find out what's up now but GDB is crapping out on me.20:20
llnzdo you do something useful with the log from the library?20:23
mhilmiwell yeah it helps with debugging - typically I don't debug the library itself so I read the messages from the log to see if the library is at xyz point etc20:25
mhilmiie right now I know the game info is being read because of the log msg, just the client side isn't getting it from getAvailableGames(), again probably timing things but can't tell20:26
tansell_morning20:47
tansell_alanp, did you fix your problem?20:47
tansell_alanp, if not just "find -type f -name \*.pyc | xarg rm" should fix it20:48
*** mithro_ has joined #tp21:06
alanptansell_: which? the git error?21:30
alanpyes21:30
tansell_alanp, no the wrong number of arguments error21:31
alanpah, yes21:31
alanptansell_: so i have a build weapon order that creates a resource on the planet "alanp's missile"21:31
*** tansell_ is now known as tansell21:32
alanpi guess i am going to use mass/volume to differentiate missile/torp resources21:32
alanpfor the load/unload armaments21:33
tansellalanp, why not the name?21:33
alanpwell i mean how would i differentiate between missile/torp resources and other resources when i fill a list for the "load armaments" order?21:34
alanpmaybe I could use units?21:35
alanp"weapon"21:35
alanpor "missile"/"torpedoe"21:35
alanptansell: ping22:26
*** jnengland77 has joined #tp23:21
tansellalanp, pong?23:32
tansellalanp, use id ranges or something?23:32
alanpno, i was thinking about something else23:33
alanpi have it now though, no worries23:33
alanpi was thinking that if i create a missile design, create a resource from that and load it onto a ship23:33
alanpi could still edit the design in the design window23:33
tansellalanp, your required to prevent that23:34
alanp*nod*23:35
alanptansell: so, you said you had some ideas RE: combat?23:36
*** jmtan has joined #tp23:46

Generated by irclog2html.py 2.17.2 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!