<< Back to Programming Forum   Search

Posts 21 - 40 of 49   <<Prev   1  2  3  Next >>   
New to programming?: 2012-12-14 23:51:37


Clifford The Big Red Dog 
Level 37
Report
i was able to download python and i have it working on iterm, but i was looking for a better program to run it on
New to programming?: 2012-12-15 02:27:25


Wally Balls 
Level 59
Report
Google 'python IDE' there are lots of them
New to programming?: 2012-12-15 12:29:52

Grzechooo 
Level 32
Report
I think he means terminal emulator, not IDEs.
New to programming?: 2012-12-18 12:04:15

unknownsoldier 
Level 57
Report
So, has anyone got this working and created a tournament/ladder/league or whatever?

I was considering giving it a go (since I know some python and maybe have some spare time soon) but would like to know how/if others have got on already.

Thankyou.
New to programming?: 2012-12-18 12:54:56


ps 
Level 61
Report
unknownsoldier: only took a look at the code and ran fizzer's example on localhost. decided not to venture further until i have a couple of days open and 3 or 4 fake accounts to test things with. if i do anything i'll dump it on my github and post about it here for reference sake. would be nice if others experimenting with it did the same. a documented process tutorial / guide / reference / whatever would sure shave off some time.
New to programming?: 2012-12-18 17:11:22


Ironheart
Level 54
Report
A teammate roulette will make a great Clot tourny.
New to programming?: 2012-12-18 18:01:37

unknownsoldier 
Level 57
Report
@ps: thanks for that. I have done about the same (except I'm not sure how to test on my own machine - I create multiple accounts, and use several different browsers?).

Anyway, I ploughed right on (let's see everything runs Fizzer's basic case first, then modify it) to put it on the google app engine ...
I had error from tabs present in cron.yaml, no big deal to change.
But now, my fine webpage (warlight001.appspot.com) fails with:

"
ViewDoesNotExist at /
Could not import home. Error was: No module named json
...
/base/python_runtime/python_lib/versions/third_party/django-0.96/django/core/urlresolvers.py in _get_callback
...


Not sure why django cannot find json, seems unrelated to Fizzer's code.
Probably I have done something wrong (this is usually the case). I'm using linux, so some things are different from Fizzer's description. Now I am reduced to actually reading the documentation on google apps :/

Anyone else got this working? Fizzer, I presume you have? :)
New to programming?: 2012-12-18 18:46:43

Fizzer 
Level 64

Warzone Creator
Report
Could not import home. Error was: No module named json


Thanks for reporting this. It looks like I imported json wrong. Just change all coinsurances of "import json" to "from django.utils import simplejson as json"

Or just download the latest from github - I just checked in that change.
New to programming?: 2012-12-18 22:46:13

unknownsoldier 
Level 57
Report
Ok, that works now, thanks.

Fizzer - is it worth updating your test.yaml file also, to replace the tabs with spaces? (Mine failed, complaining about "\t" until I did this).

Here is the tournament page: https://warlight001.appspot.com/
I am just messing about at the moment. Will produce something 'useful' sometime soon.

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

Fizzer, a few questions/observations/comments ...

(1) Do you intend to work on this more? Naturally I would like to stay close to your code, because then I benefit from your improvements... or should I stick my code somewhere like github, to share the things I add?

(2) Seems I can only make 1 tournament at a time. And new tournaments delete the old ones? (or, you have to make more instances of your google apps pages, of which you have a limited number).

(3) How do I invite people, and also stop others from joining? Can't anyone visit my webpage and generate an invitation? Or do I just get that impression because all my dummy players come from the same computer?

(4) When I first start the webpage, and am faced by the 'start tournament' /start page - could another person jump in ahead of me and make that tournament?

(5) You prefer tabs over spaces for python indentation? :/

(5) Seems I need to know a bit of html also - in order to eg sort the players by rank, etc. - not a bit deal, but it isn't (quite) all in python (doesn't bother me, but it might be tough for the hordes of enthusiastic people learning python... :)


(finally) Nice that you have made this stuff, thanks. My comments are meant to be constructive, not critical :)
New to programming?: 2012-12-18 23:18:04

Fizzer 
Level 64

Warzone Creator
Report
Cool, glad to see you're working on it.

(0) Hmm, where did you see the yaml error? On upload? or in a log? I didn't see an error, but I'm willing to change the tabs anyway just in case.

(1) There are things I can think that would be useful to add, but I'm not working on it at the moment. Right now my top priority is the iOS/Android clients. Please do feel free to share code back into github if you make something useful or clean up the code.

The idea is that the main github repro should be a starter package. You should submit code to here that would be applicable to any CLOT that someone could make.

You shouldn't submit code that's specific to a single type (like elimination tournaments or ladders). However, it would be great if you made your own github fork with examples of these things so other people can learn from it or fork it.

(2) To support multiple tournaments, add a "Tournament" table, then add a TournamentID to the Game table, so each game belongs to a single tournament.

(3) Right now the invites are pretty open. This has positives and negatives. The positives are that it's easy to set up tournaments as you can invite your friends in a jiff, set up clan matches, etc. The negatives are that someone could invite someone else unwillingly. This could be improved in the future if it becomes a problem.

(4) They could if they knew the URL. But you still control the database, so all you need to do is log into your Google App Engine page and delete the data they entered. I don't think this will be a problem, but if you're worried about it you could easily modify the page to ask for a password that only you know.

(5) It doesn't really matter, but tabs are more flexible since each person can control via their IDE settings how big of an indent they like to see, instead of having it forced upon them by the code writer.
New to programming?: 2012-12-18 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?: 2012-12-19 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?: 2012-12-19 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?: 2012-12-19 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?: 2012-12-19 20:46:12


Ⓖ. Ⓐrun 
Level 57
Report
Hoping that multi is to test this CLOT thing....
New to programming?: 2012-12-19 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?: 2012-12-19 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?: 2012-12-19 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?: 2012-12-19 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?: 2012-12-19 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.
Posts 21 - 40 of 49   <<Prev   1  2  3  Next >>