mirror of
https://github.com/RYGhub/royalnet.git
synced 2024-11-23 11:34:18 +00:00
💥 Update royalnet_console to 2.0.2
This commit is contained in:
parent
ff4ad9ee7a
commit
2abaf6298c
12 changed files with 219 additions and 7 deletions
20
docs/Makefile
Normal file
20
docs/Makefile
Normal file
|
@ -0,0 +1,20 @@
|
|||
# Minimal makefile for Sphinx documentation
|
||||
#
|
||||
|
||||
# You can set these variables from the command line, and also
|
||||
# from the environment for the first two.
|
||||
SPHINXOPTS ?=
|
||||
SPHINXBUILD ?= sphinx-build
|
||||
SOURCEDIR = source
|
||||
BUILDDIR = build
|
||||
|
||||
# Put it first so that "make" without argument is like "make help".
|
||||
help:
|
||||
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
||||
|
||||
.PHONY: help Makefile
|
||||
|
||||
# Catch-all target: route all unknown targets to Sphinx using the new
|
||||
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
|
||||
%: Makefile
|
||||
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
35
docs/make.bat
Normal file
35
docs/make.bat
Normal file
|
@ -0,0 +1,35 @@
|
|||
@ECHO OFF
|
||||
|
||||
pushd %~dp0
|
||||
|
||||
REM Command file for Sphinx documentation
|
||||
|
||||
if "%SPHINXBUILD%" == "" (
|
||||
set SPHINXBUILD=sphinx-build
|
||||
)
|
||||
set SOURCEDIR=source
|
||||
set BUILDDIR=build
|
||||
|
||||
if "%1" == "" goto help
|
||||
|
||||
%SPHINXBUILD% >NUL 2>NUL
|
||||
if errorlevel 9009 (
|
||||
echo.
|
||||
echo.The 'sphinx-build' command was not found. Make sure you have Sphinx
|
||||
echo.installed, then set the SPHINXBUILD environment variable to point
|
||||
echo.to the full path of the 'sphinx-build' executable. Alternatively you
|
||||
echo.may add the Sphinx directory to PATH.
|
||||
echo.
|
||||
echo.If you don't have Sphinx installed, grab it from
|
||||
echo.http://sphinx-doc.org/
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
|
||||
goto end
|
||||
|
||||
:help
|
||||
%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
|
||||
|
||||
:end
|
||||
popd
|
1
docs/source/_static/engineer_diagram.drawio
Normal file
1
docs/source/_static/engineer_diagram.drawio
Normal file
|
@ -0,0 +1 @@
|
|||
<mxfile host="Electron" modified="2021-01-11T18:17:27.045Z" agent="5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) draw.io/13.9.9 Chrome/85.0.4183.121 Electron/10.1.5 Safari/537.36" etag="PtfY7jWmXTYP-W-kbB7z" version="13.9.9" type="device"><diagram id="CE8n8ZrOl62DmRSVWgVr" name="Page-1">7V1bc6O4Ev41edmqbGF8Sx5jZzLn7CRzMslc9+WUDLLRBEssiNjOr19JSFxGAmNPjElCTWpiZF3p1ve1uhty0p8u1+9DEHg3xIX+iW2565P+5Ylt90Yjm/3iJZuk5GwwSAoWIXJlpazgHj1BWWjJ0hi5MCpUpIT4FAXFQodgDB1aKANhSFbFanPiF0cNwAJqBfcO8PXSb8ilnlzF0MrK/wPRwlMj9yz5zRKoyrIg8oBLVrmi/ruT/jQkhCaflusp9PnNU/claXdV8m06sRBiWqfBxf1m/fGmfwvn4/DDYvrXh08Xn0+HIzk5ulErhi67AfKShNQjC4KB/y4rnbCVBPxbH+EHdhmSGLuQj2Kxq6zJNSEBK+yxwp+Q0o0ULogpYUUeXfryW7hG9Dtv/udQXv2QnfHPl+v8xUZdYBpuco345Q/VH7/Imokr1S5ZLl9j6W2URRGJQ0fWCv+O7+7Q3aeJ/b9vs/Hisz+58E6VOoJwAWlVPTuVNtsmkCwhmxBrGEIfUPRYnAiQ+rpI62UiZR+kVM0SrprlI/BjOdI3tlTH0+QerdDSB5gLeE4wVSrAb5rjId+9BhsS83VG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UuCJx1lviDKbPgZnzZTpp7FMTUwZaL0hrSNji1bw5Z2u9ly+OIPl0dky0FdtiwxmRpiSz18nKXBdHz5cvmy4cyaNvOlHlQ28WWm9iWEmfhhKxJxDHRZzqxvIBWnUSpteQC4314qVd/sRqUZeR6eSs91Kq14QcixqFS9n7+FIm6/tWQQ8S55Hg0ZS/prhG75U1Pi3QndI4ONPDL4rIl3B/bDt/SZQaNuG95jk2q05YHHxEgSeW4xfsBkZXjBVf7JOvHGeBnA5qbPLEnY40YT5blx2suxNie5VLnOKNpR7yvwqr1G0eCsRYypPufC0DUYs2ASHSh4XfW8wHb3wvCYjDk47yRcQ8KV73LaLuL+MUU87LVIxNY+Im4kA6Xy7TPbRdzUO+7MJ5s2vcWwvbu46omGducYjVoVFt9LwEfzTpheU1n+iOzzS5hdZn/5LjkNZH8/sP/uXw==</diagram></mxfile>
|
BIN
docs/source/_static/engineer_diagram.png
Normal file
BIN
docs/source/_static/engineer_diagram.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 130 KiB |
3
docs/source/_static/royalblue.css
Normal file
3
docs/source/_static/royalblue.css
Normal file
|
@ -0,0 +1,3 @@
|
|||
.wy-side-nav-search, .wy-nav-top {
|
||||
background-color: #0d193b !important;
|
||||
}
|
8
docs/source/autodoc/index.rst
Normal file
8
docs/source/autodoc/index.rst
Normal file
|
@ -0,0 +1,8 @@
|
|||
Autogenerated documentation
|
||||
===========================
|
||||
|
||||
Welcome to the autogenerated documentation of Royalnet Console!
|
||||
|
||||
It may be incomplete or outdated, as it is automatically updated.
|
||||
|
||||
.. automodule:: royalnet_console
|
100
docs/source/conf.py
Normal file
100
docs/source/conf.py
Normal file
|
@ -0,0 +1,100 @@
|
|||
# Configuration file for the Sphinx documentation builder.
|
||||
#
|
||||
# This file only contains a selection of the most common options. For a full
|
||||
# list see the documentation:
|
||||
# https://www.sphinx-doc.org/en/master/usage/configuration.html
|
||||
|
||||
# -- Path setup --------------------------------------------------------------
|
||||
|
||||
# If extensions (or modules to document with autodoc) are in another directory,
|
||||
# add these directories to sys.path here. If the directory is relative to the
|
||||
# documentation root, use os.path.abspath to make it absolute, like shown here.
|
||||
#
|
||||
# import os
|
||||
# import sys
|
||||
# sys.path.insert(0, os.path.abspath('.'))
|
||||
|
||||
import pkg_resources
|
||||
|
||||
# -- Project information -----------------------------------------------------
|
||||
|
||||
project = 'royalnet_console'
|
||||
# noinspection PyShadowingBuiltins
|
||||
copyright = '2021, Stefano Pigozzi'
|
||||
author = 'Stefano Pigozzi'
|
||||
|
||||
# The full version, including alpha/beta/rc tags
|
||||
release = pkg_resources.get_distribution("royalnet_console").version
|
||||
|
||||
|
||||
# -- General configuration ---------------------------------------------------
|
||||
|
||||
# Add any Sphinx extension module names here, as strings. They can be
|
||||
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
||||
# ones.
|
||||
extensions = [
|
||||
"sphinx.ext.autodoc",
|
||||
"sphinx.ext.intersphinx",
|
||||
'sphinx.ext.todo',
|
||||
]
|
||||
|
||||
# Add any paths that contain templates here, relative to this directory.
|
||||
templates_path = ['_templates']
|
||||
|
||||
# List of patterns, relative to source directory, that match files and
|
||||
# directories to ignore when looking for source files.
|
||||
# This pattern also affects html_static_path and html_extra_path.
|
||||
exclude_patterns = ['Thumbs.db', '.DS_Store']
|
||||
|
||||
# Print warnings on the page
|
||||
keep_warnings = True
|
||||
|
||||
# Display more warnings than usual
|
||||
nitpicky = True
|
||||
|
||||
# -- Options for HTML output -------------------------------------------------
|
||||
|
||||
# The theme to use for HTML and HTML Help pages. See the documentation for
|
||||
# a list of builtin themes.
|
||||
#
|
||||
html_theme = 'sphinx_rtd_theme'
|
||||
|
||||
# Add any paths that contain custom static files (such as style sheets) here,
|
||||
# relative to this directory. They are copied after the builtin static files,
|
||||
# so a file named "default.css" will overwrite the builtin "default.css".
|
||||
html_static_path = ['_static']
|
||||
|
||||
|
||||
# -- Intersphinx options -----------------------------------------------------
|
||||
|
||||
intersphinx_mapping = {
|
||||
"python": ("https://docs.python.org/3.8", None),
|
||||
"sqlalchemy": ("https://docs.sqlalchemy.org/en/13/", None),
|
||||
"async_property": ("https://async-property.readthedocs.io/en/latest/", None),
|
||||
}
|
||||
|
||||
|
||||
# -- Setup function ----------------------------------------------------------
|
||||
def setup(app):
|
||||
app.add_css_file('royalblue.css')
|
||||
|
||||
|
||||
# -- Substitutions -----------------------------------------------------------
|
||||
|
||||
|
||||
rst_prolog = """
|
||||
|
||||
"""
|
||||
|
||||
# -- Automodule settings -----------------------------------------------------
|
||||
|
||||
autodoc_default_options = {
|
||||
'members': True,
|
||||
'member-order': 'bysource',
|
||||
'special-members': '__init__',
|
||||
'undoc-members': True,
|
||||
}
|
||||
|
||||
# -- Automodule settings -----------------------------------------------------
|
||||
|
||||
todo_include_todos = True
|
32
docs/source/index.rst
Normal file
32
docs/source/index.rst
Normal file
|
@ -0,0 +1,32 @@
|
|||
Royalnet 6
|
||||
==========
|
||||
|
||||
Welcome to the documentation of Royalnet 6!
|
||||
|
||||
|
||||
Table of contents
|
||||
-----------------
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 3
|
||||
|
||||
autodoc/index
|
||||
|
||||
|
||||
Useful links
|
||||
------------
|
||||
|
||||
* `Royalnet on GitHub <https://github.com/Steffo99/royalnet-6>`_
|
||||
|
||||
|
||||
Indices and tables
|
||||
------------------
|
||||
|
||||
* :ref:`genindex`
|
||||
* :ref:`modindex`
|
||||
* :ref:`search`
|
||||
|
||||
To do
|
||||
-----
|
||||
|
||||
.. todolist::
|
8
poetry.lock
generated
8
poetry.lock
generated
|
@ -279,7 +279,7 @@ socks = ["PySocks (>=1.5.6,!=1.5.7)", "win-inet-pton"]
|
|||
|
||||
[[package]]
|
||||
name = "royalnet"
|
||||
version = "6.2.1"
|
||||
version = "6.3.0"
|
||||
description = "A multipurpose bot framework"
|
||||
category = "main"
|
||||
optional = false
|
||||
|
@ -479,7 +479,7 @@ brotli = ["brotlipy (>=0.6.0)"]
|
|||
[metadata]
|
||||
lock-version = "1.1"
|
||||
python-versions = "^3.8"
|
||||
content-hash = "dd03dba3d8cafa05d423d919e0dbda54ac96dddab43573811d49929b468f5d1a"
|
||||
content-hash = "b9acdca9d1875f1be11616d4e534d383646f484e92732ee78be19d84077a7888"
|
||||
|
||||
[metadata.files]
|
||||
alabaster = [
|
||||
|
@ -728,8 +728,8 @@ requests = [
|
|||
{file = "requests-2.25.1.tar.gz", hash = "sha256:27973dd4a904a4f13b263a19c866c13b92a39ed1c964655f025f3f8d3d75b804"},
|
||||
]
|
||||
royalnet = [
|
||||
{file = "royalnet-6.2.1-py3-none-any.whl", hash = "sha256:e5b333fda9e5b0cf34537903e76ce9ffc3ca231df6c6ba28a9b1f9ee94efc843"},
|
||||
{file = "royalnet-6.2.1.tar.gz", hash = "sha256:a41bb353840f4b0c4f8fb40d0852d1da9f284af0f525c90f9bfb77d26ccd2c53"},
|
||||
{file = "royalnet-6.3.0-py3-none-any.whl", hash = "sha256:f2f6ea15def33e27ca92a0ba3b7863fab7b7339bcbb99bc83f6be74bd8e805e6"},
|
||||
{file = "royalnet-6.3.0.tar.gz", hash = "sha256:6301ef60a1402ec59e55a206462f5b7296c5f6bbd6ab0bf38851ede42add5b20"},
|
||||
]
|
||||
snowballstemmer = [
|
||||
{file = "snowballstemmer-2.1.0-py2.py3-none-any.whl", hash = "sha256:b51b447bea85f9968c13b650126a888aabd4cb4463fca868ec596826325dedc2"},
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
[tool.poetry]
|
||||
name = "royalnet-console"
|
||||
version = "2.0.1"
|
||||
version = "2.0.2"
|
||||
description = "A terminal-based frontend for the royalnet.engineer module."
|
||||
authors = ["Stefano Pigozzi <me@steffo.eu>"]
|
||||
license = "AGPL-3.0-or-later"
|
||||
|
@ -19,7 +19,7 @@ classifiers = [
|
|||
|
||||
[tool.poetry.dependencies]
|
||||
python = "^3.8"
|
||||
royalnet = "~6.2.0"
|
||||
royalnet = "~6.3.0"
|
||||
psutil = "^5.8.0"
|
||||
click = "^7.1.2"
|
||||
colorama = "^0.4.4"
|
||||
|
|
|
@ -2,7 +2,12 @@
|
|||
<module type="PYTHON_MODULE" version="4">
|
||||
<component name="NewModuleRootManager" inherit-compiler-output="true">
|
||||
<exclude-output />
|
||||
<content url="file://$MODULE_DIR$" />
|
||||
<content url="file://$MODULE_DIR$">
|
||||
<sourceFolder url="file://$MODULE_DIR$/royalnet_console" isTestSource="false" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/royalnet_console.egg-info" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/.pytest_cache" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/dist" />
|
||||
</content>
|
||||
<orderEntry type="jdk" jdkName="Poetry (royalnet-console)" jdkType="Python SDK" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
|
|
|
@ -46,6 +46,14 @@ class ConsolePDAImplementation(engi.ConversationListImplementation):
|
|||
if isinstance(cycles, int):
|
||||
cycles -= 1
|
||||
|
||||
async def _handle_conversation_exc(
|
||||
self,
|
||||
dispenser: engi.Dispenser,
|
||||
conv: engi.ConversationProtocol,
|
||||
exception: Exception,
|
||||
) -> None:
|
||||
self.log.error(f"ERROR: {exception}")
|
||||
|
||||
|
||||
__all__ = (
|
||||
"ConsolePDAImplementation",
|
||||
|
|
Loading…
Reference in a new issue