Bug 1406005 Comment 47 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

Morphing this bug per comment 44 and comment 46 to set experiment and variation params using the updated stub-attribution.js API from bug 1567331 which would get written to the stub with https://github.com/mozilla-services/stubattribution/pull/95

In this case, the additional attribution "%26experiment%3Dua-onboarding%26variation%3Dchrome" is 50 characters, so we probably don't require increasing the length from 200 currently enforced by the stub attribution service as well as in Firefox https://searchfox.org/mozilla-central/search?q=ATTR_CODE_MAX_LENGTH But definitely should change it if adding a dedicated ua param later.

---

If it's not too much additional load and/or complexity, it sounds like there's multiple product desires to attribute more than "just chrome" to include the other top default browser UAs. Where the default browser UA should be correctly identified and any others can be false positives.

```
Chrome:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/78.0.3904.108 Safari/537.36

Firefox:
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:67.0) Gecko/20100101 Firefox/71.0

Safari:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_1) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/13.0.3 Safari/605.1.15

Edge:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140 Safari/537.36 Edge/18.17763

Internet Explorer:
Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0) like Gecko
```
E.g., I believe something like this could be acceptable:
```js
function deriveVariation(ua) {
  if (ua.includes("Trident")) return "ie";
  if (ua.includes("Edge"))    return "edge";
  if (ua.includes("Version")) return "safari";
  if (ua.includes("Firefox")) return "firefox";
  if (ua.includes("Chrome"))  return "chrome";
  return "other";
}
```
(Where chromium shows up as "chrome," opera might be false positive "safari" or "chrome," older IE "other," and practically the various mobile UAs probably aren't downloading desktop firefox in significant numbers anyway.)
Morphing this bug per comment 44 and comment 46 to set experiment and variation params using the updated stub-attribution.js API from bug 1567331 which would get written to the stub with https://github.com/mozilla-services/stubattribution/pull/95

In this case, the additional attribution "%26experiment%3Dua-onboarding%26variation%3Dchrome" is 50 characters, so we probably don't require increasing the length from 200 currently enforced by the stub attribution service as well as in Firefox https://searchfox.org/mozilla-central/search?q=ATTR_CODE_MAX_LENGTH But definitely should change it if adding a dedicated ua param later.

---

If it's not too much additional load and/or complexity, it sounds like there's multiple product desires to attribute more than "just chrome" to include the other top default browser UAs. Where the default browser UA should be correctly identified and any others can be false positives.

```
Chrome:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/78.0.3904.108 Safari/537.36

Firefox:
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:67.0) Gecko/20100101 Firefox/71.0

Safari:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_1) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/13.0.3 Safari/605.1.15

Edge:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140 Safari/537.36 Edge/18.17763

Internet Explorer:
Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0) like Gecko
```
E.g., I believe something like this could be acceptable:
```js
function deriveVariation(ua) {
  if (ua.includes("Trident")) return "ie";
  if (ua.includes("Edg"))    return "edge";
  if (ua.includes("Version")) return "safari";
  if (ua.includes("Firefox")) return "firefox";
  if (ua.includes("Chrome"))  return "chrome";
  return "other";
}
```
(Where chromium shows up as "chrome," opera might be false positive "safari" or "chrome," older IE "other," and practically the various mobile UAs probably aren't downloading desktop firefox in significant numbers anyway.)
Morphing this bug per comment 44 and comment 46 to set experiment and variation params using the updated stub-attribution.js API from bug 1567331 which would get written to the stub with https://github.com/mozilla-services/stubattribution/pull/95

In this case, the additional attribution "%26experiment%3Dua-onboarding%26variation%3Dchrome" is 50 characters, so we probably don't require increasing the length from 200 currently enforced by the stub attribution service as well as in Firefox https://searchfox.org/mozilla-central/search?q=ATTR_CODE_MAX_LENGTH But definitely should change it if adding a dedicated ua param later.

---

If it's not too much additional load and/or complexity, it sounds like there's multiple product desires to attribute more than "just chrome" to include the other top default browser UAs. Where the default browser UA should be correctly identified and any others can be false positives.

```
Chrome:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/78.0.3904.108 Safari/537.36

Firefox:
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:67.0) Gecko/20100101 Firefox/71.0

Safari:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_1) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/13.0.3 Safari/605.1.15

Edge:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140 Safari/537.36 Edge/18.17763

Internet Explorer:
Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0) like Gecko
```
E.g., I believe something like this could be acceptable:
```js
function deriveVariation(ua) {
  if (ua.includes("Trident")) return "ie";
  if (ua.includes("Edg"))     return "edge";
  if (ua.includes("Version")) return "safari";
  if (ua.includes("Firefox")) return "firefox";
  if (ua.includes("Chrome"))  return "chrome";
  return "other";
}
```
(Where chromium shows up as "chrome," opera might be false positive "safari" or "chrome," older IE "other," and practically the various mobile UAs probably aren't downloading desktop firefox in significant numbers anyway.)
Morphing this bug per comment 44 and comment 46 to set experiment and variation params using the updated stub-attribution.js API from bug 1567331 which would get written to the stub with https://github.com/mozilla-services/stubattribution/pull/95

In this case, the additional attribution "%26experiment%3Dua-onboarding%26variation%3Dchrome" is 50 characters, so we probably don't require increasing the length from 200 currently enforced by the stub attribution service as well as in Firefox https://searchfox.org/mozilla-central/search?q=ATTR_CODE_MAX_LENGTH But definitely should change it if adding a dedicated ua param later.

---

If it's not too much additional load and/or complexity, it sounds like there's multiple product desires to attribute more than "just chrome" to include the other top default browser UAs. Where the default browser UA should be correctly identified and any others can be false positives.

```
Chrome:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/78.0.3904.108 Safari/537.36
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.117 Safari/537.36

Firefox:
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:67.0) Gecko/20100101 Firefox/71.0
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:67.0) Gecko/20100101 Firefox/72.0

Safari:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_1) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/13.0.3 Safari/605.1.15

Edge:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140 Safari/537.36 Edge/18.17763
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.117 Safari/537.36 Edg/44.18362.449.0

Internet Explorer:
Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0) like Gecko
```
E.g., I believe something like this could be acceptable:
```js
function deriveVariation(ua) {
  if (ua.includes("Trident")) return "ie";
  if (ua.includes("Edg"))     return "edge";
  if (ua.includes("Version")) return "safari";
  if (ua.includes("Firefox")) return "firefox";
  if (ua.includes("Chrome"))  return "chrome";
  return "other";
}
```
(Where chromium shows up as "chrome," opera might be false positive "safari" or "chrome," older IE "other," and practically the various mobile UAs probably aren't downloading desktop firefox in significant numbers anyway.)

Back to Bug 1406005 Comment 47