1. When making a thread, please tag your thread accordingly using the menu to the left of the textfield where you name your thread where applicable. Server Advertisements and Mod Releases should be contained to their respective subforums.

Server Discussion StarryPy - A plugin driven server wrapper written in Python.

Discussion in 'Multiplayer' started by Carrots Are Mediocre, Jan 29, 2014.

  1. sebasti161

    sebasti161 Tentacle Wrangler

  2. Aviakio

    Aviakio Weight of the Sky

    You're going to want to look at the StarryPy config, not the Starbound config. There should be a value for passthrough, and make sure it is set to false.
     
  3. teihoo

    teihoo Ketchup Robot

    StarryPy - A plugin driven server wrapper written in Python - StarryPy ingame commands (for beta 1.4.2).
    I've mentioned passthrough in commands post. When you do /passthrough it will set your config option "passthrough" : true
    You need to edit config.json, while the starrypy is not running, and set it back to false. I could make it always reset to false, and then it would only work with a /passthrough command until restart. Maybe that would make more sense, since there's a command now.
     
  4. sebasti161

    sebasti161 Tentacle Wrangler

    I mean't, that config is crashing the server before it start's. I set useDefaultWorldCoords : true but it crashes my game. I just want to set a planet for the /spawn point.
     
  5. teihoo

    teihoo Ketchup Robot

    Does that planet exist? Maybe that is the problem...
    Set useDefaultWorldCoords : true run the game, if it works fine - then find a planet you want for spawn and do a /whoami on that planet, it will tell you planet name - you can also do /poi_set spawn and then just copy the planet coordinates from starrypy's config.json (just find spawn in that text file, you'll the planet coord there). Change "defaultWorldCoordinate" in your starbound.config to that planet. See if that helps
     
  6. sebasti161

    sebasti161 Tentacle Wrangler

    Okay thank's.
    By the way, for some reason when other people connect to the server they get connected to the Starbound server and I can still see their name but they aren't on the StarryPy server.
    What is the problem?
     
  7. teihoo

    teihoo Ketchup Robot

    They are connecting to the starbound_server port. Your server should have most ports closed, only have port 21025 open for starrypy and starrypy will connect locally to 21024. You should also disable upnp auto router config, since this will also most likey open your firewall:
    "gamePort" : 21024,
    "upnpPortForwarding" : false,
    You should have these 2 values set like that in starbound.config

    How to close ports on your router, might need some googling :)
    https://encrypted.google.com/search?hl=en&q=how to close ports on your router
     
  8. SweFox

    SweFox Guest

    I had a silly thought, would it be possible to give player a title :O?

    It should be possible no? Some wrappers let you have a prefix as in [SA] Ella etc.

    Does starrypy support that?
     
    Last edited by a moderator: Mar 25, 2014
  9. teihoo

    teihoo Ketchup Robot

    Well not rly, but since I implemented nickname, I guess that shouldn't be that difficult to do. Just the question of how to pick titles rly - something for some future update i think.
     
  10. Brockway

    Brockway Pangalactic Porcupine

    Fot me the right thing to do about that is to format chat.

    Example of chat format: [1] [2] [3] [4]

    [1] is prefix (or title)
    [2] is player name
    [3] is the message
    [4] is the suffix

    Cheers.
     
  11. Armed Mosquito

    Armed Mosquito Existential Complex

    python server.py
    Traceback (most recent call last):
    File "server.py", line 11, in <module>
    import construct
    ImportError: No module named construct


    when I run the command "python server.py" on CentOS please help someone? I been trying for a couple days now I had to do alot to get this far even

    p.s.
    yum install buildesstenials

    i did already to said nothing was needed for that
     
  12. teihoo

    teihoo Ketchup Robot

    You're missing requirements (listed in requirements.txt): sudo pip install -r StarryPy/requirements.txt
    You'll have google for centos commands probably, its using yum instead of apt ..

    Edit: you should have PIP already in centos, http://superuser.com/questions/292378/how-to-install-pip-and-easy-install-on-centos


    Linux
    (CentOS instructions coming in the near future.) On Debian, the installation is decidedly simple, but it will require sudo access if you do not have python 2.7 installed.

    First, let's make sure that all the prerequisites are installed:

    sudo apt-get install python2.7 python-dev python-pip git

    After installing the prerequisites, clone the repo in the directory of your choice using git:

    git clone https://github.com/CarrotsAreMediocre/StarryPy

    Then install the Python requirements:

    sudo pip install -r StarryPy/requirements.txt
     
    Last edited: Mar 26, 2014
  13. NuRRi

    NuRRi Starship Captain

    Getting weird error in logs. Never saw that before:

    Code:
    2014-03-26 15:52:27,686 - starrypy.plugin_manager.PluginManager - ERROR - Error in plugin <Plugin instance: loginwho_plugin (version .1)> with function after_connect_response.
    Traceback (most recent call last):
      File "/usr/local/starrypy/plugin_manager.py", line 165, in do
        res = getattr(plugin, command, lambda _: True)(data)
      File "/usr/local/starrypy/plugins/loginwho_plugin/loginwho_plugin.py", line 18, in after_connect_response
        self.user_commands.who(data)
      File "/usr/local/starrypy/plugins/core/player_manager/manager.py", line 366, in wrapped_function
        if self.protocol.player.access_level >= level:
    AttributeError: 'NoneType' object has no attribute 'access_level'
    
     
  14. teihoo

    teihoo Ketchup Robot

    Is your server listed and they have a bot that initiates login then disconnects? To check player count? I saw that in Brokways logs also.
     
  15. NuRRi

    NuRRi Starship Captain

    Yes this could be it. Its listened in two Server Lists.

    Another question: Does the player greeter one plugin to work? I dont get any playergreeter errors in the logs and its acitvated, but new players dont get nothing. It worked some days before but I also disabled some plugins like player announcer etc. where I think we dont need them. So perhaps the playergretter needs a plugin to be acitvated?

    Thank you Teihoo!
     
  16. teihoo

    teihoo Ketchup Robot

    New player greeter has its own setting in config what items to give. Maybe you disabled that one? Im not at computer to check atm

    Edit: Announcer plugin shouldn't affect anything, it merely announces when players join or leave the server.
     
    Last edited: Mar 26, 2014
  17. Brockway

    Brockway Pangalactic Porcupine

    Teihoo, i talk with the guy of the list.
    He say to me that he use the in-build method developt by chucklefish. Not some weird protocol he build, so the fact is this not that the website is not compatible with starrypy, but just the fact that Sttarypy doesnt forward or let passtrought UDP request.

    Indeed, players connect on TCP, and stats request are made on UDP.

    So starrypy have to do something about handling UDP requests.
    Or have a different query port.

    He say to me that the first option to not block UDP request is much more simple and viable than making a special Query port. But his website support it.
     
  18. Armed Mosquito

    Armed Mosquito Existential Complex

    I get this return in my command running these commands pretty sure that I installed pip and other yum tools this stuff though is all new to me I never go this deep into ssh. Sorry if you notice common mistakes, I've learned alot but anyhow this is the error I get after it downloads requirements..

    Code:
    copying twisted/web/rewrite.py -> build/lib.linux-x86_64-2.6/twisted/web
    
    copying twisted/web/error.py -> build/lib.linux-x86_64-2.6/twisted/web
    
    copying twisted/web/sux.py -> build/lib.linux-x86_64-2.6/twisted/web
    
    copying twisted/web/distrib.py -> build/lib.linux-x86_64-2.6/twisted/web
    
    copying twisted/web/_element.py -> build/lib.linux-x86_64-2.6/twisted/web
    
    copying twisted/web/tap.py -> build/lib.linux-x86_64-2.6/twisted/web
    
    creating build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_template.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_distrib.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_static.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/requesthelper.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_wsgi.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_agent.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_http.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_util.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_error.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/_util.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_domhelpers.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_vhost.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_httpauth.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_xmlrpc.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_proxy.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_script.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_http_headers.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_resource.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_newclient.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_tap.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_web.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_cgi.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/__init__.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_soap.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_stan.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_xml.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_webclient.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    copying twisted/web/test/test_flatten.py -> build/lib.linux-x86_64-2.6/twisted/web/test
    
    creating build/lib.linux-x86_64-2.6/twisted/web/_auth
    
    copying twisted/web/_auth/wrapper.py -> build/lib.linux-x86_64-2.6/twisted/web/_auth
    
    copying twisted/web/_auth/digest.py -> build/lib.linux-x86_64-2.6/twisted/web/_auth
    
    copying twisted/web/_auth/__init__.py -> build/lib.linux-x86_64-2.6/twisted/web/_auth
    
    copying twisted/web/_auth/basic.py -> build/lib.linux-x86_64-2.6/twisted/web/_auth
    
    creating build/lib.linux-x86_64-2.6/twisted/enterprise
    
    copying twisted/enterprise/adbapi.py -> build/lib.linux-x86_64-2.6/twisted/enterprise
    
    copying twisted/enterprise/__init__.py -> build/lib.linux-x86_64-2.6/twisted/enterprise
    
    running egg_info
    
    creating Twisted.egg-info
    
    writing requirements to Twisted.egg-info/requires.txt
    
    writing Twisted.egg-info/PKG-INFO
    
    writing top-level names to Twisted.egg-info/top_level.txt
    
    writing dependency_links to Twisted.egg-info/dependency_links.txt
    
    writing manifest file 'Twisted.egg-info/SOURCES.txt'
    
    warning: manifest_maker: standard file '-c' not found
    
    reading manifest file 'Twisted.egg-info/SOURCES.txt'
    
    writing manifest file 'Twisted.egg-info/SOURCES.txt'
    
    copying twisted/test/raiser.c -> build/lib.linux-x86_64-2.6/twisted/test
    
    creating build/lib.linux-x86_64-2.6/twisted/internet/iocpreactor/iocpsupport
    
    copying twisted/internet/iocpreactor/iocpsupport/iocpsupport.c -> build/lib.linux-x86_64-2.6/twisted/internet/iocpreactor/iocpsupport
    
    copying twisted/internet/iocpreactor/iocpsupport/winsock_pointers.c -> build/lib.linux-x86_64-2.6/twisted/internet/iocpreactor/iocpsupport
    
    copying twisted/python/_initgroups.c -> build/lib.linux-x86_64-2.6/twisted/python
    
    copying twisted/python/sendmsg.c -> build/lib.linux-x86_64-2.6/twisted/python
    
    copying twisted/runner/portmap.c -> build/lib.linux-x86_64-2.6/twisted/runner
    
    running build_ext
    
    gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -fPIC -I/usr/include/python2.6 -c conftest.c -o conftest.o
    
    building 'twisted.runner.portmap' extension
    
    creating build/temp.linux-x86_64-2.6
    
    creating build/temp.linux-x86_64-2.6/twisted
    
    creating build/temp.linux-x86_64-2.6/twisted/runner
    
    gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -fPIC -I/usr/include/python2.6 -c twisted/runner/portmap.c -o build/temp.linux-x86_64-2.6/twisted/runner/portmap.o
    
    twisted/runner/portmap.c:10:20: error: Python.h: No such file or directory
    
    twisted/runner/portmap.c:14: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before â*â token
    
    twisted/runner/portmap.c:31: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before â*â token
    
    twisted/runner/portmap.c:45: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before âPortmapMethodsâ
    
    twisted/runner/portmap.c: In function âinitportmapâ:
    
    twisted/runner/portmap.c:55: warning: implicit declaration of function âPy_InitModuleâ
    
    twisted/runner/portmap.c:55: error: âPortmapMethodsâ undeclared (first use in this function)
    
    twisted/runner/portmap.c:55: error: (Each undeclared identifier is reported only once
    
    twisted/runner/portmap.c:55: error: for each function it appears in.)
    
    error: command 'gcc' failed with exit status 1
    
    ----------------------------------------
    Cleaning up...
    Command /usr/bin/python -c "import setuptools, tokenize;__file__='/tmp/pip_build_root/twisted/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-qMlzsX-record/install-record.txt --single-version-externally-managed --compile failed with error code 1 in /tmp/pip_build_root/twisted
    Traceback (most recent call last):
      File "/usr/bin/pip", line 11, in <module>
        sys.exit(main())
      File "/usr/lib/python2.6/site-packages/pip/__init__.py", line 185, in main
        return command.main(cmd_args)
      File "/usr/lib/python2.6/site-packages/pip/basecommand.py", line 161, in main
        text = '\n'.join(complete_log)
    UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 49: ordinal not in range(128)
    
    Message from my host, Creeperhost

    "Our servers use CentOS, which comes shipped with Python 2.6.6. You will most likely have to install a more recent distribution of Python on your system (the install instructions you pasted note Python 2.7) - however please bear in mind that we do not support any changes being made out of the /home/minecraft directory - but you should be able to do it."

    Just to verify some things I wanted to add the last message from support.
     
    Last edited: Mar 26, 2014
  19. Brockway

    Brockway Pangalactic Porcupine

    Hi, i'm glad to announce you that i found a solution to our problem.
    First of all on http://starbound-servers.net. set the listening port on the 21024.

    Then do not touch anything on your configuration of starrypy or starbound, you dont need to :)

    Just open the 21024 on only UDP protocol, users use TCP, stats use UDP.

    So http://starbound-servers.net will get all stats, number players etc... And the request will never pass trough Starrypy, so no error ;)

    Enjoy !
     
    teihoo likes this.
  20. teihoo

    teihoo Ketchup Robot

    upload_2014-3-26_22-55-19.png
    Edit: A picture is supposed to say a thousand words, hopefully one is enough :)
     
    Last edited: Mar 26, 2014

Share This Page