Merge branch 'master' of github.com:jamesatjaminit/PyRIGS

This commit is contained in:
James Cook
2025-10-06 21:18:07 +01:00
10 changed files with 1806 additions and 2378 deletions

View File

@@ -18,34 +18,37 @@ jobs:
- name: Install build dependencies - name: Install build dependencies
run: | run: |
sudo apt-get install libcairo2-dev sudo apt-get install libcairo2-dev
- name: Set up Python
- name: "Set up Python"
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: "3.10" python-version-file: ".python-version"
cache: 'pipenv'
- name: Install uv
uses: astral-sh/setup-uv@v6
- name: Install Dependencies - name: Install Dependencies
run: | run: uv sync --locked --all-extras --dev
python3 -m pip install --upgrade pip pipenv
pipenv install -d
# if: steps.pcache.outputs.cache-hit != 'true'
- name: Cache Static Files - name: Cache Static Files
id: static-cache id: static-cache
uses: actions/cache@v4 uses: actions/cache@v4
with: with:
path: 'pipeline/built_assets' path: 'pipeline/built_assets'
key: ${{ hashFiles('package-lock.json') }}-${{ hashFiles('pipeline/source_assets') }} key: ${{ hashFiles('package-lock.json') }}-${{ hashFiles('pipeline/source_assets') }}
- uses: bahmutov/npm-install@v1 - uses: bahmutov/npm-install@v1
if: steps.static-cache.outputs.cache-hit != 'true' if: steps.static-cache.outputs.cache-hit != 'true'
- run: node node_modules/gulp/bin/gulp build - run: node node_modules/gulp/bin/gulp build
if: steps.static-cache.outputs.cache-hit != 'true' if: steps.static-cache.outputs.cache-hit != 'true'
- name: Basic Checks - name: Basic Checks
run: | run: |
pipenv run pycodestyle . --exclude=migrations,node_modules uv run pycodestyle . --exclude=.venv,migrations,node_modules
pipenv run python3 manage.py check uv run python3 manage.py check
pipenv run python3 manage.py makemigrations --check --dry-run uv run python3 manage.py makemigrations --check --dry-run
pipenv run python3 manage.py collectstatic --noinput uv run python3 manage.py collectstatic --noinput
- name: Run Tests - name: Run Tests
run: pipenv run pytest -n auto --cov run: uv run pytest -n auto --cov
- uses: actions/upload-artifact@v4 - uses: actions/upload-artifact@v4
if: failure() if: failure()
with: with:
@@ -53,4 +56,4 @@ jobs:
path: screenshots/ path: screenshots/
retention-days: 5 retention-days: 5
- name: Coveralls - name: Coveralls
run: pipenv run coveralls --service=github run: uv run coveralls --service=github

1
.python-version Normal file
View File

@@ -0,0 +1 @@
3.10

98
Pipfile
View File

@@ -1,98 +0,0 @@
[[source]]
url = "https://pypi.python.org/simple"
verify_ssl = true
name = "pypi"
[packages]
ansicolors = "~=1.1.8"
asgiref = "~=3.3.1"
"backports.tempfile" = "~=1.0"
"backports.weakref" = "~=1.0.post1"
beautifulsoup4 = "~=4.9.3"
Brotli = "~=1.0.9"
cachetools = "~=4.2.1"
chardet = "~=4.0.0"
configparser = "~=5.0.1"
contextlib2 = "~=0.6.0.post1"
cssselect = "~=1.1.0"
cssutils = "~=1.0.2"
dj-database-url = "~=0.5.0"
dj-static = "~=0.0.6"
Django = "~=3.2"
django-debug-toolbar = "~=4.0.0"
django-filter = "~=2.4.0"
django-ical = "~=1.7.1"
django-recurrence = "~=1.10.3"
django-registration-redux = "~=2.9"
django-reversion = "~=3.0.9"
django-widget-tweaks = "~=1.4.8"
django-htmlmin = "~=0.11.0"
envparse = "*"
gunicorn = "~=22.0.0"
icalendar = "~=4.0.7"
idna = "~=3.7"
Markdown = "~=3.3.3"
msgpack = "~=1.0.2"
pep517 = "~=0.9.1"
Pillow = "~=10.0.1"
premailer = "~=3.7.0"
progress = "~=1.5"
psutil = "~=5.8.0"
psycopg2 = "~=2.8.6"
Pygments = "~=2.15.0"
pyparsing = "~=2.4.7"
PyPDF2 = "~=1.27.5"
PyPOM = "~=2.2.4"
python-dateutil = "~=2.8.1"
pytoml = "~=0.1.21"
pytz = "~=2020.5"
reportlab = "*"
requests = "~=2.32.3"
retrying = "~=1.3.3"
simplejson = "~=3.17.2"
six = "~=1.15.0"
soupsieve = "~=2.1"
sqlparse = "~=0.5.0"
static3 = "~=0.7.0"
svg2rlg = "~=0.3"
tini = "~=3.0.1"
tornado = "~=6.3"
urllib3 = "~=1.26.19"
whitenoise = "~=5.2.0"
yolk = "~=0.4.3"
zipp = "~=3.4.0"
"zope.component" = "~=4.6.2"
"zope.deferredimport" = "~=4.3.1"
"zope.deprecation" = "~=4.4.0"
"zope.event" = "~=4.5.0"
"zope.hookable" = "~=5.0.1"
"zope.proxy" = "~=4.3.5"
"zope.schema" = "~=6.0.1"
sentry-sdk = "*"
diff-match-patch = "*"
python-barcode = "*"
django-hCaptcha = "*"
importlib-metadata = "*"
django-hcaptcha = "*"
"z3c.rml" = "*"
pikepdf = "*"
django-queryable-properties = "*"
django-mass-edit = "*"
selenium = "~=4.9.1"
"zope.interface" = "*"
[dev-packages]
pycodestyle = "~=2.9.1"
coveralls = "*"
django-coverage-plugin = "*"
pytest-cov = "*"
pytest-django = "*"
pluggy = "*"
pytest-splinter = "*"
pytest = "*"
pytest-reverse = "*"
pytest-xdist = {extras = [ "psutil",], version = "*"}
PyPOM = {extras = [ "splinter",], version = "*"}
[requires]
python_version = "3.10"

2265
Pipfile.lock generated

File diff suppressed because it is too large Load Diff

View File

@@ -104,6 +104,9 @@ DATABASES = {
if not DEBUG: if not DEBUG:
import dj_database_url import dj_database_url
if env("FRANKENRIGS_DATABASE_URL") is not None:
DATABASES['default'] = dj_database_url.config(env="FRANKENRIGS_DATABASE_URL")
else:
DATABASES['default'] = dj_database_url.config() DATABASES['default'] = dj_database_url.config()
# Logging # Logging

View File

@@ -6,7 +6,36 @@
{% load total_invoices_todo from filters %} {% load total_invoices_todo from filters %}
{% block titleheader %} {% block titleheader %}
<a class="navbar-brand" style="margin-left: auto; margin-right: auto;" href="/">RIGS</a> <style>
.franken {
font-family: Fontdiner Swanky;
color: #00ff00;
animation: glow 1.5s infinite alternate;
}
@keyframes glow {
0% {
text-shadow: 0 0 5px #00ff00,
0 0 10px #00ff00,
0 0 20px #00ff00,
0 0 40px #00ff00;
}
50% {
text-shadow: 0 0 10px #00ff00,
0 0 20px #00ff00,
0 0 30px #00ff00,
0 0 60px #00ff00;
}
100% {
text-shadow: 0 0 5px #00ff00,
0 0 10px #00ff00,
0 0 20px #00ff00,
0 0 40px #00ff00;
}
}
</style>
<a class="navbar-brand" style="margin-left: auto; margin-right: auto;" href="/"><span class="franken">Franken</span>RIGS</a>
{% endblock %} {% endblock %}
{% block titleelements %} {% block titleelements %}

99
pyproject.toml Normal file
View File

@@ -0,0 +1,99 @@
[project]
name = "pyrigs"
version = "0.1.0"
description = "A Django-based event booking system designed for use by TEC PA and Lighting"
readme = "README.md"
requires-python = "~=3.10.0"
dependencies = [
"ansicolors~=1.1.8",
"asgiref~=3.3.1",
"backports.tempfile~=1.0",
"backports.weakref~=1.0.post1",
"beautifulsoup4~=4.9.3",
"Brotli~=1.0.9",
"cachetools~=4.2.1",
"chardet~=4.0.0",
"configparser~=5.0.1",
"contextlib2~=0.6.0.post1",
"cssselect~=1.1.0",
"cssutils~=1.0.2",
"dj-database-url~=0.5.0",
"dj-static~=0.0.6",
"Django~=3.2",
"django-debug-toolbar~=4.0.0",
"django-filter~=2.4.0",
"django-ical~=1.7.1",
"django-recurrence~=1.10.3",
"django-registration-redux~=2.9",
"django-reversion~=3.0.9",
"django-widget-tweaks~=1.4.8",
"django-htmlmin~=0.11.0",
"envparse",
"gunicorn~=22.0.0",
"icalendar~=4.0.7",
"idna~=3.7",
"Markdown~=3.3.3",
"msgpack~=1.0.2",
"pep517~=0.9.1",
"Pillow~=10.0.1",
"premailer~=3.7.0",
"progress~=1.5",
"psutil~=5.8.0",
"psycopg2-binary",
"Pygments~=2.15.0",
"pyparsing~=2.4.7",
"PyPDF2~=1.27.5",
"PyPOM~=2.2.4",
"python-dateutil~=2.8.1",
"pytoml~=0.1.21",
"pytz~=2020.5",
"reportlab",
"requests~=2.32.3",
"retrying~=1.3.3",
"simplejson~=3.17.2",
"six~=1.15.0",
"soupsieve~=2.1",
"sqlparse~=0.5.0",
"static3~=0.7.0",
"svg2rlg~=0.3",
"tini~=3.0.1",
"tornado~=6.3",
"urllib3~=1.26.19",
"whitenoise~=5.2.0",
"yolk~=0.4.3",
"zipp~=3.4.0",
"zope.component~=4.6.2",
"zope.deferredimport~=4.3.1",
"zope.deprecation~=4.4.0",
"zope.event~=4.5.0",
"zope.hookable~=5.0.1",
"zope.proxy~=4.3.5",
"zope.schema~=6.0.1",
"sentry-sdk",
"diff-match-patch",
"python-barcode",
"django-hCaptcha",
"importlib-metadata",
"django-hcaptcha",
"z3c.rml",
"pikepdf",
"django-queryable-properties",
"django-mass-edit",
"selenium~=4.9.1",
"zope.interface",
]
[dependency-groups]
dev = [
"pycodestyle~=2.9.1",
"coveralls",
"django-coverage-plugin",
"pytest-cov",
"pytest-django",
"pluggy",
"pytest-splinter",
"pytest",
"pytest-reverse",
"pytest-xdist[psutil]",
"PyPOM[splinter]",
]

View File

@@ -1,2 +1,3 @@
[pycodestyle] [pycodestyle]
max-line-length = 320 max-line-length = 320
exclude = .venv

View File

@@ -13,6 +13,10 @@
<meta name="theme-color" content="#3853a4"> <meta name="theme-color" content="#3853a4">
<meta name="color-scheme" content="light dark"> <meta name="color-scheme" content="light dark">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Fontdiner+Swanky&display=swap" rel="stylesheet">
<link rel="icon" type="image/png" href="{% static 'imgs/pyrigs-avatar.png' %}"> <link rel="icon" type="image/png" href="{% static 'imgs/pyrigs-avatar.png' %}">
<link rel="apple-touch-icon" href="{% static 'imgs/pyrigs-avatar.png' %}"> <link rel="apple-touch-icon" href="{% static 'imgs/pyrigs-avatar.png' %}">

1651
uv.lock generated Normal file

File diff suppressed because it is too large Load Diff