I have nothing against removing it from the built-in libs, but as long as we look for the system's libraries first what's the big downside to keeping it?
On Dec 1, 5:02 am, "Russell Keith-Magee" <[EMAIL PROTECTED]> wrote: > On Mon, Dec 1, 2008 at 4:21 PM, James Bennett <[EMAIL PROTECTED]> wrote: > > > On Mon, Dec 1, 2008 at 12:45 AM, Russell Keith-Magee > > <[EMAIL PROTECTED]> wrote: > > I guess the thing that's bugging me is that this mostly seems to come > > down to historical inertia; we already have simplejson in Django, and > > so the perception is that we should continue to bundle it. I think > > eventually we're going to have to get rid of it since sooner or later > > we'll be targeting only Python versions which have a json module built > > in, so we might as well start dealing with it. > > Granted - the Python 3 migration plan will eventually force the issue. > I just don't see any urgency to address it before then. If we link the > two schedules, we can end up in a situation where SimpleJSON is > guaranteed to be available while deprecating our own maintained > version. > > >> On the other hand: at present, the only prerequisite for running the > >> system test suite is a database backend, and not even that if you're > >> running Python 2.5 and SQLite. If we stopped packaging SimpleJSON with > >> Django, a great chunk of the system test suite would no longer work > >> out of the box. On top of that, no matter obvious we make the error > >> message, we're going to get "Why doesn't my fixture load" questions on > >> Django-users. > > > Several large and popular third-party Django apps already make use of > > non-JSON fixture formats; for example, Satchmo cannot load its > > fixtures or run its unit tests without PyYAML (and in my experience, > > YAML is preferred over JSON as a fixture format when it can be used), > > and yet they don't seem to be crushed under the weight of "I can't > > load the fixtures" problems. > > Django community != Satchmo community. I would be very surprised if > the Python competence of the average Satchmo newbie wasn't > significantly higher than that of the average Django newbie. By the > time a new developer has worked out what Satchmo is, and how it fits > into Django, one would hope that they have also worked out that this > is all just Python code, and the error messages really are telling you > what is wrong. > > > Similarly, ImageField has always required PIL (which is much trickier > > to install), and yet we don't see corresponding large numbers of > > questions on this list from people who can't manage to get it working. > > Firstly, there aren't that many tests that depend on PIL. By contrast, > every test with a fixture depends on SimpleJSON. > > Secondly, in most (all?) of the tests where PIL is required, the test > downgrades the ImageField to a FileField if PIL isn't available. This > does lead to slightly less complete test coverage, but not failed > tests. A similar downgrade would not be possible if SimpleJSON were > absent without providing fixtures in alternate formats or disabling > half the test suite. > > > So I have a hard time believing that this would pose such a large > > hurdle to use of Django. > > I wouldn't have thought an error message that reads "Error: Settings > cannot be imported, because environment variable > DJANGO_SETTINGS_MODULE is undefined" would lead to so many questions > on the mailing list, and yet.... > > >> IMHO, the suggestions hovering around #9266 and the related mailing > >> list threads - that users should be able to override the bundled > >> version of SimpleJSON - have merit, and it looks like Malcolm has a > >> handle on how to make this approach happen. However, completely > >> removing SimpleJSON seems like asking for a world of pain, with no > >> real gain. > > > To me, the gain is no longer bundling and maintaining something that > > we don't *have* to bundle and maintain. Advertising simplejson (or > > Python 2.6+) as a dependency for using JSON serialization doesn't, to > > me, seem to be too onerous a thing to do, and it gets something out of > > Django (where, arguably, it didn't belong in the first place) and out > > of our hair. > > My point (and Malcolm's) is that while this is true, the burden of > maintaining SimpleJSON simply isn't that high. In all honesty, I've > probably spent more effort writing emails on this thread that I have > dealing with SimpleJSON issues in the last 3 years. On the other hand, > I have spent a lot of time answering newbie questions by pointing them > at obvious error messages. > > Yours, > Russ Magee %-) --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-developers?hl=en -~----------~----~----~----~------~----~------~--~---