Bug 1756620 - [devtools] Remove devtools/shared/compatibility/dataset/browsers.json. r=jdescottes.

The file is not used anymore since we switched to RemoteSettings
to store this dataset.

Differential Revision: https://phabricator.services.mozilla.com/D139392
This commit is contained in:
Nicolas Chevobbe 2022-03-01 15:20:23 +00:00
Родитель 95b15421a5
Коммит 2894b6c434
4 изменённых файлов: 13 добавлений и 7 удалений

Просмотреть файл

@ -15,6 +15,16 @@ In order to download up-to-date data, you need to run the following commands:
- `yarn install --no-lockfile` and select the latest package version for the `@mdn/browser-compat-data` package
- `yarn update`
This should save the JSON files directly in `devtools/shared/compatibility/dataset/`.
This should save the `css-properties.json` JSON file directly in `devtools/shared/compatibility/dataset/`.
For the browsers data, we need to update the RemoteSettings collection.
While connected to the Mozilla Corporate VPN (See https://mana.mozilla.org/wiki/display/SD/VPN), log into https://settings-writer.stage.mozaws.net/v1/admin/#/buckets/main/collections/devtools-compatibility-browsers/records (Using `OpenID Connect (LDAP)`). Then copy the authentication header using the icon in the top toolbar.
You can then run `SERVER=stage AUTH='XXX' yarn update-rs-records`, replacing `XXX` with the value of the authentication header.
The logs should indicate if the collection was updated, and if so, provide a short summary of the modifications.
If the collection was updated, then run Firefox, and use the [RemoteSettings DevTools WebExtension](https://github.com/mozilla-extensions/remote-settings-devtools) to use the `Stage (preview)` environment.
Then open the compatibility panel and make sure that the updated browsers do appear in the `Settings` panel.
If everything looks right, you can run the same command, on the prod server this time: `SERVER=prod AUTH='XXX' yarn update-rs-records`
Check that all tests still pass. It is possible that changes in the structure or contents of the latest dataset will cause tests to fail. If that is the case, fix the tests. **Do not manually change the contents or structure of the local dataset** because any changes will be overwritten by the next update from the official dataset.

Просмотреть файл

@ -7,11 +7,10 @@
// This dataset needs to be manually synchronized periodically
// The subsets from the dataset required by the Compatibility panel are:
// * browsers: https://github.com/mdn/browser-compat-data/tree/master/browsers
// * css.properties: https://github.com/mdn/browser-compat-data/tree/master/css
// The MDN compatibility data is available as a node package ("@mdn/browser-compat-data").
// This node script downloads `browsers.json` and `css-properties.json` and updates the relevant files.
// The MDN compatibility data is available as a node package ("@mdn/browser-compat-data"),
// which is used here to update `../dataset/css-properties.json`.
/* global __dirname */
@ -19,7 +18,6 @@
const compatData = require("@mdn/browser-compat-data");
exportData(compatData.css.properties, "css-properties.json");
exportData(compatData.browsers, "browsers.json");
function exportData(data, fileName) {
const fs = require("fs");

Различия файлов скрыты, потому что одна или несколько строк слишком длинны

Просмотреть файл

@ -5,6 +5,5 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
DevToolsModules(
"browsers.json",
"css-properties.json",
)