Bug 1494644 - fedora.client.bodhi.BodhiClientException: You must provide a captcha_key
Summary: fedora.client.bodhi.BodhiClientException: You must provide a captcha_key
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: bodhi
Version: 26
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Randy Barlow
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-09-22 17:52 UTC by Randy Barlow
Modified: 2017-12-09 04:56 UTC (History)
21 users (show)

Fixed In Version: bodhi-2.11.0-3.fc28 bodhi-2.11.0-2.fc26 bodhi-2.11.0-2.fc27 bodhi-2.11.0-2.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 1445703
Environment:
Last Closed: 2017-12-09 04:56:09 UTC


Attachments (Terms of Use)

Description Randy Barlow 2017-09-22 17:52:58 UTC
+++ This bug was initially created as a clone of Bug #1445703 +++

Description of problem:

<snip>
  https://bodhi.fedoraproject.org/updates/FEDORA-2017-cb3894a567

 inst. RPMS: gtk-update-icon-cache-3.22.12-2.fc25.x86_64 - Icon theme caching utility (installed 2 days ago)
           : gtk3-3.22.12-2.fc25.x86_64 - The GIMP ToolKit (GTK+), a library for creating GUIs for X (installed 2 days ago)
           : gtk3-3.22.12-2.fc25.i686 - The GIMP ToolKit (GTK+), a library for creating GUIs for X (installed 2 days ago)
           : gtk3-devel-3.22.12-2.fc25.x86_64 - Development files for GTK+ (installed 2 days ago)

Comment? -1/0/1 -> karma, 'i' -> ignore, other -> skip> 1
Comment> gtk apps work fine
Traceback (most recent call last):
  File "/usr/bin/fedora-easy-karma", line 831, in <module>
    fek = FedoraEasyKarma()
  File "/usr/bin/fedora-easy-karma", line 690, in __init__
    karma)
  File "/usr/bin/fedora-easy-karma", line 815, in send_comment
    res = bc.comment(update["title"], comment, karma=karma)
  File "/usr/lib/python2.7/site-packages/fedora/client/bodhi.py", line 93, in wrapper
    raise BodhiClientException(problems)
fedora.client.bodhi.BodhiClientException: You must provide a captcha_key.


Happens every time I try it. Weird is that abrt doesn't detect it, so I had to report this manually.


Version-Release number of selected component (if applicable):
fedora-easy-karma-0-0.28.20150921gitc932687a.fc25.noarch

How reproducible:
always

--- Additional comment from Christian Dersch on 2017-04-26 12:49:36 EDT ---

I get the same on Fedora 26, fedora-easy-karma-0-0.30.20160408gitb5cdbc7f.fc26.noarch

--- Additional comment from Björn "besser82" Esser on 2017-04-26 13:19:48 EDT ---

Can confirm for f25 and f26.

--- Additional comment from Pete Walter on 2017-04-27 05:32:14 EDT ---

I was able to get it to work again with:

rm -rf ~/.fedora-easy-karma/ ~/.fedora/

--- Additional comment from Sandro Bonazzola on 2017-04-27 09:28:50 EDT ---

Same here on fedora-easy-karma-0-0.30.20160408gitb5cdbc7f.fc26.noarch
IMHO ~/.fedora-easy-karma/ is not relevant since the only file included was the ignored cpickle.

--- Additional comment from Björn "besser82" Esser on 2017-04-27 09:42:39 EDT ---

(In reply to Pete Walter from comment #3)
> I was able to get it to work again with:
> 
> rm -rf ~/.fedora-easy-karma/ ~/.fedora/

Removing the openid cache seems to be enough to get it working again:

$ rm ~/.fedora/openidbaseclient-sessions.cache


Maybe this can be handled by some exception in easy-karma…

--- Additional comment from Till Maas on 2017-05-04 02:33:16 EDT ---



--- Additional comment from Till Maas on 2017-05-04 02:39:38 EDT ---

I am not sure why the captcha key is missing, but it should be handled in python-fedora afaics. The file ~/.fedora/openidbaseclient-sessions.cache
also contains session IDs for different Fedora web apps, so just removing them in f-e-k seems to be quite radical.

--- Additional comment from Till Maas on 2017-05-04 02:39:52 EDT ---

I am not sure why the captcha key is missing, but it should be handled in python-fedora afaics. The file ~/.fedora/openidbaseclient-sessions.cache
also contains session IDs for different Fedora web apps, so just removing them in f-e-k seems to be quite radical.

--- Additional comment from Randy Barlow on 2017-05-04 14:37:11 EDT ---

This may be a Bodhi server-side issue, but I'm not sure yet until I investigate. It also happens with the bodhi 2 CLI:

https://github.com/fedora-infra/bodhi/issues/1503

--- Additional comment from Kamil Páral on 2017-07-04 08:17:15 EDT ---

Folks, any progress on this? We're getting more reports of this in the test list. Also, even when I deleted ~/.fedora/openidbaseclient-sessions.cache, the problem re-occurred after a short time. So this is a complete showstopper for using fedora-easy-karma for me.

--- Additional comment from Randy Barlow on 2017-07-05 13:29:39 EDT ---

Hello Kamil!

Have you experienced this issue with the bodhi >= 2 CLI installed, or only with the 0.9 CLI? (Fedora 26+ ships wih the Bodhi 2 CLI, and there is a Copr[0] available from me with the Bodhi 2 CLI for F24/25.)

I had seen this problem briefly with the Bodhi 2 CLI but the problem seemed to go away mysteriously and I now cannot reproduce with that version.


[0] https://copr.fedorainfracloud.org/coprs/bowlofeggs/bodhi/

--- Additional comment from Harald Reindl on 2017-07-05 18:31:13 EDT ---

most test-users are *far away* from F26 and the for the Fedora project most important currently are people giving karma for F24 because too less testers and a ton of stuff don't make it to stable repos at all or in case of kernel way too late before the next version is released and built

fuck up fedora-easy-karma regulary leads in "so well, it works for me and do what you want with your stable updates"

--- Additional comment from Björn "besser82" Esser on 2017-07-06 03:59:49 EDT ---

(In reply to Randy Barlow from comment #11)
> Hello Kamil!
> 
> Have you experienced this issue with the bodhi >= 2 CLI installed, or only
> with the 0.9 CLI? (Fedora 26+ ships wih the Bodhi 2 CLI, and there is a
> Copr[0] available from me with the Bodhi 2 CLI for F24/25.)
> 
> I had seen this problem briefly with the Bodhi 2 CLI but the problem seemed
> to go away mysteriously and I now cannot reproduce with that version.
> 
> 
> [0] https://copr.fedorainfracloud.org/coprs/bowlofeggs/bodhi/

I can still perfectly reproduce with Bodhi 2 CLI on fc26:

Traceback (most recent call last):
  File "/usr/bin/fedora-easy-karma", line 834, in <module>
    fek = FedoraEasyKarma()
  File "/usr/bin/fedora-easy-karma", line 693, in __init__
    karma)
  File "/usr/bin/fedora-easy-karma", line 818, in send_comment
    res = bc.comment(update["title"], comment, karma=karma)
  File "/usr/lib/python2.7/site-packages/fedora/client/bodhi.py", line 118, in wrapper
    raise BodhiClientException(problems)
fedora.client.bodhi.BodhiClientException: You must provide a captcha_key.

--- Additional comment from Björn "besser82" Esser on 2017-07-06 04:00:29 EDT ---



--- Additional comment from Björn "besser82" Esser on 2017-07-06 04:02:08 EDT ---



--- Additional comment from Randy Barlow on 2017-07-06 10:30:37 EDT ---

It just occurred to me by looking at that traceback that fedora-easy-karma is still using python-fedora to get Bodhi Python bindings instead of the Bodhi 2 CLI. (So even though you have the Bodhi 2 CLI installed, it's not being used here.)

The server requires a captcha_key when the client is not authenticated. I did some work recently in the bindings to rework how Bodhi's bindings do authentication that I think would help here.

Anyways, I think we can fix this in at least Fedora 26+ by patching fedora-easy-karma to use the new Bodhi 2 client bindings.

For Fedora < 26, the problem always is that the bodhi 2 CLI is not backwards compatible and I'm not confident that it's feature complete with bodhi 0.9. Sometimes I think about asking for an exception to the backwards compatibility guideline. Perhaps I should start a thread on devel@ to see what the developers think.

--- Additional comment from Till Maas on 2017-07-06 15:52:50 EDT ---

(In reply to Randy Barlow from comment #16)

> Anyways, I think we can fix this in at least Fedora 26+ by patching
> fedora-easy-karma to use the new Bodhi 2 client bindings.
> 
> For Fedora < 26, the problem always is that the bodhi 2 CLI is not backwards
> compatible and I'm not confident that it's feature complete with bodhi 0.9.
> Sometimes I think about asking for an exception to the backwards
> compatibility guideline. Perhaps I should start a thread on devel@ to see
> what the developers think.

If the code on Fedora < 26 is broken anyhow I am not sure if there is a big objection for the new code not being feature complete. One remaining problem even after updating all of Fedora would be EPEL. I do not have any statistics but in the past people also used it to report update feedback there. Do you see any chance to provide the new bindings there as well?

--- Additional comment from Randy Barlow on 2017-07-06 17:37:16 EDT ---

(In reply to Till Maas from comment #17)
> If the code on Fedora < 26 is broken anyhow I am not sure if there is a big
> objection for the new code not being feature complete.

That is a good point, but on the other hand the Bodhi client does at least partially function for Fedora 24/25. It's a bit of a grey area to me - it'd be much more obvious what to do if the Bodhi 0.9 client didn't work at all. This is why I decided to provide it via the Copr so that each user could choose for themselves the experience they want for those versions of Fedora.

> One remaining problem
> even after updating all of Fedora would be EPEL. I do not have any
> statistics but in the past people also used it to report update feedback
> there. Do you see any chance to provide the new bindings there as well?

EPEL 7 does have Bodhi 2 - I went through a special process to ask for an exception to the EPEL update policy since it was backwards-incompatible. EPEL 6 does not have Bodhi 2, but also could not due to not having a new enough Python version and other dependencies. I have never heard from anyone using the Bodhi CLI on EPEL 6 though, so I don't have data about whether it is used there or not.

--- Additional comment from Harald Reindl on 2017-07-13 17:23:41 EDT ---

this bullshit makes me sick

fedora.client.bodhi.BodhiClientException: You must provide a captcha_key
rm -f /root/.fedora/openidbaseclient-sessions.cache

in the past you had to enter your password everytime, fine, worked, now you wait a long time until fedora-easy-karma does something sueful and then after wait again see above...

--- Additional comment from Kamil Páral on 2017-07-26 06:00:56 EDT ---

It just happened to me again on F26 using bodhi-client-2.8.1-1.fc26.noarch. 

Randy, fedora-easy-karma can hardly start using Bodhi2 client when it's not available in F25 (that would require two different codebases, and it wouldn't solve the problem in F25). This either needs to be fixed in python-fedora (it used to work before, even with Bodhi2 server, so there's clearly some regression somewhere), or Bodhi2 client needs to be pushed even to F25 and then fedora-easy-karma patched. Please note that you don't need to replace older Bodhi client in F25 if you're not sure about it - you can introduce it as a parallel package.

--- Additional comment from Randy Barlow on 2017-07-27 23:22:39 EDT ---

I filed https://pagure.io/fedora-easy-karma/issue/1 about fedora-easy-karma being updated to use bodhi.client.bindings.

--- Additional comment from Ken Dreyer on 2017-09-22 12:15:44 EDT ---

With fedora-easy-karma Git master (0c81432c4ec207a293cdf633fa93634a003f71c9) I am still seeing this issue.

Comment> no problems noticed
Traceback (most recent call last):
  File "./fedora-easy-karma.py", line 839, in <module>
    fek = FedoraEasyKarma()
  File "./fedora-easy-karma.py", line 699, in __init__
    karma)
  File "./fedora-easy-karma.py", line 823, in send_comment
    res = bc.comment(update["title"], comment, karma=karma)
  File "/usr/lib/python2.7/site-packages/bodhi/client/bindings.py", line 101, in wrapper
    raise BodhiClientException(problems)
bodhi.client.bindings.BodhiClientException: You must provide a captcha_key.

--- Additional comment from Randy Barlow on 2017-09-22 12:34:32 EDT ---

Hello Ken!

The current release of Bodhi turns out to also have this captcha bug, but I've written a patch upstream that will fix it in a future release:

https://github.com/fedora-infra/bodhi/issues/1787

That fix won't make it into F25 unfortunately, and this ticket is associated with F25.

--- Additional comment from Ken Dreyer on 2017-09-22 13:33:35 EDT ---

Thanks Randy! I tried a Git clone of bodhi (a87f5a6169a03d3a03df57bbb713ffb0ad8b80b6) in a virtualenv, and it works properly, even with my old credentials in ~/.fedora that were triggering the crash earlier. Thanks!

--- Additional comment from Randy Barlow on 2017-09-22 13:49:14 EDT ---

Since I can fix this with a Bodhi update in F26+ and EPEL 7, I'm going to clone this bug to F26 and switch it to the Bodhi component. I'll leave this ticket open, since the fix for F25 will need to be in python-fedora.

I also cannot commit to getting that done before F25 EOLs, due to time constraints. Of course, patches welcome for python-fedora if anyone is so inclined!

Comment 1 Fedora Update System 2017-09-23 15:00:15 UTC
bodhi-2.11.0-2.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2017-ab5f75bb11

Comment 2 Fedora Update System 2017-09-23 15:00:36 UTC
bodhi-2.11.0-2.el7 has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-1e6d4edc57

Comment 3 Fedora Update System 2017-09-23 15:00:50 UTC
bodhi-2.11.0-2.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2017-78b7bf9773

Comment 4 Fedora Update System 2017-09-23 18:27:38 UTC
bodhi-2.11.0-2.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-ab5f75bb11

Comment 5 Fedora Update System 2017-09-23 20:49:28 UTC
bodhi-2.11.0-2.el7 has been pushed to the Fedora EPEL 7 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-1e6d4edc57

Comment 6 Fedora Update System 2017-09-24 05:52:08 UTC
bodhi-2.11.0-2.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-78b7bf9773

Comment 7 Fedora Update System 2017-09-26 23:56:18 UTC
bodhi-2.11.0-2.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.

Comment 8 Fedora Update System 2017-09-30 06:52:02 UTC
bodhi-2.11.0-2.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.

Comment 9 Fedora Update System 2017-09-30 11:35:55 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2017-1a378bed07

Comment 10 Fedora Update System 2017-09-30 11:36:12 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.el6 has been submitted as an update to Fedora EPEL 6. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-e2634c3757

Comment 11 Fedora Update System 2017-09-30 11:36:28 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.el7 has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-35e7efea31

Comment 12 Fedora Update System 2017-09-30 11:36:44 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.fc27 has been submitted as an update to Fedora 27. https://bodhi.fedoraproject.org/updates/FEDORA-2017-f6271d2b93

Comment 13 Fedora Update System 2017-09-30 11:37:00 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.fc25 has been submitted as an update to Fedora 25. https://bodhi.fedoraproject.org/updates/FEDORA-2017-da6c16bf49

Comment 14 Fedora Update System 2017-10-01 23:48:37 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.el6 has been pushed to the Fedora EPEL 6 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-e2634c3757

Comment 15 Fedora Update System 2017-10-01 23:49:30 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.el7 has been pushed to the Fedora EPEL 7 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-35e7efea31

Comment 16 Fedora Update System 2017-10-01 23:55:08 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-1a378bed07

Comment 17 Fedora Update System 2017-10-02 00:55:43 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.fc25 has been pushed to the Fedora 25 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-da6c16bf49

Comment 18 Fedora Update System 2017-10-02 00:56:35 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.fc27 has been pushed to the Fedora 27 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-f6271d2b93

Comment 19 Fedora Update System 2017-10-08 23:55:21 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.fc27 has been pushed to the Fedora 27 stable repository. If problems still persist, please make note of it in this bug report.

Comment 20 Fedora Update System 2017-10-09 01:20:08 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.

Comment 21 Fedora Update System 2017-10-10 20:48:54 UTC
bodhi-2.11.0-2.el7 has been pushed to the Fedora EPEL 7 stable repository. If problems still persist, please make note of it in this bug report.

Comment 22 Fedora Update System 2017-10-19 21:47:10 UTC
fedora-easy-karma-0-0.34.20171019gitbc16e916.fc25 has been submitted as an update to Fedora 25. https://bodhi.fedoraproject.org/updates/FEDORA-2017-d136b70561

Comment 23 Fedora Update System 2017-10-22 03:23:13 UTC
fedora-easy-karma-0-0.34.20171019gitbc16e916.fc25 has been pushed to the Fedora 25 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-d136b70561

Comment 24 Fedora Update System 2017-10-25 23:55:32 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.el7 has been pushed to the Fedora EPEL 7 stable repository. If problems still persist, please make note of it in this bug report.

Comment 25 Fedora Update System 2017-10-26 09:46:39 UTC
fedora-easy-karma-0-0.32.20170930git0c81432c.el6 has been pushed to the Fedora EPEL 6 stable repository. If problems still persist, please make note of it in this bug report.

Comment 26 Fedora Update System 2017-12-09 04:56:09 UTC
fedora-easy-karma-0-0.34.20171019gitbc16e916.fc25 has been pushed to the Fedora 25 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.