File: self_contained_program.py

package info (click to toggle)
python-mitogen 0.3.0~rc1-4
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 3,240 kB
  • sloc: python: 19,899; sh: 91; perl: 19; ansic: 18; makefile: 13
file content (15 lines) | stat: -rw-r--r-- 208 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
"""
I am a self-contained program!
"""

import mitogen


def repr_stuff():
    return repr([__name__, 50])


@mitogen.main()
def main(router):
    context = router.local()
    print(context.call(repr_stuff))