Saravanan666/pypi-org huggingface dataset:
Package: djorm-ext-pgfulltext
Pgfulltext module of django orm extensions package (collection of third party plugins build in one unified package).Now compatible with python2 and python3 with same code base.Ready for django 1.3, 1.4, 1.5 and 1.6IntroductionFull Text Searching (or just text search) provides the capability to identify natural-language documents that satisfy a query, and optionally to sort them by relevance to the query. The most common type of search is to find all documents containing given query terms and return them in order of their similarity to the query. Notions of query and similarity are very flexible and depend on the specific application. The simplest search considers query as a set of words and similarity as the frequency of query words in the document. (From postgresql documentation.)Classesdjorm_pgfulltext.fields.VectorFieldAn tsvector index field which stores converted text into special format.djorm_pgfulltext.models.SearchManagerDjango manager that contains helper methods for search and re/genereate indexes.How to use itTo use it, you will need to add a new field. Obviously, this is not mandatory, as it can specify which fields you want to search at the time of calling thesearch. Keep in mind that you should put the corresponding indices for the fields to be used.fromdjorm_pgfulltext.modelsimportSearchManagerfromdjorm_pgfulltext.fieldsimportVectorFieldfromdjango.dbimportmodelsclassPage(models.Model):name=models.CharField(max_length=200)description=models.TextField()search_index=VectorField()objects=SearchManager(fields=('name','description'),config='pg_catalog.english',# this is defaultsearch_field='search_index',# this is defaultauto_update_search_field=True)The manager automatically injectedupdate_search_fieldmethod to the model instance.
Also, not to override the save method, you can pass the parameterauto_update_search_field = True, so
the index field  is updated automatically by calling thesavemethod.Usage examples:The config parameter is optional and defaults to ‘pg_catalog.english’.The fields parameter is optional. If a list of tuples, you can specify the ranking of each field, if it is None, it gets ‘D’ as the default.It can also be a simple list of fields, and the ranking will be selected by default. If the field is empty, the index was applied to all fieldsCharFieldandTextField.To search, use thesearchmethod of the manager. The current implementation, by default uses unaccent extension for ignore the accents. Also, the searches are case insensitive.>>>Page.objects.search("documentation & about")[<Page:Page:Homepage>]>>>Page.objects.search("about | documentation | django | home",raw=True)[<Page:Page:Homepage>,<Page:Page:About>,<Page:Page:Navigation>]FTS extension by default uses plainto_tsquery instead of to_tosquery, for this reason the use of raw parameter.General notes:You must ensure you have installed the extensionunaccent:CREATEEXTENSIONunaccent;ALTERFUNCTIONunaccent(text)IMMUTABLE;You can install this extension on template1 database for make this extension automatically available for all new created databases.Changelog0.9Fix django 1.6 compatibility (transaction management).
Package: djorm-ext-pgtrgm
djorm-ext-pgtrgm================Django pgtrgm is a Django application with some addons regarding PostgreSQL trigram(or trigraph) text comparisonA trigram is a group of three consecutive characters taken from a string. We canmeasure the similarity of two strings by counting the number of trigrams they share.This simple idea turns out to be very effective for measuring the similarity of wordsin many natural languages.For example, the set of trigrams in the string "cat" is " c", " ca", "cat", and "at ".With this extension, we could use this feature inside Django ORM with a simpleQuerySet filter keywordIt is distributed under the terms of the [GNU Lesser General PublicLicense](http://www.gnu.org/licenses/lgpl.html)PostgreSQL syntax-----------------`text % text` -> boolean Returns true if its arguments have a similarity that is greaterthan the current similarity threshold set by set_limit.[How to install and use pg_trgm extension in PostgreSQL 9.2](http://www.postgresql.org/docs/9.2/static/pgtrgm.html)Requeriments------------- Django 1.5 (or higher). It's possible that works with other versions lower 1.5- Postgres `pg_trgm` extension. In debian/ubuntu: `sudo apt-get install postgres-contrib`Installation------------- In your `settings.py````pythonINSTALLED_APPS = ('djorm_pgtrgm',)```- You need to *register* the extension in your database. Run `./manage.py dbshell` and then execute:```sqlCREATE EXTENSION pg_trgm;```- Optionally, you can create an index over a text column for the purpose of very fast similarity searches. For example, supose you will filter a lot over the field`description` of the model `myapp.Product`:```sqlCREATE INDEX desctiption_trgm_idx ON myapp_product USING gist (description gist_trgm_ops);```Usage-----------Adds a new query set filter keyword to allow text searching.```pythonMyModel.objects.filter(field_name__similar='whatever')```To ensure results ordered by similarity, you could do this:```pythonMyModel.objects.filter(field_name__similar='whatever').extra(select={'distance': "similarity(name, 'whatever')"}).order_by('-distance'))```In a sake of brevity, you could use a provided `SimilarManager` that has a `filter_o`method.```pythonfrom djorm_pgtrgm import SimilarManagerclass MyModel(models.Model):objects = SimilarManager()# your fields...````filter_o` is a shortcut for the `filter + extra + order_by` in the snippet above.```pythonMyModel.objects.filter_o(field_name__similar='whatever')```So, this will return every similar `MyModel` instance with a `field_name` *similar*to `'whatever'` and sorted by the distance ot each intance's `field_name` value to target `'whatever'`. In addition, an extra field `field_name_distance` is addedto each item in the queryset.Development-----------You can get the last version of djorm-ext-pgtrgm by doing a cloneof its repository:git clone git://github.com/jleivaizq/djorm-ext-pgtrgm.git0.0.1  (2013-10-23)===================* First version to djorm-ext-pgtrgm
Package: djorm-ext-pool
DB-API2 connection poolling for Django.DescriptionIs a simple application that uses the excellent SQLAlchemy connection pool to incorporate a it to django. All work is based onhttps://github.com/kennethreitz/django-postgrespool/Note:currently only been tested with postgresql, but in theory it should work perfectly with mysql and sqlite3.How to installRunpython setup.py installto install, or placedjorm_poolon your Python path.You can also install it with:pip installdjorm-ext-poolHow use it?Very simple, putdjorm_poolin yourINSTALLED_APPSsettings:# settings.pyINSTALLED_APPS=('djorm_pool',...)You can add options to sqlalchemy connection pool adding them in the settings “DJORM_POOL_OPTIONS”.Example:DJORM_POOL_OPTIONS={"pool_size":20,"max_overflow":0,"recycle":3600,# the default value}Also, can activate the pessimistic connection handling withDJORM_POOL_PESSIMISTIC:# With this settings, every checkout of a connection from a pool# executes an additional query for check the connection state.DJORM_POOL_PESSIMISTIC=True
Package: djorm-hstore-editor
================djorm-hstore-editor================Поле модели с удобным виджетом для редактирования плоского массива HStoreУстановка==========* Добавьте hstore_editor в INSTALLED_APPS* Замените поле DictionaryField из состава djorm-ext-hstore на `hstore_editor.fields.DictionaryField`* Выполните python manage.py collectstaticПример:-------.. image:: http://habrastorage.org/storage2/94c/2aa/60b/94c2aa60b99d1f6110d82a7b26d60bc5.png
Package: djorum
Simple Django ForumDocumentationThe full documentation is athttps://djorum.readthedocs.orgQuickstartInstall djorum:pip install djorumThen use it in a project:import djorumFeaturesTODO** Everyting.Cookiecutter Tools Used in Making This Packagecookiecuttercookiecutter-djangopackageHistory0.1.0 (2015-11-01)First release on PyPI.0.1.0 (2015-10-07)Added requirements to setup
Package: djoser
REST implementation ofDjangoauthentication
system.djoserlibrary provides a set ofDjango Rest Frameworkviews to handle basic actions such as registration, login, logout, password
reset and account activation. It works withcustom user model.Instead of reusing Django code (e.g.PasswordResetForm), we reimplemented
few things to fit better intoSingle Page Apparchitecture.Developed bySUNSCRAPERSwith passion & patience.RequirementsTo be able to rundjoseryou have to meet the following requirements:Python>=3.8Django>=3.0.0Django REST Framework>=3.12InstallationSimply install usingpip:$pipinstalldjoserAnd continue with the steps described atconfigurationguide.DocumentationDocumentation is available to study athttps://djoser.readthedocs.ioand indocsdirectory.Contributing and developmentTo start developing ondjoser, clone the repository:$gitclonegit@github.com:sunscrapers/djoser.gitWe usepoetryas dependency management and packaging tool.$cddjoser$poetryinstall--all-extrasThis will create a virtualenv with all development dependencies.To run the test just type:$poetryrunpy.testtestprojectWe also prepared a convenientMakefileto automate commands above:$makeinit$maketestTo activate the virtual environment run$poetryshellWithout poetryNew versions ofpipcan usepyproject.tomlto build the package and install its dependencies.$pipinstall.[test]$cdtestproject$./manage.pytestExample projectYou can also play with test project by running following commands:$makemigrate$makerunserverCommiting your codeBefore sending patches please make sure you havepre-commitactivated in your local git repository:$pre-commitinstallThis will ensure that your code is cleaned before you commit it.Similar projectsList of projects related to Django, REST and authentication:django-rest-registrationdjango-oauth-toolkitPlease, keep in mind that while using custom authentication and TokenCreateSerializer
validation, there is a path thatignores intentional return of Nonefrom authenticate()
and try to find User using parameters. Probably, that will be changed in the future.
Package: djoser-edge
NOTE: this is a modified version of djoser that support drf-yasgREST implementation ofDjangoauthentication
system.djoserlibrary provides a set ofDjango Rest Frameworkviews to handle basic actions such as registration, login, logout, password
reset and account activation. It works withcustom user model.Instead of reusing Django code (e.g.PasswordResetForm), we reimplemented
few things to fit better intoSingle Page Apparchitecture.Developed bySUNSCRAPERSwith passion & patience.RequirementsTo be able to rundjoseryou have to meet following requirements:Python (3.5, 3.6, 3.7, 3.8)Django (1.11, 2.2)Django REST Framework (3.9, 3.10)If you need to support other versions, please use djoser<2.InstallationSimply install usingpip:$pipinstalldjoserAnd continue with the steps described atconfigurationguide.DocumentationDocumentation is available to study athttps://djoser.readthedocs.ioand indocsdirectory.Contributing and developmentTo start developing ondjoser, clone the repository:$gitclonegit@github.com:sunscrapers/djoser.gitIf you are apipenvuser you can quickly setup testing environment by
using Make commands:$makeinit$maketestOtherwise, if you cannot use Make commands, please create virtualenv and install
requirements manually:$pipinstalldjangodjangorestframework$pipinstall-rrequirements.txt$cdtestproject$./manage.pytestIf you need to run tests against all supported Python and Django versions then invoke:$pipinstalltox$tox-pallYou can also play with test project by running following commands:$./manage.pymigrate$./manage.pyrunserverSimilar projectsList of projects related to Django, REST and authentication:django-rest-framework-simplejwtdjango-oauth-toolkitdjango-rest-authdjango-rest-framework-digestauth(not maintained)
Package: dj-pagination
dj-paginationHow to use dj-paginationSee our official documentation for more details.http://dj-pagination.readthedocs.io/Support this Project!This project is run by a voluntees. Please support them in their efforts to maintain and improve Cookiecutter Django:pydanny on GitHubProjects that provide financial support to the maintainer:Django Crash Course 3.xTwo Scoops of Django 3.xAbout the forkThis project is a fork of the "django-pagination" project
originally written by 'Eric Florenzano' then forked by the Linaro
Validation/Infrastructure team. Latest releases can be found on pypi.About top-level package name changeThe top level package name was changed frompaginationtolinaro_django_paginationtodj_pagination. Following the Linaro pattern
I did this to ensure that existing users of the original package could easily
transition, on their own terms. Since both packages are co-installable you
are free to check things out and see if the new pagination code works well for
you or not.Since the implementation of the actual tags were rewritten since the
django-pagination days it's fairly certain the new package is a NOT a
drop-in replacement.
Package: dj-paginator
A super-simple set of pagination tools for Django 1.8+DocumentationThe full documentation will soon be athttps://dj-paginator.readthedocs.org.FeaturesSuper simple code base.Easy to create and switch themes.Really good documentation! (coming soon)Really good tests! (coming soon)Class-Based View mixin so you don’t need to load template tags (coming soon)QuickstartInstall dj-paginator:pip install dj-paginatorIn your installed apps:INSTALLED_APPS = [
    'paginator'
]In your list view:class MyListView(ListView):
    model = MyModel
    paginate_by = 10In your list view template:{% load paginator_tags %}

{% paginator %}Done!Switching to a new theme method 1# Currently defaults to bootstrap.
# I'll add foundation soon.
PAGINATOR_THEME = 'foundation'Switching to a new theme method 2{% load paginator_tags %}

{# Is the default #}
{% bootstrap_paginator %}

{# For when I add the foundation theme#}
{% foundation_paginator %}History0.1.0 (2015-07-26)First release on PyPI.Inception
Package: dj.paste
IntroductionYet anotherpastefactories for djangoContentsIntroductionMakina Corpus sponsored softwareWhat is dj.pasteHow to use dj.pasteDjango Appdjango factoryChangelog1.14 (2012-02-22)1.10 (2012-02-22)1.81.3 - 1.41.21.0Makina Corpus sponsored softwarePlanet Makina CorpusContact usWhat is dj.pasteIt is just anotherPythonPaste applicationswsgi wrappers:dj.paste#monoor onlydj.paste:A paste factory to use when you have only one django on your instancedj.paste#multiA paste factory to use when you have more than one django on your instance
but be careful that there is a fakeDjangoModule trick that can lead to problems (not seen so far)How to use dj.pasteDjango AppWith paste, just add another app entry with a django_settings_module  variable to point to
your django settings[composite:main]
use = egg:Paste#urlmap
/ = foo

[app:foo]
use=egg:dj.paste
django_settings_module=foo.settingsdjango factoryChecking that everything is in place:>>> resp = app.get('/')
>>> 'first django' in resp.body.lower()
TrueChangelog1.14 (2012-02-22)add weberror wrapper1.10 (2012-02-22)proper release1.8add a mono factory (and now the default)cleanup1.3 - 1.4fix multiple djangos in the same paste instance1.2fix script_path, seehttp://code.djangoproject.com/ticket/15161.0Initial release
Package: djpasty
Description===========Djpasty makes it easy to run Django with the Paste_ web-server. Itdoes this by providing a management command which (just like`runserver`) starts the web-server.The server directly serves the media folder. This makes it an idealsolution for small sites or applications for which easy of deploymentis more important than raw performance.When serving the static files it looks at the `MEDIA_ROOT` and`MEDIA_URL` settings. Make sure that the `MEDIA_URL` looks like`/media/` and not like `http://nohost/media/`. Admin media will betaken care of automatically.
Package: dj-paypal
dj-paypalA Paypal integration for Django, inspired bydj-stripe.Currently only supports subscriptions.RequirementsPython 3.6+Django 3.1+Postgres 9.6+ (Non-postgres engines not supported)InstallationInstall dj-paypal withpip install dj-paypalAdddjpaypalto djangoINSTALLED_APPSsettingGet a client ID and client secret from paypal and add them to the settingsPAYPAL_CLIENT_IDandPAYPAL_CLIENT_SECRETSetPAYPAL_MODE = "sandbox"(or"live") in the settingsInstall your Billing Plans (see below)Setting up billing plansDownload already-created billing plans from PaypalRunmanage.py djpaypal_download_plansto sync all plans already created upstream
into the local database.This will createdjpaypal.models.BillingPlanobjects, which can be listed from
the Django admin.Creating new Paypal billing plansThemanage.py djpaypal_upload_plansmanagement command creates billing plans using
the Paypal API. An extraPAYPAL_PLANSsetting must be set, which will contain a dict
of Paypal billing plans to create.Seeexample_settings.pyfor an example of plans to create.WebhooksThedjpaypal.views.ProcessWebhookViewview should be hooked up to an URL endpoint
which you then set up in Paypal as a webhook endpoint (https://developer.paypal.com).In order to verify webhooks being transmitted to your app, dj-paypal needs to know the
ID of the webhook that is expected at that URL. Set it in the settingPAYPAL_WEBHOOK_ID.Sandbox vs. LiveAll models have alivemodeboolean attribute. That attribute is set toTrueif created
in Live (production) mode,Falseotherwise (sandbox mode).
Sandbox and Live data can co-exist without issues. Once you are done testing in Sandbox
mode, use themanage.py djpaypal_delete_all_test_datamanagement command to (locally)
clear all the test data. This command has no impact on the upstream data.Data considerationsMost of the models defined in dj-paypal are copies of the upstream Paypal model data.
Deleting or editing objects (be it from the admin or in the database) does not actually
change any of the upstream Paypal data.License and SponsorshipThis project was designed and developed byHearthSim. It is
licensed under the MIT license. The full license text is available in the LICENSE file.
Package: dj-places
django-placesA Django app for store places with autocomplete function and a related map to the selected place.QuickstartInstalldj-placesand add it to your installed apps:$ pip install dj-placesINSTALLED_APPS = (
    	...
    	'places',
    	...
    )Add the following settings and maps api key (read more here):PLACES_MAPS_API_KEY='YourAwesomeUltraSecretKey'PLACES_MAP_WIDGET_HEIGHT=480PLACES_MAP_OPTIONS='{"center": { "lat": 38.971584, "lng": -95.235072 }, "zoom": 10}'PLACES_MARKER_OPTIONS='{"draggable": true}'UsageThen use it in a project:fromdjango.dbimportmodelsfromplaces.fieldsimportPlacesFieldclassMyLocationModel(models.Model):location=PlacesField()This enables the following API:>>>frommyapp.modelsimportModelName>>>poi=ModelName.objects.get(id=1)>>>poi.positionPlace('Metrocentro, Managua, Nicaragua',52.522906,13.41156)>>>poi.position.place'Metrocentro, Managua, Nicaragua'>>>poi.position.latitude52.522906>>>poi.position.longitude13.41156For using outside the Django Admin:<formmethod="post">{% csrf_token %}
    {{ form.as_p }}<inputtype="submit"value="Save">{{ form.media }}</form>Remember to add the{{ form.media }}in your template.DemoCreditsTools used in rendering this package:Cookiecuttercookiecutter-djangopackagejquery-geocomplete(no longer used in the project.)Similar ProjectsDjango Location FieldDjango GeoPosition
Package: dj-plotly-dash
dj-plotly-dashDash is a Python framework for building analytical web applications. No JavaScript required.It's fork of PlotlyDash.Here’sa example of view of Django Dash App(original example with Flask) that ties a Dropdown to a D3.js Plotly Graph.
As the user selects a value in the Dropdown, the application code dynamically
exports data from Google Finance into a Pandas DataFrame.Dash app code is declarative and reactive, which makes it easy to build complex apps that contain many interactive elements. Here’s an example (original example with Flask) with 5 inputs, 3 outputs, and cross filtering. This app was composed in just 160 lines of code, all of which were Python.Dash usesPlotly.jsfor charting. Over 35 chart types are supported, including maps.Dash isn't just for dashboards. You have full control over the look and feel of your applications. Here's a Dash app that's styled to look like a PDF report.To learn more about Dash, read theextensive announcement letterorjump in with the user guide.UsageSee examples of usage intests/django_projectInstallation$pipinstalldj-plotly-dash[all]$pipinstall"dash_core_components>=0.40.2"--no-deps
$pipinstall"dash_html_components>=0.14.0"--no-depsDocumentationView theDash User Guide. It's chock-full of examples, pro tips, and guiding principles.LicenseMIT
Package: djplus
Why does this package exist?Because 80% of customer projects have common apps
such as authentication, store, admin, blog, forum, academy, etc.
Therefore, as freelancers, we decided to code all these apps only once in one place
and use them in different projects as often as desired,
and all these apps can be customized by the settings of each project.
This helps to save our time and increase our income in exchange for doing projects.InstallingYou can use pip to installdjplusfor usage:pipinstalldjplusUsageCreate ProjectSimple command line for jumpstarting production-ready Django projects:djorpython-mdjAuth#settings.pyINSTALLED_APPS=[# ..."dj.auth",# ...]MIDDLEWARE=[# ...'dj.auth.middleware.AuthenticationMiddleware',# ...]# urls.pyurlpatterns=[# ...path("auth/",include("dj.auth.urls",namespace="auth")),# ...]Blog#settings.pyINSTALLED_APPS=[# ..."dj.blog",# ...]# urls.pyurlpatterns=[# ...path("blog/",include("dj.blog.urls",namespace="blog")),# ...]ContributingContributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make aregreatly appreciated.If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement".
Don't forget to give the project a star! Thanks again!Fork the ProjectCreate your Feature Branch (git checkout -b feature/AmazingFeature)Commit your Changes (git commit -m 'Add some AmazingFeature')Push to the Branch (git push origin feature/AmazingFeature)Open a Pull Request
Package: dj-postgres-stats
Django Postgres Stats exposes statistical and datetime functions specific to
Postgres to Django without making the user write raw SQL. The plan is to
expand the library over time to cover many Postgres-specific functions. For
now, only functions personally used by the authors have been added.Detailed documentation is in the “docs” directory.Quick startAdd “postgres_stats” to your INSTALLED_APPS setting like this:INSTALLED_APPS = (
    ...
    'postgres_stats',
)Import the functions you need to use with your models.