Skip to main content

SciDataContainer Django Server

Documentation Status

This is the django based implementation of the server to manage SciDataContainer objects.

Documentation

The documentation is hosted on Read the Docs.

Installation

Install using pip:

pip install django-scidatacontainer

Then add 'scidatacontainer_db' and all third party libraries to your INSTALLED_APPS.

INSTALLED_APPS = [
    ...,
    'scidatacontainer_db',
    'guardian',
    'rest_framework',
    'knox',
    'django_filters',
]

Finally, configure it in your settings.py.

  • Define MEDIA_ROOT. It is the location where the dataset files are stored.
  • Define LOGIN_URL and LOGOUT_REDIRECT_URL. This packages provides a login page that can be used.
  • Configure the required third party packages.

A good starting point might be the following configuration:

AUTHENTICATION_BACKENDS = (
    'django.contrib.auth.backends.ModelBackend',
    'guardian.backends.ObjectPermissionBackend',
)

REST_FRAMEWORK = {
    'DEFAULT_AUTHENTICATION_CLASSES': [
        'knox.auth.TokenAuthentication',
        # remove the following if you only want to allow token authentification (no web browser)
        'rest_framework.authentication.BasicAuthentication',
        'rest_framework.authentication.SessionAuthentication',
        ],
    'DEFAULT_PERMISSION_CLASSES': [
        'rest_framework.permissions.IsAuthenticated', # only registered user have access.
        # 'rest_framework.permissions.AllowAny', # everyone can access the api.
        ],
    # Make sure datetime is imported!!
    # API key settings: valid for 2 weeks, but the expiration date is extended by 2 weeks every time it's used.
    'TOKEN_TTL' : datetime.timedelta(weeks=2),
    'AUTO_REFRESH' : True,
}

Metadata

Release files for django-scidatacontainer 0.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for django-scidatacontainer 0.2.1
File Size Uploaded
django-scidatacontainer-0.2.1.tar.gz 13.1 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for django-scidatacontainer 0.2.1
File Interpreter ABI Platform
django_scidatacontainer-0.2.1-py3-none-any.whl Python 3 none any Details

Total release size: 26.2 MB

Release files / django-scidatacontainer-0.2.1.tar.gz

Download URL django-scidatacontainer-0.2.1.tar.gz
Size 13.1 MB
Tags Source
SHA-256 checksum
How to use checksums
ad74cfe265dac4f1a99b2ddf0dec9666a276ab63775672a1f8ee4134b2bee460
BLAKE2b-256 checksum
How to use checksums
75efa8ce1a589b9bb8f9196915d31f1e811c11e07662f3f0922392d1ab8d8edb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.6

Release files / django_scidatacontainer-0.2.1-py3-none-any.whl

Download URL django_scidatacontainer-0.2.1-py3-none-any.whl
Size 13.1 MB
Tags Python 3
SHA-256 checksum
How to use checksums
849edba2037e64a0a054b0ff218bccd1a8d90f490363584aa7eb0ca4c4950c84
BLAKE2b-256 checksum
How to use checksums
b066f7ea5fa62da2d1653e5ba7b2e478e96926a77f8103f67be2d1e97cf2a1a6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.6

Release history Release notifications | RSS feed

This release

0.2.1 This release

2 release files

0.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page