Skip to content
This repository was archived by the owner on Feb 15, 2024. It is now read-only.
This repository was archived by the owner on Feb 15, 2024. It is now read-only.

Passing commands to the console #65

Closed

Description

@reka7490

EN: Hi, I have a question is it possible to enter commands into the server console somehow?
RU: И снова привет у меня есть вопросик а можно ли как то вводить команды в консоль сервера?

Activity

  1. added
    duplicateThis issue or pull request already exists
    documentationImprovements or additions to documentation
    on Jan 7, 2023
  2. changed the title [-]Just asking[/-] [+]Passing commands to the console[/+] on Jan 7, 2023
  3. DarkCat09 commented on Jan 8, 2023

    @DarkCat09
    Owner

    Duplicate of #20

  4. DarkCat09 commented on Jan 8, 2023

    @DarkCat09
    Owner

    Here is an example how to read and write to the server's console: https://github.com/DarkCat09/python-aternos/blob/main/examples/console_example.py
    You have to use Websockets API. And rememeber to start the server before working with console.

  5. DarkCat09 commented on Jan 8, 2023

    @DarkCat09
    Owner

    По-русски:

    Вот пример, как читать/записывать в консоль: https://github.com/DarkCat09/python-aternos/blob/main/examples/console_example.py
    Это делается через Websockets API. И не забудьте запустить сервер перед тем, как отсылать запросы к консоли.

  6. DarkCat09 commented on Jan 8, 2023

    @DarkCat09
    Owner

    I hope I've answered the question.
    Надеюсь, ответил на вопрос.

  7. reka7490 commented on Jan 8, 2023

    @reka7490
    Author

    EN: not completely, but is it possible to do plug and play? (it is inconvenient to turn off and turn on the server so that commands go to the console)
    RU: так может я глупый но консоль работает только если сервер включен через неё но можно ли как то обойтись без перезапуска и просто подключиться к консоли?

  8. DarkCat09 commented on Jan 9, 2023

    @DarkCat09
    Owner

    @reka7490,

    Да, команды можно отправлять только когда сервер запущен.
    Использование wss.send() на остановленном сервере ничего не даст.

    Yes, commands can be sent only when server is running.
    Using wss.send() when server is stopped doesn't give any effect.

  9. reka7490 commented on Jan 9, 2023

    @reka7490
    Author

    EN: ...uh Okay I'll just show you what I mean
    RU: ладно я просто покажу что имелось в виду
    image

  10. reka7490 commented on Jan 9, 2023

    @reka7490
    Author

    да блин ладно просто на русском объясню короче в файле примере есть запуск сервера s.start() я его удалил вручную запустил сервер (полностью) потом запустил файл пример но консоль не заработала могу кинуть скрин кода если нужно

  11. DarkCat09 commented on Jan 9, 2023

    @DarkCat09
    Owner

    @reka7490,

    Спасибо, я уже понял.
    Будет время, проверю у себя. Такого быть не должно.

  12. reka7490 commented on Jan 9, 2023

    @reka7490
    Author

    окк

  13. DarkCat09 commented on Jan 11, 2023

    @DarkCat09
    Owner

    1 more question. Which version of python-aternos do you have?
    Ещё вопрос: какая у Вас версия модуля?

  14. reka7490 commented on Jan 11, 2023

    @reka7490
    Author

    image

  15. reka7490 commented on Jan 11, 2023

    @reka7490
    Author

    image
    EN: okay I updated all the modules using pip and checked the error again the error remained
    RU: я обновил все модули но ничего не изменилось

  16. DarkCat09 commented on Jan 13, 2023

    @DarkCat09
    Owner

    @reka7490,

    У меня всё работает.
    Вы нажали Y когда скрипт спросил "Show responses"?

    It works for me.
    Did you press Y when the script asked "Show responses"?

  17. reka7490 commented on Jan 13, 2023

    @reka7490
    Author

    image
    EN: no I replaced this part of the code
    RU: у меня он залочен и да я знаю что у меня нет вкуса

  18. reka7490 commented on Jan 13, 2023

    @reka7490
    Author

    image
    EN: here you can see everything is working if you run the server through the code, but if you first turn on the server yourself, wait for the load and only then start the console, then nothing will work
    RU: вот тут видно всё рабит если сервер запускать через код но если сначала самому включить сервер дождаться загрузки и лишь потом запустить консоль то ничего не сработает

  19. reka7490 commented on Jan 29, 2023

    @reka7490
    Author

    шок контент чёрный кот стал коричневым 😱 ТАК ДЕРЖАТЬ

  20. DarkCat09 commented on Feb 5, 2023

    @DarkCat09
    Owner

    шок контент чёрный кот стал коричневым ТАК ДЕРЖАТЬ

    Ага :)
    На предыдущей аватарке, правда, кот был примерно такого же цвета.
    А вообще, сообщения, не относящиеся к python-aternos, лучше в тг-канал, группу обсуждения или личный чат:

    Скажите, когда прочитаете этот коммент, я удалю (ибо не по теме).

  21. DarkCat09 commented on Feb 5, 2023

    @DarkCat09
    Owner

    @reka7490,

    Your last screenshots was moved to a new issue with title related to this bug. You can continue the discussion there: #68
    This one will be closed.

    Последние скрины перенёс в новый issue, с соответствующим заголовком. Обсуждение самого бага можно продолжить тут: #68
    Этот issue закрою.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationduplicateThis issue or pull request already exists

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions