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 8623983
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T07:24:50+00:00 2026-06-12T07:24:50+00:00

I am building an application with Python 2.7 using the Google App Engine framework.

  • 0

I am building an application with Python 2.7 using the Google App Engine framework.
To test my application I have a several tests that are run through nosetests making use of the nosegae plugin. I run them with the following command:

nosetests --with-gae --gae-lib-root=/usr/local/google_appengine/ -w . -w */test/ -v

In the model layer of my application, I have the need to run several database operations that affect multiple entity groups inside the same transaction. I do this by making use of the run_in_transaction_options function of the db package:
https://developers.google.com/appengine/docs/python/datastore/functions#run_in_transaction

Unfortunately, when running my test suites, I get the following error in those testcases that try to run such transaction:

BadRequestError: transactions on multiple entity groups only allowed
with the High Replication datastore

I cannot find any flag in nosetests that makes it possible to enable the HRD.

I am wondering if it is possible at all to run HRD from nosetests and if so, how it can be set up?

  • 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-12T07:24:51+00:00Added an answer on June 12, 2026 at 7:24 am

    I would highly suggest you to switch from db to ndb, where you can use cross group transactions.

    To simulate the HRD, you can add this part to the setUp function of your tests, from Writing High Replication Datastore tests:

    # Create a consistency policy that will simulate the High Replication consistency model.
    self.policy = datastore_stub_util.PseudoRandomHRConsistencyPolicy(probability=0)
    
    # Initialize the datastore stub with this policy.
    self.testbed.init_datastore_v3_stub(consistency_policy=self.policy)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm building a multiuser realtime application with Google App Engine (Python) that would look
I am building a web application on google app engine using python and jinja2.
I'm building an application using Google app engine with python, and I'm stuck with
I'm currently building a Python webapp on the Google App Engine and I want
I'm building a scientific application in Python and considering using Amazon EC2 to run
Building a python application that converts raw audio files into wave using sox on
I'm building web app that needs to communicate with another application using socket connections.
I am using python and webapp framework in app engine for backend and flex
I'm building my new website using app-engine with python and webapp2 I'm having hard
I'm building a centralized desktop application using Python/wxPython. One of the requirements is User

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.