Build timeout but actually succeeded

https://travis-ci.org/Last-Order/Monita/jobs/509885403

The build status is failed due to timeout but it actually has finished all the procedures. How to solve this problem?
Thanks in advance.

Looks like a variation of

It’s related to yarn GPG. This solution worked for me:

recently I started getting this error:
https://travis-ci.org/igagis/utki/jobs/638886761

I did not change anything which could cause that, so it looks like something has changed in the environment, either in travis windows image or in msys2 chocolatey package or somewhere else.

Already tried YARN_GPG=no, did not help.

does anybody see this as well? Any idea what could cause that?