{ "info": { "author": "Eric Higgins", "author_email": "erichiggins@gmail.com", "bugtrack_url": null, "classifiers": [], "description": "GAEK: Google App Engine Kit\n===============================\n\n[![Build Status](https://travis-ci.org/erichiggins/gaek.svg)](https://travis-ci.org/erichiggins/gaek)\n\n\nA collection of useful tools for Python apps running on Google App Engine.\n\n* Free software: BSD license\n* Documentation: http://erichiggins.github.io/gaek/\n\nNDB JSON module\n---------------\n\nUsage:\n\n from gaek import ndb_json\n\n # Serialize NDB Model(s) to a JSON string.\n json_str = ndb_json.dumps(models)\n\n # Parse a JSON string into a Python dictionary.\n ndb_json.loads(json_str)\n\nWhen the encoder meets a property of the `ndb.Key` type, \nthere are three encoding options available: \n\n* `ndb_keys_as_entities` - encode Key property as a `Future` whose eventual result is the entity for the key.\n This is the default option.\n* `ndb_keys_as_pairs` - encode Key property as a tuple of (kind, id) pairs.\n* `ndb_keys_as_urlsafe` - encode Key property as a websafe-base64-encoded serialized version of the key.\n\nPlease refer to [NDB Key Class](https://cloud.google.com/appengine/docs/python/ndb/keyclass) documentation for details.\n\nFor example, for the following data models:\n\n```\n class Master(ndb.Model):\n name = ndb.StringProperty()\n```\n```\n class Details(ndb.Model):\n master = ndb.KeyProperty()\n description = ndb.StringProperty()\n```\n\nand following records:\n\n```\n master = Master(id=123456L, name='Europe')\n details = Details(\n master=ndb.Key(Master, 123456L), \n description='List of European customers'\n )\n```\n\nThe calls\n```\n json_str = ndb_json.dumps(details)\n json_str = ndb_json.dumps(details, ndb_keys_as_entities=True)\n```\nwill return\n\n```\n{\"master\": {\"name\": \"Europe\"}, \"description\": \"List of European customers\"}\n```\n\nThe call\n```\n json_str = ndb_json.dumps(details, ndb_keys_as_pairs=True)\n```\nwill return\n\n```\n{\"master\": [[\"Master\", 123456]], \"description\": \"List of European customers\"}\n```\n\nThe call\n```\n json_str = ndb_json.dumps(details, ndb_keys_as_urlsafe=True)\n```\nwill return\n\n```\n{\"master\": \"agFfcg4LEgZNYXN0ZXIYwMQHDA\", \"description\": \"List of European customers\"}\n```\n\n\nFeature parity with the Python `json` module functions.\n\n* `ndb_json.dumps`\n* `ndb_json.dump`\n* `ndb_json.loads`\n\n\nEnvironment module\n------------------\n\n* `environ.get_dot_target_name(version=None, module=None)`\n\n Returns the current version/module in `-dot-` notation which is used by `target:` parameters.\n\n* `environ.get_dot_target_name_safe(version=None, module=None)`\n\n Same as `environ.get_dot_target_name`, but this function returns `None` if there is no version or module found.\n\n* `environ.get_environ_dict()`\n\n Return a dictionary of all environment keys/values.\n\n* `environ.is_host_google()`\n\n True if the app is being hosted from Google App Engine servers.\n\n* `environ.is_development()`\n\n True if the dev_appserver is running (localhost or local development server).\n\n* `environ.is_staging(version=None)`\n\n True if the app is hosted by Google (appspot.com) but the version is not the default.\n\n* `environ.is_staging_safe(version=None)`\n\n Same as `environ.is_staging`, but returns `None` if there is no version found.\n\n* `environ.is_production(version=None)`\n\n True if the app is being hosted by Google and the default version.\n\n* `environ.is_production_safe(version=None)`\n\n Same as `environ.is_production`, but returns `None` if there is no version found.\n\n* `environ.is_default_version(version=None)`\n\n True if the current or specified app version is the default.\n\n* `environ.is_default_version_safe(version=None)`\n\n Same as `environ.is_default_version`, but returns `None` if there is no version found.\n\n* `environ.get_current_version_name_safe()`\n\n Wrapper around `google.appengine.api.modules.get_current_version_name`. Returns `None` if there is any error raised, otherwise it returns the current version name.\n\n* `environ.get_current_module_name_safe()`\n\n Wrapper around `google.appengine.api.modules.get_current_module_name`. Returns `None` if there is any error raised, otherwise it returns the current version name.\n\n\n", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/erichiggins/gaek", "keywords": "", "license": "BSD", "maintainer": "", "maintainer_email": "", "name": "gaek", "package_url": "https://pypi.org/project/gaek/", "platform": "", "project_url": "https://pypi.org/project/gaek/", "project_urls": { "Homepage": "https://github.com/erichiggins/gaek" }, "release_url": "https://pypi.org/project/gaek/0.4.0/", "requires_dist": [ "python-dateutil (>=2.4.2)" ], "requires_python": "", "summary": "A collection of useful tools for Python apps running on Google App Engine.", "version": "0.4.0" }, "last_serial": 3495106, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "cf802b06c0b15603ed81bf4511989567", "sha256": "8152f3d6f6d1173c98eb23c336ffc038beaa2cd6dda6b60e24a86ae52b5ec6b0" }, "downloads": -1, "filename": "gaek-0.1.0.tar.gz", "has_sig": false, "md5_digest": "cf802b06c0b15603ed81bf4511989567", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13364, "upload_time": "2015-06-30T21:40:25", "url": "https://files.pythonhosted.org/packages/c5/32/860a41611c5aec470759335cd101b4b02d26e74f501c7059b213afa04749/gaek-0.1.0.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "063ea9499eb3fa14a48b6928d818a20d", "sha256": "3067622d2f75be538f766ac2813a28df09cb3082920f4b9dd9abd9f0d082fd32" }, "downloads": -1, "filename": "gaek-0.1.1.tar.gz", "has_sig": false, "md5_digest": "063ea9499eb3fa14a48b6928d818a20d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13430, "upload_time": "2015-07-10T23:10:36", "url": "https://files.pythonhosted.org/packages/59/ac/fe55b12ac93a903ea4bd8526a528f831e23666c56d7a922b94d479d3da2e/gaek-0.1.1.tar.gz" } ], "0.1.2": [ { "comment_text": "built for Darwin-14.5.0", "digests": { "md5": "b901c860fcfb78f8663bdad348539155", "sha256": "a06335bb85b959abf72f27048be89d32c65349890af507b9a15370d71832df75" }, "downloads": -1, "filename": "gaek-0.1.2.macosx-10.10-intel.tar.gz", "has_sig": false, "md5_digest": "b901c860fcfb78f8663bdad348539155", "packagetype": "bdist_dumb", "python_version": "any", "requires_python": null, "size": 4872, "upload_time": "2015-10-12T20:48:52", "url": "https://files.pythonhosted.org/packages/e4/24/0faad75b85e3ab150591a127134ef0c7c2fb1a2a3ffbc8aeef46c8c6a079/gaek-0.1.2.macosx-10.10-intel.tar.gz" }, { "comment_text": "", "digests": { "md5": "fdd55fac2451e90b21146a81d6b68874", "sha256": "30a1d8b06dd86e728a42eb1c8a8bd7bccece216209685370092f48dc1785aeaf" }, "downloads": -1, "filename": "gaek-0.1.2.tar.gz", "has_sig": false, "md5_digest": "fdd55fac2451e90b21146a81d6b68874", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5540, "upload_time": "2015-10-12T20:48:47", "url": "https://files.pythonhosted.org/packages/88/36/2b4acc2c6bf7b3cf963c25615092a51c1e0af3402f03cffa47353b0233d3/gaek-0.1.2.tar.gz" } ], "0.2.1": [ { "comment_text": "", "digests": { "md5": "c49fae8d931aaa86af6e31380f442c07", "sha256": "b27e0bf843da1d77dacf6833490fb5d8645cfb53ad6535e4e1a77ab57ddb17c8" }, "downloads": -1, "filename": "gaek-0.2.1.tar.gz", "has_sig": false, "md5_digest": "c49fae8d931aaa86af6e31380f442c07", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7389, "upload_time": "2015-10-13T07:13:13", "url": "https://files.pythonhosted.org/packages/c8/15/f0c53718e4c07fedf04b6de4a1d1b041bc82cf9093b374b11ddf4b4edcb8/gaek-0.2.1.tar.gz" } ], "0.2.2": [ { "comment_text": "", "digests": { "md5": "0856b73b0e25bd8647f731c1f3e105c9", "sha256": "bf1945f8d552cac5eab1ef9f2b3ba7fc2358f0784be0844570217b62eeab912d" }, "downloads": -1, "filename": "gaek-0.2.2.tar.gz", "has_sig": false, "md5_digest": "0856b73b0e25bd8647f731c1f3e105c9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 131032, "upload_time": "2016-04-29T00:40:52", "url": "https://files.pythonhosted.org/packages/eb/0a/808c08cbf2bb7a8beff235cd6617922b8c131eee2b3afc041688b39b82dd/gaek-0.2.2.tar.gz" } ], "0.2.3": [ { "comment_text": "", "digests": { "md5": "fc5743b5b16f7bf69e53583a3067d362", "sha256": "e13a1579e7f3d270a9df07718d47a46229ba150ff37277ec218ac844f127168d" }, "downloads": -1, "filename": "gaek-0.2.3.tar.gz", "has_sig": false, "md5_digest": "fc5743b5b16f7bf69e53583a3067d362", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 131572, "upload_time": "2016-05-07T07:20:29", "url": "https://files.pythonhosted.org/packages/74/52/23121857a7c7f96cf7bd7e5ea2429e7865f0a517b941bf2a706b8a756c03/gaek-0.2.3.tar.gz" } ], "0.3.0": [ { "comment_text": "", "digests": { "md5": "4ea50122f3449b09f89393110f134464", "sha256": "adf33e15191002e7fe3dd65254aa5f6711829a8d0d9d6925d5de9ccfb0b0fe04" }, "downloads": -1, "filename": "gaek-0.3.0.tar.gz", "has_sig": false, "md5_digest": "4ea50122f3449b09f89393110f134464", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 157568, "upload_time": "2016-10-22T02:02:13", "url": "https://files.pythonhosted.org/packages/f7/ee/09275c677dd024291bd5216f941ccb116d772153fdde6607eda352909c94/gaek-0.3.0.tar.gz" } ], "0.4.0": [ { "comment_text": "", "digests": { "md5": "6027b88c3102505d04ef9d0283f21963", "sha256": "48e7413138e38c2b475e5f554fd8bf8b34c91adfbb650559c24dce1acfafb96c" }, "downloads": -1, "filename": "gaek-0.4.0-py2-none-any.whl", "has_sig": false, "md5_digest": "6027b88c3102505d04ef9d0283f21963", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 9253, "upload_time": "2018-01-16T19:50:14", "url": "https://files.pythonhosted.org/packages/5d/a3/800bc25645f7ce08cfd023af863d8e6e90997d4c542eabcae8185e761848/gaek-0.4.0-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "a0515e2646fc207a241bc987e9b7838f", "sha256": "1a7225cb693ad300f8b506ef005430ff5e77e792bd8c3ecd68f3762394247e42" }, "downloads": -1, "filename": "gaek-0.4.0.tar.gz", "has_sig": false, "md5_digest": "a0515e2646fc207a241bc987e9b7838f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 162134, "upload_time": "2018-01-16T19:50:16", "url": "https://files.pythonhosted.org/packages/d3/2c/322c6956954db7a228a4525db188d18e6b2a19715521a0b3c654d54796c3/gaek-0.4.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "6027b88c3102505d04ef9d0283f21963", "sha256": "48e7413138e38c2b475e5f554fd8bf8b34c91adfbb650559c24dce1acfafb96c" }, "downloads": -1, "filename": "gaek-0.4.0-py2-none-any.whl", "has_sig": false, "md5_digest": "6027b88c3102505d04ef9d0283f21963", "packagetype": "bdist_wheel", "python_version": "py2", "requires_python": null, "size": 9253, "upload_time": "2018-01-16T19:50:14", "url": "https://files.pythonhosted.org/packages/5d/a3/800bc25645f7ce08cfd023af863d8e6e90997d4c542eabcae8185e761848/gaek-0.4.0-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "a0515e2646fc207a241bc987e9b7838f", "sha256": "1a7225cb693ad300f8b506ef005430ff5e77e792bd8c3ecd68f3762394247e42" }, "downloads": -1, "filename": "gaek-0.4.0.tar.gz", "has_sig": false, "md5_digest": "a0515e2646fc207a241bc987e9b7838f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 162134, "upload_time": "2018-01-16T19:50:16", "url": "https://files.pythonhosted.org/packages/d3/2c/322c6956954db7a228a4525db188d18e6b2a19715521a0b3c654d54796c3/gaek-0.4.0.tar.gz" } ] }