A Django web application for documenting and analyzing patterns of early modern violence. This project powers the Mapping Early Modern Violence website, providing historians with tools to explore historical crime data from Venice and surrounding regions.
Mapping Violence is a collaborative research project that examines violent crime in early modern Europe, focusing on cases from Venice and the Venetian terraferma. The project digitizes and analyzes court records, witness testimonies, and archival documents to understand patterns of violence, social relationships, and legal proceedings in the 16th and 17th centuries.
- Crime Database: Comprehensive cataloging of violent crimes with detailed metadata
- Person Registry: Network of individuals involved in criminal cases (victims, perpetrators, witnesses, judges)
- Historical Date Handling: Specialized fields for managing uncertain and approximate historical dates
- Geographic Data: Location-based analysis using historical place names and modern coordinates
- Content Management: Wagtail CMS integration for managing static content and project information
- Data Import/Export: CSV-based data ingestion and export capabilities
- Advanced Search: Multi-faceted search and filtering across crimes, people, and locations
- Backend: Django 5.1+ with Python 3.12
- CMS: Wagtail 7.1 for content administration
- Database: PostgreSQL 16 with PostGIS support
- Frontend: Tailwind CSS with Django templates
- Authentication: Django Allauth with social login support
- Development: Poetry for dependency management, Black for code formatting
- Crime: Central model storing details about violent incidents, court proceedings, and outcomes
- Person: Individuals involved in cases (victims, perpetrators, witnesses, court officials)
- Event: Ceremonial or social events connected to crimes (feast days, weddings, etc.)
- Weapon: Categorized inventory of weapons used in violent acts
- Location: Geographic entities with historical and modern place names
- Python 3.12+
- PostgreSQL 16+
- Node.js (for frontend dependencies)
- Poetry (Python package manager)
- Clone the repository:
git clone <repository-url>
cd mapping_violence
- Install Python dependencies:
poetry install
- Install frontend dependencies:
npm install
- Set up environment variables:
cp .env.example .env
# Edit .env with your database credentials and other settings
- Set up the database:
poetry run python manage.py migrate
poetry run python manage.py createsuperuser
- Load initial data (optional):
poetry run python manage.py loaddata fixtures/weapon_types.json
- Run the development server:
poetry run python manage.py runserver
This project uses Black for Python code formatting and follows Django best practices:
# Format code
poetry run black .
# Run linting
poetry run pylint mapping_violence/
# Format HTML templates
poetry run djhtml templates/
Frontend assets are managed with Tailwind CSS:
# Start Tailwind development server
cd theme/static_src
npm run dev
# Build for production
npm run build
# Run tests
poetry run pytest
# Run with coverage
poetry run pytest --cov=mapping_violence
mapping_violence/
├── config/ # Django settings and configuration
├── mapping_violence/ # Main app with Crime, Person models
├── content/ # Wagtail CMS pages and content
├── locations/ # Geographic models and utilities
├── historical_dates/ # Custom date handling for uncertain dates
├── theme/ # Frontend theme and Tailwind configuration
├── templates/ # Django templates
├── static/ # Static assets
├── fixtures/ # Initial data fixtures
└── docs/ # Project documentation
The application centers around documenting violent crimes with rich contextual information:
- Crimes are linked to People (victims, perpetrators, witnesses)
- Historical dates handle uncertainty in early modern records
- Locations provide geographic context with modern coordinates
- Events connect crimes to social and religious occasions
- Weapons are categorized and defined for analysis
- Fork the repository
- Create a feature branch (
git checkout -b feat/amazing-feature
) - Make your changes following the code style guidelines
- Run tests and ensure they pass
- Commit your changes (
git commit -m 'Add amazing feature'
) - Push to the branch (
git push origin feat/amazing-feature
) - Open a Pull Request
This project is licensed under the MIT License. See the LICENSE file for details.
This project is developed by the Roy Rosenzweig Center for History and New Media at George Mason University.
- Project Lead: Amanda Madden
- Lead Developer: Jason Heppler ([email protected])
For technical issues, please use the GitHub issue tracker.