Skip to content
This repository has been archived by the owner on Feb 24, 2024. It is now read-only.

output of get_gss_error should be available to the caller #3

Closed
macosforgebot opened this issue Sep 15, 2006 · 4 comments
Closed

output of get_gss_error should be available to the caller #3

macosforgebot opened this issue Sep 15, 2006 · 4 comments

Comments

@macosforgebot
Copy link

agx@… originally submitted this as ticket:51


Errorhandling in pykerberos is currently very poor - especially in the gssapi case. We can only check for 0 and -1. I see two ways out of this: we modify the functions to also return the output of get_gss_error or (what I'd like better) throw an exception that has the get_gss_error output as textual represenations. Without this, the module is kind of hard to use since there are little ways to diagnose errors. Any thoughs?

@macosforgebot
Copy link
Author

@cyrusdaboo originally submitted this as comment:1:⁠ticket:51

  • Type changed from Defect to Enhancement
  • Owner changed from @wsanchez to @cyrusdaboo
  • Status changed from new to assigned
  • Priority changed from 5: Not set to 4: Nice to have
  • Milestone set to Later

I agree - better error handling is needed in PyKerberos. I prefer the solution of raising an exception - new exception  type should be defined in PyKerberos for that.

@macosforgebot
Copy link
Author

agx@… originally submitted this as comment:2:⁠ticket:51


Just for reference a patch that implements this is here: https://honk.sigxcpu.org/unsorted-patches/pykerberos-exception-handling.diff

In case that matters (contribution terms) it's APL 2.0. I keep the patch outside of the Trac since updating patches in Trac is so cumbersome and it might need a few revisions until you're happy with it. Any comments?

Cheers,

-- Guido

@macosforgebot
Copy link
Author

agx@… originally submitted this as comment:3:⁠ticket:51


...and here's the patch to move calendarserver over to the new exception aware API:

https://honk.sigxcpu.org/unsorted-patches/calendarserver-pykerberos-exceptions.diff

Cheers,

-- Guido

@macosforgebot
Copy link
Author

@cyrusdaboo originally submitted this as comment:4:⁠ticket:51

  • Status changed from assigned to closed
  • Resolution set to fixed

Patches applied, with some minor tweaks. r271 & r272.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants