<< Back to Programming Forum   Search

Posts 31 - 49 of 49   <<Prev   1  2  3  
New to programming?: 12/18/2012 23:23:53

unknownsoldier 
Level 57
Report
(0) On upload (only the 1st time I tried, since after that I had changed that (and had changed only that)).

(1) OK, makes sense. Will do.

(2) I'll try take, thanks.

(3,4,5) Fair enough.
New to programming?: 12/19/2012 04:26:45

[WG] Reza
Level 60
Report
i seem to get test.yaml errors when trying to upload, what is wrong with my code? Or is it not me :\
New to programming?: 12/19/2012 04:29:23


Clifford The Big Red Dog 
Level 37
Report
I joined yours unknown just in case you needed more testers
New to programming?: 12/19/2012 10:22:23

unknownsoldier_II♦123
Level 2
Report
@Ryan - ok, thanks.

@Reza - what was your error message? Mine complained about '\t' in file test.yaml - so I replaced all the tabs with spaces and that error went away. btw - you saw Fizzer updated the files on github 2 times yesterday? - maybe best to get his latest version and try that.
New to programming?: 12/19/2012 20:46:12


Ⓖ. Ⓐrun 
Level 57
Report
Hoping that multi is to test this CLOT thing....
New to programming?: 12/19/2012 22:21:36

unknownsoldier 
Level 57
Report
Hmm, seems non-ascii characters have been causing problems (I think - there were no error messages shown initially, games just were not created). Now, games have been created, but I get many errors other places ...

'ascii' codec can't encode character u'\u2666'

I think that this is HHH and friends with their fancy names (fine with just my accounts in local testing).

google search advises including a django library that isn't in our package,
*** django.utils.encoding import smart_str ***
so that won't work.
Anyway, tomorrow I'll try and fix this. Meantime, if any kind python expert can tell me an answer ... (I have always lead a sheltered programming existence, writing code in clean environments, safe from people with chinese characters in their usernames :)
New to programming?: 12/19/2012 22:23:13

unknownsoldier 
Level 57
Report
(anyway, games have been created in the default random-matchup tourney, if you want to start playing your games ...)
New to programming?: 12/19/2012 22:37:03


Clifford The Big Red Dog 
Level 37
Report
I got a game in the strategic 1v1 one you made and i have diamonds so i don't know if it is just chinese characters or something else
New to programming?: 12/19/2012 23:08:43

unknownsoldier 
Level 57
Report
OK, I went for:

player_name = player_name.encode('ascii','ignore') #this deals with special characters that would mess up our code, by removing them.

@Ryan - yes, it was you - thanks for providing the robust testing, I wouldn't have found this otherwise :)
New to programming?: 12/19/2012 23:21:15

unknownsoldier 
Level 57
Report
I reset the website, to remove the bad player names. If you could rejoin, that would be good.
New to programming?: 12/19/2012 23:42:25

unknownsoldier 
Level 57
Report
Fizzer - when creating game between unknownsoldier_with_a_vengeance\80abc & unknownsoldier, i get the error below - seems your API does not like the long game name?
Any suggestions? (maybe you make your API allow games names of length 2*max-player-name-length +10 or some such?

Thanks.

------------------------------------------------------------

warlight001/games.py in createGame

raise Exception("CreateGame returned error: " + apiRet.get('error', apiRetStr)) ...

▼ Local vars
Variable Value
apiRet
{u'error': u'StringTooLong', u'termsOfUse': u'Please use this API responsibly, as it can consume significant amounts of server resources if called excessively. Please see http://warlight.net/API for details on WarLight APIs. The format of this data feed may change in the future.'}
apiRetStr
'{\r\n "termsOfUse": "Please use this API responsibly, as it can consume significant amounts of server resources if called excessively. Please see http://warlight.net/API for details on WarLight APIs. The format of this data feed may change in the future.",\r\n "error": "StringTooLong"\r\n}\r\n'
config
<main.ClotConfig object at 0xb00d6ec>
gameName
u'unknownsoldier_II123 vs unknownsoldier_with_a_vengeance\x80abc'
gid
-1
p
7 unknownsoldier_with_a_vengeance\x80abc
players
(3 unknownsoldier_II123, 7 unknownsoldier_with_a_vengeance\x80abc)
templateID
251301
New to programming?: 12/19/2012 23:50:27

Fizzer 
Level 64

Warzone Creator
Report
Game names are limited to 50 characters. To truncate the name, change this:

gameName = ' vs '.join([p.name for p in players])

to this

gameName = ' vs '.join([p.name for p in players])[:50]

I just checked this into github
New to programming?: 12/20/2012 00:03:15

unknownsoldier 
Level 57
Report
OK, thanks.
New to programming?: 12/20/2012 02:35:12


Clifford The Big Red Dog 
Level 37
Report
Joined again
New to programming?: 12/20/2012 04:13:10

[WG] Reza
Level 60
Report
I got errors with the apex guys joining aswell the circle in their name gave them errors when leaving and joining.
But the main problem right now seems to be how the games dont start being made :\
(https://lolowuttestclot.appspot.com/) (no more people needed :) )
New to programming?: 12/20/2012 06:02:07


Kenny • apex 
Level 59
Report
I have no idea why Fizzer, but cron.yaml kept on giving me errors until I deleted all of your # side text. I cleaned it up to just have this:

cron:
- description: create game
url: /cron
schedule: every 6 hours

^-- No tab, and indentation the same. No side text. Finally worked perfectly. For those of you having the same issue just remember: Don't go below every 3 hours since you'll put a strain on the WL servers. If you read and understand that, but for some reason the cron job doesn't want to work with his side text, remove it.

Otherwise, it's smooth sailing so far.
New to programming?: 12/20/2012 23:26:09

unknownsoldier 
Level 57
Report
So, https://warlight001.appspot.com/ now has a head-to-head record table. I don't know if I should be happy I added it, or depressed that it took me so long :/

It seems we need to know some django webstuff also, www.djangobook.com seems a nice book/website.
Also, I had some problem with python 2.5 vs 2.7 (my code ran ok locally but not on google apps - a pain to debug like that).
The other thing that slows me down is that many code errors do not show up - you have to guess what might have gone wrong. I guess this is because I don't have full debugging on, but that is because when setting up, other things fell over when I did.

I sometimes wonder if Fizzer set this API stuff up as part of a cunning plan to make us appreciate more the hard work and skill he has put into creating warlight :)



Anyway, the next thing I thought I would try is making a swiss tournament. I want to do something simple, but that is not currently on warlight. Any advice/comments?

(Swiss is a bit like round-robin, but (much) fewer games. Everyone plays the same number of games though, and at the end, the number of points you have is a pretty good reflection of how good you are.)

And please, if people could join the current random-match tourney, and play their games fast, that would help with testing. Cheers.
New to programming?: 12/21/2012 01:39:55

Fizzer 
Level 64

Warzone Creator
Report
now has a head-to-head record table.


Nice work!

I had some problem with python 2.5 vs 2.7


Ack, that's not good. I'm not sure if this will help you, but in app.yaml you can change the word "python" to "python27" to make it run 2.7. I'm not familiar enough with Python to know if this will break anything else though. It might be a good idea to upgrade the base CLOT code too for others.

The other thing that slows me down is that many code errors do not show up - you have to guess what might have gone wrong.


I'm not sure what you mean by this. Can you elaborate?

And please, if people could join the current random-match tourney, and play their games fast, that would help with testing


If you don't find enough from this post, make a new forum thread asking for people.
New to programming?: 12/26/2012 19:41:22


ChrisCMU 
Level 61
Report
My CLOT ran fine without edits and I have 2.7. The only change I made was eliminating the tabs/comments like Lolowut did.
Posts 31 - 49 of 49   <<Prev   1  2  3