New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ddel: AttributeError: type object 'HttpError' has no attribute 'resp' #133
Comments
Thanks for reporting this @de-code! We can certainly work around this, although I'd like to be able reproduce it or otherwise reason about why you are seeing this. We have not seen this particular error in our end-to-end tests that call Are you able to reproduce this error consistently? Can you dump out anything further on this object using |
I have since been able to cancel all tasks and I am not sure I feel brave enough to get into the same situation again (I am a bit worried about the cost - unless I can limit the compute engines to a very small number). I can give you more information of what lead to it: I created a All of the tasks are very short lived (probably not the intended use-case). Therefore the overhead of creating a compute engine is much greater. If however it re-used the VM and just run docker exec or run many times the overhead would be much lower. The UI cloud console showed around 4/5 pages of compute engines running and being started. First I deleted them there, which probably wasn't a good move. Then I went to the Pipelines page which only showed 32 pending tasks which I cancelled there as well. But it was still creating new compute engines. That is when I tried to cancel all of the tasks via |
Also working with a dsub user that just showed me the same error. He's using the latest version of sub and has a tasks file with thousands of entries. The only difference is that they aren't deleting using a '*', but they are using a job id. The error is very similar: xxxxxx@bxxxxx:~$ ddel --provider google-v2 --project phs-207015 --jobs 'bg-noise--xxxxx--181106-032254-56' job-id: Found 2544 tasks to delete. |
Thanks for reporting this Joe. In the meantime, you can drop in the code change suggested above to handle the original exception more cleanly so that the user can delete their tasks. |
|
Thanks Joe. One of our engineers was able to reproduce the problem. Line 415 change:
to:
We'll have the fix included in the next release. |
Its nice when its simple. Thanks!
…________________________________
From: Matt Bookman [notifications@github.com]
Sent: Thursday, November 08, 2018 9:48 PM
To: DataBiosphere/dsub
Cc: Slagel, Joseph L; Comment
Subject: Re: [DataBiosphere/dsub] ddel: AttributeError: type object 'HttpError' has no attribute 'resp' (#133)
Thanks Joe.
One of our engineers was able to reproduce the problem.
It looks like it has always been there for the google_v2 provider and is a 1-line (1-character) change:
Line 415 change:
exception = sys.exc_info()[0]
to:
exception = sys.exc_info()[1]
We'll have the fix included in the next release.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub<https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_DataBiosphere_dsub_issues_133-23issuecomment-2D437257540&d=DwMFaQ&c=KoC5GYBOIefzxGAm2j6cjFf-Gz7ANghQIP9aFG9DuBs&r=wItZQv9607iYGyuIVq_Pk3Qr-Yy3oS1MW_vcxPgKYrE&m=EsPN6UMIxAWfaPzX_VTO2huuEtnJFCIkW6G9p1eY3VA&s=BGosgJCDfTHtzPt7iEk9EaQNB_5nT409XiMn4eUR-_Q&e=>, or mute the thread<https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_AKBQyN4KR-2D-5FL7UKfCJ2lBqqi3m0ZqVd9ks5utRdIgaJpZM4Xz-2Ddh&d=DwMFaQ&c=KoC5GYBOIefzxGAm2j6cjFf-Gz7ANghQIP9aFG9DuBs&r=wItZQv9607iYGyuIVq_Pk3Qr-Yy3oS1MW_vcxPgKYrE&m=EsPN6UMIxAWfaPzX_VTO2huuEtnJFCIkW6G9p1eY3VA&s=E3pG21k-ohCfn_Fo6WltPi77GfQbLzUwJ0UmKDn5tYw&e=>.
________________________________
This message is intended for the sole use of the addressee, and may contain information that is privileged, confidential and exempt from disclosure under applicable law. If you are not the addressee you are hereby notified that you may not use, copy, disclose, or distribute to anyone the message or any information contained in the message. If you have received this message in error, please immediately advise the sender by reply email and delete this message.
|
This was fixed in release 0.2.3 (#136) |
I've created too many jobs "by accident" (or rather I hoped it would re-use compute engines). When I tried to delete all of them using:
ddel --provider google-v2 --project my-project-name --jobs '*'
I am getting the following exception at some point:
It could be that there are so many tasks to delete. HttpError should have the resp set in the constructor, not sure why it hasn't in that case. Maybe it's a different object (although the full classname was
googleapiclient.errors.HttpError
).I got around it by putting a try/catch google_base, something like (which is obviously a workaround, not a proper solution, but enough to get everything deleted - which took a while):
The text was updated successfully, but these errors were encountered: