8

WHY THE FUCK IS DJANGO RETURNING A STRING FOR A DECIMAL FIELD WTF

Comments
  • 5
    So that you could parse it and determine on your own. You know, flexibility
  • 3
    @asgs That'd be fine if it was at least consistent
  • 2
    would you rather have it as boolean?
  • 4
    @tosensei I'd rather it blow up the cloud server
  • 2
    @BordedDev man, that's a fucked impl whether it is consistent or not . I was spraying fuel to the wildfire
  • 1
    Fuck languages which make this crap possible.
    Fuck people which excuse this by saying "just don‘t do it".
    This example shows that if it’s possible, some idiot will do it.
  • 2
    @Lensflare *makes spooky JavaScript noises*
  • 2
    @jestdotty Yeah, JS is so scary, that‘s the obvious reason why it sucks.
    </sarcasm>
  • 1
  • 2
    Because its Python -- it tells type safety to go fuck itself
  • 1
    We even had a company policy to do that for all numeric id JSON responses due to the size limitations. Same for some representations of monetary amounts to prevent floating point calculation errors.

    There can be good reasons for it. But in isolation all solutions look odd.
  • 2
    @hjk101 that’s fine as long as the api specifically says that it’s a string and not a number
  • 2
    Django UNCHAINED.

    Stupid references notwithstanding, I never understood the appeal of django. Always seemed pretty heavy out of the box.
  • 1
    @Wisecrack I've heard decent things about it over the years, but this project has definitely cured me of it
  • 1
    @BordedDev "this project has definitely cured me of it"

    ha.
Add Comment