guess what codehilite broke notes and pplaceholders

main
km0 2 years ago
parent f82f6c28b0
commit 40d6e12b41

@ -220,9 +220,9 @@ The system is written in Python, and its code documentation consists mainly of _
A _docstring_ is a piece of text written at the very beginning of a function to document it. Unlike normal comments, that are usually stripped out from code at runtime, _docstrings_ are preserved, and can be consulted with interactive help systems or used as metadata. Many programming languages support this pattern, that is often used to produce automatic pieces of documentation by simply collecting and listing all the functions and relative descriptions. A _docstring_ is a piece of text written at the very beginning of a function to document it. Unlike normal comments, that are usually stripped out from code at runtime, _docstrings_ are preserved, and can be consulted with interactive help systems or used as metadata. Many programming languages support this pattern, that is often used to produce automatic pieces of documentation by simply collecting and listing all the functions and relative descriptions.
In the project these are used to create a world around the code and its structure: in the initial menu, for example, they are used as scenography for the Screenless Office. Reading it we discover how the office is organized in different _bureau_, each dedicated to a specific task. The _Pubblications Office_ deals with daily news and weather forecast, the _Public Relations_ department manage exchanges with social platforms, the _Audio Service Dept._ provides for playback soundtrack, and so on, with the _Inhuman Resources bureau_ keeping track of them all.
``` ```python
#!python
class Humor(Bureau): class Humor(Bureau):
""" """
This bureau entertains the modern worker and provides colorful This bureau entertains the modern worker and provides colorful
@ -244,10 +244,11 @@ class Humor(Bureau):
jux = str(subprocess.check_output("/usr/games/fortune"), encoding="UTF-8") jux = str(subprocess.check_output("/usr/games/fortune"), encoding="UTF-8")
self.print_small(jux) self.print_small(jux)
``` ```
Sample from `jokes.py`, the module of the _Department of Humor_. Here two _docstrings_ describe the bureau itself and the `joke` command.
![The Screenless Office menu printed during a workshop at XPUB](../img/2022-04-04-brendan_humor.jpg) ![The Screenless Office menu printed during a workshop at XPUB](../img/2022-04-04-brendan_humor.jpg)
Menu printed by the Inhuman Resources bureau using the docstrings from the other offices, ready to be invoked with the barcode-scanner.
In the project these are used to create a world around the code and its structure: in the initial menu, for example, they are used as scenography for the Screenless Office. Reading it we discover how the office is organized in different _bureau_, each dedicated to a specific task. The _Pubblications Office_ deals with daily news and weather forecast, the _Public Relations_ department manage exchanges with social platforms, the _Audio Service Dept._ provides for playback soundtrack, and so on, with the _Inhuman Resources bureau_ keeping track of them all.
- versioning tiger dingusun and the chimeric worlding - versioning tiger dingusun and the chimeric worlding

Loading…
Cancel
Save