Repository navigation
Commit 117f115
Show square brackets in airflowctl table and plain output as typed (#76175)
* Show square brackets in airflowctl table and plain output as typed
`airflowctl ... --output table` and `--output plain` passed values to Rich
as markup, so a value such as `[/b]` crashed the command with a
MarkupError and a value such as `s3://[bucket]/path` silently lost its
bracketed part. Render the values literally, as `--output json` and
`--output yaml` already do.
* Show square brackets in airflowctl table headers as typed
Column headers were still passed to Rich as markup, so a key such as
`[/b]` raised a MarkupError and `[red]name[/red]` lost its tags in
`--output table`. Escape them like the cell values, and run the output
tests once per value, including a backslash before a tag.
---------
Co-authored-by: Shahar Epstein <[email protected]>1 parent 4eba351 commit 117f115
2 files changed
Lines changed: 33 additions & 3 deletions
File tree
- airflow-ctl
- src/airflowctl/ctl
- tests/airflow_ctl/ctl
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
| 26 | + | |
26 | 27 | | |
27 | 28 | | |
28 | 29 | | |
| |||
74 | 75 | | |
75 | 76 | | |
76 | 77 | | |
77 | | - | |
| 78 | + | |
78 | 79 | | |
79 | 80 | | |
80 | | - | |
| 81 | + | |
81 | 82 | | |
82 | 83 | | |
83 | 84 | | |
| |||
87 | 88 | | |
88 | 89 | | |
89 | 90 | | |
90 | | - | |
| 91 | + | |
91 | 92 | | |
92 | 93 | | |
93 | 94 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
162 | 162 | | |
163 | 163 | | |
164 | 164 | | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
0 commit comments