Commit Graph

2680 Commits

Author SHA1 Message Date
Sylvestre Ledru
113b09cdd5 Bug 1918098 - ruff: upgrade ruff to v0.6.4 r=linter-reviewers,ahal
+ Rename --format to the new option + include it in the verbose command

Differential Revision: https://phabricator.services.mozilla.com/D221875
2024-11-06 12:51:33 +00:00
Sylvestre Ledru
d35ba16a18 Bug 1918098 - ruff: fix the errors identified by 0.6.4 r=linter-reviewers,taskgraph-reviewers,releng-reviewers,webdriver-reviewers,perftest-reviewers,migration-reviewers,jmaher,whimboo,sparky,xpcom-reviewers,beth,ahal,mconley
Differential Revision: https://phabricator.services.mozilla.com/D221874
2024-11-06 12:51:32 +00:00
Mark Banner
d55f746762 Bug 1928625 - Remove ESLint rule mozilla/consistent-if-bracing as curly already enforces more than it. r=frontend-codestyle-reviewers,mossop
Differential Revision: https://phabricator.services.mozilla.com/D227658
2024-11-04 13:48:54 +00:00
Mark Banner
28154dc55a Bug 1928625 - Improve performance of loading globals for ESLint. r=frontend-codestyle-reviewers,mossop
There's no need to get the AST source if we are not in the global scope.

Differential Revision: https://phabricator.services.mozilla.com/D227657
2024-11-04 13:48:54 +00:00
Sylvestre Ledru
4d9d8dc7dd Bug 1918098 - ruff: --verbose --fix should show the fix command too r=linter-reviewers,ahal DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D223912
2024-11-03 20:47:14 +00:00
Sylvestre Ledru
cd289bcb06 Bug 1921433 - reformat with black 24.8.0 r=linter-reviewers,webdriver-reviewers,perftest-reviewers,taskgraph-reviewers,releng-reviewers,dom-storage-reviewers,janv,jmaher,whimboo,afinder,ahal
Differential Revision: https://phabricator.services.mozilla.com/D223963
2024-11-03 20:28:59 +00:00
Sylvestre Ledru
1e17a3910f Bug 1921433 - Update to black 24.8.0 r=linter-reviewers,ahal
Differential Revision: https://phabricator.services.mozilla.com/D223962
2024-11-03 20:28:59 +00:00
Mark Banner
cbb55a4a55 Bug 1927798 - Re-enable the curly rule for ESLint. r=frontend-codestyle-reviewers,mossop
This was accidentally disabled in bug 1920531 with the re-organisation of how eslint-plugin-mozilla worked.
The rule needs to be (re)enabled after eslint-config-prettier is applied, as eslint-config-prettier turns it off by default.

Differential Revision: https://phabricator.services.mozilla.com/D227621
2024-11-01 14:15:01 +00:00
Beth Rennie
91c7baf502 Bug 1922040 - Remove fxrecord from the tree r=sparky,perftest-reviewers,taskgraph-reviewers,ahal
Differential Revision: https://phabricator.services.mozilla.com/D227389
2024-10-31 18:30:53 +00:00
Mark Banner
cee5571f91 Bug 1881696 - Make the eslint-plugin-mozilla recommended configuration work with the ESLint flat config. r=frontend-codestyle-reviewers,mossop
This provides additional "flat/...." configurations which work with the flat config of ESLint. The changes in recommended.js make it easier to handle the two different types of configuration. The changes in index.js are to ensure that the resultant configurations are correct for legacy or flat configs. The index.js changes also inject the plugin object back into itself, as required by ESLint.

Once we have switched mozilla-central to flat configuration, we can drop support for the legacy config.

Differential Revision: https://phabricator.services.mozilla.com/D225705
2024-10-18 09:21:27 +00:00
Mark Banner
072008e5f7 Bug 1881696 - Rework the ESLint environment so that eslint-plugin-mozilla is not enforcing the environment everywhere. r=frontend-codestyle-reviewers,Gijs
This makes it easier for subscribers of eslint-plugin-mozilla to use it more generally as a set of recommended
rules. The only environment definitions are for mozilla-specific file types, where we should be safe to specify
them.

Differential Revision: https://phabricator.services.mozilla.com/D225704
2024-10-18 09:21:27 +00:00
Greg Mierzwinski
114aecfb2a Bug 1924838 - [perfdocs] Check for skipped tests for mozperftest. r=perftest-reviewers,fbilt DONTBUILD
This patch fixes an issue where having `skip-if` defined in the test manifests would prevent perfdocs from finding the test even though it exists.

Differential Revision: https://phabricator.services.mozilla.com/D225696
2024-10-17 15:12:01 +00:00
Hanna Jones
7d802bf04c Bug 1921088 - Upgrade Stylelint and related libraries to the latest version r=Standard8,devtools-reviewers,omc-reviewers,home-newtab-reviewers,nchevobbe,thecount,desktop-theme-reviewers,dao,aminomancer
In addition to upgrding our Stylelint packages, this patch also introduces the @stylistic/stylelint-plugin to preserve a number of rules that were completely removed in v16. It also migrates the code for the custom plugin introduced in bug 1838298 to ES Modules.

Differential Revision: https://phabricator.services.mozilla.com/D224250
2024-10-15 19:39:46 +00:00
Dão Gottwald
3694fee4a9 Bug 1924532 - Move tabMediaIndicator tests to browser/components/tabbrowser/. r=tabbrowser-reviewers,frontend-codestyle-reviewers,dwalker,mossop
Differential Revision: https://phabricator.services.mozilla.com/D225516
2024-10-15 16:04:13 +00:00
Makoto Kato
ae5f3581ce Bug 1924039 - Run license lint for Kotlin source files. r=linter-reviewers,sylvestre,Standard8,ahal
Differential Revision: https://phabricator.services.mozilla.com/D225324
2024-10-15 01:28:22 +00:00
Dão Gottwald
1d3c8fc2a0 Bug 1924105 - Move tab tests from browser/base/ to browser/components/tabbrowser/. r=tabbrowser-reviewers,dwalker
Differential Revision: https://phabricator.services.mozilla.com/D225356
2024-10-14 14:22:00 +00:00
William Durand
d510f68c17 Bug 1923268 - Update soft/hard block strings. r=rpl,fluent-reviewers,android-reviewers,bolsson,delphine,amejiamarmol
Differential Revision: https://phabricator.services.mozilla.com/D225047
2024-10-14 10:00:26 +00:00
florin.bilt
1d1a1f4640 Bug 1881556 - Add documentation on the cpuTime metric to raptor documentation r=perftest-reviewers,sparky
Differential Revision: https://phabricator.services.mozilla.com/D223298
2024-10-11 09:52:43 +00:00
Bastian Gruber
b7941358f4 Bug 1923364 - Add topic guides for app-services, r=nanj,markh DONTBUILD
Bug 1923364 - cleanup extensions, r=nanj

Bug 1923364 - Adding tabs to lint, r=nanj

Bug 1923364 - Ignore tabs linting, r=nanj

Bug 1923364 - Restructure and combine rust components, r=nanj

Bug 1923364 - Replace rst with MyST markdown, r=nanj

Bug 1923364 - PR review fixes, r=nanj

Differential Revision: https://phabricator.services.mozilla.com/D224949
2024-10-09 23:24:17 +00:00
Andrew Osmond
f6f0434b71 Bug 1921554 - Generate gfx blocklist features/status/etc list to create downloadable blocklist bindings. r=bradwerth,jnicol
This patch turns the various nsIGfxInfo::FEATURE_* constants into macros
that can be included to generate C++ code at runtime. This has been done
to automatically generate the necessary bindings for the downloadable
blocklist. This way we will never miss adding the necessary
prerequisities as we have in the past.

Differential Revision: https://phabricator.services.mozilla.com/D224056
2024-10-05 15:10:32 +00:00
Mike Hommey
d832365263 Bug 1922437 - Rename nsIAndroid* classes to nsIGeckoView*. r=geckoview-reviewers,nika,frontend-codestyle-reviewers,owlish
Differential Revision: https://phabricator.services.mozilla.com/D224429
2024-10-03 22:21:51 +00:00
Luca Greco
82ac083630 Bug 1917846 - Update about addons blocked and softblocked strings (message bar message and link action button strings). r=willdurand,fluent-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D222366
2024-10-02 17:20:10 +00:00
Luca Greco
dc4e37e2c1 Bug 1917845 - Block and show an install error on new soft-blocked addons versions installs. r=willdurand,fluent-reviewers,bolsson
Differential Revision: https://phabricator.services.mozilla.com/D222101
2024-10-02 17:20:09 +00:00
Sylvestre Ledru
b395da236f Bug 1920521 - Remove jprof from m-c r=jesup,zeid
Differential Revision: https://phabricator.services.mozilla.com/D223158
2024-10-01 14:13:43 +00:00
Hanna Jones
9e854657c9 Bug 1838298 - Custom Stylelint plugin to prevent color tokens from being used directly r=Standard8,frontend-codestyle-reviewers,desktop-theme-reviewers,dao
This patch lays the foundation for a Mozilla-specific Stylelint plugin that we can continue to expand on with new rules as needed. For the first rule I've implemented a simple check to ensure our color tokens are being used as intended.

Differential Revision: https://phabricator.services.mozilla.com/D223204
2024-09-27 14:58:41 +00:00
Florian Quèze
66306a3b3a Bug 1918702 - Migrate telemetry events to use Glean APIs for security.doh.neterror, security.ui.certerror and security.ui.tlserror, r=chutten,frontend-codestyle-reviewers.
Differential Revision: https://phabricator.services.mozilla.com/D223634
2024-09-27 11:48:58 +00:00
Florian Quèze
ce72f422e3 Bug 1918702 - Migrate telemetry events to use Glean APIs for security.ui.protections, r=chutten,frontend-codestyle-reviewers.
Differential Revision: https://phabricator.services.mozilla.com/D223616
2024-09-27 11:48:58 +00:00
Mark Banner
25045cc41e Bug 1920970 - Move ESLint node_modules bundles away from tooltool and into the toolchain. r=jcristau
Differential Revision: https://phabricator.services.mozilla.com/D223647
2024-09-26 10:55:31 +00:00
Mark Banner
fae021d5ee Bug 1920802 - Update node_modules related to ESLint as far as possible. r=frontend-codestyle-reviewers,Gijs
Differential Revision: https://phabricator.services.mozilla.com/D222622
2024-09-25 06:37:10 +00:00
Mark Banner
9e50226bf3 Bug 1920531 - Remove html, json and prettier plugin dependencies from eslint-plugin-mozilla. r=frontend-codestyle-reviewers,Gijs
Requiring these in eslint-plugin-mozilla seems a bit unnecessary:

* The html plugin is used as a parser and is only required if a project is parsing html.
* Similary, we use the recommended config for the JSON parser, and it only applies for JSON files.
* The prettier option is only required if a project wants to use prettier. Whilst I think we should have prettier for all Mozilla projects, I don't think we need to enforce/require it here.

Differential Revision: https://phabricator.services.mozilla.com/D222628
2024-09-23 17:46:18 +00:00
Mark Banner
d2c42a23fa Bug 1920532 - Remove unnecessary '../lib' path loading in requires in eslint-plugin-mozilla's index.js. r=frontend-codestyle-reviewers,Gijs
Differential Revision: https://phabricator.services.mozilla.com/D222623
2024-09-23 17:46:17 +00:00
Nico Burns
1ef2bef1f1 Bug 1918093: Inline derive_common crate into style_derive (r=emilio)
Signed-off-by: Nico Burns <nico@nicoburns.com>

Differential Revision: https://phabricator.services.mozilla.com/D221816
2024-09-19 13:06:54 +00:00
myeongjun
e187818d25 Bug 1826822 - Make tp6 the default for AWSY r=sparky,perftest-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D220147
2024-09-18 12:12:53 +00:00
Ben Dean-Kawamura
fba8dd2c1e Bug 1910404 - UniFFI proc-macro support, r=lina,firefox-build-system-reviewers,glandium
Switched to library mode for generating bindings.

Updated our strategy for UniFFI components/fixtures.  There's now a
crate for components and a crate for fixtures.  These crates are a
dependency of gkrust-shared and also built as standalone libraries which
UniFFI uses to generate the bindings.

One upshot of this is that we no longer need the `crate_name` or
`udl_file` config values.  library-mode can figure out the udl paths
automatically.

Differential Revision: https://phabricator.services.mozilla.com/D221824
2024-09-16 15:18:07 +00:00
Julian Descottes
42cf53ea82 Bug 1917003 - [eslint] Add linter rule to ban await await r=Standard8,frontend-codestyle-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D221187
2024-09-16 09:13:30 +00:00
Nick Alexander
97967b0ece Bug 1918249 - Fix mach lint linting prefs JS files on Windows by forcing UTF-8. r=ahal
Prefs files in general are allowed to not be UTF-8, but all the prefs
files in tree are UTF-8, so we can lint them with that assumption.

Differential Revision: https://phabricator.services.mozilla.com/D221878
2024-09-13 17:00:04 +00:00
Cristian Tuns
5f82b0e5a2 Backed out changeset 78d0a0c70d7c (bug 1918411) for causing bc failures in browser_quicksuggest_fakespot.js CLOSED TREE 2024-09-13 10:43:48 -04:00
Francesco Lodolo (:flod)
cd4219cfed Bug 1918411 - Use explicit NUMBER() in Fluent plurals, update docs, r=bolsson,credential-management-reviewers,devtools-reviewers,places-reviewers,omc-reviewers,urlbar-reviewers,nchevobbe,daisuke,dimi,mviar
Differential Revision: https://phabricator.services.mozilla.com/D221992
2024-09-13 13:34:52 +00:00
Mark Banner
2387ca3533 Bug 1917532 - Remove overrides sections from *-test configurations in eslint-plugin-mozilla. r=frontend-codestyle-reviewers,mossop
ESLint v9 doesn't support overrides/file specification in the configurations, so we don't want these
now.

The top-level configuration already strips out the overrides for these and handles them separately, so
there's nothing to add - simply remove the 'removeOverrides' function.

Differential Revision: https://phabricator.services.mozilla.com/D221447
2024-09-12 21:08:45 +00:00
Mark Banner
533bbce8a6 Bug 1575506 - Enable ESLint rule no-redeclare with builtinGlobals on all module and worker files. r=frontend-codestyle-reviewers,devtools-reviewers,nchevobbe,mossop
Differential Revision: https://phabricator.services.mozilla.com/D221446
2024-09-12 21:08:45 +00:00
Mark Banner
0075a7ce1f Bug 1917530 - Enable ESLint rule no-shadow by default across the tree, disabling where it currently fails. r=frontend-codestyle-reviewers,mossop
Differential Revision: https://phabricator.services.mozilla.com/D221445
2024-09-12 21:08:44 +00:00
Mark Banner
f63765b6ef Bug 1917530 - Enable ESLint rule no-shadow on system modules where no-shadow is enabled already, and warn for remaining failures. r=frontend-codestyle-reviewers,mossop
This moves the ESLint rule to apply to jsx, system modules and workers. It is excluded from most system
modules by the roll out, which we can work on later. However, it will be enabled where no-shadow is
already enabled - previously these were hidden due to the order in which ESLint was applying the rules.

Differential Revision: https://phabricator.services.mozilla.com/D221444
2024-09-12 21:08:44 +00:00
Sandor Molnar
6a28b1e440 Backed out 8 changesets (bug 1917532, bug 1575506, bug 1917530) for causing node newtab failures CLOSED TREE
Backed out changeset 8d6f7bc74d08 (bug 1917532)
Backed out changeset 7c963e72cf06 (bug 1575506)
Backed out changeset d5e110187781 (bug 1917530)
Backed out changeset 1d2325ffded6 (bug 1917530)
Backed out changeset 8a361e37e32c (bug 1917530)
Backed out changeset c4011d92c7f7 (bug 1917530)
Backed out changeset 1a45047dfb3c (bug 1917530)
Backed out changeset ed6b35444c45 (bug 1917530)
2024-09-12 20:45:28 +03:00
Mark Banner
6b786d4a84 Bug 1917532 - Remove overrides sections from *-test configurations in eslint-plugin-mozilla. r=frontend-codestyle-reviewers,mossop
ESLint v9 doesn't support overrides/file specification in the configurations, so we don't want these
now.

The top-level configuration already strips out the overrides for these and handles them separately, so
there's nothing to add - simply remove the 'removeOverrides' function.

Differential Revision: https://phabricator.services.mozilla.com/D221447
2024-09-12 16:42:00 +00:00
Mark Banner
c7331a02cd Bug 1575506 - Enable ESLint rule no-redeclare with builtinGlobals on all module and worker files. r=frontend-codestyle-reviewers,devtools-reviewers,nchevobbe,mossop
Differential Revision: https://phabricator.services.mozilla.com/D221446
2024-09-12 16:41:59 +00:00
Mark Banner
1a8d60d410 Bug 1917530 - Enable ESLint rule no-shadow by default across the tree, disabling where it currently fails. r=frontend-codestyle-reviewers,mossop
Differential Revision: https://phabricator.services.mozilla.com/D221445
2024-09-12 16:41:59 +00:00
Mark Banner
5302b1261d Bug 1917530 - Enable ESLint rule no-shadow on system modules where no-shadow is enabled already, and warn for remaining failures. r=frontend-codestyle-reviewers,mossop
This moves the ESLint rule to apply to jsx, system modules and workers. It is excluded from most system
modules by the roll out, which we can work on later. However, it will be enabled where no-shadow is
already enabled - previously these were hidden due to the order in which ESLint was applying the rules.

Differential Revision: https://phabricator.services.mozilla.com/D221444
2024-09-12 16:41:58 +00:00
Andrew McCreight
04a47c0850 Bug 1275612 - Don't allow any origins to send objects over WebChannel. r=Gijs
The last actual Firefox user of this less-safe feature was removed in 2022.
Thunderbird's sync server still needs it, but apparently that is a prototype
that isn't really working, so they said it was okay to remove this.

Differential Revision: https://phabricator.services.mozilla.com/D220646
2024-09-08 15:28:50 +00:00
Francesco Lodolo (:flod)
d0059173bd Bug 1917163 - Update rstcheck to 6.2.4, fix resulting errors in documents, r=Standard8
Differential Revision: https://phabricator.services.mozilla.com/D221287
2024-09-06 15:04:10 +00:00
Cristina Horotan
c6ba4c0134 Backed out changeset 4e2df2c48e4b (bug 1917163) for causing mozlint failure. CLOSED TREE 2024-09-06 16:57:11 +03:00