RPGObjects.com
http://rpgobjects.com/forum/

Traipse server linux console
http://rpgobjects.com/forum/viewtopic.php?f=4&t=986
Page 1 of 2

Author:  Tromador [ Thu Dec 02, 2010 12:14 pm ]
Post subject:  Traipse server linux console

Can traipse be run as a standalone server in console only (text) mode from within a shell, same as standard 1.8? I've tried to get this to run, but even setup wants wxPython, which in turn requires X-Windows which isn't installed on the server.

I've tried working around this by running setup on a windows box, to get the System files, then copying them back onto the Linux box, but it still wants to load wxPython, even when I'm running Server.py and not Server_GUI.py.

Author:  prof.ebral [ Sat Dec 04, 2010 4:33 am ]
Post subject:  Re: Traipse server linux console

Sorry for the late reply. I had not received an email. Yes, it is possible. I thought I had this cured in beta, but I did not. I'll make an amendment to the Beta, but I don't want to modify the Beta as much any more. I want to move on with Pious Paladin; for that I am currently working on the Plugin Factory and will be placing it in OpenWorld for the time being.

It will go in the next Beta release, along with an update to the IronClaw roller. No release date set as of yet, as I need to remove some import calls to wxPython.

Author:  prof.ebral [ Tue Dec 07, 2010 11:11 pm ]
Post subject:  Re: Traipse server linux console

I should point out that I made the corrections in the most recent Beta and it is now available.

Author:  Tromador [ Wed Dec 08, 2010 12:05 pm ]
Post subject:  Re: Traipse server linux console

Thanks - I've tested this against latest beta and it is still bombing for lack of wx in the logging code, as shown below:

Code:
openrpg [ ~/Traipse ]$ grep 101205 System/orpg/orpg_version.py
BUILD = "101205-00"
openrpg [ ~/Traipse ]$ python ./Server.py
Traceback (most recent call last):
  File "./Server.py", line 9, in <module>
    runpy.run_module('start_server')
  File "/usr/lib/python2.6/runpy.py", line 140, in run_module
    fname, loader, pkg_name)
  File "/usr/lib/python2.6/runpy.py", line 34, in _run_code
    exec code in run_globals
  File "/home/openrpg/Traipse/System/start_server.py", line 26, in <module>
    import orpg.networking.mplay_server
  File "/home/openrpg/Traipse/System/orpg/networking/mplay_server.py", line 50, in <module>
    from mplay_client import *
  File "/home/openrpg/Traipse/System/orpg/networking/mplay_client.py", line 43, in <module>
    from orpg.tools.settings import settings
  File "/home/openrpg/Traipse/System/orpg/tools/settings.py", line 3, in <module>
    from orpg.tools.orpg_log import logger
  File "/home/openrpg/Traipse/System/orpg/tools/orpg_log.py", line 30, in <module>
    import sys, os, os.path, time, traceback, inspect, wx
ImportError: No module named wx
openrpg [ ~/Traipse ]$ cd System/
openrpg [ ~/Traipse/System ]$ python ./start_server.py
Traceback (most recent call last):
  File "./start_server.py", line 26, in <module>
    import orpg.networking.mplay_server
  File "/home/openrpg/Traipse/System/orpg/networking/mplay_server.py", line 50, in <module>
    from mplay_client import *
  File "/home/openrpg/Traipse/System/orpg/networking/mplay_client.py", line 43, in <module>
    from orpg.tools.settings import settings
  File "/home/openrpg/Traipse/System/orpg/tools/settings.py", line 3, in <module>
    from orpg.tools.orpg_log import logger
  File "/home/openrpg/Traipse/System/orpg/tools/orpg_log.py", line 30, in <module>
    import sys, os, os.path, time, traceback, inspect, wx
ImportError: No module named wx
openrpg [ ~/Traipse/System ]$

Author:  Tromador [ Wed Dec 08, 2010 12:44 pm ]
Post subject:  Re: Traipse server linux console

Further to the above, if I remove the classes Term2Win and DebugConsole, along with removing wx from the import line in orpg_log.py then it does seem to run console mode and I can connect up an OpenRPG client.

I'm seeing some odd errors ('NoneType' object has no attribute 'add_setting') when I register the server, but also some other errors relating to my config, which is almost certainly because I've blindly copied my 1.8 files across and expected it to 'just work' without rtfm ;).

I don't know what knock-on effect removing those classes might have in a GUI environment, but hopefully the info is helpful.

Author:  prof.ebral [ Wed Dec 08, 2010 4:41 pm ]
Post subject:  Re: Traipse server linux console

You better check again.
Quote:
[sirebral@madmathlab traipse-ornery]$ python ./Server.py
Rooting OpenRPG at: /home/sirebral/Programs/traipse-ornery/System
Loaded Module /home/sirebral/Programs/traipse-ornery/System/plugins/server/examplePlugin.py
start_server
Processing Server Configuration File... /home/sirebral/Programs/traipse-ornery/System/myfiles/
Enter admin password: test
Auto Kick: Delay=480
Room Defaults: Allowing Passworded Rooms
Room Defaults: Using LobbyMessage.html for room messages
Protocol Validation: OFF
Creating Persistant Group... (100) Example Persistant #1
('create_group', ('Example Persistant #1', 100, 0, 'Yes'))
Creating Persistant Group... (101) Example Persistant #2
('create_group', ('Example Persistant #2', 101, 0, 'No'))
Server Configuration File: Processing Completed.
Processing Ban List File...
message handler thread running...

listen thread running...
Saving Ban List File...
-----------------------------------------------------
Type 'help' or '?' or 'h' for server console commands
-----------------------------------------------------
console logging now off
action?:kill
Closing down OpenRPG server. Please wait...
[sirebral@madmathlab traipse-ornery]$ grep 101205 System/orpg/orpg_version.py
BUILD = "101205-00"



No sure why yours is not working but you mention the files I specifically modified. I would suggest re-run the update manager and 'Update' again. Since all the changes are held within Mercurial you'll be able to reapply those changes through update manager.

Author:  Tromador [ Thu Dec 09, 2010 1:15 pm ]
Post subject:  Re: Traipse server linux console

Ref: http://hg.assembla.com/traipse_dev/rev/1df5912db00c

Modified files for this update:
orpg/dieroller/rollers/ironclaw.py orpg/dirpath/dirpath_tools.py orpg/networking/meta_server_lib.py orpg/networking/mplay_client.py orpg/networking/mplay_server.py orpg/orpg_version.py orpg/templates/feature.xml

Not modified:
orpg/tools/orpg_log.py

Which still imports wx on line 30
import sys, os, os.path, time, traceback, inspect, wx

I suspect your madmathlab server has xwindows and the wx module installed, and so you can run the console version, even in a shell without the gui.

It's also sort of hard to run the updater as that, too uses wx and does require a gui environment. What I'm hoping can be achieved is as in standard 1.8 where the server can be set up and run from a shell, where the wx module is simply not present. Something also to bear in mind for PP. I'm presuming pyQT will need the standard QT libraries, which again all rely on having a gui environment available.

Author:  prof.ebral [ Thu Dec 09, 2010 1:27 pm ]
Post subject:  Re: Traipse server linux console

yeah ... I thought I removed the log requirement. Ok, I'll check again!!

As for Pious ... I have taken great measure to remove the GUI from ALL .. central and core functions. Check it out, OpenWorld and OpenCartographer are each steps in the next milestones development. See how I removed the gametree UI from the game tree itself? :) I plan on using the game tree a lot, because it is really awesome.

From your traceback it looks like the problem is in the client.

Author:  prof.ebral [ Sun Dec 19, 2010 3:28 pm ]
Post subject:  Re: Traipse server linux console

Here is the biggest problem I see. Somehow your software has not fully updated. You are pointing to orpg_log as not being modified. It wasn't, but the dependency for orpg_log was removed. It's not being imported by the client anymore and yet your software still requests it.

In fact, if you click on the link you provide and then look at the network files you will see that I have removed the requirements needed.

Author:  Tromador [ Mon Dec 20, 2010 11:05 pm ]
Post subject:  Re: Traipse server linux console

Yup, I see the comment at line 42 of mplay_client.py which removes the dependancy on orpg_log.py

However at line 43

from orpg.tools.settings import settings

and at line 3 of settings.py

from orpg.tools.orpg_log import logger

And thus the dependancy is just now in a different part of the chain. Client imports settings, and settings imports logger. You can see this in my earlier traceback

File "/home/openrpg/Traipse/System/orpg/networking/mplay_client.py", line 43, in <module>
from orpg.tools.settings import settings
File "/home/openrpg/Traipse/System/orpg/tools/settings.py", line 3, in <module>
from orpg.tools.orpg_log import logger
File "/home/openrpg/Traipse/System/orpg/tools/orpg_log.py", line 30, in <module>

So, I'm pretty sure my software update is fine.

Page 1 of 2 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/