Skip to content

Instantly share code, notes, and snippets.

@Pishoy
Created May 18, 2020 12:18
Show Gist options
  • Save Pishoy/7f05ab05e3f3b491d33bb3264e1cdb3f to your computer and use it in GitHub Desktop.
Save Pishoy/7f05ab05e3f3b491d33bb3264e1cdb3f to your computer and use it in GitHub Desktop.
root@bishoy_testnet:/sandbox# js_logs -a bottle_server tail
Mon 18 12:12:22 gedis.py - 15 - bottle : Incoming Request name: package_manager, cmd: packages_list, threebot_name: zerobot, package_name: admin
Mon 18 12:12:22 gedis.py - 15 - bottle : Incoming Request name: notifications, cmd: check_new_release, threebot_name: zerobot, package_name: admin
Mon 18 12:12:22 gedis.py - 15 - bottle : Incoming Request name: health, cmd: get_identity, threebot_name: zerobot, package_name: admin
Mon 18 12:12:22 gedis.py - 15 - bottle : Incoming Request name: identity, cmd: threebot_name, threebot_name: zerobot, package_name: webinterface
Mon 18 12:12:22 GedisClient.py - 87 - gedisclient_health_actor : reload
Mon 18 12:12:22 GedisClient.py - 173 - gedisclient_health_actor : redisclient: 127.0.0.1:8901
Mon 18 12:12:22 handlers.py - 262 - 127.0.0.1:60560 : new incoming connection
Mon 18 12:12:22 handlers.py - 266 - 127.0.0.1:60560 : command zerobot.base.system.ping
Mon 18 12:12:22 handlers.py - 266 - 127.0.0.1:60560 : command zerobot.base.system.ping
Mon 18 12:12:22 handlers.py - 266 - 127.0.0.1:60560 : command zerobot.base.system.jsx_schemas_get
Mon 18 12:12:22 handlers.py - 266 - 127.0.0.1:60560 : command zerobot.base.system.api_meta_get
Mon 18 12:12:22 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.wiki.find.in
Mon 18 12:12:22 gedis.py - 15 - bottle : Incoming Request name: health, cmd: network_info, threebot_name: zerobot, package_name: admin
Mon 18 12:12:22 gedis.py - 15 - bottle : Incoming Request name: health, cmd: health, threebot_name: zerobot, package_name: admin
Mon 18 12:12:22 gedis.py - 15 - bottle : Incoming Request name: health, cmd: get_disk_space, threebot_name: zerobot, package_name: admin
Mon 18 12:12:22 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.wiki.find.out
Mon 18 12:12:22 BCDBFactory.py - 711 - bcdbfactory : new bcdb:test_health
Mon 18 12:12:22 GedisClient.py - 138 - gedisclient_health_actor : cmds for actor:wiki
Mon 18 12:12:22 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:12:22 GedisClient.py - 138 - gedisclient_health_actor : cmds for actor:wiki_team_manager
Mon 18 12:12:22 gedis.py - 15 - bottle : Incoming Request name: health, cmd: jsx_version, threebot_name: zerobot, package_name: admin
Mon 18 12:12:22 gedis.py - 15 - bottle : Incoming Request name: health, cmd: get_running_processes, threebot_name: zerobot, package_name: admin
Mon 18 12:12:22 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:12:22 gedis.py - 15 - bottle : Incoming Request name: health, cmd: get_running_processes, threebot_name: zerobot, package_name: admin
Mon 18 12:12:22 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.mdbook.books_list.out
Mon 18 12:12:22 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:12:22 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.mdbook.reload.in
Mon 18 12:12:22 gedis.py - 15 - bottle : Incoming Request name: health, cmd: get_running_ports, threebot_name: zerobot, package_name: admin
v10.5.2-63-gf5ee6f78
Mon 18 12:12:22 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:12:22 GedisClient.py - 138 - gedisclient_health_actor : cmds for actor:mdbook
Mon 18 12:12:23 health.py - 59 - health : TEST OK
Mon 18 12:12:23 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.wiki_gdrive_manager.file_get.in
Mon 18 12:12:23 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.wiki_gdrive_manager.file_get.out
Mon 18 12:12:23 GedisClient.py - 138 - gedisclient_health_actor : cmds for actor:wiki_gdrive_manager
Mon 18 12:12:23 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.identity.threebot_name.in
Mon 18 12:12:23 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.identity.threebot_name.out
Mon 18 12:12:23 GedisClient.py - 138 - gedisclient_health_actor : cmds for actor:identity
Mon 18 12:12:23 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.wiki_content.load.in
Mon 18 12:12:23 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.wiki_content.pull.in
Mon 18 12:12:23 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.wiki_content.reload.in
Mon 18 12:12:23 GedisClient.py - 138 - gedisclient_health_actor : cmds for actor:wiki_content
Mon 18 12:12:23 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.chatbot.session_new.in
Mon 18 12:12:23 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.chatbot.work_get.in
Mon 18 12:12:23 GedisClient.py - 135 - gedisclient_health_actor : load schema: actors.zerobot.webinterface.chatbot.work_report.in
Mon 18 12:12:23 GedisClient.py - 138 - gedisclient_health_actor : cmds for actor:chatbot
Mon 18 12:12:23 handlers.py - 266 - 127.0.0.1:60560 : command zerobot.webinterface.identity.threebot_name
Mon 18 12:12:27 gedis.py - 15 - bottle : Incoming Request name: wallet, cmd: get_wallets, threebot_name: zerobot, package_name: admin
Mon 18 12:12:27 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:12:27 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:12:56 gedis.py - 15 - bottle : Incoming Request name: wallet, cmd: import_wallet, threebot_name: zerobot, package_name: admin
Mon 18 12:12:56 gedis.py - 15 - bottle : Incoming Request name: package_manager, cmd: packages_list, threebot_name: zerobot, package_name: admin
Mon 18 12:12:56 gedis.py - 15 - bottle : Incoming Request name: notifications, cmd: check_new_release, threebot_name: zerobot, package_name: admin
Mon 18 12:12:56 gedis.py - 15 - bottle : Incoming Request name: wallet, cmd: get_wallets, threebot_name: zerobot, package_name: admin
Mon 18 12:12:58 gedis.py - 15 - bottle : Incoming Request name: wallet, cmd: manage_wallet, threebot_name: zerobot, package_name: admin
Mon 18 12:13:16 gedis.py - 15 - bottle : Incoming Request name: tfgrid_solutions, cmd: solutions_list, threebot_name: tfgrid_solutions, package_name: tfgrid_solutions
Mon 18 12:13:16 DBAdminClientBase.py - 9 - bclientseqmodeadmin_threebot_admin : AUTH in namespace default
Mon 18 12:13:16 DBAdminClientBase.py - 9 - bclientseqmodeadmin_threebot_admin : AUTH in namespace default
Mon 18 12:13:16 DBAdminClientBase.py - 9 - bclientseqmodeadmin_threebot_admin : AUTH in namespace default
Mon 18 12:13:16 DBAdminClientBase.py - 43 - bclientseqmodeadmin_threebot_admin : namespace_new:tfgrid_solutions
Mon 18 12:13:16 DBAdminClientBase.py - 9 - bclientseqmodeadmin_threebot_admin : AUTH in namespace default
Mon 18 12:13:16 DBAdminClientBase.py - 45 - bclientseqmodeadmin_threebot_admin : namespace does not exists
Mon 18 12:13:16 DBAdminClientBase.py - 52 - bclientseqmodeadmin_threebot_admin : set secret
Mon 18 12:13:16 DBAdminClientBase.py - 60 - bclientseqmodeadmin_threebot_admin : connect client
Mon 18 12:13:16 JSConfigsBCDB.py - 119 - zdbclientfactory : NEW OBJ:temp_tfgrid_solutions:zdbclientfactory
Mon 18 12:13:16 JSConfigsBCDB.py - 119 - zdbclientfactory : NEW OBJ:tfgrid_solutions:zdbclientfactory
Mon 18 12:13:16 BCDBFactory.py - 711 - bcdbfactory : new bcdb:tfgrid_solutions
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:13:16 SchemaMeta.py - 91 - schemameta : save meta schemas
Mon 18 12:14:01 gedis.py - 15 - bottle : Incoming Request name: package_manager, cmd: packages_get_status, threebot_name: zerobot, package_name: admin
Mon 18 12:14:02 gedis.py - 15 - bottle : Incoming Request name: package_manager, cmd: package_add, threebot_name: zerobot, package_name: admin
2020-05-18 12:14:02 [INFO] (mdbook::book): Book building has started
2020-05-18 12:14:02 [INFO] (mdbook::book): Running the html backend
Mon 18 12:14:02 gedis.py - 15 - bottle : Traceback (most recent call last):
File "/sandbox/lib/jumpscale/Jumpscale/tools/codeloader/CodeLoader.py", line 81, in load
m = imp.load_source(name=md5, pathname=path)
File "/usr/lib/python3.7/imp.py", line 171, in load_source
module = _load(spec)
File "<frozen importlib._bootstrap>", line 696, in _load
File "<frozen importlib._bootstrap>", line 677, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 728, in exec_module
File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
File "/sandbox/code/github/threefoldtech/jumpscaleX_threebot/ThreeBotPackages/tfgrid_solutions/tfgrid_solutions/chatflows/network_deploy.py", line 6, in <module>
class NetworkDeploy(j.servers.chatflow.get_class()):
AttributeError: 'group_j__servers' object has no attribute 'chatflow'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/sandbox/lib/jumpscale/threebot_packages/zerobot/webinterface/bottle/gedis.py", line 76, in gedis_http
result = command(**args)
File "/sandbox/lib/jumpscale/Jumpscale/core/BASECLASSES/Decorators.py", line 71, in wrapper_action
raise e
File "/sandbox/lib/jumpscale/Jumpscale/core/BASECLASSES/Decorators.py", line 67, in wrapper_action
res = func(self, **kwargs)
File "/sandbox/code/github/threefoldtech/jumpscaleX_threebot/ThreeBotPackages/zerobot/admin/actors/package_manager.py", line 102, in package_add
package.reload(reset=reload)
File "/sandbox/lib/jumpscale/Jumpscale/tools/threebot_package/ThreeBotPackage.py", line 80, in reload
self.chatflows_load()
File "/sandbox/lib/jumpscale/Jumpscale/tools/threebot_package/ThreeBotPackage.py", line 253, in chatflows_load
raise e
File "/sandbox/lib/jumpscale/Jumpscale/tools/threebot_package/ThreeBotPackage.py", line 249, in chatflows_load
self._chatflows = self.gedis_server.chatbot.chatflows_load(path)
File "/sandbox/lib/jumpscale/Jumpscale/servers/gedis/GedisChatBot.py", line 119, in chatflows_load
module, is_changed = j.tools.codeloader.load("chat", path=chatflow_path, reload=False)
File "/sandbox/lib/jumpscale/Jumpscale/tools/codeloader/CodeLoader.py", line 88, in load
raise j.exceptions.Base(msg)
threesdk.InstallTools.BaseJSException: cat: exception
context: load
data: null
filepath: /sandbox/lib/jumpscale/Jumpscale/tools/codeloader/CodeLoader.py
level: 50
linenr: 88
message: "EXCEPTION: \n SCRIPT CONTENT:\n from Jumpscale import j\n \
\ import time\n from Jumpscale.servers.gedis.GedisChatBot import StopChatFlow\n\
\n\n class NetworkDeploy(j.servers.chatflow.get_class()):\n steps =\
\ [\"network_reservation\", \"network_info\"]\n model = j.threebot.packages.tfgrid_solutions.tfgrid_solutions.bcdb_model_get(\"\
tfgrid.solutions.network.1\")\n\n @j.baseclasses.chatflow_step(title=\"\
Deploy Network\")\n def network_reservation(self):\n user_form_data\
\ = {}\n user_info = self.user_info()\n\n j.sal.reservation_chatflow.validate_user(user_info)\n\
\ user_form_data[\"chatflow\"] = \"network\"\n network_name\
\ = j.sal.reservation_chatflow.network_name_add(self, self.model)\n\n \
\ user_form_data[\"Currency\"] = self.single_choice(\n \"Please\
\ choose a currency that will be used for the payment\", [\"FreeTFT\", \"TFT\"\
], default=\"TFT\",\n required=True\n )\n\n expiration\
\ = self.datetime_picker(\n \"Please enter network expiration time.\"\
,\n required=True,\n min_time=[3600, \"Date/time\
\ should be at least 1 hour from now\"],\n default=j.data.time.epoch\
\ + 3900,\n )\n user_form_data[\"Solution expiration\"]\
\ = j.data.time.secondsToHRDelta(expiration - j.data.time.epoch)\n\n \
\ ips = [\"IPv6\", \"IPv4\"]\n ipversion = self.single_choice(\n\
\ \"How would you like to connect to your network? IPv4 or IPv6?\
\ If unsure, choose IPv4\",\n ips, required=True\n )\n\
\n # create new reservation\n reservation = j.sal.zosv2.reservation_create()\n\
\ ip_range = j.sal.reservation_chatflow.ip_range_get(self)\n \
\ res = j.sal.reservation_chatflow.solution_model_get(network_name, \"tfgrid.solutions.network.1\"\
, user_form_data)\n reservation = j.sal.reservation_chatflow.reservation_metadata_add(reservation,\
\ res)\n\n # Check if reservation failed\n while True:\n\
\ self.config = j.sal.reservation_chatflow.network_create(\n \
\ network_name,\n reservation,\n \
\ ip_range,\n j.me.tid,\n ipversion,\n\
\ expiration=expiration,\n currency=user_form_data[\"\
Currency\"],\n bot=self,\n )\n \
\ try:\n j.sal.reservation_chatflow.reservation_register_and_pay(self.config[\"\
reservation_create\"], bot=self)\n break\n except\
\ StopChatFlow as e:\n if \"wireguard listen port already in\
\ use\" in e.msg:\n j.sal.zosv2.reservation_cancel(self.config[\"\
rid\"])\n time.sleep(5)\n continue\n\
\ raise\n\n j.sal.reservation_chatflow.reservation_save(\n\
\ self.config[\"rid\"], network_name, \"tfgrid.solutions.network.1\"\
, user_form_data\n )\n\n @j.baseclasses.chatflow_step(title=\"\
Network Information\", disable_previous=True)\n def network_info(self):\n\
\ message = \"\"\"\n ### Use the following template\
\ to configure your wireguard connection. This will give you access to your\n\
\ network.\n #### Make sure you have <a target=\"_blank\"\
\ href=\"https://www.wireguard.com/install/\">wireguard</a> installed\n \
\ Click next\n to download your configuration\n \
\ \"\"\"\n\n self.md_show(j.core.text.strip(message), md=True)\n\
\n filename = \"wg-{}.conf\".format(self.config[\"rid\"])\n \
\ self.download_file(msg=f'<pre>{self.config[\"wg\"]}</pre>', data=self.config[\"\
wg\"], filename=filename, html=True)\n\n message = \"\"\"\n \
\ ### In order to have the network active and accessible from your local/container\
\ machine. To do this,\n execute this command:\n #### ```wg-quick\
\ up /etc/wireguard/{}```\n # Click next\n \"\"\".format(\n\
\ filename\n )\n\n self.md_show(j.core.text.strip(message),\
\ md=True)\n\n\n chat = NetworkDeploy\n\n\n ---------------------------------\n\
\ COULD not load:/sandbox/code/github/threefoldtech/jumpscaleX_threebot/ThreeBotPackages/tfgrid_solutions/tfgrid_solutions\n\
\ /chatflows/network_deploy.py\n ERROR WAS:'group_j__servers' object\
\ has no attribute 'chatflow'"
processid: 1075
public: ''
traceback:
- - /sandbox/lib/jumpscale/Jumpscale/core/BASECLASSES/Decorators.py
- wrapper_action
- 67
- res = func(self, **kwargs)
- null
- - /sandbox/code/github/threefoldtech/jumpscaleX_threebot/ThreeBotPackages/zerobot/admin/actors/package_manager.py
- package_add
- 102
- package.reload(reset=reload)
- null
- - /sandbox/lib/jumpscale/Jumpscale/tools/threebot_package/ThreeBotPackage.py
- reload
- 80
- self.chatflows_load()
- null
- - /sandbox/lib/jumpscale/Jumpscale/tools/threebot_package/ThreeBotPackage.py
- chatflows_load
- 253
- raise e
- null
- - /sandbox/lib/jumpscale/Jumpscale/tools/threebot_package/ThreeBotPackage.py
- chatflows_load
- 249
- self._chatflows = self.gedis_server.chatbot.chatflows_load(path)
- null
- - /sandbox/lib/jumpscale/Jumpscale/servers/gedis/GedisChatBot.py
- chatflows_load
- 119
- module, is_changed = j.tools.codeloader.load("chat", path=chatflow_path, reload=False)
- null
- - /sandbox/lib/jumpscale/Jumpscale/tools/codeloader/CodeLoader.py
- load
- 88
- raise j.exceptions.Base(msg)
- null
Mon 18 12:17:11 RedisServer.py - 94 - redisserver : connection from ('127.0.0.1', 43030)
Mon 18 12:17:11 RedisServer.py - 87 - redisserver : connection error: Connection closed by server.
Mon 18 12:17:11 RedisServer.py - 90 - redisserver : close connection from ('127.0.0.1', 43030)
Mon 18 12:17:11 RedisServer.py - 94 - redisserver : connection from ('127.0.0.1', 43032)
Mon 18 12:17:11 RedisServer.py - 87 - redisserver : connection error: Connection closed by server.
Mon 18 12:17:11 RedisServer.py - 90 - redisserver : close connection from ('127.0.0.1', 43032)
Mon 18 12:17:39 RedisServer.py - 94 - redisserver : connection from ('127.0.0.1', 43054)
Mon 18 12:17:39 RedisServer.py - 87 - redisserver : connection error: Connection closed by server.
Mon 18 12:17:39 RedisServer.py - 90 - redisserver : close connection from ('127.0.0.1', 43054)
Mon 18 12:17:39 RedisServer.py - 94 - redisserver : connection from ('127.0.0.1', 43056)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment