0

Im making a webpage through google app engine that querys based on the person needs from an existing SQL database located on a local server. Im having trouble importing third party python libraries because most of them are not written in native python code (google app engine only supports fully python code). I have searched everywere for a way to connect to this database but I cant find a way around this issue.

2 Answers 2

1

You can use the MySQLdb library, which is a built-in library for App Engine. See the set up instructions in the docs for details.

Specify the MySQLdb library in the app.yaml libraries element:

libraries:
- name: MySQLdb
  version: "latest"
Sign up to request clarification or add additional context in comments.

Comments

0

What @BrettJ said, some of the common third-party libs for python are not pure python, and thus cannot be imported into the project unless google whitelists them end enables them to be imported in a safe manner, basically, what you need to do is to have MySQLdb library set in the app.yaml file.

    libraries:
      - name: MySQLdb
      version: "latest"

I highly suggest you go through several tutorials, this is basic stuff and will be cleared to you in minimum time.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.