340 Commits

Author SHA1 Message Date
Stéphane Cerveau
b2eeb6d6d3 ci: enable vulkan tests in validate
As CI now supports llvm 18 and mesa 24.1 which
allow to use properly lavapipe in the CI, the vulkan
ci tests have been removed from the validate blacklist.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9416>
2025-08-27 10:50:56 +00:00
Thibault Saunier
efdc9b1aea validate: scenario: Clear wait_message_action on stop
When executing a stop action, ensure that any pending wait_message_action
is cleared and unreffed to prevent it from being executed after the
scenario has been stopped. This prevents potential crashes or unexpected
behavior when stopping a scenario that has a pending wait action.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:51 +00:00
Thibault Saunier
fe6ad6f370 validate: scenario: Fix NULL context usage in action done callback
Use the local context variable that was retrieved earlier instead of
action->priv->context which is always NULL at this point since we
reset it right before. This ensures we invoke the callback on the
correct context.

And make sure that the wait message still has a reference when setting done
otherwise it is unref before calling the context invoke function

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:51 +00:00
Thibault Saunier
f99bf2abee validate: Add support for overrides field in meta structure
Add support for an 'overrides' field in validatetest meta structures that
allows changing issue severity levels during test execution. This enables
tests to pass when encountering known issues by downgrading their severity.

The overrides field accepts an array of change-severity structures with:
- issue-id: The issue ID to override
- new-severity: New severity level (critical, warning, issue, ignore)

Currently only change-severity overrides are supported. The feature follows
the same pattern as expected-issues and is only available in .validatetest
files, not .scenario files.

Includes comprehensive documentation and a test case demonstrating the
functionality.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9013>
2025-08-19 17:11:50 +00:00
Thibault Saunier
775187188d dots-viewer: Reindent and remove unused code in jquery.graphviz.svg.js
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9547>
2025-08-19 15:34:44 +00:00
Thibault Saunier
d3ad6136ef dots-viewer: Refactor JavaScript into modular architecture
Split monolithic embedded JavaScript in overlay.html into dedicated modules:
- tooltip.js: Custom tooltip functionality with interactive copy/paste mode
- pipeline-navigation.js: Clickable pipeline-dot references for navigation
- text-ellipsizer.js: Text ellipsizing with tooltip integration
- svg-overlay-manager.js: Main coordinator orchestrating all functionality

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9547>
2025-08-19 15:34:44 +00:00
Thibault Saunier
4d5fa1c43b dots-viewer: make pipeline dot references clickable for navigation
When GStreamer pipeline graphs contain references to other pipeline dot files,
users should be able to navigate between related pipeline views by clicking
on these references. This enables exploring complex pipeline hierarchies
where one pipeline references sub-pipelines.

The implementation detects text elements containing pipeline-dot references,
styles them as web links, and handles click events to navigate to the
referenced pipeline while preserving existing text selection and drag
functionality for other elements.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9547>
2025-08-19 15:34:44 +00:00
Thibault Saunier
28684cba1a dots-viewer: Make text copyable while preserving drag functionality
Enable text selection on SVG text elements by changing CSS user-select
properties from 'none' to 'text' and cursor from 'default' to 'text'.

Add JavaScript event handling to intercept mousedown events on text
elements, preventing dragscroll interference while allowing normal text
selection. This preserves the existing drag-to-pan functionality for
non-text areas while making text elements selectable and copyable.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9547>
2025-08-19 15:34:44 +00:00
Thibault Saunier
48a2be6d6a validate: http-actions: Replace GUri with GstURI for GLib 2.64 compatibility
GUri was added in GLib 2.66, but GStreamer claims to build with 2.64.
Replace GUri usage with equivalent GstURI functions to maintain
backward compatibility.

Fixes #4607

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9572>
2025-08-19 06:49:41 +00:00
Sebastian Dröge
c61039e95a dots-viewer: Update Rust dependencies
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9397>
2025-07-15 14:15:17 +00:00
Tim-Philipp Müller
24ee088cee Back to development after 1.27.1 2025-07-08 20:00:07 +01:00
Tim-Philipp Müller
1fa56616fb Release 1.27.1 2025-07-08 19:58:12 +01:00
Doug Nazar
49a81965fc validate: Ignore error msgs when executing next action
When processing an expected error msg, the test for if the next action
was a message would trigger and we'd never execute the next action
causing a timeout.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9118>
2025-06-20 00:27:57 +00:00
Doug Nazar
1fb195e08e validate: Fix memory leaks
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9118>
2025-06-20 00:27:57 +00:00
Doug Nazar
198498d3d2 validate: Pass correct argument size to va_arg function
sizeof(int) != sizeof (GType) and can cause an invalid access.
Also one function call was missing the terminator altogether.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9118>
2025-06-20 00:27:57 +00:00
Doug Nazar
0f32647aae validate: Fix a memory leak
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9118>
2025-06-20 00:27:57 +00:00
Doug Nazar
83be566ca7 validate: Reset mutex to NUL to allow re-init
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9118>
2025-06-20 00:27:57 +00:00
Doug Nazar
76fc1d0acf validate: tests: use fixtures to init/deinit and fix leaks
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9118>
2025-06-20 00:27:57 +00:00
Doug Nazar
79321deb27 validate: cleanup several items on shutdown
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9118>
2025-06-20 00:27:57 +00:00
Doug Nazar
b0885d2fc3 validate: Fix various memory leaks
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9118>
2025-06-20 00:27:57 +00:00
Doug Nazar
2f5ecdc911 validate: ensure we shutdown execute_actions source
Actions are no longer always called directly from the main loop
so we can't depend on G_SOURCE_REMOVE to remove it. It's also
possible while returning up the call chain after running stop
to try to re-add it.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9118>
2025-06-20 00:27:57 +00:00
Arnout Engelen
b3099f7877 devtools: dots-viewer: sort static files
The fact that static-files followed the (nondeterministic) file system
order is likely what caused the dots-viewer executable not to be binary
reproducible. Enabling this feature that was added upstream should fix
it.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9208>
2025-06-17 18:51:54 +00:00
Víctor Manuel Jáquez Leal
82a71a7739 gstreamer-vaapi: remove subproject
It's almost superseded by va plugin in gst-plugins-bad.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9200>
2025-06-10 17:32:46 +00:00
Thibault Saunier
c0d8d1b942 validate: launcher: Downgrade non-critical log messages from ERROR to INFO
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9165>
2025-06-03 10:31:39 +02:00
Thibault Saunier
07bac2b40a validate: launcher: Remove log files for passing tests by default
Adding an option to keep them no matter what.
Log files are often pretty large and keeping them around can be annoying,
usually people won't look at logs files for passing tests, and we do not
even print them out.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9127>
2025-05-31 07:48:46 +00:00
Thibault Saunier
b51dadf6f1 validate: launcher: Allow using debug log colors when those are being redirected
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9127>
2025-05-31 07:48:46 +00:00
Thibault Saunier
ca36315dab validate: Do not check that timestamp are in input range for encoders
As some encoder offset the segment range to handle bframes, that check doesn't make sense.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9127>
2025-05-31 07:48:46 +00:00
Thibault Saunier
313435f6cb general: Stop checking G_HAVE_GNUC_VARARGS now that we depend on c99
Cleaning up a bit the code now that we can rely on C99 which specifies
varargs for macros.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8990>
2025-05-30 15:30:36 +00:00
Doug Nazar
feb6e1602a validate: Escape '%' in Valgrind log filenames
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9042>
2025-05-28 16:01:44 +00:00
Doug Nazar
822bef51f0 validate: Fix marking actions done
Don't take extra ref during calling done() from 'stream-selection'
Mark as done actions that are completed immediately

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9042>
2025-05-28 16:01:44 +00:00
Doug Nazar
5c4bf60c94 validate: Free log files
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9042>
2025-05-28 16:01:44 +00:00
Doug Nazar
09cf44aa13 validate: Various minor cleanups for lost memory or use after free
Includes several missing unref(), clear() or free() calls.
Reset current_seek since we just cleared all the seeks.
Reset all_configs to NULL to prevent double clearing.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9042>
2025-05-28 16:01:44 +00:00
Thibault Saunier
d0b2e6cb68 validate: scenario: Fix race condition when ignoring EOS
The part of the code that is commented with:

```
  /* gst_validate_action_set_done() does not finish the action
    * immediately. Instead, it posts a task to the main thread to do most
    * of the work in _action_set_done().
    *
    * While the EOS handling lock guarantees that if an action had to call
    * gst_validate_action_set_done() it has done so, it does not guarantee
    * that _action_set_done() has been called.
    *
    * Is it possible that this handler is run before _action_set_done(), so
    * we check at this point for actions that have a pending_set_done and
    * call it before continuing. */
```

was not being executed in the case where the scenario was 'ignoring EOS'
while it was also required.

Also fix potential use after free in that specific code path.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9014>
2025-05-27 06:59:36 +00:00
Thibault Saunier
6fc32cbe0e validate: Do not list test files that are not autogenerated in .testlist
It was useless, adding the .validatetest to the git repo should be enough

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9035>
2025-05-20 21:43:14 +00:00
Doug Nazar
08143e9967 validate: baseclasses: Reset Test timeouts between iterations
Several options (valgrind, gdb, rr) increase the timeout each time
the tests start. Eventually reaching inf and causing a conversion
to integer to throw an exception.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9019>
2025-05-19 17:09:43 +00:00
Tim-Philipp Müller
128710caab meson: rename meson_options.txt to meson.options
Which is supported since Meson 1.1:
https://mesonbuild.com/Release-notes-for-1-1-0.html#support-for-reading-options-from-mesonoptions

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8651>
2025-05-03 10:38:25 +01:00
Nirbheek Chauhan
48cbdf73a5 devtools: Fix meson warning when calling add_languages()
WARNING: add_languages is missing native:, assuming languages are wanted for both host and build.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8753>
2025-04-30 10:18:57 +00:00
Alexander Slobodeniuk
a03c4de48f elements: use set_static_metadata when it's allowed
Those strings are nice but CPU doesn't want to copy them

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8905>
2025-04-26 19:30:15 +02:00
Thibault Saunier
f110f9c290 devtools: dots-viewer: Bundle js dependncies using webpack
And avoid relying on cdn's and require access to the network to use `dots-viewer`

And git ignore `node_modules`

Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/4334

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8754>
2025-04-10 18:48:49 +00:00
Jan Tojnar
13c0f44dd5 validate: Add gst-video to Requires in pkg-config
`gst/validate/validate.h` includes `gst/validate/gst-validate-media-info.h`,
which in turn includes `gst/pbutils/pbutils.h` but `gstreamer-pbutils-1.0`
was only listed in `Requires.private` field of `gstreamer-validate-1.0.pc`.

This would cause projects linking against `gstreamer-validate-1.0.pc` to fail to find
the headers when using alternative interpretation of pkg-config specification
that only considers private dependencies for include path during static builds,
such as the case e.g. on Nix.

https://gitlab.freedesktop.org/pkg-config/pkg-config/-/issues/28

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8661>
2025-03-26 23:40:04 +00:00
Thibault Saunier
801620242e dotsviewer: Fix search
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8696>
2025-03-26 22:46:56 +00:00
Thibault Saunier
fdcd0ddca0 devtools: dots-viewer: Add a button to download the SVG file
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8696>
2025-03-26 22:46:56 +00:00
Thibault Saunier
e845b596a2 validate: baseclasses: Reset Test.extra_logfiles when copying to start an iteration
Otherwise we get a big mixup with all iteration pointing to all the extra_logfiles

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8640>
2025-03-14 12:50:34 +00:00
Sebastian Dröge
5b1f7ef803 devtools: dots-viewer: Update dependencies and make windows dependencies conditional
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8624>
2025-03-12 21:48:33 +00:00
Tim-Philipp Müller
1a971d8e12 Back to development in main branch after 1.26.0
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8621>
2025-03-12 14:21:08 +01:00
Tim-Philipp Müller
d31ce8e5e1 Release 1.26.0 2025-03-11 20:20:16 +00:00
Nicolas Dufresne
356c1ff8e3 validate: Do not use G_URI_FLAGS_NONE symbol from 2.66
The GStreamer project currently requires GLib 2.64,
so just avoid this new API for now.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8577>
2025-03-01 00:03:55 +00:00
Thibault Saunier
4c051f25c8 dots-viewer: cargo: Mark as not being part of a workspace
Otherwise if GStreamer is checked out inside a directory that
has a `Cargo.toml` file, building fails with:

```
error: current package believes it's in a workspace when it's not:
current rust-project/gstreamer/subprojects/gst-devtools/dots-viewer/Cargo.toml
workspace rust-project/Cargo.toml

This may be fixable by adding `gstreamer/subprojects/gst-devtools/dots-viewer`
to the `workspace.members` array of the manifest located at: rust-project/Cargo.toml

Alternatively, to keep it out of the workspace, add the package to the `workspace.exclude`
array, or add an empty `[workspace]` table to the package's manifest.
```

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8562>
2025-02-26 16:20:25 +00:00
Jochen Henneberg
30a00b6a97 validate: Don't print to stdout on bail out
Otherwise, if the output is multiline like from expected/actual file
comparison mismatch, meson will parse the lines for TAP formatted
strings and report an error. In that case the tests is accidently
SKIPPED instead of FAIL.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8376>
2025-02-24 19:00:16 +00:00
Jochen Henneberg
8a5ca84612 validate: Get proper error message on diff error instead of assert
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8376>
2025-02-24 19:00:16 +00:00