-
Notifications
You must be signed in to change notification settings - Fork 74
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
Exception ignored message when creating failed + valid session #691
Comments
@qubixes What's the scheme used by your client env file ? With native authentication, I wasn't able to reproduce the issue. |
Also (again to @qubixes ) - assuming I'm able to reproduce at some point - which older version of PRC corrects the problem? |
Will try with SSL enabled. Sometimes that makes a difference. @qubixes Since the error is incurred while trying to send a disconnect message to the server, on a socket the iRODS server has already given up on, I am pretty sure functionality won't be threatened by the issue underlying this error message. Perhaps it would be an option to turn this into an INFO level of logged message, instead of an actual exception. Will discuss with the rest of the iRODS Team. |
@d-w-moore I'll just paste my irods_environment.json for completeness: {
"irods_host": "geo.data.uu.nl",
"irods_port": 1247,
"irods_home": "/nluu11p/home",
"irods_user_name": "<snip>",
"irods_default_resource": "irodsResc",
"irods_zone_name": "nluu11p",
"irods_authentication_scheme": "pam",
"irods_encryption_algorithm": "AES-256-CBC",
"irods_encryption_key_size": 32,
"irods_encryption_num_hash_rounds": 16,
"irods_encryption_salt_size": 8,
"irods_client_server_policy": "CS_NEG_REQUIRE",
"irods_client_server_negotiation": "request_server_negotiation"
} |
Yes, functionally there are no problems, it's just the messaging to the user. |
I did a little bit of a manual bisect, and I get the problem with PRC==2.2.0, but not with PRC==2.1.0. Let me know if you need me to bisect on commits. |
not too many to eyeball there... |
No, but I see 2 or 3 that are potentially influencing changes. |
Since unhandled exceptions aren't good in finalizers, this loose end should be tied up neatly and logged. But the logging shouldn't be seen at the default level of WARNING, so let's do an INFO level message that simply displays the object representation of the Exception. |
It's still elusive to try and reproduce this error, so although I have what I think is a fix, I can't really test it. |
For now, keep your solution to this in its own branch until we can reproduce it. That keeps other PRs from being blocked by this. |
I could test it if you want! |
Yes, it's certainly a help to find conditions that reproduce it; could help us to get a fix in sooner. |
@d-w-moore - Please share the branch and/or diff with the experimental fix and perhaps @qubixes can apply it and try it out? |
Good idea, will do. |
@qubixes Please see dev branch https://github.com/d-w-moore/python-irodsclient/tree/691.m , the very latest commit 3239d54, as a basis for how to test for whether my existing patch helps in this issue |
Yes, it does help the issue, I don't get a message about the connection anymore with the default logging level. I can still reproduce the error message for the latest version on PyPI (3.0.0). |
Good. @d-w-moore Does @qubixes' recent success with the change help us understand the problem? |
Not on any grand level. But it does suppress a message that was potentially not useful for the application user (ie noise control) -- provided the default WARNING log level isn't decreased for the log message in question. It also means we've put a bandage on what was a potential troublemaker, since exceptions should never allowed to be unhandled within the scope of the |
@qubixes - I tried again with iRODS 4.2.12, PRC v2.2.0, with PAM & SSL login, using your script above almost exactly, and am still not able to reproduce, which means I can't really write a test. Can you think of any other special conditions (or modifications relative to a "fresh" install) that apply to your system? Or perhaps a set of steps you go through that is guaranteed to produce the error? |
@d-w-moore I have asked @stsnel, since he knows a lot more about the system than I do. For now we have the server logs from the server side from when I run the script:
|
Preliminary results for UU Yoda 1.9.x environment (based on iRODS 4.2.12) with Python 3.12.3 client:
If I run a bisect between 3.0.0 and 3.1.0, I get:
Link to this commit: bee8294 I'll check with @qubixes to see if we can compare notes and gather more information. |
Checking into this again. It could be sensitive to the slightest things, and I'm beginning to think the Python version makes the difference (It wouldn't be the first time, esp where interpreter exit / GC issues are concerned). I had not been testing with anything as recent as Python 3.11 or 3.12.... @stsnel , I was wondering what you use in your bisect to determine success/failure. Do you have a ready-made script or were you evaluating the condition manually? |
I was using the script provided by Qubixes at #691 (comment) . I invoked it three times per PRC version to determine if the failure occurred (sort of) consistently. |
Right, that makes sense, I also see that I get different results with Python 3.9.20 on my system:
|
Unfortunately I'm not getting consistent results with yours , @stsnel and @qubixes . Still unable to reproduce the error dump:
Using this script and alice as the PAM login with password 'apass'
and in the same terminal session
|
@stsnel - Any changes to the |
Hi @d-w-moore, I've performed these tests on a laptop running Ubuntu 24.04 LTS. I don't see any relevant environment variables that could influence this behaviour. Please find the settings in the irods_environment file on the client below:
Settings on the provider that we're connecting to:
I can reproduce the issue with your script in combination with Python 3.12.3 and PRC 3.1.0:
If I print a traceback for the exception that is raised when creating the first session, it seems to complain about a missing import:
So it looks like |
hi @stsnel , |
Hi!
During work on one of my PRs we ran into some exception ignored messages such as:
Even though the functionality in iBridges still works fine, this is of course somewhat confusing to the user/us. We first thought it was caused by the new PR, but it seems to originate from the PRC, since installing an old version of PRC removes the message. For reproducing I have found this works relatively consistently:
If you can't reproduce it the first time, it might reproduce the second time in my experience.
Looking through the PRC release notes, if found that f2332b3 might be related to this, since I think the issue appears in the cleanup phase.
Let me know if you need more information (I get 4.2.12 for the server version)).
The text was updated successfully, but these errors were encountered: