Bug 341682 - Cannot select any key, regardless of where
Summary: Cannot select any key, regardless of where
Status: RESOLVED WORKSFORME
Alias: None
Product: kmail2
Classification: Applications
Component: crypto (show other bugs)
Version: Git (master)
Platform: Compiled Sources Linux
: NOR major
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-12-09 06:15 UTC by Dan O.
Modified: 2022-11-18 05:16 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Possible fix for selection window (856 bytes, patch)
2014-12-10 09:46 UTC, Dan O.
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Dan O. 2014-12-09 06:15:05 UTC
Trying to set a crypto key in either the identities config, or through attaching a public key, the OK button does nothing. I can see my key, and can click on it, but I can't actually select it. It never seems to spawn gpg, or anything for that matter. Kleopatra seems to be working on its own for the most part. When I click on a key, I get these messages:

log_kleo_ui: Kleo::ProgressDialog::slotDone()
log_kleo_ui: Kleo::KeyListView::slotUpdateTimeout(): processing 1 items en block
log_kleo_ui: KeySelectionDialog::slotSelectionChanged()
log_kleo_ui: KeySelectionDialog::slotCheckSelection()
log_kleo_ui: KeySelectionDialog::slotCheckSelection()
log_kleo_ui: Kleo::ProgressBar::startStopBusyTimer() cur = -1 ; tot = 100 ; real = -1
log_kleo_ui: (new value) switch to reset
"/home/dan/.gnupg"
"/home/dan/.gnupg"
log_kleo_ui: Kleo::ProgressDialog::slotDone()
log_kleo_ui: KeySelectionDialog::slotSelectionChanged()
log_kleo_ui: KeySelectionDialog::slotCheckSelection()

Though when I click the 'OK' button, there is no log of anything happening.

Reproducible: Always

Steps to Reproduce:
1. Open identities editor, change to the Cryptography tab
2. Press the change button for PGP and view the list
3. Select a key and press 'OK'

Actual Results:  
Absolutely nothing happens with no logs or errors

Expected Results:  
A key is selected and used for signing/encryption
Comment 1 Dan O. 2014-12-10 09:02:06 UTC
In void Kleo::KeySelectionDialog::slotOk(), it seems to be returning back to the widget if the key selection is not empty and the keys are valid, as referenced by this line: if (!mSelectedKeys.empty() && checkKeyUsage(mSelectedKeys, mKeyUsage)). Should it not accept() if that is true? I'm testing it now, but it seems the return/accept() conditions are reversed to me.
Comment 2 Dan O. 2014-12-10 09:46:04 UTC
Created attachment 89899 [details]
Possible fix for selection window

I appear to have been right, at least from my testing I am now able to select and use keys properly. I don't really know what the timer is there for so I didn't touch that, but I think this should work.
Comment 3 Laurent Montel 2014-12-10 22:20:14 UTC
Do you have same bug in 4.14 ?
Code was not changed so patch is not correct.
So bug is in other code.
Comment 4 Dan O. 2014-12-10 23:04:52 UTC
Sorry, I have never run 4.14 so I can't say for sure. I had a hard time tracing that part of code so the handling of that issue might be elsewhere. I changed that part because it seemed like control was never passing back on the OK press
Comment 5 Laurent Montel 2014-12-11 06:15:46 UTC
Do you know that kf5 kdepim will release in 18 months ?

But I can't change this code without know if it's this bug occurs in stable version.
Otherwise we will change this code and after fix real bug and it will still broken.

So first step, look at if we can reproduce in 4.14
Secondary create an unit test for this feature
3: test on kf5
4: fix kf5 code.
Regards.
Comment 6 Justin Zobel 2022-10-19 22:10:46 UTC
Thank you for reporting this bug in KDE software. As it has been a while since this issue was reported, can we please ask you to see if you can reproduce the issue with a recent software version?

If you can reproduce the issue, please change the status to "CONFIRMED" when replying. Thank you!
Comment 7 Bug Janitor Service 2022-11-03 05:06:36 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 8 Bug Janitor Service 2022-11-18 05:16:51 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!