Because of our partial loading implementation we need to specify
finishedAt and startedAt differently than we would normally do. For some
reason duration was not recalculated while loading record and specifying
raw attributes helps here.
Duration on job was not specified, beacuse we actually don't return
duration from the API, it's always calculated based on startedAt and
finishedAt, that's why it's obsolete. It doesn't hurt to have it defined
on the Job model, but there's no need to do it.
Add vim relic file gitignore entry for .sw[op] files
Upgrade return due to an uninitialized constant Listen uninitialized constant
Listen::MultiListener exception (see:
https://github.com/rails/spring/issues/145)
* duration was not actually defined in Travis.Job, which may have caused
bugs when combined with partial record loading (so for example it was
ok on a refresh, but may have been broken on update)
* notStarted was not a dependency of duration
For some reason mocked ajax queries don't fire when build page is opened
directly in specs. I don't want to go into detail at this point, because
I plan rewriting build/job related views and controllers to decouple
repo controller anyway, which should fix some of the oddities.
We set job and build directly on repo controller for routes like job,
build and repo.index. We also need to clean that up when we exit to not
show for example download log button when we switch to different route.
A while ago I introduced a change to auth code which signs out user on
failed try to get user data. The problem with it was it signed out on
all kind of errors, like network error. I changed the code to log out on
401 status, but I haven't tested it properly, we actually return 403 on
unauthenticated queries for user data.