After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 616356 - Change SCOPE_TYPE_INVALID handling to be a warning and not an error
Change SCOPE_TYPE_INVALID handling to be a warning and not an error
Status: RESOLVED FIXED
Product: pygi
Classification: Deprecated
Component: general
unspecified
Other All
: Normal normal
: 0.6
Assigned To: pygi-maint
pygi-maint
Depends on:
Blocks:
 
 
Reported: 2010-04-21 03:01 UTC by Zach Goldberg
Modified: 2010-04-26 16:28 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Change SCOPE_TYPE_INVALID handling to be a warning and not an error (984 bytes, patch)
2010-04-21 03:01 UTC, Zach Goldberg
none Details | Review
Change SCOPE_TYPE_INVALID handling to be a more verbose error. (750 bytes, patch)
2010-04-25 18:42 UTC, Zach Goldberg
committed Details | Review

Description Zach Goldberg 2010-04-21 03:01:30 UTC
J5 hit this today because he typed "notify" instead of "notified" and I guess was a bit
miffed that 1) the code segv'd for it and 2) that the code didn't immediatly point him
in the direction of his annotation.  This fixes both issues.  In reality though
the scanner should probably bail out on an invalid scope type.  Filed bug 616355
to fix the scanner.
Comment 1 Zach Goldberg 2010-04-21 03:01:32 UTC
Created attachment 159223 [details] [review]
Change SCOPE_TYPE_INVALID handling to be a warning and not an error

Be slightly nicer to library maintainers.  It really isn't a fatal condition
if we don't have a proper scope type, better to leave a good code comment
and a warning than to cause their code to segv.
Comment 2 Tomeu Vizoso 2010-04-23 12:27:43 UTC
Review of attachment 159223 [details] [review]:

I'm not sure if sigsegving is the major issue here, or rather the lack of a message properly explaining what happened.
Comment 3 Johan (not receiving bugmail) Dahlin 2010-04-23 14:45:44 UTC
Yeah, I think it's okay to have a fatal warning, invalid scopes should be fixed, not worked around.
Comment 4 Zach Goldberg 2010-04-25 18:42:11 UTC
Created attachment 159525 [details] [review]
Change SCOPE_TYPE_INVALID handling to be a more verbose error.
Comment 5 Tomeu Vizoso 2010-04-26 08:24:13 UTC
Review of attachment 159525 [details] [review]:

Great, though maybe we could give some more context such as the function where it happened? Just an idea.
Comment 6 Zach Goldberg 2010-04-26 16:28:27 UTC
Pushed.