Skip to content

umd-lib/autonumber-django

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Autonumber Django Application

Django implementation of the Autonumber service.

This is a reimplementation of the Autonumber service from the Ruby on Rails app.

Installation Options

There are two ways to install this application:

  • uv (for the recommended installation)
  • pyenv, which will manages the shims for pip and python

Installation

First, get the code by cloning the repository:

git clone https://github.com/umd-lib/autonumber-django.git
cd autonumber-django

With uv you can install python like so:

uv python install 3.14.0

With pyenv you use

pyenv install 3.14.0

Option 1: Using uv (Recommended)

  1. Create a virtual environment:

    uv venv
  2. Install the dependencies:

    uv sync --extra dev

Option 2: Using pyenv

This uses the standard tools built into Python.

  1. Create a virtual environment:

    python -m venv .venv --prompt autonumber
  2. Activate the environment:

    source .venv/bin/activate
  3. Install the project and its dependencies:

    pip install -e ".[dev]"

Running the Application

Once you have installed the project using either method, you need to set up the database and run the server.

Option 1: Using uv (Recommended)

  1. Run the database migrations:

    uv run src/manage.py migrate
  2. (Optional) Create a superuser: This allows you to log into the Django admin interface at /admin/.

    uv run src/manage.py createsuperuser
  3. Run the development server:

    uv run src/manage.py runserver
  4. Visit http://127.0.0.1:8000 in your web browser.

Option 2: Using pyenv

  1. Run the database migrations:

    python src/manage.py migrate
  2. (Optional) Create a superuser: This allows you to log into the Django admin interface at /admin/.

    python src/manage.py createsuperuser
  3. Run the development server:

    python src/manage.py runserver
  4. Visit http://localhost:8000 in your web browser.


Running Tests

This project uses pytest and pytest-django.

  1. Run the test suite: With uv

    uv run pytest

    With pyenv

    pytest

    NOTE With pyenv you may need to source .venv/bin/activate again after installing the optional dependencies, so that the pytest shim gets properly updated in your terminal session.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors