It is currently Tue Apr 24, 2018 4:26 pm Advanced search

Troubles with the local server

Code won't compile? Found a bug? Post here!

Troubles with the local server

Postby linus_rules » Sat Nov 13, 2010 8:24 pm

have developed some bots with the python starter package and tested with the local server without problems.
After that, I developed a new PlanetWars package and a simulator. I tested all the examples and a new bot and worked fine.
Now, I am testing all the bots with the local server. Only the example bots execute ok. My new bot is failing with the following message:

player 1 wins after 0 turns (player 2 sent an invalid command: local: execv: Bot_02_d.py: Exec format error)

I tested my bot alone with the following comand
cat maps/map1.txt go.txt | python Bot_02_d.py
1 22 36
1 16 10
1 3 22
go
Traceback (most recent call last):
File "Bot_02_d.py", line 225, in <module>
game()
File "Bot_02_d.py", line 207, in game
current_line = raw_input()
EOFError: EOF when reading a line

This is the test for BotRage.py (it is working fine with the local server)
cat maps/map1.txt go.txt | python2.6 BotRage.py
1 2 100
go
Traceback (most recent call last):
File "BotRage.py", line 57, in <module>
game()
File "BotRage.py", line 39, in game
current_line = raw_input()
EOFError: EOF when reading a line

Any clue?

Thanks
linus_rules
Cadet
 
Posts: 2
Joined: Sat Nov 13, 2010 8:05 pm

Re: Troubles with the local server

Postby jwkvam » Sat Nov 13, 2010 8:58 pm

I'm not sure what your issue might be, but you may want to check out the unofficial python starter kit, search for it in the forums. It has some nice features that are lacking in the official package.
jwkvam
Cadet
 
Posts: 7
Joined: Tue Oct 05, 2010 6:57 am

Re: Troubles with the local server

Postby linus_rules » Sat Nov 13, 2010 10:01 pm

Solved!

I had messed the shebang line (#!/usr/local/bin/python). Very stupid error!
linus_rules
Cadet
 
Posts: 2
Joined: Sat Nov 13, 2010 8:05 pm


Return to Technical Issues

Who is online

Users browsing this forum: No registered users and 1 guest

cron