You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Note that one line 15, I add two blank space " " which means "Got to next line" in markdown.
I think when python parses the yaml of the ConfigMap, it doesn't use the string as-is and does some funky stuff.
The only thing I managed to do was to add two blank line, but that creates a new markdown paragraph, instead of going to next line.
Note 1
Strictly using the dashboard UI in NetBox to create a note block and going to next line with the double space syntax does work correctly.
Note 2
If I strictly follow the example on NetBox documentation, is doesn't work at all as the parenthesis string literals in python don't play well with yaml :
{'widget': 'extras.NoteWidget','width': 4,'height': 2,'title': 'Welcome!','color': 'green','config': {'content': ('This is your personal dashboard. Feel free to customize it by rearranging, resizing, or removing ''widgets. You can also add new widgets using the "add widget" button below. Any changes affect only ''_your_ dashboard, so feel free to experiment!')}},
Note 3
First thing I tried is using the | pipe yaml string literal to try and make a non escaped multi line paragraph :
Remember that the example you pointed at is actually Python code; your snippet should use valid YAML. The python code looks a little like JSON (which is valid YAML) but the quoting is wrong. I haven't actually tried this, but this is valid YAML at least:
I'm adding a ConfigMap to the namespace for
DEFAULT_DASHBOARD
declaration, it looks like this :Note that one line 15, I add two blank space " " which means "Got to next line" in markdown.
I think when python parses the yaml of the ConfigMap, it doesn't use the string as-is and does some funky stuff.
The only thing I managed to do was to add two blank line, but that creates a new markdown paragraph, instead of going to next line.
Note 1
Strictly using the dashboard UI in NetBox to create a note block and going to next line with the double space syntax does work correctly.
Note 2
If I strictly follow the example on NetBox documentation, is doesn't work at all as the parenthesis string literals in python don't play well with yaml :
Note 3
First thing I tried is using the
|
pipe yaml string literal to try and make a non escaped multi line paragraph :But it doesn't seem python
yaml.safe_load()
is interpreting this correctly and leads to exceptions in the logs :The text was updated successfully, but these errors were encountered: