Text and Markup
markdown.errors
import markdown.errors
Zuri
markdownlifts part of this module out to its own top level; each name below is shown with the path that reaches it. Anything still spelledmarkdown.errors.*needsimport markdown.errors.
The errors that the markdown module raises.
Markdown syntax can't cause an error by itself. Every string is a valid document, and text that doesn't match any Markdown syntax is rendered as plain text. Errors come from the parts around the Markdown, such as front matter that isn't valid YAML.
Classes
MarkdownError
class markdown.MarkdownError < Error
ZuriThe base class of every error that this module raises.
- printable — has a
@to_string(), soechoandprint()show something useful
Constructor
markdown.MarkdownError(message)
ZuriParameters
message(string)
MarkdownError.to_string()
markdown.MarkdownError.to_string()
ZuriMetadataError
class markdown.MetadataError < MarkdownError
ZuriRaised when front matter can't be read, because it isn't valid YAML or it isn't a mapping.
import markdown
catch {
markdown.parse('---\n- a list\n---\n', { metadata: true })
} as error {
echo error.message
}
Zuri- printable — has a
@to_string(), soechoandprint()show something useful
Fields
| Field | Type | Description |
|---|---|---|
line |
number |
The source line that the front matter starts on. |
Constructor
markdown.MetadataError(message, line)
ZuriParameters
message(string)line(?number)
2026, Richard Ore and Zuri contributors