Closed
Bug 872230
Opened 12 years ago
Closed 7 years ago
bug785146.py and some code from permissions.py is completely insane
Categories
(Testing :: Mozbase, defect)
Testing
Mozbase
Tracking
(Not tracked)
RESOLVED
WONTFIX
People
(Reporter: k0scist, Unassigned)
Details
https://github.com/mozilla/mozbase/blob/master/mozprofile/tests/bug785146.py
remember those highlights with "What is wrong with this picture?"
Well...
-
https://github.com/mozilla/mozbase/blob/master/mozprofile/tests/bug785146.py#L42
I'm not sure what this code is supposed to do. One thing it doesn't
do is anything. Luckily, you have a file that is at EOF since
you're writing to it, but were it not EOF, like supposing you wanted
to read from it and you did seek(0), then it would blow up on
https://github.com/mozilla/mozbase/blob/master/mozprofile/mozprofile/permissions.py#L249
since of course the string returned does not have an 'options' attr
- not sure why we're calling this anyway; we already wrote the
locations in __init__
- ...which has complicated and undocumented logic for determining what
to do with what to get some locations out of it. Wow. We should use
*args to make this magically deal with singl items and lists,
maybe. Also, we should make this a decorator, or at least a
free-standing function so that people that wanted it could consume
it. Like, say, perhaps, what someone that called write_db thought
was going to happen?
- and i'm pretty sure all the add_callback stuff is wrong in the sense
that we're probably writing too often but i'm not even going to look
at that now
Reporter | ||
Updated•12 years ago
|
Summary: bug785146.py is completely insane → bug785146.py and some code from permissions.py is completely insane
Comment 1•7 years ago
|
||
Mass closing bugs with no activity in 2+ years. If this bug is important to you, please re-open.
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•