Page MenuHomeSoftware Heritage

Debug swh-docker-dev ci failure
Closed, MigratedEdits Locked

Description

It's been failing for a while now.
Latest build failure https://jenkins.softwareheritage.org/view/all/job/swh-docker-dev/232/console

The build log reference an issue with the swh-indexer-journal-client:

Waiting for the git loading task to complete[test_01_loader_git.sh] 
Service swh-indexer-journal-client died unexpectedly, exiting
Dumping logs for all services in file /var/lib/jenkins/workspace/swh-docker-dev/tests/swh-docker-compose.logs
An error occurred when running test script test_01_loader_git.sh
Dumping logs for all services in file /var/lib/jenkins/workspace/swh-docker-dev/tests/swh-docker-compose.logs

Event Timeline

ardumont triaged this task as Normal priority.Nov 20 2019, 10:17 AM
ardumont created this task.

I failed to find the swh-docker-compose.logs file.
I finally found the reference of the node the build ran on though (because i keep forgetting that) [1]

Triggering the test locally, it does not fail as the ci do.
(as in echo $? is 0 so success).

Although, there is indeed an issue in the indexer-journal-client:

workon swh
cd swh-docker-dev
./tests/run_test.sh

In another shell:

doco logs --follow swh-indexer-journal-client

Failure:

swh-indexer-journal-client_1  | swh.indexer                   0.0.157
swh-indexer-journal-client_1  | swh.journal                   0.0.19
swh-indexer-journal-client_1  | swh.lister                    0.0.41
swh-indexer-journal-client_1  | swh.loader.core               0.0.52
swh-indexer-journal-client_1  | swh.loader.dir                0.0.35
swh-indexer-journal-client_1  | swh.loader.git                0.0.52
swh-indexer-journal-client_1  | swh.loader.mercurial          0.0.21
swh-indexer-journal-client_1  | swh.loader.svn                0.0.45
swh-indexer-journal-client_1  | swh.loader.tar                0.0.41
swh-indexer-journal-client_1  | swh.model                     0.0.51
swh-indexer-journal-client_1  | swh.objstorage                0.0.39
swh-indexer-journal-client_1  | swh.scheduler                 0.0.63
swh-indexer-journal-client_1  | swh.storage                   0.0.158
swh-indexer-journal-client_1  | swh.vault                     0.0.31
swh-indexer-journal-client_1  | swh.web                       0.0.220
swh-indexer-journal-client_1  | urllib3                       1.25.7
swh-indexer-journal-client_1  | vcversioner                   2.16.0.0
swh-indexer-journal-client_1  | vine                          1.3.0
swh-indexer-journal-client_1  | Werkzeug                      0.16.0
swh-indexer-journal-client_1  | wheel                         0.33.6
swh-indexer-journal-client_1  | wrapt                         1.11.2
swh-indexer-journal-client_1  | xmltodict                     0.12.0
swh-indexer-journal-client_1  | yarl                          1.3.0
swh-indexer-journal-client_1  | zipp                          0.6.0
swh-indexer-journal-client_1  | Starting swh-indexer-journal client
swh-indexer-journal-client_1  | wait-for-it: waiting for kafka:9092 without a timeout
swh-indexer-journal-client_1  | wait-for-it: kafka:9092 is available after 3 seconds
swh-indexer-journal-client_1  | INFO:swh.core.config:Loading config file /etc/softwareheritage/indexer/journal_client.yml
swh-indexer-journal-client_1  | Traceback (most recent call last):
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/bin/swh", line 8, in <module>
swh-indexer-journal-client_1  |     sys.exit(main())
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/swh/core/cli/__init__.py", line 97, in main
swh-indexer-journal-client_1  |     return swh(auto_envvar_prefix='SWH')
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/click/core.py", line 764, in __call__
swh-indexer-journal-client_1  |     return self.main(*args, **kwargs)
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/click/core.py", line 717, in main
swh-indexer-journal-client_1  |     rv = self.invoke(ctx)
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/click/core.py", line 1137, in invoke
swh-indexer-journal-client_1  |     return _process_result(sub_ctx.command.invoke(sub_ctx))
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/click/core.py", line 1137, in invoke
swh-indexer-journal-client_1  |     return _process_result(sub_ctx.command.invoke(sub_ctx))
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/click/core.py", line 956, in invoke
swh-indexer-journal-client_1  |     return ctx.invoke(self.callback, **ctx.params)
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/click/core.py", line 555, in invoke
swh-indexer-journal-client_1  |     return callback(*args, **kwargs)
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/click/decorators.py", line 17, in new_func
swh-indexer-journal-client_1  |     return f(get_current_context(), *args, **kwargs)
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/swh/indexer/cli.py", line 229, in journal_client
swh-indexer-journal-client_1  |     nb_messages += client.process(worker_fn)
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/swh/journal/client.py", line 175, in process
swh-indexer-journal-client_1  |     worker_fn(dict(objects))
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/swh/indexer/journal_client.py", line 19, in process_journal_objects
swh-indexer-journal-client_1  |     process_origin_visits(messages['origin_visit'], scheduler, task_names)
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/swh/indexer/journal_client.py", line 32, in process_origin_visits
swh-indexer-journal-client_1  |     [visit['origin']['url'] for visit in visit_batch],
swh-indexer-journal-client_1  |   File "/srv/softwareheritage/venv/lib/python3.7/site-packages/swh/indexer/journal_client.py", line 32, in <listcomp>
swh-indexer-journal-client_1  |     [visit['origin']['url'] for visit in visit_batch],
swh-indexer-journal-client_1  | TypeError: string indices must be integers
swh-docker-dev_swh-indexer-journal-client_1 exited with code 1

[1] https://forge.softwareheritage.org/almanac/device/view/worker01-test.softwareheritage.org/

Ok, the stacktrace and the current indexer code (master) seems out of sync.
rDCIDXb2ff26454b37f3d332b90ff6a70a45b43dea6526 fixing that part of the journal client.

So releasing a new indexer version now.

ardumont claimed this task.
zack renamed this task from Debunk swh-docker-dev ci failure to Debug swh-docker-dev ci failure.Nov 20 2019, 10:55 AM