Manual source linking. Ouch. #74

Merged
ag merged 1 commits from nightly into main 2024-08-01 22:04:50 +00:00
49 changed files with 112 additions and 12 deletions

View File

@ -1,5 +1,11 @@
<a id="hopper-small-internet-interop-utilities"></a>
# hopper: Small internet interop utilities
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/Protocols/map.py)
<a id="module-Components.hopper"></a>
### Components.hopper.get(url: str, params=None)
http/s get request

View File

@ -4,6 +4,8 @@ Fernet based encryption
### *class* Cryptography.WhaleSong.DHEFern(cache, nodeNickname, cLog)
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/Cryptography/WhaleSong.py)
#### cLog
Method reference to run.Node.cLog so we can log to the ui from here

View File

@ -1,9 +1,13 @@
<a id="daisy-based-cache"></a>
# Daisy based cache
### *class* Daisy.Cache.Cache(filepaths=None, cacheFile=None, path: str = 'daisy', walk: bool = False, isCatch: bool = False)
In memory collection of Daisy records
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/Daisy/Cache.py)
#### create(path: str, data: dict)
Create new record

View File

@ -8,6 +8,12 @@ Sub class of Cache for handling catchs
![image](https://git.utopic.work/PierMesh/piermesh/raw/branch/main/imgs/catchdisplay.png)
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/Daisy/Catch.py)
#### addc(peer, node, seperator, head, tail, data, fins=None)
#### catches *= {}*
#### get(head: str, tail: str, fins=None)
Get catch by pieces

View File

@ -1,9 +1,13 @@
<a id="daisy-signal-management"></a>
# Daisy signal management
### *class* Daisy.Soil.Compound(cache, isCatch: bool = False)
File system watcher to propagate disk changes
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/Daisy/Soil.py)
#### on_any_event(event)
Called when a CRUD operation is performed on a record file

View File

@ -3,3 +3,11 @@ store with recursion
==========================
### *class* Daisy.Store.Store(store: str, path: str, nodeNickname: str)
Key value store
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/Daisy/Store.py)
#### getRecord(key: str)
#### update(entry: str, data, recur: bool = True)

View File

@ -1,9 +1,13 @@
<a id="header-packet-metadata-packet"></a>
# Header packet: Metadata packet
### *class* Packets.HeaderPacket.Header(packetsID: int, packetCount: int, sender: int, senderDisplayName: int, recipient: int, recipientNode: int, subpacket: bool = False, wantFullResponse: bool = False, packetsClass: int = 0, pAction: int = -1)
Metadata packet for messages
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/Packets/HeaderPacket.py)
#### sender
6 digit (maximum) node or peer ID

View File

@ -1,3 +1,5 @@
<a id="base-packet"></a>
# Base packet
### *class* Packets.Packet.Packet(data: bytes, packetsID: int = -1, packetNumber=False, packetCount: int = 1, packetsClass: int = -1)

View File

@ -7,3 +7,5 @@ for very low data applications
WIP
Single packet for very small protocols
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Packets/SinglePacket.py)

View File

@ -1,10 +1,12 @@
<a id="network-map-representation"></a>
# Network map representation
### *class* Siph.map.Network(file=None)
Layered graph network
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Bubble/map.py)
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Siph/map.py)
#### omap

View File

@ -1,9 +1,13 @@
<a id="serve-web-ui-server"></a>
# serve: Web UI server
### *class* Splash.serve.Server(transceiver, catch, onodeID, network, cLog)
Web server that serves the web ui and provides web to node communication
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Sponge/serve.py)
#### cLog
Reference to run.Node.cLog for logging

View File

@ -51,19 +51,19 @@ Base filtering logic, takes a single MeshTastic packet
Peer to peer protol
[🔗 Bubble Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Sponge/Protocols/bubble.py)
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Sponge/Protocols/bubble.py)
#### *async* catch.filter(recipient, recipientNode, todo)
Catch exchange protocol
[🔗 Catch Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/Protocols/catch.py)
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/Protocols/catch.py)
#### *async* cryptography.filter(recipientNode, todo)
Cryptographic operations protocol
[🔗 Cryptography Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/Protocols/cryptography.py)
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/Protocols/cryptography.py)
#### *async* map.filter(todo)

View File

@ -1,9 +1,13 @@
<a id="layer-0-data-transceiving"></a>
# Layer 0 data transceiving
### *class* Transceiver.Transceiver.Transceiver(device, filter, onodeID, cache, catch, cryptographyInfo, cLog)
Handling LoRa transceiving
[🔗 Source](https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Transceiver/Transceiver.py)
#### cLog
Reference to run.Node.cLog for logging

View File

@ -3,6 +3,8 @@
<!-- PierMesh documentation master file, created by
sphinx-quickstart on Fri Jul 26 23:30:55 2024. -->
<a id="piermesh-documentation"></a>
# PierMesh documentation
# Contents:
@ -68,6 +70,8 @@ sphinx-quickstart on Fri Jul 26 23:30:55 2024. -->
* [`Cache.refresh()`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Cache.md#Daisy.Cache.Cache.refresh)
* [`Cache.search()`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Cache.md#Daisy.Cache.Cache.search)
* [`Catch`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Catch.md)
* [`Catch.addc()`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Catch.md#Daisy.Catch.Catch.addc)
* [`Catch.catches`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Catch.md#Daisy.Catch.Catch.catches)
* [`Catch.get()`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Catch.md#Daisy.Catch.Catch.get)
* [`Catch.sget()`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Catch.md#Daisy.Catch.Catch.sget)
* [`Daisy`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Daisy.md)
@ -81,6 +85,8 @@ sphinx-quickstart on Fri Jul 26 23:30:55 2024. -->
* [`Compound`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Soil.md#Daisy.Soil.Compound)
* [`Compound.on_any_event()`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Soil.md#Daisy.Soil.Compound.on_any_event)
* [`Store`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Store.md)
* [`Store.getRecord()`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Store.md#Daisy.Store.Store.getRecord)
* [`Store.update()`](/PierMesh/piermesh/src/branch/main/docs/Daisy/Store.md#Daisy.Store.Store.update)
* [`DHEFern`](/PierMesh/piermesh/src/branch/main/docs/Cryptography/WhaleSong.md)
* [`DHEFern.cLog`](/PierMesh/piermesh/src/branch/main/docs/Cryptography/WhaleSong.md#Cryptography.WhaleSong.DHEFern.cLog)
* [`DHEFern.loadedParams`](/PierMesh/piermesh/src/branch/main/docs/Cryptography/WhaleSong.md#Cryptography.WhaleSong.DHEFern.loadedParams)

View File

@ -1,3 +1,5 @@
<a id="run-piermesh-service-runner"></a>
# run: PierMesh service runner
### *class* run.Node

View File

@ -1,3 +1,5 @@
<a id="ui-tui-application"></a>
# ui: TUI application
### *class* ui.TUI(driver_class: Type[Driver] | None = None, css_path: str | PurePath | List[str | PurePath] | None = None, watch_css: bool = False)

View File

@ -1,5 +1,7 @@
hopper: Small internet interop utilities
========================================
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/Protocols/map.py>`__
.. automodule:: Components.hopper
:members:

View File

@ -21,6 +21,8 @@ from Daisy.Store import Store
class DHEFern:
"""
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Cryptography/WhaleSong.py>`__
Attributes
----------
cLog

View File

@ -5,3 +5,4 @@ Fernet based encryption
.. autoclass:: Cryptography.WhaleSong.DHEFern
:members:
:undoc-members:

View File

@ -12,6 +12,8 @@ from watchdog.observers import Observer
class Cache:
"""
In memory collection of Daisy records
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Daisy/Cache.py>`__
"""
def __init__(

View File

@ -3,3 +3,4 @@ Daisy based cache
.. autoclass:: Daisy.Cache.Cache
:members:
:undoc-members:

View File

@ -9,6 +9,8 @@ class Catch(Cache):
Sub class of Cache for handling catchs
.. image:: https://git.utopic.work/PierMesh/piermesh/raw/branch/main/imgs/catchdisplay.png
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Daisy/Catch.py>`__
"""
catches = {}

View File

@ -4,3 +4,4 @@ PierMesh's domain analog
.. autoclass:: Daisy.Catch.Catch
:members:
:undoc-members:

View File

@ -29,7 +29,7 @@ class Daisy:
"""
Base class for Daisy data representation
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Components/daisy.py>`_
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Components/daisy.py>`__
Attributes
----------

View File

@ -4,3 +4,4 @@ base class
.. autoclass:: Daisy.Daisy.Daisy
:members:
:undoc-members:

View File

@ -12,6 +12,8 @@ garden = {}
class Compound(FileSystemEventHandler):
"""
File system watcher to propagate disk changes
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Daisy/Soil.py>`__
"""
def __init__(self, cache, isCatch: bool = False):

View File

@ -3,3 +3,4 @@ Daisy signal management
.. autoclass:: Daisy.Soil.Compound
:members:
:undoc-members:

View File

@ -4,6 +4,12 @@ import os
class Store(Daisy):
"""
Key value store
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Daisy/Store.py>`__
"""
def __init__(self, store: str, path: str, nodeNickname: str):
fpath = "daisy/{0}/{1}".format(path, nodeNickname)
cpath = "{0}/{1}/{2}".format(path, nodeNickname, store)

View File

@ -4,3 +4,4 @@ store with recursion
.. autoclass:: Daisy.Store.Store
:members:
:undoc-members:

View File

@ -7,6 +7,8 @@ class Header(Packet):
"""
Metadata packet for messages
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Packets/HeaderPacket.py>`__
Attributes
----------
sender: int

View File

@ -3,3 +3,4 @@ Header packet: Metadata packet
.. autoclass:: Packets.HeaderPacket.Header
:members:
:undoc-members:

View File

@ -12,6 +12,8 @@ class Message:
"""
Full message which is composed of `Packets.Packet.Packet`s
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Packets/Message.py>`__
Attributes
----------
packets: list[Packets.Packet.Packet]

View File

@ -3,3 +3,4 @@ Full message
.. autoclass:: Packets.Message.Message
:members:
:undoc-members:

View File

@ -3,3 +3,4 @@ Base packet
.. autoclass:: Packets.Packet.Packet
:members:
:undoc-members:

View File

@ -11,6 +11,8 @@ class SinglePacket(Packet):
WIP
Single packet for very small protocols
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Packets/SinglePacket.py>`__
"""
def __init__(self, data, packetsID, packetsClass=None, cache=None):

View File

@ -4,3 +4,4 @@ for very low data applications
.. autoclass:: Packets.SinglePacket.SinglePacket
:members:
:undoc-members:

View File

@ -10,7 +10,7 @@ class Network:
"""
Layered graph network
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Bubble/map.py>`_
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Siph/map.py>`_
Attributes
----------

View File

@ -3,3 +3,4 @@ Network map representation
.. autoclass:: Siph.map.Network
:members:
:undoc-members:

View File

@ -18,6 +18,8 @@ class Server:
"""
Web server that serves the web ui and provides web to node communication
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Sponge/serve.py>`__
Attributes
----------
cLog

View File

@ -3,3 +3,4 @@ serve: Web UI server
.. autoclass:: Splash.serve.Server
:members:
:undoc-members:

View File

@ -2,7 +2,7 @@ async def filter(completeMessage, recipient, recipientNode, onodeID, todo):
"""
Peer to peer protol
`🔗 Bubble Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Sponge/Protocols/bubble.py>`_
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Sponge/Protocols/bubble.py>`__
"""
m = completeMessage
if recipientNode == onodeID:

View File

@ -2,7 +2,7 @@ async def filter(completeMessage, recipient, recipientNode, todo):
"""
Catch exchange protocol
`🔗 Catch Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/Protocols/catch.py>`_
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/Protocols/catch.py>`__
"""
m = completeMessage
# TODO: Sending to other nodes clients

View File

@ -2,7 +2,7 @@ async def filter(completeMessage, recipientNode, todo):
"""
Cryptographic operations protocol
`🔗 Cryptography Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/Protocols/cryptography.py>`_
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/Protocols/cryptography.py>`__
"""
todo.append(
{

View File

@ -2,7 +2,7 @@ async def filter(completeMessage, todo):
"""
Network mapping protocol
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/Protocols/map.py>`_
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/Protocols/map.py>`__
"""
m = completeMessage
todo.append(

View File

@ -12,7 +12,7 @@ class Filter:
"""
Packet filtering orchestration
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/base.py>`_
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/Sponge/base.py>`__
cLog
Reference to `run.Node.cLog` for logging

View File

@ -4,6 +4,7 @@ Dispatches to Protocols
.. autoclass:: Sponge.base.Filter
:members:
:undoc-members:
.. automethod:: Sponge.Protocols.bubble.filter

View File

@ -13,6 +13,8 @@ class Transceiver:
"""
Handling LoRa transceiving
`🔗 Source <https://git.utopic.work/PierMesh/piermesh/src/branch/main/src/Transceiver/Transceiver.py>`__
Attributes
----------
cLog

View File

@ -3,3 +3,4 @@ Layer 0 data transceiving
.. autoclass:: Transceiver.Transceiver.Transceiver
:members:
:undoc-members:

View File

@ -23,9 +23,11 @@ extensions = [
"sphinx_markdown_builder",
"sphinx.ext.autodoc",
"sphinx.ext.napoleon",
"sphinx.ext.viewcode",
]
napoleon_use_param = True
markdown_anchor_sections = True
templates_path = ["_templates"]
exclude_patterns = []