Not all classes derived from TaskItem are tasks,
but the common denominator is that all may be placed
inside a group: thus GroupItem sounds more appropriate.
Addresses the 10th point in the bugreport below.
Task-number: QTCREATORBUG-28741
Change-Id: I94d728a8e39ec732810f2e5bbe6b9a76f3bc387c
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
The NetworkQuery class is prepared to work with TaskTree.
Provide the task tree adapter for the NetworkQuery class.
Register the task inside the Tasking namespace under
the NetworkQueryTask name.
This class introduces the dependency to Qt::Network,
otherwise Tasking namespace is independent on Qt::Network.
Possibly, may be added into Qt::Network lib,
as a wrapper around the QNetworkReply.
Change-Id: I29f160c0bf128c567ce20f044540b2dd6f1e17c4
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Fetch the new textures from the remote server
Also, disabled tst_qml_wizard, for now.
Task-number: QDS-9607
Change-Id: I35081b90afadddff8d8c4b32da8bed82996304cd
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Before the change, we got zero results in the
expected case or up to two fails on error.
Change-Id: I6583844eb5473cad8190acc91db1207933dc6630
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
The Enable QML check box is nowadays a combo box.
Change-Id: I87d94892ac02ea16d18bf78999f17065e02c5ac6
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
Get back to the originally intended behavior
for StopOnDone and ContinueOnDone workflow policies.
By default, these policies report an error until
at least one child task finished with success.
Since the group is empty, no child finished with success,
so the group should report an error.
Change also the return result for the StopOnFinished policy
when placed in an empty group. The policy is meant to
report the finished child's result. Since no task finished,
report an error in this case.
Fix tests accordingly.
Amends c9638ff642
Change-Id: Idc449e8c68a658755bf566df56844126167f1751
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Make it available for Group or CustomTask items.
Note, that when withTimeout() is used, the total
number of tasks grows by one.
Change-Id: Idc71737ba66b92bdc4bf17599c793b1127d22f5e
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Ensure the timeout tasks preserve the right order of
their done signals.
Change-Id: I62508d0710eb2324d7c347a9907a899c97d3975d
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
By default, when finished, it returns success.
In order to convert it into failing task,
enclose it inside a Group with finishAllAndError.
Reuse it in tasking tests.
Task-number: QTCREATORBUG-28741
Change-Id: Ic81203203e0b139d4f9bfd553279ecb01cd303f4
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Sometimes multiple nodes or properties has to be removed. In that case
there is also the possibilty that we want to bypass the model resource
management.
Task-number: QDS-9766
Change-Id: I6c3cb0f682a7579f23d72431f641e2f812e2c63c
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
That's going to replace FileIterator.
Benefits over FileIterator:
1. The FileContainer is a value type which may be
freely copied.
2. Much faster iterating, especially for SubDirFileContainer
with a big number of dirs / files (over 500000).
The FileContainer has begin() and end() functions returning
FileContainerIterator. The FileContainerIterator, when it's
not an end() iterator, contains the Item's value itself.
Whenever the iterator advances, the Item's value changes,
while the reference to Item's value remains unchanged inside
the iterator.
The SubDirFileContainer doesn't keep the references to all
visited Items anymore, contrary to the corresponding
SubDirFileInterator. The values of the individually visited
Items are kept only inside FileContainerIterator instances.
The progress information is available through the
FileContainerIterator's progressValue() / progressMaximum().
Task-number: QTCREATORBUG-28892
Change-Id: If89ac1121c21fa2fb7355aa12438dce3e85e465d
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
And ~175000 directories.
Distribute the generation and cleanup on all available cores.
With this patch I get the following config / measurements (linux):
Generating on 24 cores...
Generating 698881 files...
Generating 174721 dirs...
Generating inside "/tmp/tst_manual_subdirfileiterator-eHVKTL" dir...
GENERATING TEMPORARY FILES TREE stopped with timeout: 1777ms
ITERATING with SubDirFileIterator stopped with timeout: 92744ms
ITERATING with manual iterator stopped with timeout: 7905ms
ITERATING with QDirIterator stopped with timeout: 4706ms
CLEANING UP stopped with timeout: 1969ms
Amends 686a40d199
Change-Id: I7838e9cf73eae731a4dc3be02eeefa5caae8613d
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Fixes tst_build_new_project, tst_CCOM02 et al.
tst_tasks_handling fails which might be an actual issue, reported in:
Task-number: QTCREATORBUG-29209
Change-Id: I5eae54df27d8ba8f441e5b9c4acdaa2b41716245
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This patch also includes a small update to skip creating 'shaderTool'
object in the json container if it doesn't exist in the qmlproject
file.
Task-number: QDS-9969
Change-Id: I1b8639c5e0a57aa77cbd417b51d57c1f4910613a
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
The model is now deleting and changing the dependencies by itself. That
has the advantage of consistency. So if a node is now removed all the
dependecies will be deleted changing in the same way.
Task-number: QDS-9766
Change-Id: I1edf9ce172e51b9f52b62612ed2bb7386bf5b221
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
... for the case where the first line with semantic tokens has multiple
tokens.
This was not considered in the algorithm and uncovered by
d6f5d07639.
Also improve variable names and comments.
Fixes: QTCREATORBUG-29218
Change-Id: I0a1927c21edd70a3a91efc902e7e6ad2c734c91f
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: David Schulz <david.schulz@qt.io>
Rationale:
1. More descriptive.
2. More consistent with a planned new finishAllAndError policy.
3. Limits the possibilities of making a conflict with std::optional.
Change-Id: I5155630188e4b699e6c18b13a101e0e2d4fe98f2
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
Make the TaskTree tests dependent only on Tasking lib.
Introduce simple Timeout and Delay tasks for tests.
Using Timeout and Delay has a big advantage for these tests,
since e.g. when scheduling two parallel tasks with the same
timeout, we can expect the proper order in which they
finish. With AsyncTask it wasn't possible. Now, the tests
should be much more reliable and shouldn't exibit flakiness
anymore.
Use TickAndDone for Barrier tests.
Limit the tests' execution time from ~100ms into ~30ms.
Change-Id: Ifa08fd62c1a2759a877231c2220e353c1a26364f
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
The future synchronizer may abuse the subsequent test invocation
as it may still have spinning threads from the previous test run.
As all the started tasks should finish quickly on cancel,
we drop putting the canceled futures into the synchronizer.
Instead, we blocking wait for them to finish.
In this way, when the subsequent test is invoked, we should expect
the all available threads are ready to be used.
Change-Id: I9bb022b8c0950d27cb323ff83bf18148829160b3
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
The database has to be locked because otherwise it is not thread save.
Because Sqlite connections are already called in different threads this
has to be enforced. The easiest way to lock a database is to put it in a
transaction.
It should be ok without locking so long the connection is only called
from one thread but I prefer to enforce it because I have already seen
code was preparing a statement not on initialization stage where it is
highly unlikely that there is more than one thread pre connection but in
the middle of the code. Because preparing is much more expensive than a
lock I prefer to enfore a lock here.
Change-Id: Id0b47f8d615a6697bb807392cafbe976bdd37233
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
There are many callback which do not control the flow and want to be
called for all steps. For that case we assume that a callback without a
return value will continue always.
Change-Id: I706123f2c425ac8c937d4d60ab977dae5ea9b030
Reviewed-by: Vikas Pachdha <vikas.pachdha@qt.io>
We don't have 32 bit packages anymore so the OS must be 64 bit.
Change-Id: If1ce6a502dd9c6b14d416915caf1d30bd5d01ddc
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
It's going to be reused in filesearch.h API.
Change-Id: I7ef133368536a647e19949ba8623134cf078a87d
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>