Page MenuHomePhabricator

CI job mw-tools-codesniffer-mwcore-testrun fails on clean run
Closed, ResolvedPublic

Description

After the new release of codesniffer used on mediawiki/core there are no failures on job mw-tools-codesniffer-mwcore-testrun but it fails. It is indented to always reported as "FAILURE"?

https://integration.wikimedia.org/ci/job/mw-tools-codesniffer-mwcore-testrun/1874/console
https://gerrit.wikimedia.org/r/c/mediawiki/tools/codesniffer/+/591451 Patch Set 7

I have seen only:

ERROR: Step ‘Archive the artifacts’ failed: No artifacts found that match the file pattern "log/". Configuration error?

Another nitpick:
Composer does not use cache here?

22:37:56 [7.4MiB/0.47s] Updating dependencies
22:38:35 [232.6MiB/39.65s] Package operations: 3 installs, 0 updates, 0 removals
22:38:36 [232.6MiB/39.65s]   - Installing squizlabs/php_codesniffer (3.5.8): [232.7MiB/39.65s] Downloading[232.7MiB/40.10s]  (100%)[232.7MiB/40.10s] 
22:38:36 [232.7MiB/40.40s]   - Installing composer/semver (1.5.2): [232.7MiB/40.40s] Downloading[232.7MiB/40.93s]  (100%)[232.7MiB/40.93s] 
22:38:37 [232.7MiB/40.99s]   - Installing composer/spdx-licenses (1.5.4): [232.7MiB/41.00s] Downloading[232.7MiB/41.08s]  (100%)[232.7MiB/41.08s] 
22:38:37 [232.0MiB/41.68s] Writing lock file
22:38:37 [232.0MiB/41.68s] Generating autoload files
22:38:37 [232.0MiB/41.68s] 2 packages you are using are looking for funding.
22:38:37 [232.0MiB/41.68s] Use the `composer fund` command to find out more!
22:38:37 [232.2MiB/41.84s] Memory usage: 232.16MiB (peak: 286.46MiB), time: 41.84s

Event Timeline

hashar subscribed.

The job is configured to archive files in the log directory and fails when it finds none there. We can stop failing or adjust the job to write some reports to /log.

Change 639003 had a related patch set uploaded (by Hashar; owner: Hashar):
[integration/config@master] jjb: allow empty log for phpcs testrun

https://gerrit.wikimedia.org/r/639003

Change 639003 merged by jenkins-bot:
[integration/config@master] jjb: allow empty log for phpcs testrun

https://gerrit.wikimedia.org/r/639003

I have updated the job, it no more complains when there are no logs.

Regarding the lack of a composer cache: we only save caches either on gate-and-submit or after a change has been merged (postmerge). That job only triggers in the test pipeline, and thus there are no cache saved for it! We do not have a good way to save it, I guess for a low traffic job and 3 dependencies, we can afford not having a cache.

That being said, ideally I would like to overhaul the way caches are saved. The current system definitely has reached its limits.

The job passes now, I apparently just forgot to mark this resolved.

Regarding lack of cache: it is only populated via gate-and-submit or postmerge and that job doesn't run in either of those pipelines. That system eventually has to be overhauled.