Skip to content
This repository was archived by the owner on Apr 29, 2024. It is now read-only.

Commit ace0fb2

Browse files
committed
Add detailed site-breakage data
This is intended to allow us to compute the overall priority of an issue based on the factors we use in triage, rather than assigning the impact/severity directly. It adds a number of fields under 'breakage' that contain details about the extent and impact of the breakage. For now plain URLs are still allowed, to avoid having to rewrite all existing entries at once.
1 parent 968002f commit ace0fb2

File tree

3 files changed

+160
-8
lines changed

3 files changed

+160
-8
lines changed

data/sidebar.yml

Lines changed: 32 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,37 @@ solutions:
1616

1717
references:
1818
breakage:
19-
- https://github.com/webcompat/web-bugs/issues/11622
20-
- https://github.com/webcompat/web-bugs/issues/55685
21-
- https://github.com/webcompat/web-bugs/issues/67848
22-
- https://github.com/webcompat/web-bugs/issues/106830
19+
- url: https://github.com/webcompat/web-bugs/issues/11622
20+
site: http://www.election.gov.np
21+
platform:
22+
- all
23+
intervention: https://github.com/mozilla-extensions/webcompat-addon/blob/4a3094f52d561925620ac441d5c4423766ec5c29/src/webextension/injections/js/bug1472081-election.gov.np-window.sidebar-shim.js
24+
impact: feature_broken
25+
affects_users: all
26+
resolution: site_changed
27+
- url: https://github.com/webcompat/web-bugs/issues/55685
28+
site: http://www.susu09.com/forum.php
29+
platform:
30+
- all
31+
last_reproduced: 2020-07-27
32+
impact: site_broken
33+
affects_users: all
34+
resolution: site_fixed
35+
- url: https://github.com/webcompat/web-bugs/issues/67848
36+
site: https://indichords.com/
37+
platform:
38+
- all
39+
last_reproduced: 2021-03-08
40+
impact: feature_broken
41+
affects_users: all
42+
resolution: site_fixed
43+
- url: https://github.com/webcompat/web-bugs/issues/106830
44+
site: https://www.pontefractfhs.org.uk
45+
platform:
46+
- all
47+
last_reproduced: 2022-07-09
48+
impact: site_broken
49+
affects_users: all
50+
resolution: site_fixed
2351
platform_issues:
2452
- https://bugzilla.mozilla.org/show_bug.cgi?id=1428302

schemas/entry.schema.json

Lines changed: 60 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,11 +80,68 @@
8080
"additionalProperties": false,
8181
"properties": {
8282
"breakage": {
83-
"description": "List of URLs to issues where actual site breakage is tracked. If available, point the link directly to a comment with clear STR",
83+
"description": "List of issues tracking known site breakage.",
8484
"type": "array",
8585
"items": {
86-
"type": "string",
87-
"format": "uri"
86+
"anyOf": [
87+
{
88+
"type": "string",
89+
"format": "uri",
90+
"description": "URL of tracking issue"
91+
},
92+
{
93+
"type": "object",
94+
"properties": {
95+
"url": {
96+
"type": "string",
97+
"format": "uri",
98+
"description": "URL of tracking issue"
99+
},
100+
"site": {
101+
"type": "string",
102+
"format": "uri",
103+
"description": "URL of broken site of page"
104+
},
105+
"platform": {
106+
"type": "array",
107+
"items": {
108+
"type": "string",
109+
"enum": ["all", "desktop", "mobile", "windows", "macos", "linux"],
110+
"description": "List of affected platforms. Default is 'all'"
111+
}
112+
},
113+
"last_reproduced": {
114+
"type": "string",
115+
"format": "date",
116+
"description": "Most recent date the issue was successfully reproduced"
117+
},
118+
"intervention": {
119+
"type": "string",
120+
"format": "uri",
121+
"description": "URL of intervention that is shipping or has been shipped. Link to the code in the GitHub repository, and use the canonical URLs to ensure persistance over time"
122+
},
123+
"impact": {
124+
"type": "string",
125+
"enum": ["site_broken", "feature_broken", "significant_visual", "minor_visual", "unsupported_message"],
126+
"description": "Type of breakage"
127+
},
128+
"affects_users": {
129+
"type": "string",
130+
"enum": ["all", "some", "few"],
131+
"description": "What fraction of users are affected. 'all' where any site user is likely to run into the issue, 'some' for issues that are common but many users will not experience, and 'few' where the breakage depends on an unusual configuration or similar."
132+
},
133+
"resolution": {
134+
"type": "string",
135+
"enum": ["site_changed", "site_fixed"],
136+
"description": "If the issue no longer reproduces on this site, the kind of change that happened. 'site_change' if there was a general redesign or the site is no longer online, 'site_fixed' if the specific issue was patched."
137+
},
138+
"notes": {
139+
"type": "string",
140+
"description": "Any additional notes about why the other fields for this issue are set to the given values."
141+
}
142+
}
143+
}
144+
]
88145
}
89146
},
90147
"platform_issues": {

tools/kbcheck/src/entry.rs

Lines changed: 68 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ pub struct Solutions {
3434
#[serde(deny_unknown_fields)]
3535
pub struct References {
3636
#[serde(default)]
37-
pub breakage: Vec<Url>,
37+
pub breakage: Vec<BreakageItem>,
3838
#[serde(default)]
3939
pub platform_issues: Vec<Url>,
4040
#[serde(default)]
@@ -47,6 +47,73 @@ pub struct References {
4747
pub standards_discussions: Vec<Url>,
4848
}
4949

50+
#[derive(Debug, Serialize, Deserialize)]
51+
#[serde(untagged)]
52+
pub enum BreakageItem {
53+
Url(Url),
54+
Breakage(Breakage),
55+
}
56+
57+
impl BreakageItem {
58+
pub fn url(&self) -> &Url {
59+
match self {
60+
BreakageItem::Url(url) => url,
61+
BreakageItem::Breakage(item) => &item.url,
62+
}
63+
}
64+
}
65+
66+
#[derive(Debug, Serialize, Deserialize)]
67+
#[serde(deny_unknown_fields)]
68+
pub struct Breakage {
69+
url: Url,
70+
site: Url,
71+
platform: Vec<Platform>,
72+
last_reproduced: Option<String>, // Date
73+
intervention: Option<Url>,
74+
impact: Impact,
75+
affects_users: AffectsUsers,
76+
resolution: Option<BreakageResolution>,
77+
#[serde(default)]
78+
notes: String,
79+
}
80+
81+
#[derive(Debug, PartialEq, Serialize, Deserialize)]
82+
#[serde(rename_all = "lowercase")]
83+
pub enum Platform {
84+
All,
85+
Desktop,
86+
Mobile,
87+
Windows,
88+
Macos,
89+
Linux,
90+
}
91+
92+
#[derive(Debug, PartialEq, Serialize, Deserialize)]
93+
#[serde(rename_all = "snake_case")]
94+
pub enum Impact {
95+
SiteBroken,
96+
FeatureBroken,
97+
SignificantVisual,
98+
MinorVisual,
99+
UnsupportedMessage,
100+
}
101+
102+
#[derive(Debug, PartialEq, Serialize, Deserialize)]
103+
#[serde(rename_all = "lowercase")]
104+
pub enum AffectsUsers {
105+
All,
106+
Some,
107+
Few,
108+
}
109+
110+
#[derive(Debug, PartialEq, Serialize, Deserialize)]
111+
#[serde(rename_all = "snake_case")]
112+
pub enum BreakageResolution {
113+
SiteChanged,
114+
SiteFixed,
115+
}
116+
50117
#[derive(Debug, Serialize, Deserialize)]
51118
#[serde(deny_unknown_fields)]
52119
pub struct Entry {

0 commit comments

Comments
 (0)