aboutsummaryrefslogtreecommitdiffstats
path: root/python
Commit message (Collapse)AuthorAgeFilesLines
* Adjust the missing taplo message (#30473)Martin Robinson2023-10-031-3/+1
| | | | The current message doesn't have a line break where you would expect it to and instead has a gap due to the indentation of the code in Python.
* Update WebGPU CTS (#30454)Samson2023-09-301-0/+2
| | | | | | | * Fix webgpu-cts import script * Update webgpu-cts to https://github.com/gpuweb/cts/commit/f2b59e03621238d0d0fd6305be2c406ce3e45ac2 * Updated expectations
* fix WebGPU runtime dependencies on linux (#30407)Delan Azabani2023-09-221-4/+24
|
* Enforce formatting of TOML files (#30128)Samson2023-09-192-3/+35
| | | | | | | | | * Fmt all toml files * bootstrap taplo * enforce toml formatting with taplo * Install taplo in CI using cargo-install action
* Add TUXEDO OS to mach bootstrap (#30363)Carlos Bentzen2023-09-151-1/+1
| | | Signed-off-by: Carlos Bentzen <cadubentzen@gmail.com>
* Use MozTools 4 and update mozjs (#30326)Samson2023-09-112-5/+5
| | | | | | | | | | | | | | | | | | | * Update mozjs * moztools4 in bootstrap * no autoconf * tidy * switch to servo-build-deps * update mozjs for real * glue mozjs * fmt * move to servo/mozjs
* No extern crate test/tidy & better RUSTFLAGS handling in mach (#30328)Samson2023-09-103-22/+5
| | | | | | | | | | | * Remove unused extern crate rustflag * Remove tidy check alphabetical order of extern crates rustfmt's reorder_imports already does that * fix * better RUSTFLAGS handling
* Move user input logic into servoshell (#30238)Atbrakhi2023-09-061-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * cleanup and move user input logix into servoshell * fix fmt * moves test from servoshell file * move command-line args into servoshell * remove feature media-gstreamer * fix fmt * move user input logic code into lib to make it more testable * remove opts_matches in fn instead get it from main2 * remove pub and fix import * add licence in new file * revert passing Matches, instead pass Option String * review update, also move sanitize fn to parser file * fmt fix * review fix: remove extra line
* Update mozjs and use moztools infra (#30292)Samson2023-09-051-5/+0
|
* Let WPT commands take the --legacy-layout argument (#30239)Martin Robinson2023-08-304-24/+27
| | | This also prints a better message when starting tests.
* Always dummy (#30240)Samson2023-08-301-5/+5
|
* Rename ports/winit package to servoshell (#30163)Atbrakhi2023-08-282-4/+4
| | | | | * rename winit package to servoshell * revert previous changes and rename only package
* Add Raspbian GNU/Linux distro for mach bootstrap (#30223)Manuel Rego Casasnovas2023-08-281-1/+2
|
* Get LLVM from chocolatey (#30140)Martin Robinson2023-08-212-7/+3
| | | | | | | | | | | | LLVM is the largest package that we get from servo-build-deps, so installing it via chocolatey should reduce the amount of data that we transfer from that source. In addition, it's one less dependency that we have to manage. It also seems that installing LLVM to the default location with choco means that we no longer have to set the LIBCLANG_PATH environment variable for bindgen. Co-authored-by: Mukilan Thiyagarajan <mukilan@igalia.com>
* Upgrade whole webgpu stack (#29795)Samson2023-08-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Allow noidl files in script/dom/webidls * Upgrade wgpu to 0.16 and refresh whole webgpu implementation * Update WebGPU test expectations * misc * MutNullableDom -> DomRefCell<Option<Dom for GPUTexture * Direct use of GPUTextureDescriptor * Remove config from GPUCanvasContext * misc * finally blue color * gpubuffer "handle" error * GPU object have non-null label * gpu limits and info * use buffer_size * fix warnings * Cleanup * device destroy * fallback adapter * mach update-webgpu write webgpu commit hash in file * Mising deps in CI for webgpu tests * Updated expectations * Fixups * early reject * DomRefCell<Option<Dom -> MutNullableDom for GPUTexture
* Fix `mach test-wpt` to make crash tests work (#29832)Mukilan Thiyagarajan2023-08-182-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Fix `mach test-wpt` to make crash tests work There are two issues related to crash tests: 1. test-wpt is unable to find existing crash tests even when called with --test-types=crashtests. The fix here is to add crashtests to the default test suite types to python/wpt/run.py 2. When running in headless mode, crashes in style threads don't cause servo to crash because the logic in constellation.rs currently calls handle_panic only when the top-level browsing context id is some value. Since style pool threads are shared, they always generate Panic messages with None as top-level browsing context id. Co-authored-by: Martin Robinson <mrobinson@igalia.com> Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> * Send bactrace to stderr and capture it in test runner Servo's panic hook writes backtraces to stdout. This patch changes it so they are written to stderr. The crash test executor for servo in WPT grouping formatter was also not capturing the output correctly for crashtests as the log events were being aggregated based on thread name which doesn't seem to match correctly in case of crashtests. This patch also fixes the log grouping logic to be based on test name. Co-authored-by: Martin Robinson <mrobinson@igalia.com> Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> * crashtests: update expectations for layout 2020 Co-authored-by: Martin Robinson <mrobinson@igalia.com> Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> * crashtests: update expectations for layout 2013 Co-authored-by: Martin Robinson <mrobinson@igalia.com> Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> * remove outdated & intemittent test expectations Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> --------- Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> Co-authored-by: Martin Robinson <mrobinson@igalia.com>
* Use system lld on NixOS instead of rust-lld (#30123)Mukilan Thiyagarajan2023-08-183-2/+16
| | | | | | | | | | | | | | | | The -Zgcc-ld=lld flag makes rust use the rust-lld linker that is distributed as part of rust toolchain. However, this flag doesn't work on nixos correctly as 1) rust-lld needs to be patched to have the correct rpath to find libz.so 2) the bin/gcc-ld/ld.lld wrapper which calls rust-lld also needs to be patched to use the correct dynamic loader 3) rust-lld doesn't respect NIX_LDFLAGS which contains the additional search path derived from buildInputs. The system linkers on nixos are wrapped so that NIX_LDFLAGS is added as the rpath to the final binary. Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
* Format toml files (#30112)Samson2023-08-172-3/+3
| | | | | | | * Add taplo fmt config for toml fmt * fmt toml files * Add even-better-toml to extensions recommendations
* Clean up the environment variables set for mozjs (#30106)Martin Robinson2023-08-161-23/+8
| | | | mozjs from the repository now has a simplified interface for setting these.
* Replace "-mmacosx-version-min" with MACOSX_DEPLOYMENT_TARGET (#30102)Martin Robinson2023-08-151-6/+1
| | | | | | | | It's unclear if the compiler flag was doing anything, but I've verified (with otool) that the environment variable does affect the minimum version of the MacOS set in the binary. We could examine later if this is still necessary. This was added in #23163 when switching CI from gcc to clang.
* Remove gold config option and use lld on Linux (#30100)Martin Robinson2023-08-151-3/+5
| | | | | | | | | | | | | | | | There are a few motivations for this change: 1. lld is demonstrably faster than gold, but is really only stable on Linux at the moment. There's a good chance that it will be ready for all platforms soon though. 2. Most people do not have gold installed on MacOS and Windows. You'd have to do this manually through homebrew. I think it's a safe assumption that this probably won't be slowing things down much on those platforms. 3. We need to remove all configuration of the build that happens while running `./mach build` if we ever hope to make `cargo build` equivalent to the mach build. This unlocks static configuration of the rustflags. One of the big blockers for proper `cargo build` support.
* Run same tests for layout-2020 and layout-2013 (#30092)Oriol Brufau2023-08-151-2/+2
| | | | | | | | | | Most tests were only being run for layout-2013, not for layout-2020. This wasn't great since layout-2020 is now the default. So this patch unifies the lists of included tests for both layouts. For layout-2013 this implies adding css/css-content/, css/css-logical/ and css/css-masking/clip/. For layout-2020 this implies adding several additional css tests, and also tests like dom/, js/, html/, etc.
* Make `native-bluetooth` a default feature (#30097)Martin Robinson2023-08-141-2/+0
| | | This features is turned on unconditionally by `./mach build`.
* Make the `--release`/`--dev` more consistent and less surprising (#30091)Martin Robinson2023-08-148-344/+242
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There were some issues with the way that the `--release` and `--dev` arguments were handled in mach commands. - Not all commands accepted them in the same way. For instance `./mach test-wpt` didn't really accept them at all. - If you did not pass either of them, mach would try to guess which build you meant. This guess was often quite surprising as it wasn't printed and it depended on the state of the your target directory, which is difficult to remember. - The `dev` profile is colloquially called a "debug" profile and some commands accepted `-d` or `--debug...` like arguments, but `--debug` with `./mach run` meant run in a debugger. It was easy to mix this up. This change: - Centralizes where build type argument processing happens. Now it the same shared decorator in CommandBase. - Uses a `BuildType` enum instead of passing around two different booleans. This reduces the error checking for situations where both are true. - Be much less clever about guessing what build to use. Now if you don't specify a build type, `--dev` is chosen. I think this behavior matches cargo. - Makes it so that `./mach test-wpt` accepts the exact same arguments and has the same behavior as other commands. In addition, the suite correct for `test-wpt` is removed. There are only two suites now and it's quite unlikely that people will confuse WPT tests for rust unit tests.
* Support mac wpt builds (#29867)Samson2023-08-111-1/+11
| | | | | | | * Add wpt-mac builds * Fix wpt reporting check run tag * There can only be five concurrent mac runners
* Switch to rustls and webpki-roots (#30025)Martin Robinson2023-08-084-42/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change replaces OpenSSL with rustls and also the manually curated CA certs file with webpki-roots (effectively the same thing, but as a crate). Generally speaking the design of the network stack is the same. Changes: - Code around certificate overrides needed to be refactored to work with rustls so the various thread-safe list of certificates is refactored into `CertificateErrorOverrideManager` - hyper-rustls takes care of setting ALPN protocols for HTTP requests, so for WebSockets this is moved to the WebSocket code. - The safe set of cypher suites is chosen, which seem to correspond to the "Modern" configuration from [1]. This can be adjusted later. - Instead of passing a string of PEM CA certificates around, an enum is used that includes parsed Certificates (or the default which reads them from webpki-roots). - Code for starting up an SSL server for testing is cleaned up a little, due to the fact that the certificates need to be overriden explicitly now. This is due to the fact that the `webpki` crate is more stringent with self-signed certificates than SSL (CA certificates cannot used as end-entity certificates). [2] 1. https://wiki.mozilla.org/Security/Server_Side_TLS 2. https://github.com/briansmith/webpki/issues/114 Fixes #7888. Fixes #13749. Fixes #26835. Fixes #29291.
* Switch default layout option to `--layout-2020` in some mach commands (#30048)Yutaro Ohno2023-08-023-16/+15
| | | | | | | | | | Currently, `./mach test-wpt` family of commands (`test-wpt`, `test-wpt-android`, and `test-wpt-failure`) and `./mach update-wpt` default to using the legacy-layout option `--layout-2013` unless `--layout-2020` is specified. Given that we are now using layout-2020 by default, this change updates these commands to default to using the `--layout-2020` option instead of `--layout-2013`.
* Fix the docs build (#30058)Martin Robinson2023-08-022-6/+8
| | | | | | Type inference was incorrectly inferring that our `check_output()` helper was returning `str` when in reality, it returns `bytes`. This fixes the caller that was no longer decoding those bytes and fixes the type annotation on the function.
* Set the MacOS rpath in the build script (#30054)Martin Robinson2023-08-011-14/+0
| | | | Use the build script to set the rpath in MacOS instead of mach. This is another step toward allowing building servo without mach.
* Make rustup a requirement and switch to `rust-toolchain.toml` (#30056)Martin Robinson2023-08-015-81/+40
| | | | | | | | | | | | | | This change makes rustup a requirement for building Servo with `./mach` and switches to the newer `rust-toolchain.toml` format. The goal here is to make mach builds more similar to non-mach builds. - The new format allows listing the required components, removing some of the complexity from our mach scripts. - This means we must raise the required version of rustup to 1.23. The current version is 1.26. - We no longer wrap every call to cargo and rustc in "rustup run" calls as both cargo and rustc will take care of installing and using all necessary components specified in `rust-toolchain.toml` when run inside the project directory.
* Remove lzma path workaround for MacOS (#30053)Martin Robinson2023-08-012-26/+3
| | | | | Now that the new version of GStreamer fixes this issue, we can remove the workarounds for this problem as well as all of the homebrew bootstrapping logic.
* Remove homebrew packaging (#30047)Martin Robinson2023-08-011-91/+1
| | | | | | | This hasn't been updated since 2017 and homebrew installation is also provided via a cask which downloads the latest version from the website [^1]. I think this code is basically unused. [^1]: https://github.com/Homebrew/homebrew-cask/blob/9e944ae828ccde27340413ff2ac4de603243f5e0/Casks/servo.rb
* Remove Gecko-specific Python bootstrap logic (#30041)Martin Robinson2023-07-281-41/+11
| | | | | | Servo is no longer completely vendored into Gecko. Instead parts of Gecko are vendored into Servo. This change removes Python mach bootstrap code that was written to accommodate the previous situation. It's no longer necessary.
* Embed git hash using vergen instead of mach (#30030)Martin Robinson2023-07-281-36/+0
| | | | | | Embed the git hash into the servo binary using vergen instead of using custom Python code in mach. The benefit here is ones less difference between a normal cargo run and building via mach in addition to removing a bunch of code.
* Remove old code for out-of-date CA stores (#30031)Martin Robinson2023-07-273-30/+3
| | | | | This code was written to handle both Python 2 (which we no longer support) and old Windows CI machines that did not have up-to-date CA stores. I think we can remove this now.
* Run unit tests with both layout 2013 and layout 2020 (#30032)Oriol Brufau2023-07-272-7/+3
| | | | | | | | Since #29950, unit tests were only running with the legacy layout, and there was no way to run them for layout 2020. This patch makes './mach test-unit' run unit tests for both. Also doing some changes so that the layout 2020 floats.rs tests compile.
* `mach bootstrap` should also bootstrap GStreamer on Windows (#30018)Martin Robinson2023-07-211-1/+2
| | | Fixes #30007.
* Remove the YAML tidy code (#30004)Martin Robinson2023-07-186-103/+4
| | | | | | | | | This code was used to test buildbox_steps.yml, but Servo no longer uses buildbot, so this code is essentially unused. In addition, YAML + Cython 3 is causing issues on the CI. Fixes #30003 Signed-off-by: Martin Robinson <mrobinson@igalia.com>
* Fix WPT sync and simplify the update scripts (#29999)Martin Robinson2023-07-173-269/+113
| | | | | | | | | Much of the code used to import WPT tests from upstream has been moved to the WPT repository itself, so this can be reused. In addition, simplify the workflows by merging the entire process into mach and also directly into the GitHub workflow. This should fix WPT imports after combining compilation of layout and legacy layout. Signed-off-by: Martin Robinson <mrobinson@igalia.com>
* Enable the GitHub merge queue (#29989)Martin Robinson2023-07-132-4/+12
| | | Signed-off-by: Martin Robinson <mrobinson@igalia.com>
* Fix package name for windows nightlyMukilan Thiyagarajan2023-07-091-10/+0
| | | | | | Also remove the 2020 specific packages. Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
* Make the choice of layout runtime settingMartin Robinson2023-07-063-20/+7
| | | | Co-authored-by: Samson <16504129+sagudev@users.noreply.github.com>
* Auto merge of #29970 - mrobinson:remove-uwp, r=jdmbors-servo2023-07-058-370/+43
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove UWP / Hololens support <!-- Please describe your changes on the following line: --> --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: --> - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [x] These changes do not require tests because they remove a feature. <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
| * Remove UWP / Hololens supportMartin Robinson2023-07-058-370/+43
| |
* | Collect android build setup into two methodsMartin Robinson2023-07-052-242/+251
|/ | | | | | | | | | This is small refactor which tries to isolate all of the Android setup into a couple methods, so that it is easier to reason about in the scripts. This doesn't change any behavior but does fix a few small linting errors in the existing code. Note: The Android build is currently broken and this change doesn't fix it. It shouldn't break it any more though.
* Windows bootstrap supportMartin Robinson2023-07-038-71/+64
|
* Auto merge of #29956 - mrobinson:update-mozangle, r=jdmbors-servo2023-07-021-3/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update mozangle This should allow servo to take advantage of faster compilation times on Windows. <!-- Please describe your changes on the following line: --> --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: --> - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->
| * Update mozangleMartin Robinson2023-07-011-3/+1
| | | | | | | | | | This should allow servo to take advantage of faster compilation speeds on Windows.
* | Set the Windows subsystem using a rust directiveMartin Robinson2023-07-011-5/+0
|/ | | | This is one less thing that mach has to do now.
* Auto merge of #29934 - mrobinson:move-third-party, r=atbrakhibors-servo2023-06-301-2/+2
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Create a top-level "third_party" directory This directory now contains third_party software that is vendored into the Servo source tree. The idea is that it would eventually hold webrender and other crates from mozilla-central as well with a standard patch management approach for each. <!-- Please describe your changes on the following line: --> --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: --> - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [x] These changes do not require tests because this should not change behavior. <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->