Saravanan666/pypi-org huggingface dataset:
Package: django-args
django-argsis theDjangowrapper onpython-args.python-argsprovides the ability to decorate functions with validators,
context, and default value processors.django-argstakes this a
step further, allowing any function decorated withpython-argsto
seamlessly integrate with Django form views and form wizards.For example,djarg.views.FormViewautomatically constructs a DjangoFormViewon a python function and maps the form fields to the
function arguments. Assuming the function is wrapped witharg.validators,django-argswill seamlessly bind
the validators to the form. This same concept is extended to bulk
views and form views offered bydjango-args.Along with this,django-argsalso helps eliminate the burden
of passing around variables from views to forms for doing simple
initializations (choice fields, etc) and other boilerplate that
can become difficult to follow as a project grows.Check out thedocsfor
more information on how you can usedjango-argsfor your
project.DocumentationView the django-args docs here.InstallationInstall django-args with:pip3 install django-argsAfter this, adddjargto theINSTALLED_APPSsetting of your Django project.Contributing GuideFor information on setting up django-args for development and
contributing changes, viewCONTRIBUTING.rst.Primary Authors@wesleykendall (Wes Kendall)
Package: django-ariadne-jwt
Support for JWT based authentication for use with theariadnegraphql library
running inside aDjangoproject. It is heavily inspired bydjango-graph-jwt.Installationpip install django-ariadne-jwtHow to usedjango-ariadne-jwtaims to be easy to install and use.First addJSONWebTokenBackendto yourAUTHENTICATION_BACKENDSAUTHENTICATION_BACKENDS=["django_ariadne_jwt.backends.JSONWebTokenBackend",# Any other authentication backends..."django.contrib.auth.backends.ModelBackend",]Then addJSONWebTokenMiddlewareto your viewfromdjango_ariadne_jwt.middlewareimportJSONWebTokenMiddlewareurlpatterns=[# Your other paths...path("graphql/",csrf_exempt(GraphQLView.as_view(schema=schema,middleware=[JSONWebTokenMiddleware()])),name="graphql")]Or to your queries:ariadne.graphql_sync(schema,{"query":"""
        query {
            test
        }
        """},middleware=[JSONWebTokenMiddleware()],)And then add thelogin_decoratorto your resolvers before adding the field:fromdjango_ariadne_jwt.decoratorsimportlogin_required@query_type.field("test")@login_requireddefresolve_test(*args):...This will prevent the field from resolving andariadnewill add an error to
the query result.Finally add the type definitions and resolvers to the executable schemafromdjango_ariadne_jwt.resolversimport(auth_token_definition,auth_token_verification_definition,resolve_token_auth,resolve_refresh_token,resolve_verify_token,)type_definitions="""
  ...

  type Mutation {
    ...
    tokenAuth(username: String!, password: String!): AuthToken!
    refreshToken(token: String!): AuthToken!
    verifyToken(token: String!): AuthTokenVerification!
    ...
  }
"""auth_type_definitions=[auth_token_definition,auth_token_verification_definition,]resolvers=[...]auth_resolvers=[resolve_token_auth,resolve_refresh_token,resolve_verify_token,]schema=ariadne.make_executable_schema([type_definitions]+auth_type_definitions,resolvers+auth_resolvers)Once you get an auth token, set the HTTP Authorization header to:Token <token>How to contributedjango-ariadne-jwtis at a very early stage. It is currently
missing documentation, better testing and a lot of configuration options. Pull
requests with any of these are greatly appreciated.django-ariadne-jwtis missing feature XFeel free to open an issue or create a pull request with the implementation
Package: django-aries-community
Aries Community is a simple Django framework for building
Hyperledger Indy/Aries Agent enabled web applications.
Detailed documentation is in the “docs” directory.Please seehttps://github.com/AnonSolutions/django-aries-communityfor detailed docmentationQuick startYou can find a basic Aries Community application herehttps://github.com/AnonSolutions/aries-community-demoTo add aries_community to your own django application:Copy the requirements.txt file into your application directory and install requirementsAdd “aries_community” to your INSTALLED_APPS setting like this:INSTALLED_APPS=[...'aries_community',]Add the following Indy configuration settings (this is for a local install):importplatformdeffile_ext():ifplatform.system()=='Linux':return'.so'elifplatform.system()=='Darwin':return'.dylib'elifplatform.system()=='Windows':return'.dll'else:return'.so'ARIES_CONFIG={'storage_config':{'url':'localhost:5432'},'storage_credentials':{'account':'postgres','password':'mysecretpassword','admin_account':'postgres','admin_password':'mysecretpassword'},'register_dids':True,'ledger_url':'http://localhost:9000','genesis_url':'http://localhost:9000/genesis','default_enterprise_seed':'aries_community_enterprise_00000','default_institution_seed':'aries_community_institution_0000','managed_agent_host':'localhost','webhook_host':'localhost','webhook_port':'8000',}Ensure your local templates are loaded first:TEMPLATES=[{...'DIRS':[os.path.join(BASE_DIR,'<your app>/templates'),],...},]Override User, Organization and Relationship models, if you have your own subclass of these models:AUTH_USER_MODEL='aries_community.IndyUser'ARIES_ORGANIZATION_MODEL='aries_community.IndyOrganization'ARIES_ORG_RELATION_MODEL='aries_community.IndyOrgRelationship'Include the indy URLconf in your project urls.py like this:path('aries/',include('aries_community.urls')),Ensure you have all pre-requisites running, as per django-aries-community docsRunpython manage.py migrateto create the indy models.Runpython manage.py runserverand connect tohttp://localhost:8000/You can customize the UI and add event handling for Aries Connection and Messaging events.  See the demos inhttps://github.com/AnonSolutions/aries-community-demofor examples of how to do this.View detailed documentation in the Docs directory (https://github.com/AnonSolutions/django-aries-community)
Package: django-arkid
# 一账通ArkID是全新一代企业单点登录解决方案, 彻底告别企业内多系统多账号的烦恼, 节省管理成本, 自带功能全面的WEB管理界面，提升管理效率。更多细节参见 [docs.arkid.longguikeji.com](https://docs.arkid.longguikeji.com)## 功能特性### 兼容各种常见协议, 让每个应用都可以连接LDAPOAuthOpenID(即将开放)SAML(即将开放)HTTP API### 丰富的账号与分组管理灵活高效的管理企业内部账号与分组支持一键钉钉导入### 完备的权限管理细粒度的权限管理，让企业没有管理不到的权限账号权限分组权限应用白名单，黑名单应用内权限### 工作台(Workspace)每位员工均拥有自己的工作台，一键访问业务系统### 自定义登陆UI名称、LOGO、主题色，让登陆页面彰显企业文化## 项目说明[arkid-frontend](https://github.com/longguikeji/arkid-frontend): 前端代码[arkid-core](https://github.com/longguikeji/arkid-core): 后端核心以及其他[arkid-broker](https://github.com/longguikeji/arkid-broker): 一账通部署在ArkOS中的服务Broker## DEMOhttps://arkid.demo.longguikeji.com` 用户名: admin 密码: longguikeji `## Screenshots![image](https://raw.githubusercontent.com/skoogi/charts/assets/assets/login.png)![image](https://raw.githubusercontent.com/skoogi/charts/assets/assets/ucenter.png)![image](https://raw.githubusercontent.com/skoogi/charts/assets/assets/admin.png)## 文档[完整文档](https://docs.arkid.longguikeji.com)[接口文档](https://oneid1.docs.apiary.io/#)## 部署我们推荐基于Kubernetes的环境部署，官方helm charts参考: [Charts](https://github.com/longguikeji/arkid-charts)## Issues请通过[Github Issues](https://github.com/longguikeji/arkid-core/issues)给我们提交问题## Changelog[Release Notes](https://github.com/longguikeji/arkid-core/releases)## Contact[Website](https://www.longguikeji.com)技术交流 QQ 群 （167885406）## License[LGPL-3.0](https://opensource.org/licenses/LGPL-3.0)Copyright (c) 2019-present, 北京龙归科技有限公司
Package: django-array-field-select
A replacement for Django’s ArrayField with a multiple select form field.  This
only makes sense if the underlying base_field is using choices.How To UseReplace all instances of your Django ArrayField model field with the new
ArrayField.  No functionality will be changed, except for the form field.Examplefromdjango.dbimportmodelsfromarray_field_select.fieldsimportArrayFieldclassStudent(models.Model):YEAR_IN_SCHOOL_CHOICES=(('FR','Freshman'),('SO','Sophomore'),('JR','Junior'),('SR','Senior'),)years_in_school=ArrayField(models.CharField(max_length=2,choices=YEAR_IN_SCHOOL_CHOICES))
Package: django-array-field-select-multiple
AcknowledgementThis is a fork of the original code written by Silver Logic,
availablehere.AboutA replacement for Django's ArrayField with a multiple select form field.Please note that this selector makes sense only if the underlying base_field is using choices.Installationpipinstalldjango-array-field-select-multipleHow To UseReplace all instances of your Django'sArrayFieldmodel field with the newArrayField. No functionality will be changed, except for the form field.Examplefromdjango.dbimportmodelsfromarray_field_select.fieldsimportArrayFieldclassStudent(models.Model):YEAR_IN_SCHOOL_CHOICES=(('FR','Freshman'),('SO','Sophomore'),('JR','Junior'),('SR','Senior'),)years_in_school=ArrayField(models.CharField(max_length=2,choices=YEAR_IN_SCHOOL_CHOICES))
Package: django-article
django-article^^^^^^^^Note: This project is still under-development.Author: 234082230@qq.comIntroduction---------- Added Article model- Added ArticleAdmin, ArticleManager- Added Article list, detail api- Added Article list, detail viewsettings.py---------::INSTALLED_APPS = [...'django_article',...]TEMPLATES = [{...'DIRS': ['templates'],...}]urls.py---------::from django.conf import settingsfrom django.conf.urls import url, includefrom django.conf.urls.static import staticfrom django.contrib import adminfrom django.views.i18n import JavaScriptCatalogfrom django_article.views.user import UserLoginView, UserLogoutView, UserRegisterViewurlpatterns = [url(r'^jsi18n/$', JavaScriptCatalog.as_view(), name='javascript-catalog'),url(r'^admin/', admin.site.urls),url(r'^article/list/', ArticleListView.as_view()),url(r'^article/(?P<aid>[0-9]+)/$', ArticleDetailView.as_view()),url(r'^api/article/', include('django_article.urls', namespace='django-article')),] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
Package: django-articles-addons
Author:Colin PowellDate:2011-04-26by:One Cardinal Web Developmentlicense:GPLv3Big chunks of thie projects were taken from @andrewebdev’s excellent adzone project. What was need though, was much less of a full-featured ad management app, but just a way to provide on-site link throughs to miscellaneous content.In other words, I wanted on-site ads that wouldn’t get caught by the adblockers and didn’t keep track of advertisers or categories or other junk like that. Just some text or an image, linked to a specific url.
Package: django-arvestust
Django Arvestustarvestustis a django app file management and record-keeping.Dependenciesarvestustdepends on django itself,django-crispy-forms, andpython-magic.ModelsThe app is split into three main models:commentfilefollowlikesavetagInstallationAddarvestustto yourINSTALLED_APPSsetting like this::INSTALLED_APPS=[# other apps...'arvestust',]Alternatively, you can also add this app like so::INSTALLED_APPS=[# other apps...'arvestust.apps.ArvestustConfig',]Include the polls URLconf in your project urls.py like this::path('records/',include('arvestust.urls',namespace='arvestust')),2.1. Optionally, you can also add the api endpoints in your project urls.py like so::path('api/',include('arvestust.api',namespace='arvestust_api')),Runpython manage.py migrateto create the app models.Start the development server and visithttp://127.0.0.1:8000/admin/to start adding objects (you'll need the Admin app enabled).Visithttp://127.0.0.1:8000/records/to use the app.5.1. If you've included the api urls as well, you can visit the endpoints by visiting:http://127.0.0.1:8000/api/...LicensearvestustisBSD-Licensed.Built withdjango-clite.Developed and maintained byLeo Neto
Package: django-asgi-lifespan
Django ASGI Handler with Lifespan protocol supportDocumentation:https://illagrenan.github.io/django-asgi-lifespanPyPI:https://pypi.org/project/django-asgi-lifespan/License: MITFeaturesThis package contains a subclass of the standard DjangoASGIHandlerthat can
handleASGI Lifespan Protocol. (Note: there is no change in handling HTTP requests.)StartupandShutdownLifespan events are
converted toDjango signals.Signalreceivers can be awaited. This way it is possible for example to
createaiohttp ClientSession/httpx clientwhen the application starts and close these resources safely when
the application shuts down. This concept is similar to events in
FastAPI (https://fastapi.tiangolo.com/advanced/events/).Quickstart:warning: This package is experimental. Lifespan signals work correctly only under uvicorn.To install this package run:Python 3.10, 3.11 and 3.12 are supported, with Django 4 and 5.$pipinstall--upgradedjango-asgi-lifespan#or$poetryadddjango-asgi-lifespan@latestModifyasgi.pyto use a ASGI Lifespan compatible handler.fromdjango_asgi_lifespan.asgiimportget_asgi_applicationdjango_application=get_asgi_application()asyncdefapplication(scope,receive,send):ifscope["type"]in{"http","lifespan"}:awaitdjango_application(scope,receive,send)else:raiseNotImplementedError(f"Unknown scope type{scope['type']}")Subscribe your (async) code to theasgi_startupandasgi_shutdownDjango signals that are sent when the server starts/shuts down.See usagefor a more advanced code sample.importasyncioimporthttpxHTTPX_CLIENT=None_signal_lock=asyncio.Lock()asyncdefcreate_httpx_client():globalHTTPX_CLIENTasyncwith_signal_lock:ifnotHTTPX_CLIENT:HTTPX_CLIENT=httpx.AsyncClient()asyncdefclose_httpx_client():ifisinstance(HTTPX_CLIENT,httpx.AsyncClient):awaitasyncio.wait_for(asyncio.create_task(HTTPX_CLIENT.aclose()),timeout=5.0)fromdjango.appsimportAppConfigfromdjango_asgi_lifespan.signalsimportasgi_shutdown,asgi_startupfrom.handlers_quickstartimportclose_httpx_client,create_httpx_clientclassExampleAppConfig(AppConfig):defready(self):asgi_startup.connect(create_httpx_client)asgi_shutdown.connect(close_httpx_client)Use some resource (in this case the HTTPX client) e.g. in views.fromdjango.httpimportHttpResponsefrom.importhandlersasyncdefmy_library_view(*_)->HttpResponse:external_api_response=awaithandlers_quickstart.HTTPX_CLIENT.get("https://www.example.com/")returnHttpResponse(f"{external_api_response.text[:42]}",content_type="text/plain")Run uvicorn::warning: Lifespan protocol is not supported if you run uvicorn via gunicorn usingworker_class:gunicorn -k uvicorn.workers.UvicornWorker. See
otherlimitationsin the documentation.uvicorn asgi:application --lifespan=on --port=8080
Package: django-askell
django-askellÁskell integration for Django and Wagtail (optional)Installationpipinstalldjango-askellAdd the app to yourINSTALLED_APPSINSTALLED_APPS=[# ... other apps'askell',# ... other apps]Add the app urls to your projecturls.py:fromdjango.urlsimportpath,includefromaskell.urlsimporturlsasaskell_urlsurlpatterns=[# ... your other urlspath('askell/',include(askell_urls)),# ... more urls]To complete your setup, it is recommended to set up a webhook in Áskell's dashboard pointing to your website's URL. If your website has the domainhttps://example.comand you have added the app urls to your project, then the view that receives the webhooks is located athttps://example.com/askell/webhook/.Create your webhook, and then obtain your webhook secret and put it in your settings file or environment in your project:ASKELL_WEBHOOK_SECRET='my-secret'Webhook handlersYou can register new webhook handlers if you want to implement custom logic when something happens in Áskell.
These are the default webhook handlers:askell.webhook_handlers.payment_created
askell.webhook_handlers.payment_changedRegistering a new handler is simple:fromaskell.webhooksimportregister_webhook_handler@register_webhook_handlerdefpayment_settled(request,event,data):from.modelsimportPaymentifevent=='payment.changed':ifdata['state']=='settled':# do something herereturnTrueTODODocument webhook handlers[ ] Document viewsImplement subscription handlingRelease notesVersion 0.1.7Fixed a bug in creating a customerVersion 0.1.6Added support for multiple statesVersion 0.1.5Fixed a bug with importsVersion 0.1.4Fixed a bug in the Payment detail viewVersion 0.1.3Fixed a bug in webhook handlerVersion 0.1.2Added logging mechanism for debuggingVersion 0.1.1Changed the way webhook handlers are imported and documentedVersion 0.1Support for creating Payment objectsSupport for webhooks processing and verificationDefault webhook handlers for payment created, and changed
Package: django-assertmaxnumqueries
Django AssertMaxNumQueriesProvides a mixin and TransactionTestCase subclass with assertMaxNumQueries(),analogous todjango.test.TransactionTestCase.assertNumQueriesFree software: MIT licenseDocumentation:https://django-assertmaxnumqueries.readthedocs.io.UsageUsage is identical todjango.test.TransactionTestCase.assertNumQueries,
except check on the number of queries isassertLessEqualinsert ofassertEqual.To use Django AssertMaxNumQueries in a project:import django_assertmaxnumqueries


class MyTestCase(django_assertmaxnumqueries.TransactionTestCase):

    def test_my_test(self):
        with self.assertMaxNumQueries(2):
            Person.objects.create(name="Aaron")
            Person.objects.create(name="Daniel")CreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.History0.1.0 (2017-12-11)First release on PyPI.
Package: django-assetfiles
Django Assetfiles=================Django Assetfiles is a drop-in replacement for staticfiles which handles asset processing.Installation------------1. Install package from PyPi:``` sh$ pip install django-assetfiles```2. Replace `'django.contrib.staticfiles'` in `INSTALLED_APPS` with `'assetfiles'`:``` pythonINSTALLED_APPS = (# ...# 'django.contrib.staticfiles','assetfiles',)```3. That's it! Assetfiles will default to your [Staticfiles settings](https://docs.djangoproject.com/en/dev/ref/contrib/staticfiles/).Usage-----1. Add an asset file that should be processed:``` scss// static/css/main.scss$color: red;body {color: $color;}```2. Add a link to the processed CSS file in your template (you can use standard Staticfiles conventions):``` html+django{% load staticfiles %}<link href="{% static 'css/main.css' %}" rel="stylesheet">```Assetfiles will automatically serve up the processed version of `main.scss` at the static url of `/static/css/main.css`.4. To serve assets in development, either use `runserver` as normal or add the following to your `urls.py`:``` pythonfrom assetfiles.urls import assetfiles_urlpatterns# ... the rest of your URLconf goes here ...urlpatterns += assetfiles_urlpatterns()```5. For deployment, run `collectstatic` as usual and Assetfiles will process and copy over the assets:``` sh$ python manage.py collectstatic$ cat public/css/main.cssbody {color: red; }```Copyright---------Copyright (c) 2012 [LocalMed, Inc.](http://localmed.com). See LICENSE for details.
Package: django-asset-server-url
Provides{{ ASSET_SERVER_URL }}(the URL for an asset server) as a
template context variable. Can be set through settings.py or by passing
an environment variable to the app.Setup# settings.pyTEMPLATE_CONTEXT_PROCESSORS+=["assets_template_context.asset_server_url"]DefinitionSet it in settings, e.g.:# settings.pyASSET_SERVER_URL='//assets.example.com/'Or when starting the site, e.g.:ASSET_SERVER_URL=//assets.example.com/pythonmanage.pyrunserverUsageUse in templates:# templates/index.html<imgsrc="{{ ASSET_SERVER_URL }}a34bc3-fish.jpg"/>Output:<imgsrc="//assets.example.com/a34bc3-fish.jpg"
Package: django-assets-livereload
livereload
static assets
Platform: UNKNOWN
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Information Technology
Classifier: License :: OSI Approved :: MIT License
Classifier: Environment :: Web Environment
Classifier: Framework :: Django
Classifier: Operating System :: POSIX :: Linux
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Internet :: WWW/HTTP :: WSGI :: Middleware
Classifier: Topic :: Internet :: WWW/HTTP :: Site Management
Package: django-assets-manager
Installpip install django-assets-managerUsageSettingsINSTALLED_APPS=(# ...'django_assets_manager',)STATICFILES_FINDERS=('django.contrib.staticfiles.finders.FileSystemFinder','django.contrib.staticfiles.finders.AppDirectoriesFinder','django_assets_manager.finders.CdnFinder',)ASSETS_MANAGER_FILES={"utils":{"js":"static://js/utils.js",},"cooleffect":{"js":["static://js/cooleffect.js"],"css":["static://css/cooleffect.css"],"depends":["utils","jquery"],},"jquery":{"js":"//code.jquery.com/jquery-2.1.4.min.js","cache":{"paths":{"//code.jquery.com/jquery-2.1.4.min.js":"jquery-2.1.4.min.js",}},},}ASSETS_MANAGER_SPRITES=({'name':'main','output':'images/sprites.png','scss_output':'css/_sprites.scss','extra_sizes':((2,'@2x'),),'width':640,'height':640,'images':({'name':'logo','src':'img/logo.png',},{'name':'bar_bg','src':'img/bar_bg.png','mode':'repeat-x',},),},)Template{% load assets_manager %}
{% assets "cooleffect" %}<!-- or -->{% assets_css "cooleffect" %}
{% assets_js "cooleffect" %}
Package: django-assets-pipeline
This file requires editingNote to the author: Please add something informative to this READMEbeforereleasing your software, asa little documentation goes a long way.  Both
README.rst (this file) and NEWS.txt (release notes) will be included in your
package metadata which gets displayed in the PyPI page for your project.You can take a look at the README.txt of other projects, such as repoze.bfg
(http://bfg.repoze.org/trac/browser/trunk/README.txt) for some ideas.CreditsDistributeBuildoutmodern-package-templateNews0.2a1Release date: UNRELEASEDExample news entry for the in-development version0.1Release date: 15-Mar-2010Example news entry for a released version
Package: django-assets-toolkit
A development toolkit for compiling sass and coffee script files.Installation`pipinstall-Udjango-assets-toolkit`UsageAddassetstoolkitin yourINSTALLED_APPSsettings, then you can load theassetstoolkitfrom your template files which has three template tags:scsslesscoffeeYou can use it in your templates like:{%loadassetstoolkit%}...<linkrel="stylesheet"type="text/css"href="{% scss 'css/styles.scss' %}"><linkrel="stylesheet"type="text/css"href="{% less 'css/styles.less' %}"><scripttype="text/javascript"src="{% coffee 'src/scripts.coffee' %}"></script>Have a look atsettings.pyto see more options.NoteIt will put the compiled sass file in the same directory of .scss file while it’ll put the compiled coffee script on the same level where the script is contained but withinjsdirectory. If you want the compiled script to be on a different directory just overrideCOFFEE_OUTPUTsettings which should be sibling of directory where script is located.For theCoffeeScriptpackage to work, you need to actually have theCoffee Scriptbinary in your system. The same is true forLess.Licensehttp://marconi.mit-license.org/