Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8124157
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T06:22:47+00:00 2026-06-06T06:22:47+00:00

I get this error when I use simplejson from django.utils in google app engine

  • 0

I get this error when I use simplejson from django.utils in google app engine project:

Traceback (most recent call last):
  File "/base/python27_runtime/python27_lib/versions/1/google/appengine/runtime/wsgi.py", line 187, in Handle
    handler = _config_handle.add_wsgi_middleware(self._LoadHandler())
  File "/base/python27_runtime/python27_lib/versions/1/google/appengine/runtime/wsgi.py", line 225, in _LoadHandler
    handler = __import__(path[0])
  File "/base/data/home/apps/s~testapp/1.359839747994604729/notify.py", line 8, in <module>
    from handlers.xmpp_handler import XMPPHandler
  File "/base/data/home/apps/s~testapp/1.359839747994604729/handlers/xmpp_handler.py", line 12, in <module>
    import commands
  File "/base/data/home/apps/s~testapp/1.359839747994604729/handlers/commands.py", line 4, in <module>
    from django.utils import simplejson
ImportError: No module named django.utils

Snippet:

import datetime
from google.appengine.api import users
from google.appengine.ext import db
from django.utils import simplejson

class jsonEncoder(simplejson.JSONEncoder):
    def default(self, obj):
        if isinstance(obj, datetime.datetime):
            return obj.isoformat()

        elif isinstance(obj, db.Model):
            return dict((p, getattr(obj, p)) 
                        for p in obj.properties())

        elif isinstance(obj, users.User):
            return obj.email()

        else:
            return simplejson.JSONEncoder.default(self, obj)
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T06:22:50+00:00Added an answer on June 6, 2026 at 6:22 am

    You need to specify that you want to use django in your app.yaml:

    libraries:
    - name: django
      version: "1.2"
    

    See the GAE docs for the supported django versions.

    On Python 2.7 runtime, you should be using python’s native json library instead of simplejson though.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I get this error when I try to use namespaces. I have namespace App;
I get this error when I try to use time_ago_in_words : Comparison of String
Why do I get this error message with this code? Use of undeclared identifier
i use this line of code : [self parseXMLFileAtURL:url]; And i get this error
I use the following jquery statements but i get error in this function onGetDataSuccess(result)
I get this error in my app { error: { message: Missing client_id parameter.,
I get this error when trying to use the latest ajaxToolKit NET4. I've downloaded
this is my sql statement i get this error. but when i use only
I get this error when I use my autogenerated ServiceBindingStub.java. WebService side is working
I get this error when I try to use autoload and namespaces: Fatal error:

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.