• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

aiidateam / aiida-core / 6712
70%

Build:
DEFAULT BRANCH: develop
Ran 12 Jul 2019 02:42PM UTC
Jobs 4
Files 403
Run time 12min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
6712

push

travis-ci

web-flow
Fix bug with never resolving calculation job update futures (#3155)

The `JobsList` class is a container and manager of requests for updates
of the status of calculation jobs. For each request, it keeps a future
that it will update in bulk after retrieving the status of all the jobs
that it manages. This is necessary to ensure that multiple jobs use the
same update call to scheduler and not all individually, in order to not
overload the scheduler.

If the scheduler update call excepts, all the futures were properly
excepted as well and the internal cache of outstanding requests would be
cleared, before re-raising the exception. The excepted futures would
each be caught by the exponential backoff mechanism and a new request to
update the status would be scheduled. This would be registered with the
same `JobsList` instance, however, the next scheduler update would never
be called and so the futures would never be resolved, causing the
calculation jobs to "hang" indefinitely.

The problem lies in the `_ensure_updating` method. When a new request
comes in, this is the method that is called first to see if a scheduler
update call has already been scheduled. If the case, a new one does not
have to be scheduled. This is based on whether the `_update_handle`
attribute is defined. This attribute is properly reset after a scheduler
update goes through successfully, in the `updating` coroutine after the
`_update_job_info` yields. However, in the case of an exception in that
last method, the code path that resets the `_update_handle` is never
reached because the exception is re-raised after the job requests cache
is reset. The solution is simply to manually set `_update_handle` to
`None` in the except clause.

24179 of 32466 relevant lines covered (74.47%)

2.76 hits per line

Jobs
ID Job ID Ran Files Coverage
5 6712.5 (TEST_AIIDA_BACKEND=django TEST_TYPE="tests") 12 Jul 2019 02:42PM UTC 0
68.16
Travis Job 6712.5
6 6712.6 (TEST_AIIDA_BACKEND=django TEST_TYPE="tests") 12 Jul 2019 02:49PM UTC 0
68.11
Travis Job 6712.6
7 6712.7 (TEST_AIIDA_BACKEND=sqlalchemy TEST_TYPE="tests") 12 Jul 2019 02:48PM UTC 0
69.72
Travis Job 6712.7
8 6712.8 (TEST_AIIDA_BACKEND=sqlalchemy TEST_TYPE="tests") 12 Jul 2019 02:53PM UTC 0
69.68
Travis Job 6712.8
Source Files on build 6712
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #6712
  • d79287c3 on github
  • Prev Build on develop (#6710)
  • Next Build on develop (#6718)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc