Saravanan666/pypi-org huggingface dataset:
Package: django-lti-toolbox
Django-lti-toolbox, a Django application to build LTI Tool ProvidersOverviewdjango-lti-toolboxis a django application that makes it easier for you to createLTITool Providers web applications.This is a set of tools that let you manage LTI requests the way you want.It is based on top of the greatOAuthLiblibrary.FeaturesVerify LTI launch requestsBase views to build your own LTI launch request handlersSample Django authentication backendManage your LTI consumers from django adminDemo project to quickly see it in actionTry it with our demo project !Clone this repository (git clone https://github.com/openfun/django-lti-toolbox.git)cd django-lti-toolboxmake bootstrapto initialize the dev environmentmake runto start the servicesGo tohttp://localhost:8090/and try the demo LTI consumerWatch django logs withmake logsContributingThis project is intended to be community-driven, so please, do not hesitate to
get in touch if you have any question related to our implementation or design
decisions.We try to raise our code quality standards and expect contributors to follow
the recommandations from ourhandbook.LicenseThis work is released under the MIT License (seeLICENSE).
Package: django-ltree
django-ltreeA tree extension implementation to support hierarchical tree-like data in Django models,
using the native Postgres extensionltree.Postgresql has already a optimized and very useful tree implementation for data.
The extension isltreeThis fork contains a backport to Django 1.11 and Python 2.7.LinksPypihttps://pypi.org/project/django-ltree/Source codehttps://github.com/mariocesar/django-ltreeBugshttps://github.com/mariocesar/django-ltree/issuesContributehttps://github.com/mariocesar/django-ltree/pullsDocumentationTODOInstallpip install django-ltreeThen adddjango_ltreetoINSTALLED_APPSin your Django project settings.And make sure to rundjango_ltreemigrations before you added thePathFieldpython manage.py migrate django_ltreedjango_ltreemigrations will install theltreeextension if not exist.You can alternatively specify thedjango_ltreedependency in the migrations of
your applications that requiresPathField, and run migrations smoothly.class Migration(migrations.Migration):
    dependencies = [
            ('django_ltree', '__latest__'),
    ]RequiresDjango 1.11 or superiorPython 2TestingMake sure you have Postgres installed. Then simply runtoxin the root directory of the project.
Package: django-ltree-2
django-ltreeA tree extension implementation to support hierarchical tree-like data in Django models,
using the native Postgres extensionltree.Postgresql has already a optimized and very useful tree implementation for data.
The extension isltreeThis fork contains is a continuation of the work done bymariocesarondjango-ltreeand merges the work done bysimkimsiaongreendeploy-django-ltreeInstallpipinstalldjango-ltreeThen adddjango_ltreetoINSTALLED_APPSin your Django project settings.INSTALLED_APPS=[...,'django_ltree',...]Then use it like this:fromdjango_ltree.modelsimportTreeModelclassCustomTree(TreeModel):...RequiresDjango 5.0 or superiorPython 3.10 or higherRoadmapsWrite documentation on how to use this repository. (If you need a quick way to check things, please check thetests/test_model.pyfile)
Package: django-ltree-field
Minimalist Django Field for the PostgreSQL ltree Type.django-ltree-field attempts to make very few assumptions about your use case.For a higher level API based on django-ltree-field, consider using a prebuilt model fromdjango-ltree-utils.Itshouldbe possible to re-implement thedjango-treebeardAPI,
allowing for drop-in compatibility, but that is not a specific goal at this time. If someone starts this, let me know and I
will provide some assistance.DocumentationThe full documentation is athttps://django-ltree-field.readthedocs.io.QuickstartInstall PostgreSQL LTreeField for Django:pip install django-ltree-fieldAdd it to yourINSTALLED_APPS:INSTALLED_APPS=(...'django_ltree_field',...)Add an LTreeField to a new or existing model:fromdjango_ltree_field.fieldsimportLTreeFieldclassSimpleNode(models.Model):path=LTreeField(index=True,unique=True)classMeta:ordering=['path']FeaturesImplementsonlythe bare minimum to make the ltree PostgreSQL type usableLTreeField accepts a string of dotted labels, or a list of labelsThe ltree type is adapted to a Python listRelatively complete set of lookups and transforms.Non-FeaturesDoes not implement an abstract “Node” model which has a nicer API (See django-ltree-utils for ready-made classes and managers)Does virtually no sanity checking. You can insert nodes without roots, and generally put the tree in a bad statePostgreSQL compatibility onlyFuture FeaturesI will happily acceptminimalfeatures required to make the field be reasonably usable. In particular, every operator,
function, and example on theofficial PostgreSQL docsshould be implemented with Django’s ORM, with no RawSQL or non-idiomatic code.Higher-level or richer features should be contributed todjango-ltree-utils.
As a rule of thumb, if an operation requires referencing more than one row at a time, or maintaining some more complicated
state, it probably belongs there.Running TestsYou need to have a reasonably updated version of PostgreSQL listening on port 5444. You can usedocker-composeto start a serverdocker-compose upDoes the code actually work?source <YOURVIRTUALENV>/bin/activate
(myenv) $ pip install -r requirements.txt -r requirements_test.txt --upgrade
(myenv) $ ./runtests.pyHistory0.1.5CI/CD with Github ActionsUpdated docs0.1.0 (2021-03-24)First release on PyPI.
Package: django-ltree-fork
django-ltreeAn tree extension implementation to support hierarchical tree-like data in Django models,
using the native Postgres extensionltree.Postgresql has already a optimized and very useful tree implementation for data.
The extension isltreeThis fork contains a backport to Django 1.11 and Python 2.7.LinksPypihttps://pypi.org/project/django-ltree/Source codehttps://github.com/boryszef/django-ltreeBugshttps://github.com/boryszef/django-ltree/issuesContributehttps://github.com/boryszef/django-ltree/pullsDocumentationTODOInstallpip install django-ltreeThen adddjango_ltreetoINSTALLED_APPSin your Django project settings.And make sure to rundjango_ltreemigrations before you added thePathFieldpython manage.py migrate django_ltreedjango_ltreemigrations will install theltreeextension if not exist.You can alternatively specify thedjango_ltreedependency in the migrations of
your applications that requiresPathField, and run migrations smoothly.class Migration(migrations.Migration):
    dependencies = [
            ('django_ltree', '__latest__'),
    ]RequiresDjango 1.11 or superiorPython 2TestingMake sure you have Postgres installed. Then simply runtoxin the root directory of the project.
Package: django-ltree-utils
Your project description goes hereDocumentationThe full documentation is athttps://django-ltree-utils.readthedocs.io.QuickstartInstall django-ltree-utils:pip install django-ltree-utilsAdd it to yourINSTALLED_APPS:INSTALLED_APPS=(...'django_ltree_utils.apps.DjangoLtreeUtilsConfig',...)Add django-ltree-utils’s URL patterns:fromdjango_ltree_utilsimporturlsasdjango_ltree_utils_urlsurlpatterns=[...url(r'^',include(django_ltree_utils_urls)),...]FeaturesTODORunning TestsYou need to have a reasonably updated version of PostgreSQL listening on port 5444. You can usedocker-compose <https://docs.docker.com/compose/>to start a serverdocker-compose upDoes the code actually work?source <YOURVIRTUALENV>/bin/activate
(myenv) $ pip install -r requirements.txt -r requirements_test.txt --upgrade
(myenv) $ ./runtests.pyDevelopment commandspip install -r requirements_dev.txt
invoke -lCreditsTools used in rendering this package:Cookiecuttercookiecutter-djangopackageHistory0.1.0 (2021-03-29)First release on PyPI.
Package: django-luhublog
=====Luhu Blog=====Luhu Blog es una app Django simple para crear blogLa documentación detallada está en el directorio "docs".Comienzo rápido---------------1. Agregar "luhublog" al setting INSTALLED_APPS::INSTALLED_APPS = (...'luhublog','froala_editor',)2. Incuir el URLconf de polls en el urls.py del proyecto::url(r'^blog/', include('luhublog.urls')),url(r'^froala_editor/', include('froala_editor.urls')),3. Correr `python manage.py syncdb` para crear los modelos de luhublog.4. Levantar el servidor de desarrollo y visitar http://127.0.0.1:8000/admin/para crear una entrada de blog (es necesario tener la app Admin habilitada).5. Visitar http://127.0.0.1:8000/blog/ para ver el blog.Incluid en la plantilla base entre el head{% block seo_meta %}{% endblock seo_meta %}Añadir en 'context_processors'context_processors: [...'luhublog.context_processors.blog_info'...],
Package: django-luigi
=====luigi=====Luigi is a simple Django app to be able to link Django to the workflow manager luigi.Quick start-----------1. Add 'django_luigi' to you INSTALLED_APPS settings like this::INSTALLED_APP = [...'django_luigi',]2. Create your `app` and `models` in Django as usual3. Run `python manage.py migrate` to create the models.You can know create objects in your luigi pipeline.Assuming a django model Test in the test app with two CharField, item1, and item2, properly migrated.. code-block:: pythonfrom django.db import modelsclass Test(models.Model):item1 = models.CharField(max_length=120)item2 = models.CharField(max_length=120)Here is a minimal example of a job to copy data to database using Django :.. code-block:: pythonimport luigifrom django_luigi.django import ToORMclass TestTask(ToORM):django_root = 'path_to_your_django_root' # Where manage.py issettings_path = 'my_site.settings'model = 'Test'app = 'test'def rows(self):for row in [("item1", "property1"), ("item2", "property2")]:yield rowif __name__ == '__main__':task = TestTask()luigi.build([task], local_scheduler=True)In the above examples, the data that needs to be copied was directly provided byoverriding the rows method. Alternately, if the data comes from another task, themodified example would look as shown below:.. code-block:: pythonimport luigifrom django_luigi.django import ToORMfrom luigi.mock import MockTargetclass BaseTask(luigi.Task):def output(self):return MockTarget("BaseTask")def run(self):out = self.output().open("w")TASK_LIST = ["item%d\\tproperty%d\\n" % (i, i) for i in range(1,3)]for task in TASK_LIST:out.write(task)out.close()class TestTask(ToORM):django_root = 'path_to_your_django_root' # Where manage.py issettings_path = 'my_site.settings'model = 'Test'app = 'test'def requires(self):return BaseTask()if __name__ == '__main__':task1, task2 = TestTask(), BaseTask()luigi.build([task1, task2], local_scheduler=True)
Package: django-lumberjack
Simple logging to the database for django projects.
Log entries are viewed in admin.Note: Be sparing with the number of messages logged to the database.  It is
convenient when you want events logged that can be viewed in the django admin,
but logging excessively to the database can cripple performance.RequirementsDjango 1.7 or greater.InstallInstall package:pip install django-lumberjackAdd'lumberjack'to yourINSTALLED_APPS:# settings.py

INSTALLED_APPS = (
    'django.contrib.admin',
    'django.contrib.auth',
    ...
    'lumberjack',
)Add handler and logger configs:# settings.py

LOGGING = {
    ...
    'handlers': {
        'lumberjack_handler': {
            'level': 'DEBUG',
            'class': 'lumberjack.handlers.DBHandler',
        },
    },
    'loggers': {
        'lumberjack': {
            'handlers': ['lumberjack_handler'],
        },
    }
}Create database tables:$ ./manage.py migrate lumberjackUsageExample of logging in a view function:# views.py

import logging

logger = logging.getLogger('lumberjack')

def someview(request):

    logger.debug('someview was called', [__name__, 'sometag'])

    ...

    try:
        # some action
        ...

    except:
        logger.error('some action failed', [__name__, 'fml'])
Package: django-macaddress-ng
django-macaddress================PS: This repository is merged back to original repository http://github.com/tubman/django-macaddress . I'm the new maintainer for that repository.Please use and/or submit patches in there... image:: https://api.travis-ci.org/kra3/django-macaddress-ng.png?branch=master:alt: Build Status:target: https://travis-ci.org/kra3/django-macaddress-ng.. image:: https://pypip.in/v/django-macaddress-ng/badge.png:target: https://crate.io/packages/django-macaddress-ng.. image:: https://pypip.in/d/django-macaddress-ng/badge.png:target: https://crate.io/packages/django-macaddress-ngMAC Address model and form fields for DjangoWe use netaddr to parse and validate the MAC address.  The tests aren'tcomplete yet.Added support for Admin search. More features are in queue.Forked from `@tubaman <https://github.com/tubaman>`_
Package: django_maccman
MAccMan is a reusable django application to facilitate easy management of email accounts, mailboxes, and aliases.MAccMan is currently under heavy development and not suited for production use.Support notesCurrently mailman is being tested and developed on PostgreSQL only. There are some specific code snippets that assume that PostgreSQL is used as a backend. This will change in the future.RequirementsPostgreSQL 9.0 or later with pgcrypto activated for the desired database (tested with 9.5)django-cryptofield (available via pip)Quick startMake sure you are using PostgreSQL 9.0 or later (tested with 9.5)Add the mailman application to your projectsINSTALLED_APPSsetting like so:INSTALLED_APPS = [
    ...,
    'maccman',
]Run./manage.py migrateto create the required models and viewsStart the development server and connect to the admin interface. From there you can configure aliases, mailboxes, etc.Configure your postfix and dovecot instances to use the following views:postfix_alias (Contains alias to destination mappings)postfix_domain (Contains all active domains)postfix_mailbox (Contains all active mailboxesdovecot_iterate (Contains all active users)dovecot_password (Contains username to password mappings for all active users)dovecot_user (Contains address to maildir mappings for all active users)DovecotMAccMan employs the cryptographic functionalities built into PostgreSQL to secure the users passwords. Therefore, you need to let the databse verify the passwords. To this, you will need the followingWHEREclause in your dovecot SQL statement:WHERE user = '%u' AND password = crypt('%w', password);This allows the database backend to verify the password and only returns as user when the passwords match. In addition to thisWHEREclause, you will need to select the following fields:... NULL AS password, 'Y' AS nopassword ...For more information, please refer to the excellent dovecot documentationLicenseMAccMan is published under the terms and coditions of the 3-Clause-BSD-License
Package: django-machina
Django-machina is a forum framework for Django providing a way to build community-driven websites.
It offers a full-featured yet very extensible forum solution:Topic and post editingForums tree managementPer-forum permissionsAnonymous postingPolls and attachmentsModeration and pre-moderationForum conversations search…Django-machina was built with integration in mind: the application is designed to be used inside
existing Django applications. It is not a standalone forum solution.Django-machina was built with customization and extensibility in mind: each single functionality
of the application can be customized or overriden to accommodate with your needs.Table of ContentsDocumentationRequirementsAuthorsLicenseDocumentationOnline browsable documentation is available athttps://django-machina.readthedocs.org.Head over to the documentation for all the details on how to set up your forum and how to customize
it to suit your needs.RequirementsPython 3.6+, Django 3.2+. Please refer to therequirementssection of the documentation for a full
list of dependencies.AuthorsMorgan Aubert (@ellmetha) andcontributors. SeeAUTHORSfor
more details.LicenseBSD. SeeLICENSEfor more details.
Package: django-machine-learning-user-interface
*This package is intended to help developers quickly build scalable and customisable front end user interfaces for machine learning models. You can start using this package by following these 5 easy steps:*<br/>
<br/>*Step 1: Install and Setup*1.1. Open up a new working directory and create a virtual environment by running this commandpython -m venv envon the comand prompt.
<br/>1.2. RunenvScriptsactivateto activate the virtual environment.
<br/>1.3. Install the Django machine learning user interface package by runningpip install django-machine-learning-user-interface.
<br/>1.4. Runcd envLibsite-packagessrcto find the package files.
<br/>1.5. Open up the files on a code editor e.g. VsCode.
<br/>1.6. Intall project requirments by runningpip install -r requirements.txton the comand prompt.
<br/>
<br/>*Step 2: Secrete Key*2.1. Genrate a secrete key. You can use get one here:https://djecrety.ir/.
<br/>2.2. Create a .env file in src and store you secrte key inside.
<br/>2.3. Make sure to label itSECRET_KEY.
<br/>
<br/>*Step 3: Inputs*3.1. Navigate tosrcinput.
<br/>3.2. Inside the input file create a folder and call itmodelthen copy your pickle model file (e.g ‘titanic.pkl’) into this folder.
<br/>3.3. In theforms.pyfile populate the classIndexFormas specified in the code comments.
<br/>3.4. In theparams.pyfile specify the name of the target variable (e.g. ‘Passenger Status’) and the name of the model (e.g ‘titanic.pkl’).
<br/>
<br/>*Step 4: Views*4.1. Navigate tosrcinterfaceviews.py.
<br/>4.2. Add the cleaned form data as specified (line 21).
<br/>4.3. List the x variables as specified (line 30).
<br/>4.4. If your model is a classification model, edit line 41 as specified.
<br/>
<br/>*Step 5: Generate the UserInterface*5.1. On the comand prompt runpython manage.py runserver.
<br/>5.2. Go to local host on your browser(http://127.0.0.1:8000/) and you should see your application and be able to interact with your application.
<br/>
Package: django-madcap-flare
Simple integration tools to link to embedded Madcap Flare helpInstallationInstall the Madcap Flare integration from PyPi:pip install django-madcap-flareand add it to your settings.py:INSTALLED_APPS=[...'madcap_flare',...]You will also need to configure the`MADCAP_FLARE_ROOTandMADCAP_FLARE_TAGS<#configuring>`__UsageYou can convert Madcap Flare header files into a Python dict with theget_help_mappingcommand:python manage.py get_help_mapping path_to_file.hThis will output a dict on the command line that you can copy into your
settings.py file.ConfiguringTo setup your template tags, take the output ofget_help_mappingand
set it to theMADCAP_FLARE_TAGSin settings.py:MADCAP_FLARE_TAGS={'my-help-topic':'1000','other-help-topic':'2000',}MADCAP_FLARE_ROOT='https://www.example.com/help_topics/'TheMADCAP_FLARE_ROOTsetting tells Django what to use for your host
name and default path.View MixinTo inject your information into your templates, you can use the view
mixin for Madcap Flare:fromdjango.views.genericimportListViewfrommadcap_flare.viewsimportMadcapFlareMixinfrommyproject.myapp.modelsimportMyModelclassMyListView(MadcapFlareMixin,ListView):"""Sample list view.
    """help_key='my-help-topic'queryset=MyModel.objects.all()The MadcapFlareMixin injects thehelp_keyobject into your template
context.Template TagThemadcap_flare_helptemplate tag outputs a Madcap Flare URL that
can be linked from your templates:{% load madcap_flare_tags %}<p>To get more help on this feature, see our<ahref="{% madcap_flare_help %}">documentation</a></p>With thehelp_keyset above, this will output:<p>To get more help on this feature, see our<ahref="https://www.example.com/help_topics/Default.htm#cshid=1000">documentation</a></p>DevelopingTo test the integration just run:virtualenvvenv.venv/bin/activatepipinstall-rrequirements.txtpythonsetup.pydeveloppythontests/manage.pytestWriting Docs for PyPITo convert the docs to RST for PyPI:pandoc--from=markdown--to=rst--output=README.txtREADME.md
Package: django-magicadmin
Django Magic AdminThis is a plugin to facilitate django-admin login through magic links.RequirementsDjango 4.X or higherAn E-mail service provider such as SMTP, Sendgrid or others configured on settings.pyInstallationpip install django-django_magicadminon your systemAdd the following URL and include it in your mainurls.pypath("", include("django_magicadmin.urls")),Add the app to your INSTALLED_APPSINSTALLED_APPS = [
    "django_magicadmin",
    ...
]If you want custom settings about Sender address, Domain, etc, use the following fields and add them to your settings.py:MAGICADMIN_DEFAULT_EXPIRATION = 10800 # default
MAGICADMIN_DEFAULT_MAGIC_LINK_SUBJECT = "Here is your magic link to login!" # default
MAGICADMIN_CURRENT_WEBSITE = localhost
MAGICADMIN_DEFAULT_SENDER_EMAIL = magiclink@localhostPro tips:Here are some tips that will enable a better experience for youPro tip #1:If you want to develop using the magic link functionality, I recommend you
the Django Terminal E-mail Backend, which enables you to see all of the messages sent through the system.Just add this one-liner to your settings.py:EMAIL_BACKEND = "django.core.mail.backends.console.EmailBackend"Pro tip #2:To override with custom e-mail templates, override the files:emails/magiclogin.htmlandemails/magiclogin.txt
Package: django-magic-cards
Django Magic Cards is a pluggable Django app for the Oracle text of all Magic: the Gathering cards.DocumentationThe full documentation is athttps://django-magic-cards.readthedocs.io.QuickstartInstall the package:pip install django-magic-cardsAdd the app to yourINSTALLED_APPS:INSTALLED_APPS=(...'magic_cards.apps.MagicCardsConfig',...)Add Django Magic Cards’ tables to your the database:./manage.py migrate magic_cardsPopulate the card database:./manage.py import_magic_cardsAcknowledgmentsMTGJSONfor providing up-to-date card data.Cookiecutterandcookiecutter-djangopackagefor providing the structure for this project.DisclaimerThe literal and graphical information presented in this software about Magic: the Gathering, including Oracle text and card images, is copyright Wizards of the Coast, LLC, a subsidiary of Hasbro, Inc. This project is not produced by, endorsed by, supported by, or affiliated with Wizards of the Coast.History0.4.1 (2017-10-26)Improve Unicode handling on Python 2, allowing the Printings admin
page to load properly (#27).0.4.0 (2017-10-04)Update aCard’s data (text, loyalty, types, etc.) when a set is re-imported (#23).0.3.0 (2017-09-28)Store planeswalkers’ starting loyalty (#19).Correctly populate flavor text.Fix issue that crashed re-importing a set without multiverse IDs.0.2.0 (2017-08-16)Speed up import function (#9).Implement basic admin pages (#7).0.1.1 (2017-08-10)Increase maximum length of aCard’sname(#2).0.1.0 (2017-08-08)First release on PyPI.
Package: django-magic-db-router
=====Django-magic-db-router=====Django-magic-db-router is an app to allow Django system can auto pick random database for read/write, generally!The key feature is we can use dedicated database for code block, this will usefull for transaction handler!Quick start-----------1. Install the app:pip install django-magic-db-router2. Config your settings file, for example:DJANGO_MAGIC_DB_ROUTER_READ_DB_LIST=['REPLICA1', 'REPLICA2', 'REPLICA3',]DJANGO_MAGIC_DB_ROUTER_WRITE_DB_LIST=['default',]DATABASE_ROUTERS = ['django_magic_db_router.DynamicDbRouter']3. For using dedicated database for code block, use: `in_database`with in_database(db_name, write=True):some_code()========================================================================================