Metadata-Version: 2.4
Name: hdn_research_environment
Version: 3.2.26
Summary: A Django app for supporting cloud-native research environments
Home-page: https://www.healthdatanexus.ai/
Author: rutvikrj26
Author-email: rutvikrj26@gmail.com
License: BSD-3-Clause
Classifier: Environment :: Web Environment
Classifier: Framework :: Django
Classifier: Framework :: Django :: 4.2
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: BSD License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Internet :: WWW/HTTP
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: Django>=4.2.18
Requires-Dist: google-cloud-workflows>=1.6.1
Requires-Dist: django-background-tasks-updated>=1.2.7
Requires-Dist: djangorestframework>=3.15.2
Dynamic: license-file

# hdn-research-environment
A Django app for supporting cloud-native research environments

## Deployment configuration

The host Django project supplies the site's branding and cloud identity domain:

- `SITE_NAME` supplies the name shown in billing instructions (and existing emails).
- `SUPPORT_EMAIL`, if set, supplies support links and error messages. Otherwise
  `CONTACT_EMAIL`, then `DEFAULT_FROM_EMAIL`, is used. Display-name addresses such
  as `PhysioNet Support <help@physionet.org>` are accepted; links use the bare email.
- `CLOUD_RESEARCH_ENVIRONMENTS_ORGANIZATION_DOMAIN` optionally overrides the domain
  used by the collaborator forms, for example `physionet.org`. When unset or empty,
  it is derived from the signed-in user's **cloud identity** email, not their login
  email or the site's hostname. Without either source, the forms use ordinary
  email validation; server-side collaborator access checks still apply.

These are Django settings, not environment variables read by this package. No
additional context processor is required. The owner is identified by their full
cloud identity email and is excluded from collaborator removal controls.

## Regression tests

The Python tests run in a configured PhysioNet Django host with this checkout on
`PYTHONPATH` and cloud research environments enabled. Use a dedicated test
database (not the host's development database):

```sh
python manage.py test environment.tests.test_deployment_config environment.tests.test_services.CreateCloudIdentityTestCase --settings=<host_test_settings>
```

The collaborator submit handlers also have dependency-free tests using Node.js
18 or newer:

```sh
node --test environment/tests/test_collaborator_domains.cjs
```

# Publishing a new version

Create the package:
```
python setup.py sdist
```

Publish the package:
```
python -m twine upload dist/*
```
