Saravanan666/pypi-org huggingface dataset:
Package: django-table-sharding
Django table sharding is an app that will allow you to shard your database tables in the
same database using a shard key or shard suffix.Detailed documentation is in the “docs” directory.Quick startAdd “django_table_sharding” to your INSTALLED_APPS setting like this:INSTALLED_APPS = [
    ...
    'django_table_sharding',
]Every time migrations are run it will copy changes from the source
table to the sharded tables.Set the model manager to the models you want to shard into their own tables.
Example:objects = ShardManager()The migration process will automatically find all sharded models and apply the
new migrations.Sharded models can have ForeignKeys, but other models cannot foreign key to the sharded
models because original table is not used.Sharded models cannot contain OneToOneField, or ManyToManyField, for same reason.When running migrations the normal migration will run as normal, and then changes to source table,
will be applied to all shards in the database.Before deploying to production please make sure everything fits your needs.
Package: django-table-sort
Django-table-sortCreate tables with sorting links on the headers in Django templates.Documentation, including installation and configuration instructions, is available athttps://django-table-sort.readthedocs.io/.The Django Table Sort is released under the BSD license, like Django itself. If you like it, please considercontributing!InstallationFirst, install with pip:pipinstalldjango-table-sortSecond, add the app to your INSTALLED_APPS setting:INSTALLED_APPS=[...,"django_table_sort",...,]UsageFirst, add the static to your Template:<linkrel="stylesheet"href="{% static 'django_table_sort.css' %}"/>django-sort-tableuses by default Font Awesome 6 to display the icons, so you might need to add it too.<linkrel="stylesheet"href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.1.2/css/all.min.css"integrity="sha512-1sCRPdkRXhBV2PBLUdRb4tMg1w2YPf37qatUFeS7zlBy7jJI8Lf4VHwWfZZfpXtYSLy85pkm9GaYVYMfw5BC1A=="crossorigin="anonymous"referrerpolicy="no-referrer"/>Second, Usedjango-table-sortto display your tables.In yourview.pyfile:classListViewExample(ListView):model=Persontemplate_name:str="base.html"ordering_key="o"defget_ordering(self)->tuple:returnself.request.GET.getlist(self.ordering_key,None)# To make Django use the orderdefget_context_data(self,**kwargs):context=super().get_context_data(**kwargs)context["table"]=TableSort(self.request,self.object_list,sort_key_name=self.ordering_key,table_css_clases="table table-light table-striped table-sm",)returncontextIn yourtemplate.htmlfile:{{ table.render }}Result:The table is render with 2 link, one to Toggle the sort direction and another to remove the sort.You can filter by each field you declare as a column.
Package: django-tabula-auth
=====
Tabula AuthTabula Auth is a django authorization by Phone Number used in TabulaRassa products
Detailed documentation is in the "docs" directory.Quick startAdd "polls" to your INSTALLED_APPS setting like this::INSTALLED_APPS = [
...
'tabula_auth',
]Include the polls URLconf in your project urls.py like this::path('auth/', include(('tabula_auth.urls', 'tabula_auth'),
namespace='tabula_auth')),Runpython manage.py migrateto create the polls models.
Package: django-tabulate
=====Django Tabulate=====Django Tabulate is a simple app on top of Python tabulate, but for Django querysets.It allows us to to Pretty-print Django QuerySetsRequirements------------* **Python**: 2.7, 3.5* **Django**: 1.8, 1.11* **tabulate**: 0.8.1Tested on these, but should still work on all actively supported Python and Django versions.Installation------------Install using pip:.. code-block:: shpip install django-tabulateUsage-----You can use it as a function:.. code-block:: pythonfrom myapp.models import MyModelfrom django_tabulate import tabulate_qsprint tabulate_qs(MyModel.objects.all())+------+----------+|   id | name     ||------+----------||    1 | Python   ||    2 | Django   ||    3 | Tabulate |+------+----------+Or as a QuerySet mixin:.. code-block:: python#models.pyfrom django.db import modelsfrom django_tabulate import TabulateMixinclass MyModelQuerySet(models.QuerySet, TabulateMixin):passclass MyModel(models.Model):name = models.CharField(max_length=255)objects = MyModelQuerySet.as_manager()#then in the shellfrom myapp.models import MyModelprint MyModel.objects.all().tabulate()Settings-----------You can override all default tabulate settings via `TABULATE_DEFAULTS`.. code-block:: pythonTABULATE_DEFAULTS = {'tablefmt': 'psql'}For a complete list of all tabulate options take a look athttps://bitbucket.org/astanin/python-tabulate/overview
Package: django-tagconstants
django-tagconstantsDefine constants in your settings file, that are then made available in
your templates.InstallationFrom the command line:pip install django-tagconstantsAdd tagconstants to your installed apps:INSTALLED_APPS=(...'tagconstants',...)Create aTAG_CONSTANTSdictionary in yoursettings.pyfile:TAG_CONSTANTS={}UsageFor security purposes,tagconstantsis designed so that you create a
whitelist of variables to make available in your templates. For more
information see theDesign and Securitysection.To use a constant in your templates, first add the constant to yourTAG_CONSTANTSsetting:TAG_CONSTANTS={'CONSTANT':'SOME STRING',}Then in your templates, you can recall these constants with the{% constant ... %}template tag:{% load tagconstants %}

{% constant "CONSTANT" %}
    {# renders to 'SOME STRING' #}

{% constant "CONSTANT" as "variable_name" %}
    {# loads the template variable variable_name="SOME STRING" #}
    {# into the template context #}ContributingPull, fork, do whatever you’d like with the code.
Package: django-tag-fields
This is a clone ofJazzband django-taggitproject.By contributing you agree to abide by theContributor Code of Conduct.NoteThis project was cloned fromdjango-taggitv3.1.0and will continue to work in the same
way as that version.Over time I endeavor to extend django-taggit with individual field tagging.django-tag-fieldsa simpler approach to tagging with Django.  Add"tag_fields"to yourINSTALLED_APPSthen just add a TaggableManager to your model and go:fromdjango.dbimportmodelsfromtag_fields.managersimportTaggableManagerclassFood(models.Model):# ... fields heretags=TaggableManager()Then you can use the API like so:>>>apple=Food.objects.create(name="apple")>>>apple.tags.add("red","green","delicious")>>>apple.tags.all()[<Tag: red>, <Tag: green>, <Tag: delicious>]>>>apple.tags.remove("green")>>>apple.tags.all()[<Tag: red>, <Tag: delicious>]>>>Food.objects.filter(tags__name__in=["red"])[<Food: apple>, <Food: cherry>]Tags will show up for you automatically in forms and the admin.django-tag-fieldsrequires Django 3.2 or greater.For more info check out thedocumentation.For questions about usage or development you can create an issue on Github (if your question is about
usage please add thequestionlabel).
Package: django-tagging-autocomplete
django-tagging-autocomplete is a jquery based autocomplete solution for
django-tagging.Requirementsdjango-taggingSetupDownload package and install, for example using pip:pip install django-tagging-autocompleteAddtagging_autocompleteto installed apps in your project’s settings.Add the following line to your project’s urls.py file:(r'^tagging_autocomplete/', include('tagging_autocomplete.urls')),UsageThe Model FieldYou can useTagAutocompleteField()to enable autocompletion right in yourmodels.py. In most cases this is the easiest solution:from django.db import models
from tagging_autocomplete.models import TagAutocompleteField

class SomeModel(models.Model):
        tags = TagAutocompleteField()The Form WidgetAlternatively you can use theTagAutocomplete()form widget while creating
your form:from django import forms
from tagging.forms import TagField
from tagging_autocomplete.widgets import TagAutocomplete

class SomeForm(forms.Form):
    tags = TagField(widget=TagAutocomplete())Optional settingsBy default the maximum number of results suggested by the autocompletion is 100.
You can modify this number by adding to yoursettings.pyproject file
theTAGGING_AUTOCOMPLETE_MAX_RESULTSconstant.
For example:TAGGING_AUTOCOMPLETE_MAX_RESULTS = 5By default autocompletion suggests tags thatstart witha given term.
In case you need to show ones thatcontainthe given term,
setTAGGING_AUTOCOMPLETE_SEARCH_CONTAINStoTrue.
For example:TAGGING_AUTOCOMPLETE_SEARCH_CONTAINS = TrueBy default suggestions are shown right after you enter first character.
You can configure this behaviour usingTAGGING_AUTOCOMPLETE_MIN_LENGTH.
For example:TAGGING_AUTOCOMPLETE_MIN_LENGTH = 3
Package: django-tagging-autocomplete-new
django-tagging-autocomplete-newdjango-tagging-autocomplete-new is a jquery based autocomplete solution for
django-tagging.This is fixed version ofdjango-tagging-autocompleteby@ludwiktrammerfor Django 2.2.Requirementsdjango-taggingSetupInstall package from PyPI:pipinstalldjango-tagging-autocomplete-newAddtaggingandtagging-autocomplete-newto installed apps in your's project's settings:INSTALLED_APPS=[...'tagging','tagging_autocomplete_new','django.contrib.admin','django.contrib.auth','django.contrib.contenttypes','django.contrib.sessions','django.contrib.messages','django.contrib.sites','django.contrib.staticfiles',...]Add route to your project'surls.pyfile:path('tagging_autocomplete_new/',include('tagging_autocomplete_new.urls'))UsageThe Model FieldYou can useTagAutocompleteField()to enable autocompletion right in yourmodels.py. In most cases this is the easiest solution:fromdjango.dbimportmodelsfromtagging_autocomplete_new.modelsimportTagAutocompleteFieldclassSomeModel(models.Model):tags=TagAutocompleteField()The Form WidgetAlternatively you can use theTagAutocomplete()form widget while creating
your form:fromdjangoimportformsfromtagging.formsimportTagFieldfromtagging_autocomplete_new.widgetsimportTagAutocompleteclassSomeForm(forms.Form):tags=TagField(widget=TagAutocomplete())Optional settingsBy default the maximum number of results suggested by the autocompletion is 100.
You can modify this number by adding to yoursettings.pyproject file
theTAGGING_AUTOCOMPLETE_MAX_RESULTSconstant.
For example:TAGGING_AUTOCOMPLETE_MAX_RESULTS=5By default autocompletion suggests tags thatstart witha given term.
In case you need to show ones thatcontainthe given term,
setTAGGING_AUTOCOMPLETE_SEARCH_CONTAINStoTrue.
For example:TAGGING_AUTOCOMPLETE_SEARCH_CONTAINS=TrueBy default suggestions are shown right after you enter first character.
You can configure this behaviour usingTAGGING_AUTOCOMPLETE_MIN_LENGTH.
For example:TAGGING_AUTOCOMPLETE_MIN_LENGTH=3
Package: django-tagging-translated
Registers theTagmodel ofdjango-taggingforsimple-translationand
extends the Tag admin.InstallationPrerequisites:Djangodjango-taggingsimple-translationIf you want to install the latest stable release from PyPi:$ pip install django-tagging-translatedIf you feel adventurous and want to install the latest commit from GitHub:$ pip install -e git://github.com/bitmazk/django-tagging-translated.git#egg=tagging_translatedAddtagging_translatedto yourINSTALLED_APPS:INSTALLED_APPS = (
    ...,
    'tagging_translated',
)Run the South migrations:./manage.py migrate tagging_translatedUsageWhen you create tags, for example via the Entry admin of cmsplugin-blog,
the english translation will be generated automatically. You can use it in
your templates like so:{% load i18n simple_translation_tags %}

{% with tag|get_preferred_translation_from_request:request as tag_title %}
<p>{{ tag_title.trans_name }}</p>
{% endwith %}RoadmapCheck the issue tracker on github for milestones and features to come.
Package: django-taggit
This is aJazzbandproject. By contributing you agree
to abide by theContributor Code of Conductand follow theguidelines.django-taggita simpler approach to tagging with Django.  Add"taggit"to yourINSTALLED_APPSthen just add a TaggableManager to your model and go:fromdjango.dbimportmodelsfromtaggit.managersimportTaggableManagerclassFood(models.Model):# ... fields heretags=TaggableManager()Then you can use the API like so:>>>apple=Food.objects.create(name="apple")>>>apple.tags.add("red","green","delicious")>>>apple.tags.all()[<Tag: red>, <Tag: green>, <Tag: delicious>]>>>apple.tags.remove("green")>>>apple.tags.all()[<Tag: red>, <Tag: delicious>]>>>Food.objects.filter(tags__name__in=["red"])[<Food: apple>, <Food: cherry>]Tags will show up for you automatically in forms and the admin.django-taggitrequires Django 3.2 or greater.For more info check out thedocumentation. And for questions about usage or
development you can create an issue on Github (if your question is about
usage please add thequestiontag).
Package: django-taggit-anywhere
Even more simpler approach to tagging withdjango-taggit. Additionally this project provides easy-to-use
integration withdjango-taggit-helpersanddjango-taggit-labelsInstallationFirst install the module, preferably in a virtual environment. It can be installed from PyPI:pipinstalldjango-taggit-anywhereRequirementsYou must havedjango-taggitinstalled and configured, see thedjango-taggitdocumentation for details and setup instructions.SetupMake sure the project is configured fordjango-taggit.You’ll need to addtaggit_anywhereas aLASTitem toINSTALLED_APPSin your project’ssettings.pyfile:INSTALLED_APPS+=[# optional integration with django-taggit-helpers'taggit_helpers',# pip install django-taggit-helpers# optional integration with django-taggit-labels'taggit_labels',# pip install django-taggit-labels'taggit_anywhere',# must be last in a list]There is only one mandatory configuration option you need to set in yoursettings.py:TAGGIT_FOR_MODELS=['<app_name>.<model_name>',]Please seeexampleapplication. This application is used to manually test the functionalities of this package. This also serves as good example…You need Django 1.8 or above to run that. It might run on older versions but that is not tested.ContributingIf you like this module, forked it, or would like to improve it, please let us know!
Pull requests are welcome too. :-)Licensedjango-taggit-anywhereis released under the MIT license.
Package: django-taggit-autocomplete
This is a fork of django-tagging-autocomplete, which can be found at:http://code.google.com/p/django-tagging-autocomplete/It’s virtually the same app, only it’s changed to work with django-taggit:http://github.com/alex/django-taggit* Installation *You need to have django-taggit already installedDownload django-taggit-autocomplete and use setup.py to install it on your system:python setup.py installDownload jquery-autocomplete and put it in the folder specified in your project’s MEDIA_URL setting. If you want to put it somewhere else add TAGGIT_AUTOCOMPLETE_JS_BASE_URL to your project settings.Add “taggit_autocomplete” to installed apps in your project’s settings.Add the following line to your project’s urls.py file:(r’^taggit_autocomplete/’, include(‘taggit_autocomplete.urls’)),* Usage *** Using the model field **You can use TaggableManager to enable autocompletion right in your models.py file. In most cases this is the easiest solution. Example:from django.db import models
from taggit_autocomplete.managers import TaggableManagerclass SomeModel(models.Model):tags = TaggableManager()
Package: django-taggit-autocomplete-modified
django-taggit-autocomplete-modifiedAuthor:George NotarasDevelopment Web Site:django-taggit-autocomplete-modified projectSource Code Repository:django-taggit-autocomplete-modified source codeDocumentation:django-taggit-autocomplete-modified documentationDownloads:django-taggit-autocomplete-modified releasesDESCRIPTION_DESCRIPTION_DESCRIPTIONLicensed under theApache License version 2.0. More licensing information
exists in thelicensesection.FeaturesFeature AFeature BDocumentationApart from thedjango-taggit-autocomplete-modified Online Documentation, more information about the
installation, configuration and usage of this application may be available
at the project’swiki.DonationsThis software is released as free-software and provided to you at no cost. However,
a significant amount of time and effort has gone into developing this software
and writing this documentation. So, the production of this software has not
been free from cost. It is highly recommended that, if you use this softwarein production, you should consider making a donation.To make a donation, please visit the CodeTRAXdonations pagewhich contains
aPayPaldonatebutton.Thank you for considering making a donation to django-taggit-autocomplete-modified.Bugs and feature requestsIn case you run into any problems while using this application or think that
a new feature should be implemented, it is highly recommended yousubmita new
report about it at the project’sissue tracker.Using theissue trackeris the recommended way to notify the authors about
bugs or make feature requests. Also, before submitting a new report, please
make sure you have read thenew issue guidelines.SupportCodeTRAX does not provide support for django-taggit-autocomplete-modified.You can still get community support at theCommunity Support Forums:LicenseCopyright 2011 George Notaras <gnot [at] g-loaded.eu>Licensed under theApache License, Version 2.0(the “License”);
you may not use this file except in compliance with the License.Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an “AS IS” BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.A copy of the License exists in the product distribution; theLICENSEfile.
For copyright and other important notes regarding this release please read
theNOTICEfile.
Package: django-taggit-autosuggest
Disclaimer: This project is unmaintained since I don’t use it myself anymore
and I did not find a maintainer within the user base so far.
However, I’m happy to accept pull requests!* Credits *This project is directly based on those projects:
* Alex Gaynor,https://github.com/alex/django-taggit* Ludwik Trammer,http://code.google.com/p/django-tagging-autocomplete/* Jeremy Epstein,https://github.com/Jaza/django-taggit-autocomplete* Flavio Curella,https://github.com/fcurella/django-taggit-autocomplete* Drew Wilson,http://code.drewwilson.com/entry/autosuggest-jquery-plugin* Installation *Add “taggit_autosuggest” to your INSTALLED_APPS in your project settingsRun “python manage.py collectstatic” in your django site dir.Add the following line to your project’s urls.py file:(r’^taggit_autosuggest/’, include(‘taggit_autosuggest.urls’)),* Settings *TAGGIT_AUTOSUGGEST_STATIC_BASE_URL:Instead of collecting and serving the static files directly, you can
also set this variable to your static base URL somewhere else.TAGGIT_AUTOSUGGEST_MAX_SUGGESTIONS (Defaults to 20):The amount of suggestions is limited, you can raise or lower the limit
of default 20 using this setting.TAGGIT_AUTOSUGGEST_CSS_FILENAME (Defaults to ‘autoSuggest.css’):Set the CSS file which best fits your site elements.The CSS file have to be in ‘jquery-autosuggest/css/’.TAGGIT_AUTOSUGGEST_MODELS (Defaults to tuple(‘taggit’,’Tag’))The Tag model used, if you happen to use Taggit custom tagging.* Usage *To enable autosuggesting Tags, just let the tagged model use TaggableManager:from django.db import models
from taggit_autosuggest.managers import TaggableManagerclass SomeModel(models.Model):tags = TaggableManager()To use autosuggesting Tags outside of Django Admin pages ensure that the static
files are added to the template’s <head>, either hardcoded, e.g.<link href=”{{ STATIC_URL }}jquery-autosuggest/css/autoSuggest-upshot.css”type=”text/css” media=”all” rel=”stylesheet” /><script type=”text/javascript”src=”{{ STATIC_URL }}jquery-autosuggest/js/jquery.autoSuggest.minified.js”>
</script>or by adding the form/formset’s media attribute to the template’s context
(this is what happens in Django Admin), e.g.# In the view:
context.update({‘media’: form.media})  # or however you add to the context# In the template:
{{ media }}(Either way, of course, the template must also include a jQuery library.)If Taggit custom tagging is used the autosuggested Tags can be filtered by
attributes of the request object after the name filtering. To enable this
the custom tag model should have a function called request_filter which
takes a request object and returns a django.db.models.Q object, e.g.from django.db import modelsclass MyTag(TagBase):@staticmethod
def request_filter(request):return models.Q(…)There’s a demo project using Grappelli bundled, you can run it and browse
/admin/ using the username ‘demo’ and password ‘demo’.
Package: django-taggit-forms
=============django-taggit-forms=============.. image:: https://travis-ci.org/akiraakaishi/django-taggit-forms.svg?branch=master:target: https://travis-ci.org/akiraakaishi/django-taggit-forms.. image:: https://coveralls.io/repos/akiraakaishi/django-taggit-forms/badge.svg?branch=master:target: https://coveralls.io/r/akiraakaishi/django-taggit-forms?branch=master.. image:: https://codeclimate.com/github/akiraakaishi/django-taggit-forms/badges/gpa.svg:target: https://codeclimate.com/github/akiraakaishi/django-taggit-forms/badges/gpa.svg``django-taggit-forms`` handles form submissions to create a tag by use of the ``django-taggit`` package.Usage======Add ``'taggit_forms'`` to your ``INSTALLED_APPS``.(Make sure that ``taggit`` and ``django.contrib.contenttypes`` are also included in ``INSTALLED_APPS``.)In your root ``urls.py``, include ``'taggit_forms.urls'`` with the namespace ``'taggit_forms'``... code:: pythonurlpatterns = patterns('',# your urlsurl(r'^taggit_forms/', include('taggit_forms.urls', namespace='taggit_forms')),)Then, create your model to be tagged with:.. code:: pythonclass MyModel(models.Model):tags = TaggableManager()Then, in your templates, render a tag-creation form for an instance of ``MyModel`` with the template tag ``render_tag_form``::{% load taggitforms%}{% render_tag_form my_obj %}The form is rendered with the template ``taggit_forms/form.html``.Altenatively, use the template tag ``get_tag_form`` to assign the form as a context variable::{% get_tag_form my_obj as tag_form %}{% for field in tag_form %}{{ field }}{% endfor %}