Commit 135444f
fix(extensions): escape the non-numeric downloads fallback for Rich markup
Address review feedback: the fallback interpolated the untrusted catalog value
straight into a Rich-rendered string, so guarding the ``:,`` ValueError just
traded it for a MarkupError -- a catalog entry with downloads "[/red]foo" still
aborted `extension search`/`info`, and balanced tags could restyle the output.
Wrap the fallback in _escape_markup(str(...)) at both sites, matching how every
other catalog field in these renderers is already escaped. Numeric values keep
the identical ``:,`` branch, so correct catalogs are unchanged.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>1 parent 9fba052 commit 135444f
2 files changed
Lines changed: 32 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
794 | 794 | | |
795 | 795 | | |
796 | 796 | | |
797 | | - | |
| 797 | + | |
| 798 | + | |
| 799 | + | |
| 800 | + | |
798 | 801 | | |
799 | 802 | | |
800 | 803 | | |
801 | | - | |
| 804 | + | |
802 | 805 | | |
803 | 806 | | |
804 | 807 | | |
| |||
983 | 986 | | |
984 | 987 | | |
985 | 988 | | |
986 | | - | |
| 989 | + | |
| 990 | + | |
| 991 | + | |
| 992 | + | |
987 | 993 | | |
988 | 994 | | |
989 | 995 | | |
990 | | - | |
| 996 | + | |
991 | 997 | | |
992 | 998 | | |
993 | 999 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4034 | 4034 | | |
4035 | 4035 | | |
4036 | 4036 | | |
4037 | | - | |
4038 | | - | |
4039 | | - | |
| 4037 | + | |
| 4038 | + | |
| 4039 | + | |
| 4040 | + | |
| 4041 | + | |
| 4042 | + | |
| 4043 | + | |
| 4044 | + | |
| 4045 | + | |
| 4046 | + | |
| 4047 | + | |
| 4048 | + | |
4040 | 4049 | | |
4041 | 4050 | | |
4042 | 4051 | | |
4043 | 4052 | | |
4044 | 4053 | | |
4045 | 4054 | | |
4046 | 4055 | | |
4047 | | - | |
| 4056 | + | |
4048 | 4057 | | |
4049 | | - | |
| 4058 | + | |
4050 | 4059 | | |
4051 | 4060 | | |
4052 | | - | |
4053 | | - | |
4054 | | - | |
| 4061 | + | |
| 4062 | + | |
| 4063 | + | |
| 4064 | + | |
| 4065 | + | |
4055 | 4066 | | |
4056 | 4067 | | |
4057 | 4068 | | |
| |||
4077 | 4088 | | |
4078 | 4089 | | |
4079 | 4090 | | |
4080 | | - | |
| 4091 | + | |
4081 | 4092 | | |
4082 | 4093 | | |
4083 | 4094 | | |
| |||
4091 | 4102 | | |
4092 | 4103 | | |
4093 | 4104 | | |
4094 | | - | |
| 4105 | + | |
| 4106 | + | |
4095 | 4107 | | |
4096 | 4108 | | |
4097 | 4109 | | |
| |||
0 commit comments