Saravanan666/pypi-org huggingface dataset:
Package: simple-print
Simple printPrint value with variable name.Userful for fast debugging.https://github.com/Sobolev5/simple-printInstallTo install run:pip install simple-printPrint variables with namesFull exampleyou can see here.master="yoda"# variable name mastersprint(master)sprint(master,c="magenta")sprint(master,c="white",b="on_blue")sprint(master,c="blue",b="white",a="underline")sprint(master,c="blue",b="on_white",a="bold",p=True)master_as_s=sprint(master,s=True)# return as stringmaster_as_s_with_path=sprint(master,s=True,p=True)# return as string with path to filepparam isFalseby default, but you can override this behavior withSIMPLE_PRINT_PATH_TO_FILE=Truein your local environment.Fn params:ccolor [grey, red, green, yellow, blue, magenta, cyan, white]bbackground [on_grey, on_red, on_green, on_yellow, on_blue, on_magenta, on_cyan]aattribute  [bold, dark, underline, blink, reverse, concealed]ppath [with path to file]iindent [indent 1..40]sstring [return as string]rreturn [print and return as string]fforce print [ignore SIMPLE_PRINT_ENABLED=False for docker production logs for example]streamoutput stream  [stdout, stderr, null]. stdout by default. null means no print.Example with indentFor indent useiparam. Full exampleyou can see here.deftest_indent():fruits=["lemon","orange","banana"]sprint(fruits,c="green")forfruitinfruits:sprint(fruit,c="yellow",i=4)Pretty error tbShow last 20 error_tb lines (useful for large error tb):fromsimple_printimportSprintErrwithSprintErr(l=20):some_broken_code/0ENVStop printing:exportSIMPLE_PRINT_ENABLED=FalseAlways show path to file:exportSIMPLE_PRINT_SHOW_PATH_TO_FILE=TrueAdd linebreak to every print:exportSIMPLE_PRINT_ADD_LINE_BREAK=TrueTesttox
Package: simpleprofiler
simpleprofilerTool to profile your code in pythonInstallationpip install simpleprofilerLogging LevelDefaultly simpleprofiler use INFO as logging levelExampleCode:fromsimpleprofilerimportget_profileimportlogginglogging.basicConfig()logging.getLogger().setLevel(logging.INFO)_logger=logging.getLogger(__name__)@get_profiledeftry_func(bool,arr):ifbool:foriteminarr:_logger.info(item)else:foriteminarr:_logger.info(info)try_func(True,["try"*10])On Console:try_func >  calls     ms
try_func >  ------------------------------------ /DIRECTORY_TO/example.py, 8

try_func > 1         0.0       @get_profile
try_func >                     def try_func(bool, arr):
try_func > 1         0.0           if bool:
try_func > 2         0.0               for item in arr:
try_func > 1         0.21                  _logger.info(item)
try_func >                         else:
try_func >                             for item in arr:
try_func >                                 _logger.info(item)

try_func > Total:
try_func > 1         0.21
Package: simpleprogress
## simpleprogressSimple progress indicator for python. Internally tracks time for updates.```pythonfrom simpleprogress import Progressmax_val = 100p = Progress(max_val, poll_time=2.0) # default poll time is 1 secondfor i in range(0, 100):if p.should_update:p.update(i)print(p.pretty_print())time.sleep(1)```
Package: simple-progress-bar
Simple Progress BarThis module will print a progress bar for console apps.
It should be used inside a for loop.Installationpip install simple-progress-barUsage# import function from modulefromsimple_progress_barimportprint_progressbardeftest_function():df_test=pd.read_excel('test_file_read.xls')df_test_size=len(df_dles.index)# iterate through anything - here is a pandas dataframeforindex,rowindf_test.iterrows():index_fix=index+1result='Test'df_test.loc[index,'result']=result# Printing the progress barprint_progressbar(index_fix,df_test_size,blank='-',description=f"Testing: Line{index_fix}of{df_test_size}")df_test.to_excel('test_file_write.xls')
Package: simpleprotocol
python-simpleprotocolA small socket wrapperUsed for sending code, subcode, parameters.Code: IntegerSubcode: IntegerParams: Array of stringsOnly has basic use, as shown in this example:Server:import simpleprotocol

server = simpleprotocol.SimpleServer(port=8080)

while True:
    handler = server.accept()
    handler.send(0)
    print(handler.get())
    handler = server.accept()
    handler.send(1)
    print(handler.get())Client:import simpleprotocol

socket = simpleprotocol.SimpleProtocol()

if socket.get().code:
    socket.send(1, 0, ["That sounds good!"])
else:
    socket.send(1, 1, ["Oh dear, that's not right..."])
Package: simple-proxypool
simple-proxy-pool简单IP代理池 simple_pp 是个 异步并发IP代理验证工具，速度很快，一千个代理半分钟左右可完成。安装pip install -U simple-proxy-pool或下载 repo (e.g.,git clone https://github.com/ffreemt/simple-proxy-pool.git换到 simple-proxy-pool目录执行python setup.py develop原理通过过IP代理访问www.baidu.com, 能成功获取百度返回的头则代理有效。再检查头里面时候含'via', 不含'via'即为匿名代理。参考 aio_headers.py。用法命令行python -m simple_pp贴入需验证的IP代理（格式 ip:端口, 以空格、回车非数字字母或中文隔开）。或：python -m simple_pp file1 file2 ...文件内含以上格式的IP代理也可以用pipe，例如curl "https://www.freeip.top/?page=1" | python -m simple_pppython 程序内调用from simple_pp import simple_pp
from pprint import pprint

ip_list = [ip1, ip2, ...]
res = simple_pp(ip_list)
pprint(res)输出 res 里格式为: res[0] = ip_list[0] +（是否有效，是否匿名，响应时间秒）可参看tests 里面的文件。有疑问或反馈可发 Issues。例如import asyncio
import httpx
from simple_pp import simple_pp

simple_pp(['113.53.230.167:80', '36.25.243.51:80'])
# 输出-> [('113.53.230.167:80', True, False, 0.31),
# ('36.25.243.51:80', True, True, 0.51)]
# 第一个代理为透明代理，第二个代理为匿名代理也可以直接将网页结果送给 simple_pp, 例如import re
import asyncio
import httpx
from pprint import pprint
from simple_pp import simple_pp

arun = lambda x: asyncio.get_event_loop().run_until_complete(x)
_ = [elm for elm in simple_pp([':'.join(elm) if elm[1] else elm[0] for elm in re.findall(r'(?:https?://)?(\d{1,3}(?:\.\d{1,3}){3})(?:[\s\t:\'",]+(\d{1,4}))?', arun(httpx.get('https://www.freeip.top/?page=1')).text)]) if elm[-3] is True]
pprint(_)
# 可能拿到将近 10 个代理
# 或
_ = [elm for elm in simple_pp(arun(httpx.get('https://www.freeip.top/?page=1')).text) if elm[-3] is True]
pprint(_)
# dittoAcknowledgments含 jhao 的 proxypool 项目里的几个文件， 但并未使用，可能将来会用。先感谢jhao开源。
Package: simple-proxy-pool
simple-proxy-pool简单IP代理池 simple_pp 是个 异步并发IP代理验证工具，速度很快，一千个代理半分钟左右可完成。安装pip install -U simple-proxy-pool或下载 repo (e.g.,git clone https://github.com/ffreemt/simple-proxy-pool.git换到 simple-proxy-pool目录执行python install -r requirements.txt
python setup.py develop代理验证原理通过IP代理访问www.baidu.com, 能成功获取百度返回的头则代理有效。再检查头里面是否含'via', 不含'via'即为匿名代理。参考 aio_headers.py。用法命令行简单用法python -m simple_ppsimple_pp 会试着以各种方式搜集到不少于 200 个代理，验证后将有效代理输出到屏幕上。普通用法用户可以提供自己的代理：直接将自由格式的代理贴在命令行后面，或提供含自由格式代理的文件名贴在命令行后面，或在运行python -m simple_pp前将代理拷入系统剪贴板。python -m simple_pp贴入需验证的IP代理（格式 ip:端口, 以空格、回车非数字字母或中文隔开均可）。或：python -m simple_pp file1 file2 ...文件内含以上格式的IP代理也可以用pipe，例如curl "https://www.freeip.top/?page=1" | python -m simple_pp如果只想验证代理可加上-c开关，例如验证本地 8889、8080和80端口python -m simple_pp -c 127.0.0.1 8889 127.0.0.1 8080 127.0.0.1得到的输出为Time elapsed: 1.075 s
         验证中……
Time elapsed: 1.075 s
 代理                   源      有效    匿名    响应时间
[('127.0.0.1:8889', 'user', True, False, 0.71)]
['total:', 1]或运行python -m simple_pp -c 127.0.0.1 127.0.0.1:8889 127.0.0.1:8080高级用法显示详细用法python -m simple_pp -h给定代理数目python -m simple_pp -p 500只显示有效匿名代理python -m simple_pp -a给定代理数目、只显示有效匿名代理python -m simple_pp -p 800 -apython 程序内调用from simple_pp import simple_pp
from pprint import pprint

ip_list = [ip1, ip2, ...]
res = simple_pp(ip_list)
pprint(res)输出 res 里格式为: res[0] = ip_list[0] +（是否有效，是否匿名，响应时间秒）可参看__main__.py 或 tests 里面的文件。有疑问或反馈可发 Issues。例如import asyncio
import httpx
from pprint import pprint
from simple_pp import simple_pp

pprint(simple_pp(['113.53.230.167:80', '36.25.243.51:80']))输出为:Time elapsed: 1.329 s
[('36.25.243.51:80', True, True, 0.61),
 ('113.53.230.167:80',
  'Cannot connect to host 113.53.230.167:80 ssl:default [Connect call failed '
  "('113.53.230.167', 80)]",
  False,
  1.33)]既是说，第一个代理 113.53.230.167:80 无效，第二个代理 36.25.243.51:80 为匿名代理也可以直接将网页结果送给 simple_pp, 例如import asyncio
import httpx
from pprint import pprint
from simple_pp import simple_pp

arun = lambda x: asyncio.get_event_loop().run_until_complete(x)
_ = [elm for elm in simple_pp([':'.join(elm) if elm[1] else elm[0] for elm in re.findall(r'(?:https?://)?(\d{1,3}(?:\.\d{1,3}){3})(?:[\s\t:\'",]+(\d{1,4}))?', arun(httpx.get('https://www.freeip.top/?page=1')).text)]) if elm[-3] is True]
pprint(_)
# 可能拿到将近 10 个代理
# 或
_ = [elm for elm in simple_pp(arun(httpx.get('https://www.freeip.top/?page=1')).text) if elm[-3] is True]
pprint(_)
# ditto鸣谢用了 jhao 的 proxypool 项目里几个文件。感谢jhao开源。
Package: simplepush
Python module to send push notifications viaSimplepush.Installationpip3installsimplepushExamplesAll examples can be made asynchronous by usingasync_sendinstead ofsend.Send a push notification to the Simplepush keyYourKey:importsimplepushsimplepush.send(key='YourKey',title='Notification title',message='Notification message')Send a push notification with actions and a callback function that will print the selected action:importsimplepushdefcallback(action_selected,action_selected_at,action_delivered_at,feedback_id):print(action_selected)simplepush.send(key='YourKey',title='Title',message='Actionable notification',actions=['yes','no','maybe'],feedback_callback=callback)Send an end-to-end encrypted push notification with actions and a callback function that will print the selected action and times out after 120 seconds:importsimplepushdefcallback(action_selected,action_selected_at,action_delivered_at,feedback_id):print(action_selected)simplepush.send(key='YourKey',password='password',salt='salt',message='Actionable notification',actions=['yes','no','maybe'],feedback_callback=callback,feedback_callback_timeout=120)Send an end-to-end encrypted push notification with an image and a video file:importsimplepushsimplepush.send(key='YourKey',message='Attachments',password='password',salt='salt',attachments=['https://upload.wikimedia.org/wikipedia/commons/e/ee/Sample_abc.jpg',{'video':'http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ElephantsDream.mp4','thumbnail':'http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/images/ForBiggerEscapes.jpg'}])
Package: simple-pushover
PushOver Push Notification API ModuleA single Python Module that allows for the interaction with PushOver's Push Notification API. PushOver offers a service that makes it really easy to send Push Notification to devices (laptops, phones, etc). This is all accomplished easily through the use of POST Requests to their API Endpoint. This module just takes the easy to use service and wraps it up in a nice and quick way to allow for quicker script writing.Set up:Get an account at:https://pushover.net/(This is the "Dashboard" URL once signed in)Copyexample.envand rename it to.envGrab the "User Key" and add it to the designated place (USER_KEY) in the.env, found in the root of the project directory (pushover/)Next create your application through:https://pushover.net/apps/buildGrab the "API Token/Key" (we'll call it a "API Token" because the POST calls it a Token so therefore it is aTOKEN). Add theAPI Tokento the designated place (API_TOKEN) in the.envFinally run:pip install -r requirements.txtDON'T FORGET TO ADD A DEVICE AND INSTALL THE APP ON YOUR PHONE OR HAVE THE BROWSER REGISTERED!This can be done through the Dashboard.Usage and Limitations:Once you have completed the set up, you should be ready to use the module. There are some limitations the PushOver Push Notification API. These limitations are actually also handled within the python module itself, as validation, to help avoid users of this module from wasting API Calls and wasting their time. Before using the module make sure to give a quick glance to the limitations:https://pushover.net/api#limits.None of the limitations are particularly major. Mainly max length restrictions on URLs and Text, and then Byte Size limits on Images.Usagefromsimple_pushoverimportPushoverAPI# first create a PushoverAPI instanceapi=PushoverAPI()# To send a message (under 1024 Characters...) You can use the simple_send_push or the more featureful send_push.# Really only the message kwarg is required.api.simple_send_push(message="Hello World")# You can also add the priority kwarg to set the priority level (-2 thru 2). I.E. priority=1 sends a message with a High Priority. It should be noted that the default is 0 which is normal priorityapi.simple_send_push(message="Hello World",priority=1)# For more complex Push notifications you can use:api.send_push(title="Test Title",message="This is an example of a more complex push notification.",url="https://example.com/",url_title="Link Display Title",attachment="path/to_img.png",priority=1)# Once again the only required kwarg is message. However If you pass the kwarg url_title, you must also pass a URL.Future Enhancements:I may add some other minor pieces to the module to help with other APIs that PushOver offers(maybe once I have a need for them :^)). The Push Notification still has some touch ups needed which can be found below...TO DO:Add filetype validation to the image attachments... Technically their API only handles images as attachments according to their API. I forgot to add that check,DOH!Add HTML parsing options
Package: simplepycli
PyCLIPyCLI is a really simple library for interactive python CLIs. I mostly built
it for personal use on side projects, but feel free to use it.Install InstructionsTo install:pipinstallsimplepycliBasic API ExampleThe API is really simple, so here is a comprehensive example of how it works. This is also available at example.py:fromsimplepycliimportPyCLIApp# The only paramater for PyCLIApp is the marker to use in front of the terminal; defaults to "> "app=PyCLIApp("> ")@app.command("egg","Prints egg to the console")defegg(params):print("egg")@app.command("echotwice","Echos the string passed in as a paramater twice")defechotwice(params):foriinrange(2):print(params)app.run()This outputs a terminal that behaves like this> egg
egg
> echotwice abc
abc
abc
> help
exit : Exit the current CLI session and close the program.
help : List available commands and their help messages.
clear : Clear the current command line.
egg : Prints egg to the console
echotwice : Echos the string passed in as a paramater twice
> |
Package: simplepycuda
The library cudapp is the basis of SimplePyCuda, a simple wrapper for CUDA functions in Python.
The idea is to workaround the issues regarding Context in old CUDA versions, that persist on PyCuda.Usage:"make [all]" will build the lib cudapp.so"make run" will execute "testSimplePyCuda.py", using library "simplepycuda.py".==========================In Python:importctypesimportnumpyfromsimplepycudaimportSimplePyCuda,SimpleSourceModule,grid,blockdefclassicExample(cuda):a=numpy.random.randn(4,4)a=a.astype(numpy.float32)printaa_gpu=cuda.mem_alloc(a.nbytes)cuda.memcpy_htod(a_gpu,a)mod=SimpleSourceModule("""#include<stdio.h>__global__ void doublify ( float* a ){int idx = threadIdx.x + threadIdx.y*4;a[idx] *= 2;//printf("oi=%d\\n",idx);}""")func=mod.get_function("doublify")# TODO: this next line will be made automatically in get_function method... just need a few more time :)func.argtypes=[ctypes.c_void_p,grid,block,ctypes.c_ulong,ctypes.c_ulong]func(a_gpu,grid(1,1),block(4,4,1),0,0)cuda.memcpy_dtoh(a,a_gpu)cuda.deviceSynchronize()printacuda.free(a_gpu)# this is not necessary in PyCUDAprint"Finished"defmain():cuda=SimplePyCuda()classicExample(cuda)return0MIT License- Igor Machado Coelho and Rodolfo Pereira Araujo (2017)
Package: simple-pygame
Simple Pygame is aPythonlibrary that provides many features usingPygameand other libraries. It can help you create multimedia programs much easier and cleaner.Installation:pip install simple_pygameDependencies:Python version:Python >= 3.7.0Python libraries:LibraryVersionpygame>= 1.9.4pyaudio>= 0.2.12Other dependencies:ffmpeg.ffprobe(optional).Example:Go toexamples folderfor examples.License:This library is distributed under theMIT License.
Package: simplepygamemenus
simplepygamemenusA package for making simple menus for your python games!By Leonardo FerrisiInstallationInstall usingpip install simplepygamemenusDocumentation / APIlocalwebpageDemo / Example:See ourDemo FileFeatures:Make simple pygame menusUsage:Create a main menu using the 'Menu()' construtorExample:
    myMenu = Menu(title="MyMainMenu")Add buttons using:myMenu.add_button(label='button text', x, y, fontsize, function=<function to perform>)

Example:
    if you have added a second menu, you can switch to it using your new button using the:
        
    `menuName.run_menu` function

Example2:

   myMenu = Menu(title="MyMainMenu")
   myOtherMenu = Menu(title="myOtherMenu")
   myMenu.add_button(label='button text', x, y, fontsize, function=myOtherMenu.run_main)I'll add more soon, see the example below!LeonardoExtra Info:PyPI Page:https://pypi.org/project/simplepygamemenus/
Package: simplepygraph
Objectifsimplepygraphest un module de manipulation de graphe permettant à la fois de manipuler la structure et de la visualiser dans un notebook. Il est notamment utile pour des enseignant•e•s souhaitant créer des ressources de cours autours des graphes, arbres etc. Le module s'appuie sur deux modules connus :unmodèlequi est un graphe au sens de networkxunevuequi est un graphe au sens de graphvizInstallation et utilisationInstaller l'outilgraphvizInstaller le modulesimplepygraph:pip3 install simplepygraphUtiliser (plutôt dans un notebook) :importsimplepygraphasspgmon_graphe=spg.Graph(5)DocumentationsLe dépot gitlab fourni un listing des fonctionnalitésCe tutoriel détaille un peu les choses :https://sebhoa.gitlab.io/iremi/01_Graphes/pygraph/
Package: simple-pyirc
Simple PyIRCThis project aims at providing a very simple IRC client that can be easily
used in Python scripts to ouput some results or information.The client is written in Python3, respects PEP-8 syntax and should be
fully documented with reST-formatted docstrings.It supports bothRFC 1459andRFC 2812server implementations.This project is not a full-blown IRC client. It is not meant to act as a bot
which would listen and react to IRC messages. For such usage, refer toPyPI's irc packagefor instance. This
IRC client is meant to be lighter and simply send messages to a channel or to
an another user from time to time.UsageThe targeted use case is to be able to connect to a set of specific channels
on a server, keep the connection alive and be able to send messages to this
channel from time to time when other components of the project require it.fromsimple_pyircimportIRCClientirc_client=IRCClient("my.irc.network","mynick")irc_client.join("#chan")# Do something ...irc_client.privmsg("#chan","Result: 42")# Do something else ...irc_client.quit()Or one can also use the context manager if a quick connection is required:fromsimple_pyircimportIRCClientwithIRCClient("my.irc.network","mynick")asirc_client:irc_client.join("#chan")irc_client.msg("#chan","Hello & Good Bye !")
Package: simplepylogg3r
SimplePyLoggerSimple Python Logger package to easily manage custom loggers in Python projects.InstallationBecause the package is hosted on PyPi, the installation process is quite simple:Notice that the package name has a 3 in place of an E, this is due to the availability of names in PyPi.pipinstallsimplepylogg3rUpgrade to latest versionpipinstallsimplepylogg3r-UUsageCurrently, the package supports 3 different loggers:Console LoggerFile LoggerIMPORTANT NOTE:Every logger must be configured before using it, this is done by calling theconfiguremethod of the logger. Once you have configured a logger, the configuration gets saved and everytime you use the logger again, it uses this initial configuration.All logger configuration methods are static, so you can call them directly from the class. They also have all necessary parameters with default values, allowing you to use them without any configuration or customizing whatever you want.Console Loggerfromsplogger.loggersimportConsoleLoggerConsoleLogger.configure('logger_name')# Logger configurationConsoleLogger.debug('Debug Message')ConsoleLogger.info('Info Message')ConsoleLogger.warning('Warning Message')ConsoleLogger.error('Error Message')ConsoleLogger.critical('Critical Message')File Loggerfromsplogger.loggersimportFileLoggerFileLogger.configure('logger_name',filename='example.log')# Logger configurationFileLogger.debug('Debug Message')FileLogger.info('Info Message')FileLogger.warning('Warning Message')FileLogger.error('Error Message')FileLogger.critical('Critical Message')To-Do ListAdd README docs.Generate wiki docs.Add Rotating File Logger (time).Add Rotating File Logger (size).Implement unit tests.Run unit tests on CI.LicenseApache License 2.0
Package: simple-pymq
mqflowmqflow is a simple Python message queue framework, providing an easy-to-use and efficient method to handle tasks asynchronously.Github:https://github.com/dockhardman/mqflowInstallationpipinstallmqflowFeaturesEasy-to-use: mqflow provides a Pythonic API that is both simple and effective for managing message queues.Flexibility: It supports different types of message queues such as FIFO, priority, and circular queues.Thread-Safe: mqflow uses Python's built-in queue library to ensure that your application is thread-safe.Customizable: mqflow allows you to customize your producer and consumer functions, providing great flexibility to fit your needs.UsageHere is an example of a simple message queue pipeline in memory:frommqflow.brokerimportQueueBrokerfrommqflow.producerimportProducerfrommqflow.consumerimportConsumerfrommqflow.pipelineimportSequentialMessageQueuedefwork(item,queue:"QueueBroker",*args,**kwargs):print(f"[{item}] -> [{queue}] -> [{''.join(args)}]")task_num=3mq=SequentialMessageQueue(producers=[Producer(target=lambda:"Task sent",max_count=task_num)],consumers=[Consumer(target=work,args=("Task received",),max_count=task_num)],broker=QueueBroker(),)mq.run()# [Task sent] -> [QueueBroker(name=QueueBroker, maxsize=0)] -> [Task received]# [Task sent] -> [QueueBroker(name=QueueBroker, maxsize=0)] -> [Task received]# [Task sent] -> [QueueBroker(name=QueueBroker, maxsize=0)] -> [Task received]This creates a SequentialMessageQueue with a single producer that generates "Task sent" messages, and a single consumer that prints these messages with some additional information. The max_count parameter specifies the number of tasks the producer/consumer will handle before stopping. The broker manages the communication between producers and consumers.
Package: simple-pyms
simple-pyms: Python Microservices Without The HeadachesSimple PyMS (SPMS) provides base class abstractions for a very simple
microservice architecture.  Currently SPMS provides a baseline component that
sends heartbeats and a monitor component that tracks microservices and their
statuses based on these heartbeats.The WAMP protocol is used to handle message brokering and RPC.  So, to use PyMS
you will need aWAMP routersuch
ascrossbar.io.What Does It Do?SPMS makes creating microservices (WAMP Components) and monitoring them easy.
There are two components to deal with - Monitor and Microservice.  Monitor
monitors Service instances.So, create a single Monitor instance and one or more Microservice instances.
Connect them to the router and you have a poor man's microservice architecture.Configuring Your Wamp RouterTo configure your wamp router, you will need to setup roles for your components.
Each microservice component will need to have permissions setup properly for
the microservice uri:py.ms.*permissions:
  # Microservice activities
  - uri: py.ms
    match: prefix
    allow:
      call: true
      register: true
      publish: true
      subscribe: trueCreating A Simple Componentfromsimplepyms.microserviceimportmk_componentfromautobahn.twisted.componentimportruncomponent=mk_component('component-name','ws://localhost:8080/ws','realm')run(component)The code above creates a component that has stop, restart and heartbeat
notification built in.  Add functionality to make your component more
meaningful.fromsimplepyms.microserviceimportmk_componentfromautobahn.twisted.componentimportruncomponent=mk_component('component-name','ws://localhost:8080/ws','realm')@component.register('py.ms.add')defadd(a,b):returna+brun(component)