Skip to content

Commit 1f7edc5

Browse files
committed
Merge branch 'release-v0.32.0' into release
2 parents e570e6f + 2a7b5d3 commit 1f7edc5

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

61 files changed

+11957
-7335
lines changed

.circleci/config.yml

Lines changed: 42 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,22 @@
77
version: 2.1
88

99
jobs:
10+
spellcheck:
11+
docker:
12+
# Use Ubuntu Focal (20.04) so we get aspell 0.60.8 or later
13+
# (which contains markdown support)
14+
- image: circleci/buildpack-deps:focal
15+
steps:
16+
- checkout
17+
- run:
18+
name: Upgrade packages
19+
command: sudo apt update
20+
- run:
21+
name: Install aspell
22+
command: sudo apt install aspell aspell-en
23+
- run:
24+
name: Check documentation spelling
25+
command: bin/spellcheck.sh list
1026
lint:
1127
docker:
1228
- image: cimg/python:3.9.4
@@ -156,14 +172,26 @@ jobs:
156172
pip install -r requirements.txt
157173
glean_parser translate src/App/metrics.yaml src/App/pings.yaml \
158174
-f javascript -o src/App/generated \
159-
--option platform=qt --option version="0.31"
175+
--option platform=qt --option version="0.32"
160176
- run:
161177
name: Run Qt sample tests
162178
command: |
163179
cd samples/qt
164180
qmake -r
165181
QML_IMPORT_TRACE=1 xvfb-run make check
166182
183+
browser-compat-smoke-tests:
184+
docker:
185+
- image: cimg/python:3.9.4-node
186+
steps:
187+
- checkout
188+
- run:
189+
name: Run browser comapt smoke tests
190+
command: |
191+
npm --prefix ./automation install
192+
npm --prefix ./automation run link:glean
193+
npm --prefix ./automation run compat:test:browserstack
194+
167195
check-size:
168196
docker:
169197
- image: cimg/node:16.1.0
@@ -172,7 +200,9 @@ jobs:
172200
- run:
173201
name: Get and post build sizes to GitHub PR
174202
command: |
175-
./benchmarks/run.sh
203+
npm --prefix ./automation install
204+
npm --prefix ./automation run link:glean
205+
npm --prefix ./automation run size:report
176206
177207
# via https://circleci.com/blog/deploying-documentation-to-github-pages-with-continuous-integration/
178208
docs-deploy:
@@ -237,6 +267,7 @@ jobs:
237267
workflows:
238268
ci:
239269
jobs:
270+
- spellcheck
240271
- lint
241272
- build:
242273
requires:
@@ -267,11 +298,19 @@ workflows:
267298
ignore:
268299
- main
269300
- release
270-
- /^release-*/
301+
- /^release-.*/
271302
- check-size:
272303
context: data-eng-gleanjs-gh
273304
requires:
274305
- hold
306+
- browser-compat-smoke-tests:
307+
context: data-eng-gleanjs-gh
308+
filters:
309+
branches:
310+
only:
311+
- main
312+
- release
313+
- /^release-.*/
275314
- docs-deploy:
276315
context: data-eng-gleanjs-gh
277316
filters:

.dictionary

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
personal_ws-1.1 en 70
2+
API's
3+
APIs
4+
BUGFIX
5+
BrowserStack
6+
CLI
7+
Changelog
8+
CircleCI
9+
Ciufo
10+
CommonJS
11+
Glean's
12+
Gzip
13+
HTTPS
14+
JSDoc
15+
JWK
16+
MPL
17+
PingType
18+
PlatformInfo
19+
QML
20+
QuantityMetricType
21+
README
22+
SDK
23+
SDK's
24+
SDKs
25+
TODO
26+
TimespanMetricType
27+
TypeScript
28+
UI
29+
UUID
30+
UploadResult
31+
UploadResultStatus
32+
benchmarking
33+
boolean
34+
booleans
35+
brizental
36+
changelog
37+
chutten
38+
compat
39+
datetime
40+
deserialize
41+
deserializing
42+
dexter
43+
enqueued
44+
enum
45+
falsy
46+
firefox
47+
gzip
48+
gzipping
49+
instantiation
50+
janerik
51+
js
52+
json
53+
linter
54+
linters
55+
md
56+
mdroettboom
57+
mozilla
58+
npm
59+
runtime
60+
schemas
61+
setRawNanos
62+
setUploadEnabled
63+
timespan
64+
travis
65+
unminified
66+
uploader
67+
uploaders
68+
url
69+
virtualenv
70+
webext
71+
webpack

.github/dependabot.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ updates:
55
schedule:
66
interval: "daily"
77
- package-ecosystem: "npm"
8-
directory: "/benchmarks"
8+
directory: "/automation"
99
schedule:
1010
interval: "weekly"
1111
- package-ecosystem: "npm"

.gitignore

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,5 +125,8 @@ generated/
125125
# This is the name of the Glean virtual environment
126126
.venv
127127

128-
# Temporary folder used on the benchmarks scripts
129-
benchmarks/size/tmp/
128+
# Temporary folder used on the automation scripts
129+
automation/size/tmp/
130+
131+
# Browserstack Local generated files
132+
*.err

CHANGELOG.md

Lines changed: 36 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,38 @@
11
# Unreleased changes
22

3-
[Full changelog](https://github.com/mozilla/glean.js/compare/v0.31.0...main)
3+
[Full changelog](https://github.com/mozilla/glean.js/compare/v0.32.0...main)
4+
5+
# v0.32.0 (2022-03-01)
6+
7+
[Full changelog](https://github.com/mozilla/glean.js/compare/v0.31.0...v0.32.0)
8+
9+
* [#1220](https://github.com/mozilla/glean.js/pull/1220): Refactor virtual environment behavior to support virtual environments that aren't in the project root.
10+
* This means it's possible to run Glean with a virtual environment created by `virtualenv` or `pyenv-virtualenv` without causing a Glean-specific `.venv` directory to be created in a project that is using Glean.
11+
* [#1130](https://github.com/mozilla/glean.js/pull/1130): BUGFIX: Guarantee event timestamps
12+
cannot be negative numbers.
13+
* Timestamps were observed to be negative in a few occurrences, for platforms that do not provide the `performance.now` API, namely QML, and in which we fallback to the `Date.now` API.
14+
* If event timestamps are negative pings are rejected by the pipeline.
15+
* [#1132](https://github.com/mozilla/glean.js/pull/1132): Retry ping request on network error with `keepalive: false`. This is sometimes an issue on Chrome browsers below v81.
16+
* [#1170](https://github.com/mozilla/glean.js/pull/1170): Update glean_parser to version 5.0.0.
17+
* [#1178](https://github.com/mozilla/glean.js/pull/1178): Enable running the `glean` command offline.
18+
* When offline Glean will not attempt to install glean_parser.
19+
* [#1178](https://github.com/mozilla/glean.js/pull/1178): Enable running the `glean` command with as many or as little arguments as wanted.
20+
* Previously the command could only be run with 3 commands, even though all glean_parser commands would have been valid commands for the `glean` CLI.
21+
* [#1210](https://github.com/mozilla/glean.js/pull/1210): Show comprehensive error message when missing `storage` permissions for Glean on web extensions.
22+
* [#1223](https://github.com/mozilla/glean.js/pull/1223): Add `--glean-parser-version` command to CLI to allow users to retrieve the glean_parser version without installing glean_parser.
23+
* [#1228](https://github.com/mozilla/glean.js/pull/1228): BUGFIX: Apply debug features before sending pings at initialize.
424

525
# v0.31.0 (2022-01-25)
626

727
[Full changelog](https://github.com/mozilla/glean.js/compare/v0.30.0...v0.31.0)
828

929
* [#1065](https://github.com/mozilla/glean.js/pull/1065): Delete minimal amount of data when invalid data is found while collecting ping.
10-
* Previous behaviour was to delete the whole ping when invalid data was found on the database,
11-
new behaviour only deletes the actually invalid data and leave the rest of the ping intact.
30+
* Previous behavior was to delete the whole ping when invalid data was found on the database,
31+
new behavior only deletes the actually invalid data and leave the rest of the ping intact.
1232
* [#1065](https://github.com/mozilla/glean.js/pull/1065): Only import metric types into the library when they are used either by the user or Glean itself.
1333
* Previously the code required to deserialize metric data from the database was always imported by the library even if the metric type was never used by the client. This effort will decrease the size of the Glean.js bundles that don't import all the metric types.
1434
* [#1046](https://github.com/mozilla/glean.js/pull/1046): Remove legacy X-Client-Type X-Client-Version from Glean pings.
15-
* [#1071](https://github.com/mozilla/glean.js/pull/1071): **BREAKING CHANGE**: Move the `testResetGlean` API from the Glean singletion and into it's own entry point `@mozilla/glean/testing`.
35+
* [#1071](https://github.com/mozilla/glean.js/pull/1071): **BREAKING CHANGE**: Move the `testResetGlean` API from the Glean singleton and into it's own entry point `@mozilla/glean/testing`.
1636
* In order to use this API one must import it through `import { testResetGlean } from "@mozilla/glean/testing"` instead of using it from the Glean singleton directly.
1737
* This lower the size of the Glean library, because testing functionality is not imported unless in a testing environment.
1838
* This change does not apply to QML. In this environment the API remains the same.
@@ -62,7 +82,7 @@
6282
* Users may provide a folder name through the `VIRTUAL_ENV` environment variable.
6383
* If the user is inside an active virtualenv the `VIRTUAL_ENV` environment variable is already set by Python. See: https://docs.python.org/3/library/venv.html.
6484
* [#968](https://github.com/mozilla/glean.js/pull/968): Add runtime arguments type checking to `Glean.setUploadEnabled` API.
65-
* [#970](https://github.com/mozilla/glean.js/pull/970): BUGFIX: Guarantee uploading is immediatelly resumed if the uploader has been stopped due to any of the uploading limits being hit.
85+
* [#970](https://github.com/mozilla/glean.js/pull/970): BUGFIX: Guarantee uploading is immediately resumed if the uploader has been stopped due to any of the uploading limits being hit.
6686

6787
# v0.25.0 (2021-11-15)
6888

@@ -79,10 +99,10 @@
7999

80100
* [#856](https://github.com/mozilla/glean.js/pull/856): Expose the `@mozilla/glean/web` entry point for using Glean.js in websites.
81101
* [#856](https://github.com/mozilla/glean.js/pull/860): Implement the `PlatformInfo` module for the web platform.
82-
* Out of `os`, `os_version`, `architecture` and `locale`, on the web platform, we can only retrive `os` and `locale` information. The other information will default to the known value `Unknown` for all pings coming from this platform.
102+
* Out of `os`, `os_version`, `architecture` and `locale`, on the web platform, we can only retrieve `os` and `locale` information. The other information will default to the known value `Unknown` for all pings coming from this platform.
83103
* [#856](https://github.com/mozilla/glean.js/pull/856): Expose the `@mozilla/glean/web` entry point for using Glean.js in websites.
84104
* [#908](https://github.com/mozilla/glean.js/pull/908): BUGFIX: Guarantee internal `uploadEnabled` state always has a value.
85-
* When `uploadEnabled` was set to `false` and then Glean was restarted with it still `false`, the internal `uploadEnabled` state was not being set. That should not cause particularly harmful behaviour, since `undefined` is still a "falsy" value. However, this would create a stream of loud and annoying log messages.
105+
* When `uploadEnabled` was set to `false` and then Glean was restarted with it still `false`, the internal `uploadEnabled` state was not being set. That should not cause particularly harmful behavior, since `undefined` is still a "falsy" value. However, this would create a stream of loud and annoying log messages.
86106
* [#898](https://github.com/mozilla/glean.js/pull/898): Implement the `Storage` module for the web platform.
87107

88108
# v0.23.0 (2021-10-12)
@@ -120,7 +140,7 @@
120140
[Full changelog](https://github.com/mozilla/glean.js/compare/v0.20.0...v0.21.0)
121141

122142
* [#754](https://github.com/mozilla/glean.js/pull/754): Change target ECMAScript target from 2015 to 2016 when building for Qt.
123-
* [#779](https://github.com/mozilla/glean.js/pull/779): Add a number of workarounds for the Qt Javascript engine.
143+
* [#779](https://github.com/mozilla/glean.js/pull/779): Add a number of workarounds for the Qt JavaScript engine.
124144

125145
* [#775](https://github.com/mozilla/glean.js/pull/775): Disallow calling test only methods outside of test mode.
126146
* NOTE: Test mode is set once the API `Glean.testResetGlean` is called.
@@ -182,9 +202,9 @@ logic, which allows for reliable sorting of events throughout restarts.
182202

183203
* [#346](https://github.com/mozilla/glean.js/pull/346): Provide default HTTP client for Qt/QML platform.
184204
* [#399](https://github.com/mozilla/glean.js/pull/399): Check if there are ping data before attempting to delete it.
185-
* This change lowers the amount of log messages related to attempting to delete inexistent data.
205+
* This change lowers the amount of log messages related to attempting to delete nonexistent data.
186206
* [#411](https://github.com/mozilla/glean.js/pull/411): Tag all messages logged by Glean with the component they are coming from.
187-
* [#415](https://github.com/mozilla/glean.js/pull/415), [#430](https://github.com/mozilla/glean.js/pull/430): Gzip ping paylod before upload
207+
* [#415](https://github.com/mozilla/glean.js/pull/415), [#430](https://github.com/mozilla/glean.js/pull/430): Gzip ping payload before upload
188208
* This changes the signature of `Uploader.post` to accept `string | Uint8Array` for the `body` parameter, instead of only `string`.
189209
* [#431](https://github.com/mozilla/glean.js/pull/431): BUGFIX: Record the timestamp for events before dispatching to the internal task queue.
190210
* [#462](https://github.com/mozilla/glean.js/pull/462): Implement persistent storage for Qt/QML platform.
@@ -202,7 +222,7 @@ logic, which allows for reliable sorting of events throughout restarts.
202222

203223
[Full changelog](https://github.com/mozilla/glean.js/compare/v0.14.0...v0.14.1)
204224

205-
* [#342](https://github.com/mozilla/glean.js/pull/342): BUGFIX: Fix timespan payload representatin to match exactly the payload expected according to the Glean schema.
225+
* [#342](https://github.com/mozilla/glean.js/pull/342): BUGFIX: Fix timespan payload representation to match exactly the payload expected according to the Glean schema.
206226
* [#343](https://github.com/mozilla/glean.js/pull/343): BUGFIX: Report the correct failure exit code when the Glean command line tool fails.
207227

208228
# v0.14.0 (2021-05-19)
@@ -314,7 +334,7 @@ logic, which allows for reliable sorting of events throughout restarts.
314334

315335
* [#123](https://github.com/mozilla/glean.js/pull/123): BUGFIX: Fix support for ES6 environments.
316336
* Include `.js` extensions in all local import statements.
317-
* ES6' module resolution algorithm does not currently support automatic resolution of file extensions and does not have the hability to import directories that have an index file. The extension and the name of the file being import need to _always_ be specified. See: https://nodejs.org/api/esm.html#esm_customizing_esm_specifier_resolution_algorithm
337+
* ES6' module resolution algorithm does not currently support automatic resolution of file extensions and does not have the ability to import directories that have an index file. The extension and the name of the file being import need to _always_ be specified. See: https://nodejs.org/api/esm.html#esm_customizing_esm_specifier_resolution_algorithm
318338
* Add a `type: module` declaration to the main `package.json`.
319339
* Without this statement, ES6 support is disabled. See: https://nodejs.org/docs/latest-v13.x/api/esm.html#esm_enabling.:
320340
* To keep support for CommonJS, in our CommonJS build we include a `package.json` that overrides the `type: module` of the main `package.json` with a `type: commonjs`.
@@ -327,7 +347,7 @@ logic, which allows for reliable sorting of events throughout restarts.
327347
* This plugin listens to the `afterPingCollection` event. It receives the collected payload of a ping and returns an encrypted version of it using a JWK provided upon instantiation.
328348
* [#95](https://github.com/mozilla/glean.js/pull/95): Add a `plugins` property to the configuration options and create an event abstraction for triggering internal Glean events.
329349
* The only internal event triggered at this point is the `afterPingCollection` event, which is triggered after ping collection and logging, and before ping storing.
330-
* Plugins are built to listen to a specific Glean event. Each plugin must define an `action`, which is executed everytime the event they are listening to is triggered.
350+
* Plugins are built to listen to a specific Glean event. Each plugin must define an `action`, which is executed every time the event they are listening to is triggered.
331351
* [#101](https://github.com/mozilla/glean.js/pull/101): BUGFIX: Only validate Debug View Tag and Source Tags when they are present.
332352
* [#102](https://github.com/mozilla/glean.js/pull/102): BUGFIX: Include a Glean User-Agent header in all pings.
333353
* [#97](https://github.com/mozilla/glean.js/pull/97): Add support for labeled metric types (string, boolean and counter).
@@ -345,8 +365,8 @@ logic, which allows for reliable sorting of events throughout restarts.
345365

346366
[Full changelog](https://github.com/mozilla/glean.js/compare/v0.2.0...v0.3.0)
347367

348-
* [#90](https://github.com/mozilla/glean.js/pull/90): Provide exports for CommonJS and browser environemnts.
349-
* [#90](https://github.com/mozilla/glean.js/pull/90): BUGIFX: Accept lifetimes as strings when instantiating metric types.
368+
* [#90](https://github.com/mozilla/glean.js/pull/90): Provide exports for CommonJS and browser environments.
369+
* [#90](https://github.com/mozilla/glean.js/pull/90): BUGFIX: Accept lifetimes as strings when instantiating metric types.
350370
* [#90](https://github.com/mozilla/glean.js/pull/90): BUGFIX: Fix type declaration paths.
351371
* [#90](https://github.com/mozilla/glean.js/pull/90): BUGFIX: Make web-ext-types a peer dependency.
352372
* This is quick fix until [Bug 1694701](https://bugzilla.mozilla.org/show_bug.cgi?id=1694701) is fixed.
@@ -376,7 +396,7 @@ logic, which allows for reliable sorting of events throughout restarts.
376396
* `initialize` and `setUploadEnabled`.
377397
* [#36](https://github.com/mozilla/glean.js/pull/36): Implement the event metric type.
378398
* [#31](https://github.com/mozilla/glean.js/pull/31): Implement a task Dispatcher to help in executing Promises in a deterministic order.
379-
* [#26](https://github.com/mozilla/glean.js/pull/26): Implement the setUploadEnable API.
399+
* [#26](https://github.com/mozilla/glean.js/pull/26): Implement the setUploadEnabled API.
380400
* [#25](https://github.com/mozilla/glean.js/pull/25): Implement an adapter that leverages browser APIs to upload pings.
381401
* [#24](https://github.com/mozilla/glean.js/pull/24): Implement a ping upload manager.
382402
* [#23](https://github.com/mozilla/glean.js/pull/23): Implement the initialize API and glean internal metrics.

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ As mentioned, Glean.js bugs are filed in Bugzilla. Anything on the Glean.js comp
2828
with the tag [`[good first bug]`](https://bugzilla.mozilla.org/buglist.cgi?f1=status_whiteboard&v1=%5Bgood%20first%20bug%5D&o1=substring&resolution=---&query_format=advanced&f2=component&v2=Glean.js&list_id=15653400&o2=equals&classification=Client%20Software&classification=Developer%20Infrastructure&classification=Components&classification=Server%20Software&classification=Other)
2929
is a good place to start.
3030

31-
These bugs will usually have a comment explaning the steps to get started working on them.
32-
(If you find a `[good first bug]` that doesn't have an explainer comment, please ask for one).
31+
These bugs will usually have a comment explaining the steps to get started working on them.
32+
(If you find a `[good first bug]` that doesn't have an explanation comment, please ask for one).
3333

3434
If you are picking a good first bug or not, make sure you are assigned to the bug before sending a Pull Request for it.
3535

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ If you want to contribute to the Glean.js code base this is the place to go.
2121

2222
If you are looking for detailed documentation on the Glean APIs (internal or external) this is the place to go.
2323

24-
_This documentation is autogenererated from the doc comments throughout the Glean.js codebase and
24+
_This documentation is auto generated from the doc comments throughout the Glean.js code base and
2525
the Glean book should be preferred over this documentation whenever possible._
2626

2727
## Contact

0 commit comments

Comments
 (0)