main bc3fcb7da9d8 cached
303 files
1.4 MB
373.3k tokens
1879 symbols
1 requests
Download .txt
Showing preview only (1,544K chars total). Download the full file or copy to clipboard to get everything.
Repository: microsoft/electionguard-python
Branch: main
Commit: bc3fcb7da9d8
Files: 303
Total size: 1.4 MB

Directory structure:
gitextract_dl9na5eh/

├── .github/
│   ├── ISSUE_TEMPLATE/
│   │   ├── bug_report.yml
│   │   ├── config.yml
│   │   └── enhancement.yml
│   ├── pull_request_template.md
│   └── workflows/
│       ├── pull_request.yml
│       └── release.yml
├── .gitignore
├── .vscode/
│   └── extensions.json
├── CODE_OF_CONDUCT.md
├── CONTRIBUTING.md
├── LICENSE
├── Makefile
├── README.md
├── SECURITY.md
├── data/
│   ├── ballot_in_simple.json
│   ├── election_manifest_simple.json
│   ├── manifest-full.json
│   ├── manifest-hamilton-general.json
│   ├── manifest-minimal.json
│   ├── manifest-small.json
│   ├── plaintext_ballots_simple.json
│   ├── plaintext_two_ballots_minimal.json
│   └── plaintext_two_ballots_small.json
├── docs/
│   ├── 0_Configure_Election.ipynb
│   ├── 1_Key_Ceremony.md
│   ├── 2_Encrypt_Ballots.md
│   ├── 3_Cast_and_Spoil.md
│   ├── 4_Decrypt_Tally.md
│   ├── 5_Publish_and_Verify.md
│   ├── Build_and_Run.md
│   ├── Design_and_Architecture.md
│   ├── Election_Manifest.md
│   ├── Project_Workflow.md
│   ├── Tablet Setup.md
│   └── index.md
├── mkdocs.yml
├── pyproject.toml
├── src/
│   ├── electionguard/
│   │   ├── __init__.py
│   │   ├── ballot.py
│   │   ├── ballot_box.py
│   │   ├── ballot_code.py
│   │   ├── ballot_compact.py
│   │   ├── ballot_validator.py
│   │   ├── big_integer.py
│   │   ├── byte_padding.py
│   │   ├── chaum_pedersen.py
│   │   ├── constants.py
│   │   ├── data_store.py
│   │   ├── decrypt_with_secrets.py
│   │   ├── decrypt_with_shares.py
│   │   ├── decryption.py
│   │   ├── decryption_mediator.py
│   │   ├── decryption_share.py
│   │   ├── discrete_log.py
│   │   ├── election.py
│   │   ├── election_object_base.py
│   │   ├── election_polynomial.py
│   │   ├── elgamal.py
│   │   ├── encrypt.py
│   │   ├── group.py
│   │   ├── guardian.py
│   │   ├── hash.py
│   │   ├── hmac.py
│   │   ├── key_ceremony.py
│   │   ├── key_ceremony_mediator.py
│   │   ├── logs.py
│   │   ├── manifest.py
│   │   ├── nonces.py
│   │   ├── proof.py
│   │   ├── py.typed
│   │   ├── scheduler.py
│   │   ├── schnorr.py
│   │   ├── serialize.py
│   │   ├── singleton.py
│   │   ├── tally.py
│   │   ├── type.py
│   │   └── utils.py
│   ├── electionguard_cli/
│   │   ├── __init__.py
│   │   ├── cli_models/
│   │   │   ├── __init__.py
│   │   │   ├── cli_decrypt_results.py
│   │   │   ├── cli_election_inputs_base.py
│   │   │   ├── e2e_build_election_results.py
│   │   │   ├── encrypt_results.py
│   │   │   ├── mark_results.py
│   │   │   └── submit_results.py
│   │   ├── cli_steps/
│   │   │   ├── __init__.py
│   │   │   ├── cli_step_base.py
│   │   │   ├── decrypt_step.py
│   │   │   ├── election_builder_step.py
│   │   │   ├── encrypt_votes_step.py
│   │   │   ├── input_retrieval_step_base.py
│   │   │   ├── key_ceremony_step.py
│   │   │   ├── mark_ballots_step.py
│   │   │   ├── output_step_base.py
│   │   │   ├── print_results_step.py
│   │   │   ├── submit_ballots_step.py
│   │   │   └── tally_step.py
│   │   ├── e2e/
│   │   │   ├── __init__.py
│   │   │   ├── e2e_command.py
│   │   │   ├── e2e_election_builder_step.py
│   │   │   ├── e2e_input_retrieval_step.py
│   │   │   ├── e2e_inputs.py
│   │   │   ├── e2e_publish_step.py
│   │   │   └── submit_votes_step.py
│   │   ├── encrypt_ballots/
│   │   │   ├── __init__.py
│   │   │   ├── encrypt_ballot_inputs.py
│   │   │   ├── encrypt_ballots_election_builder_step.py
│   │   │   ├── encrypt_ballots_input_retrieval_step.py
│   │   │   ├── encrypt_ballots_publish_step.py
│   │   │   └── encrypt_command.py
│   │   ├── import_ballots/
│   │   │   ├── __init__.py
│   │   │   ├── import_ballot_inputs.py
│   │   │   ├── import_ballots_command.py
│   │   │   ├── import_ballots_election_builder_step.py
│   │   │   ├── import_ballots_input_retrieval_step.py
│   │   │   └── import_ballots_publish_step.py
│   │   ├── mark_ballots/
│   │   │   ├── __init__.py
│   │   │   ├── mark_ballot_inputs.py
│   │   │   ├── mark_ballots_election_builder_step.py
│   │   │   ├── mark_ballots_input_retrieval_step.py
│   │   │   ├── mark_ballots_publish_step.py
│   │   │   └── mark_command.py
│   │   ├── setup_election/
│   │   │   ├── __init__.py
│   │   │   ├── output_setup_files_step.py
│   │   │   ├── setup_election_builder_step.py
│   │   │   ├── setup_election_command.py
│   │   │   ├── setup_input_retrieval_step.py
│   │   │   └── setup_inputs.py
│   │   ├── start.py
│   │   └── submit_ballots/
│   │       ├── __init__.py
│   │       ├── submit_ballot_inputs.py
│   │       ├── submit_ballots_election_builder_step.py
│   │       ├── submit_ballots_input_retrieval_step.py
│   │       ├── submit_ballots_publish_step.py
│   │       └── submit_command.py
│   ├── electionguard_db/
│   │   ├── docker-compose.db.yml
│   │   └── mongo-init.js
│   ├── electionguard_gui/
│   │   ├── .dockerignore
│   │   ├── Dockerfile
│   │   ├── __init__.py
│   │   ├── components/
│   │   │   ├── __init__.py
│   │   │   ├── component_base.py
│   │   │   ├── create_decryption_component.py
│   │   │   ├── create_election_component.py
│   │   │   ├── create_key_ceremony_component.py
│   │   │   ├── election_list_component.py
│   │   │   ├── export_election_record_component.py
│   │   │   ├── export_encryption_package_component.py
│   │   │   ├── guardian_home_component.py
│   │   │   ├── key_ceremony_details_component.py
│   │   │   ├── upload_ballots_component.py
│   │   │   ├── view_decryption_component.py
│   │   │   ├── view_election_component.py
│   │   │   ├── view_spoiled_ballot_component.py
│   │   │   └── view_tally_component.py
│   │   ├── containers.py
│   │   ├── docker-compose.yml
│   │   ├── eel_utils.py
│   │   ├── main_app.py
│   │   ├── models/
│   │   │   ├── __init__.py
│   │   │   ├── decryption_dto.py
│   │   │   ├── election_dto.py
│   │   │   ├── key_ceremony_dto.py
│   │   │   └── key_ceremony_states.py
│   │   ├── services/
│   │   │   ├── __init__.py
│   │   │   ├── authorization_service.py
│   │   │   ├── ballot_upload_service.py
│   │   │   ├── configuration_service.py
│   │   │   ├── db_serialization_service.py
│   │   │   ├── db_service.py
│   │   │   ├── db_watcher_service.py
│   │   │   ├── decryption_service.py
│   │   │   ├── decryption_stages/
│   │   │   │   ├── __init__.py
│   │   │   │   ├── decryption_s1_join_service.py
│   │   │   │   ├── decryption_s2_announce_service.py
│   │   │   │   └── decryption_stage_base.py
│   │   │   ├── directory_service.py
│   │   │   ├── eel_log_service.py
│   │   │   ├── election_service.py
│   │   │   ├── export_service.py
│   │   │   ├── guardian_service.py
│   │   │   ├── gui_setup_input_retrieval_step.py
│   │   │   ├── key_ceremony_service.py
│   │   │   ├── key_ceremony_stages/
│   │   │   │   ├── __init__.py
│   │   │   │   ├── key_ceremony_s1_join_service.py
│   │   │   │   ├── key_ceremony_s2_announce_service.py
│   │   │   │   ├── key_ceremony_s3_make_backup_service.py
│   │   │   │   ├── key_ceremony_s4_share_backup_service.py
│   │   │   │   ├── key_ceremony_s5_verify_backup_service.py
│   │   │   │   ├── key_ceremony_s6_publish_key_service.py
│   │   │   │   └── key_ceremony_stage_base.py
│   │   │   ├── key_ceremony_state_service.py
│   │   │   ├── plaintext_ballot_service.py
│   │   │   ├── service_base.py
│   │   │   └── version_service.py
│   │   ├── start.py
│   │   └── web/
│   │       ├── components/
│   │       │   ├── admin/
│   │       │   │   ├── admin-home-component.js
│   │       │   │   ├── create-decryption-component.js
│   │       │   │   ├── create-election-component.js
│   │       │   │   ├── create-key-ceremony-component.js
│   │       │   │   ├── export-election-record-component.js
│   │       │   │   ├── export-encryption-package-component.js
│   │       │   │   ├── upload-ballots-component.js
│   │       │   │   ├── upload-ballots-legacy-component.js
│   │       │   │   ├── upload-ballots-success-component.js
│   │       │   │   ├── upload-ballots-wizard-component.js
│   │       │   │   ├── view-decryption-admin-component.js
│   │       │   │   ├── view-election-component.js
│   │       │   │   ├── view-key-ceremony-component.js
│   │       │   │   ├── view-spoiled-ballot-component.js
│   │       │   │   └── view-tally-component.js
│   │       │   ├── guardian/
│   │       │   │   ├── decryption-list-component.js
│   │       │   │   ├── guardian-home-component.js
│   │       │   │   ├── view-decryption-guardian-component.js
│   │       │   │   └── view-key-ceremony-component.js
│   │       │   └── shared/
│   │       │       ├── election-list-component.js
│   │       │       ├── footer-component.js
│   │       │       ├── home-component.js
│   │       │       ├── key-ceremony-details-component.js
│   │       │       ├── key-ceremony-list-component.js
│   │       │       ├── login-component.js
│   │       │       ├── navbar-component.js
│   │       │       ├── not-found-component.js
│   │       │       ├── spinner-component.js
│   │       │       └── view-plaintext-ballot-component.js
│   │       ├── css/
│   │       │   ├── bootstrap-icons.css
│   │       │   ├── bootstrap-overrides.css
│   │       │   ├── eg-styles.css
│   │       │   └── spinner.css
│   │       ├── index.html
│   │       ├── js/
│   │       │   └── vue.esm-browser.prod.js
│   │       ├── services/
│   │       │   ├── authorization-service.js
│   │       │   └── router-service.js
│   │       └── site.webmanifest
│   ├── electionguard_tools/
│   │   ├── __init__.py
│   │   ├── factories/
│   │   │   ├── __init__.py
│   │   │   ├── ballot_factory.py
│   │   │   └── election_factory.py
│   │   ├── helpers/
│   │   │   ├── __init__.py
│   │   │   ├── election_builder.py
│   │   │   ├── export.py
│   │   │   ├── key_ceremony_orchestrator.py
│   │   │   ├── tally_accumulate.py
│   │   │   └── tally_ceremony_orchestrator.py
│   │   ├── scripts/
│   │   │   ├── __init__.py
│   │   │   └── sample_generator.py
│   │   └── strategies/
│   │       ├── __init__.py
│   │       ├── election.py
│   │       ├── elgamal.py
│   │       └── group.py
│   └── electionguard_verify/
│       ├── __init__.py
│       └── verify.py
├── stubs/
│   └── gmpy2.pyi
└── tests/
    ├── __init__.py
    ├── base_test_case.py
    ├── bench/
    │   ├── __init__.py
    │   └── bench_chaum_pedersen.py
    ├── integration/
    │   ├── __init__.py
    │   ├── test_create_schema.py
    │   ├── test_end_to_end_election.py
    │   ├── test_functional_key_ceremony.py
    │   └── test_hamilton_county_election.py
    ├── property/
    │   ├── __init__.py
    │   ├── test_ballot.py
    │   ├── test_chaum_pedersen.py
    │   ├── test_decrypt_with_secrets.py
    │   ├── test_decryption_mediator.py
    │   ├── test_discrete_log.py
    │   ├── test_elgamal.py
    │   ├── test_encrypt.py
    │   ├── test_encrypt_hypotheses.py
    │   ├── test_group.py
    │   ├── test_hash.py
    │   ├── test_nonces.py
    │   ├── test_schnorr.py
    │   ├── test_tally.py
    │   └── test_verify.py
    └── unit/
        ├── __init__.py
        ├── electionguard/
        │   ├── __init__.py
        │   ├── test_ballot.py
        │   ├── test_ballot_box.py
        │   ├── test_ballot_code.py
        │   ├── test_ballot_compact.py
        │   ├── test_constants.py
        │   ├── test_decrypt_with_shares.py
        │   ├── test_decryption.py
        │   ├── test_election_polynomial.py
        │   ├── test_elgamal.py
        │   ├── test_encrypt.py
        │   ├── test_guardian.py
        │   ├── test_hmac.py
        │   ├── test_key_ceremony.py
        │   ├── test_key_ceremony_mediator.py
        │   ├── test_logs.py
        │   ├── test_manifest.py
        │   ├── test_scheduler.py
        │   ├── test_singleton.py
        │   └── test_utils.py
        └── electionguard_gui/
            ├── __init__.py
            ├── test_decryption_dto.py
            ├── test_eel_utils.py
            ├── test_election_dto.py
            └── test_plaintext_ballot_service.py

================================================
FILE CONTENTS
================================================

================================================
FILE: .github/ISSUE_TEMPLATE/bug_report.yml
================================================
name: 🐞 Bug
description: Submit a bug if something isn't working as expected.
title: "🐞 <title>"
labels: [bug, triage]
body:
  - type: checkboxes
    attributes:
      label: Is there an existing issue for this?
      description: Please search to see if an issue already exists for the bug you encountered.
      options:
        - label: I have searched the existing issues
          required: true
  - type: textarea
    attributes:
      label: Current Behavior
      description: A concise description of what you're experiencing.
    validations:
      required: true
  - type: textarea
    attributes:
      label: Expected Behavior
      description: A concise description of what you expected to happen.
    validations:
      required: false
  - type: textarea
    attributes:
      label: Steps To Reproduce
      description: Steps to reproduce the behavior.
      placeholder: |
        1. In this environment...
        2. With this config...
        3. Run '...'
        4. See error...
    validations:
      required: false
  - type: textarea
    attributes:
      label: Environment
      description: |
        examples:
          - **OS**: Ubuntu 20.04
      value: |
        - OS:
      render: markdown
    validations:
      required: false
  - type: textarea
    attributes:
      label: Anything else?
      description: |
        Links? References? Screenshots? Possible Solution? Anything that will give us more context about the issue you are encountering!

        Tip: You can attach images or log files by clicking this area to highlight it and then dragging files in.
    validations:
      required: false


================================================
FILE: .github/ISSUE_TEMPLATE/config.yml
================================================
blank_issues_enabled: false
contact_links:
  - name: Discussions
    url: https://github.com/microsoft/electionguard/discussions
    about: Discuss suggestions and new enhancements here.
  - name: ElectionGuard Info
    url: https://https://www.electionguard.vote/
    about: Learn more about ElectionGuard or email the team.


================================================
FILE: .github/ISSUE_TEMPLATE/enhancement.yml
================================================
name: ✨ Enhancement
description: Suggest an enhancement or an improvement.
title: "✨ <title>"
labels: [enhancement, triage]
body:
  - type: checkboxes
    attributes:
      label: Is there an existing issue for this?
      description: Please search to see if an issue already exists for the suggestion.
      options:
        - label: I have searched the existing issues
          required: true
  - type: textarea
    attributes:
      label: Suggestion
      description: Tell us how we could improve ElectionGuard.
    validations:
      required: true
  - type: textarea
    attributes:
      label: Possible Implementation
      description: Not obligatory, but ideas as to the implementation of the suggestion.
    validations:
      required: false
  - type: textarea
    attributes:
      label: Anything else?
      description: |
        What are you trying to accomplish?

        Links? References? Anything that will give us more context about the suggestion!

        Tip: You can attach images by clicking this area to highlight it and then dragging files in.
    validations:
      required: false


================================================
FILE: .github/pull_request_template.md
================================================
[//]: # (🚨 Please review the CONTRIBUTING.md in this repository. 💔Thank you!)

### Issue
*Link your PR to an issue*

Fixes #___

### Description
*Please describe your pull request.*

### Testing
*Describe the best way to test or validate your PR.*


================================================
FILE: .github/workflows/pull_request.yml
================================================
name: Validate Pull Request

on:
  push:
    branches: [main, "integration/**", "releases/**"]
  pull_request:
    branches: [main, "integration/**", "releases/**"]
  repository_dispatch:
    types: [pull_request]
  schedule:
    - cron: "30 23 * * 1" # 2330 UTC Every Monday

env:
  PYTHON_VERSION: 3.9
  POETRY_PATH: "$HOME/.poetry/bin"

jobs:
  code_analysis:
    name: Code Analysis
    runs-on: ubuntu-latest
    permissions:
      actions: read
      contents: read
      security-events: write
    strategy:
      fail-fast: false
      matrix:
        language: ["python"]
    steps:
      - name: Checkout Code
        uses: actions/checkout@v2
      - name: Set up Python ${{ env.PYTHON_VERSION }}
        uses: actions/setup-python@v2
        with:
          python-version: ${{ env.PYTHON_VERSION }}
      - name: Change Directory
        run: cd ${{ github.workspace }}
      - name: Setup Environment
        run: make environment
      - name: Add Poetry Path
        run: echo ${{ env.POETRY_PATH }} >> $GITHUB_PATH
      - name: Install Dependencies
        run: make install
      - name: Lint
        run: make lint
      - name: Initialize CodeQL
        uses: github/codeql-action/init@v2
        with:
          languages: "${{ matrix.language }}"
      - name: Autobuild
        uses: github/codeql-action/autobuild@v2
      - name: Perform CodeQL Analysis
        uses: github/codeql-action/analyze@v2

  linux_check:
    name: Linux Check
    runs-on: ubuntu-latest
    steps:
      - name: Checkout Code
        uses: actions/checkout@v2
      - name: Set up Python ${{ env.PYTHON_VERSION }}
        uses: actions/setup-python@v2
        with:
          python-version: ${{ env.PYTHON_VERSION }}
      - name: Change Directory
        run: cd ${{ github.workspace }}
      - name: Setup Environment
        run: make environment
      - name: Add Poetry Path
        run: echo ${{ env.POETRY_PATH }} >> $GITHUB_PATH
      - name: Install Dependencies
        run: make install
      - name: Build
        run: make build validate
      - name: Full Test Suite & Coverage
        uses: nick-fields/retry@v2
        with:
          timeout_minutes: 10
          max_attempts: 1
          retry_on: timeout
          command: make coverage

  mac_check:
    name: MacOS Check
    runs-on: macos-latest
    steps:
      - name: Checkout Code
        uses: actions/checkout@v2
      - name: Set up Python ${{ env.PYTHON_VERSION }}
        uses: actions/setup-python@v2
        with:
          python-version: ${{ env.PYTHON_VERSION }}
      - name: Change Directory
        run: cd ${{ github.workspace }}
      - name: Setup Environment
        run: make environment
      - name: Add Poetry Path
        run: echo ${{ env.POETRY_PATH }} >> $GITHUB_PATH
      - name: Install Dependencies
        run: make install
      - name: Build
        run: make build validate
      - name: Integration Tests
        uses: nick-fields/retry@v2
        with:
          timeout_minutes: 3
          max_attempts: 1
          retry_on: timeout
          command: make test-integration


================================================
FILE: .github/workflows/release.yml
================================================
name: Release Build

on:
  milestone:
    types: [closed]

env:
  PYTHON_VERSION: 3.9
  POETRY_PATH: "$HOME/.poetry/bin"

jobs:
  code_analysis:
    name: Code Analysis
    runs-on: ubuntu-latest
    steps:
      - name: Checkout Code
        uses: actions/checkout@v2
      - name: Set up Python ${{ env.PYTHON_VERSION }}
        uses: actions/setup-python@v2
        with:
          python-version: ${{ env.PYTHON_VERSION }}
      - name: Change Directory
        run: cd ${{ github.workspace }}
      - name: Setup Environment
        run: make environment
      - name: Add Poetry Path
        run: echo ${{ env.POETRY_PATH }} >> $GITHUB_PATH
      - name: Install Dependencies
        run: make install
      - name: Lint
        run: make lint
      - name: Initialize CodeQL
        uses: github/codeql-action/init@v2
        with:
          languages: python
      - name: Autobuild
        uses: github/codeql-action/autobuild@v2
      - name: Perform CodeQL Analysis
        uses: github/codeql-action/analyze@v2

  linux_check:
    name: Linux Check
    runs-on: ubuntu-latest
    steps:
      - name: Checkout Code
        uses: actions/checkout@v2
      - name: Set up Python ${{ env.PYTHON_VERSION }}
        uses: actions/setup-python@v2
        with:
          python-version: ${{ env.PYTHON_VERSION }}
      - name: Change Directory
        run: cd ${{ github.workspace }}
      - name: Setup Environment
        run: make environment
      - name: Add Poetry Path
        run: echo ${{ env.POETRY_PATH }} >> $GITHUB_PATH
      - name: Install Dependencies
        run: make install
      - name: Build
        run: make build validate
      - name: Full Test Suite & Coverage
        run: make coverage

  mac_check:
    name: MacOS Check
    runs-on: macos-latest
    steps:
      - name: Checkout Code
        uses: actions/checkout@v2
      - name: Set up Python ${{ env.PYTHON_VERSION }}
        uses: actions/setup-python@v2
        with:
          python-version: ${{ env.PYTHON_VERSION }}
      - name: Change Directory
        run: cd ${{ github.workspace }}
      - name: Setup Environment
        run: make environment
      - name: Add Poetry Path
        run: echo ${{ env.POETRY_PATH }} >> $GITHUB_PATH
      - name: Install Dependencies
        run: make install
      - name: Build
        run: make build validate
      - name: Integration Tests
        run: make test-integration

  release:
    name: Release
    runs-on: ubuntu-latest
    needs: [code_analysis, mac_check, linux_check]
    steps:
      - name: Checkout Code
        uses: actions/checkout@v2
      - name: Set up Python ${{ env.PYTHON_VERSION }}
        uses: actions/setup-python@v1
        with:
          python-version: ${{ env.PYTHON_VERSION }}
      - name: Change Directory
        run: cd ${{ github.workspace }}
      - name: Setup Environment
        run: make environment
      - name: Add Poetry Path
        run: echo ${{ env.POETRY_PATH }} >> $GITHUB_PATH
      - name: Install Dependencies
        run: make install
      - name: Get Version
        run: echo "PACKAGE_VERSION=$(echo $VERSION | poetry version --short)" >> $GITHUB_ENV
      - name: Generate release notes
        run: make release-notes
      - name: Create Release
        id: create_release
        uses: actions/create-release@v1.0.0
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
        with:
          tag_name: ${{ env.PACKAGE_VERSION }}
          release_name: Release ${{ env.PACKAGE_VERSION }}
          draft: false
          prerelease: false
      - name: Dependency Graph
        run: make dependency-graph-ci
      - name: Upload Dependency Graph as Artifact
        uses: actions/upload-artifact@v2
        with:
          name: dependency-graph
          path: dependency-graph.svg
      - name: Build
        run: make build
      - name: Upload Package as Artifact
        uses: actions/upload-artifact@v2
        with:
          name: package
          path: dist/
      - name: Upload Package to PyPi
        env:
          TEST_PYPI_TOKEN: ${{ secrets.TEST_PYPI_TOKEN }}
          PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
        run: make publish-ci
      - name: Zip Artifacts
        run: make release-zip-ci
      - name: Add Artifacts to Release
        id: upload-release-asset_1
        uses: actions/upload-release-asset@v1.0.1
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
        with:
          upload_url: ${{ steps.create_release.outputs.upload_url }}
          asset_path: ./electionguard.zip
          asset_name: electionguard.zip
          asset_content_type: application/zip
      - name: Deploy Github Pages
        run: make docs-deploy-ci


================================================
FILE: .gitignore
================================================
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

data/0.95.0/
data/1.0/

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
pip-wheel-metadata/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
#  Usually these files are written by a python script from a template
#  before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.nox/
coverage/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
*.py,cover
.hypothesis/
.pytest_cache/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
target/

# Jupyter Notebook
.ipynb_checkpoints

# IPython
profile_default/
ipython_config.py

# pyenv
.python-version

# pipenv
#   According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
#   However, in case of collaboration, if having platform-specific dependencies or dependencies
#   having no cross-platform support, pipenv may install dependencies that don't work, or not
#   install all needed dependencies.
#Pipfile.lock

# PEP 582; used by e.g. github.com/David-OConnor/pyflow
__pypackages__/

# Celery stuff
celerybeat-schedule
celerybeat.pid

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/
.dmypy.json
dmypy.json

# Pyre type checker
.pyre/

# PyCharm
.idea/

coverage/

cov.xml

.DS_Store

# File output
election_record
election_private_data
guardian_private_data.json
election_record.zip
election_private_data.zip
schemas

# VS Code
.vscode/settings.json
sample-data.zip*

results/
gui_private_keys/
database/
egui_mnt/


================================================
FILE: .vscode/extensions.json
================================================
{
  // See https://go.microsoft.com/fwlink/?LinkId=827846 to learn about workspace recommendations.
  // Extension identifier format: ${publisher}.${name}. Example: vscode.csharp

  // List of extensions which should be recommended for users of this workspace.
  "recommendations": [
    "ms-python.python",
    "visualstudioexptteam.vscodeintellicode",
    "magicstack.magicpython",
    "hbenl.vscode-test-explorer",
    "littlefoxteam.vscode-python-test-adapter",
    "cschleiden.vscode-github-actions",
    "bungcip.better-toml"
  ],
  // List of extensions recommended by VS Code that should not be recommended for users of this workspace.
  "unwantedRecommendations": []
}


================================================
FILE: CODE_OF_CONDUCT.md
================================================
# Microsoft Open Source Code of Conduct

This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).

Resources:

- [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/)
- [Microsoft Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/)
- Contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with questions or concerns


================================================
FILE: CONTRIBUTING.md
================================================
## Contributing

This project welcomes contributions and suggestions. Before you get started, you should read the [readme](README.md) and [the design and architecture notes](docs/Design_and_Architecture.md), which describe design & architecture goals of the code and tools & techniques used.

- 🤔 **CONSIDER** adding a unit test if your PR resolves an issue.
- ✅ **DO** check open PR's to avoid duplicates.
- ✅ **DO** keep pull requests small so they can be easily reviewed.
- ✅ **DO** build locally before pushing.
- ✅ **DO** make sure tests pass.
- ✅ **DO** make sure any new changes are documented.
- ✅ **DO** make sure not to introduce any compiler warnings.
- ❌**AVOID** breaking the continuous integration build.
- ❌**AVOID** making significant changes to the overall architecture.

### Creating a Pull Request

All pull requests should have an accompanying issue. Create one if there is not one matching your code. The code will be checked by continuous integration. Once this CI passes, the code will be reviewed, ideally approved, then merged.

### CLA

Open source contributions require you to agree to a standard Microsoft Contributor License Agreement (CLA) declaring that you grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.

When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

### Code of Conduct

This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.


================================================
FILE: LICENSE
================================================
    MIT License

    Copyright (c) Microsoft Corporation.

    Permission is hereby granted, free of charge, to any person obtaining a copy
    of this software and associated documentation files (the "Software"), to deal
    in the Software without restriction, including without limitation the rights
    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
    copies of the Software, and to permit persons to whom the Software is
    furnished to do so, subject to the following conditions:

    The above copyright notice and this permission notice shall be included in all
    copies or substantial portions of the Software.

    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
    SOFTWARE


================================================
FILE: Makefile
================================================
.PHONY: all environment openssl-fix install install-gmp install-gmp-mac install-gmp-linux install-gmp-windows install-mkdocs auto-lint validate test test-example bench coverage coverage-html coverage-xml coverage-erase fetch-sample-data

CODE_COVERAGE ?= 90
OS ?= $(shell python3 -c 'import platform; print(platform.system())')
ifeq ($(OS), Linux)
PKG_MGR ?= $(shell python3 -c 'import subprocess as sub; print(next(filter(None, (sub.getstatusoutput(f"command -v {pm}")[0] == 0 and pm for pm in ["apt-get", "pacman"])), "undefined"))')
endif
SAMPLE_BALLOT_COUNT ?= 5
SAMPLE_BALLOT_SPOIL_RATE ?= 50

all: environment install build validate auto-lint coverage

environment:
	@echo 🔧 ENVIRONMENT SETUP
	make install-gmp
	python3 -m pip install -U pip
	pip3 install 'poetry==2.2.1'
	poetry config virtualenvs.in-project true 
	printf "Cython<3\n" > /tmp/pip-constraints.txt
	PIP_CONSTRAINT=/tmp/pip-constraints.txt poetry install
	poetry run pip install 'setuptools<83'
	@echo 🚨 Be sure to add poetry to PATH
	make fetch-sample-data

install:
	@echo 🔧 INSTALL
	poetry install
	poetry run pip install 'setuptools<83'

build:
	@echo 🔨 BUILD
	poetry build
	poetry install 
	poetry run pip install 'setuptools<83'

openssl-fix:
	export LDFLAGS=-L/usr/local/opt/openssl/lib
	export CPPFLAGS=-I/usr/local/opt/openssl/include 

install-gmp:
	@echo 📦 Install gmp
	@echo Operating System identified as $(OS)
ifeq ($(OS), Linux)
	make install-gmp-linux
endif
ifeq ($(OS), Darwin)
	make install-gmp-mac
endif

install-gmp-mac:
	@echo 🍎 MACOS INSTALL
	brew install gmp || true
	brew install mpfr || true
	brew install libmpc || true

install-gmp-linux:
	@echo 🐧 LINUX INSTALL
ifeq ($(PKG_MGR), apt-get)
	sudo apt-get update
	sudo apt-get install libgmp-dev
	sudo apt-get install libmpfr-dev
	sudo apt-get install libmpc-dev
else ifeq ($(PKG_MGR), pacman)
	sudo pacman -S gmp
else ifeq ($(PKG_MGR), undefined)
	@echo "We could not install GMP automatically for your Linux distribution. Please, install GMP manually."
endif

lint:
	@echo 💚 LINT
	@echo 1.Pylint
	make pylint
	@echo 2.Black Formatting
	make blackcheck
	@echo 3.Mypy Static Typing
	make mypy
	@echo 4.Package Metadata
	poetry build
	poetry run twine check dist/*
	@echo 5.Documentation
	poetry run mkdocs build --strict

auto-lint:
	@echo 💚 AUTO LINT
	@echo Auto-generating __init__
	poetry run mkinit src/electionguard --write --black
	poetry run mkinit src/electionguard_tools --write --recursive --black
	poetry run mkinit src/electionguard_verify --write --black
	poetry run mkinit src/electionguard_cli --write --recursive --black
	poetry run mkinit src/electionguard_gui --write --recursive --black
	@echo Reformatting using Black
	make blackformat
	make lint
	
pylint:
	poetry run pylint --extension-pkg-allow-list=dependency_injector ./src ./tests

blackformat:
	poetry run black .

blackcheck:
	poetry run black --check .

mypy:
	poetry run mypy src/electionguard src/electionguard_tools src/electionguard_cli src/electionguard_gui stubs

validate: 
	@echo ✅ VALIDATE
	@poetry run python3 -c 'import electionguard; print(electionguard.__package__ + " successfully imported")'

# Test
unit-tests:
	@echo ✅ UNIT TESTS
	poetry run pytest tests/unit

property-tests:
	@echo ✅ PROPERTY TESTS
	poetry run pytest tests/property

integration-tests:
	@echo ✅ INTEGRATION TESTS
	poetry run pytest tests/integration

test: 
	@echo ✅ ALL TESTS
	make unit-tests
	make property-tests
	make integration-tests

test-example:
	@echo ✅ TEST Example
	poetry run python3 -m pytest -s tests/integration/test_end_to_end_election.py

test-integration:
	@echo ✅ INTEGRATION TESTS
	poetry run pytest tests/integration

# Coverage
coverage:
	@echo ✅ COVERAGE
	poetry run coverage run -m pytest
	poetry run coverage report --fail-under=$(CODE_COVERAGE)

coverage-html:
	poetry run coverage html -d coverage

coverage-xml:
	poetry run coverage xml

coverage-erase:
	@poetry run coverage erase

# Benchmark
bench:
	@echo 📊 BENCHMARKS
	poetry run python3 -s tests/bench/bench_chaum_pedersen.py

# Documentation
install-mkdocs:
	pip install mkdocs
	pip install mkdocs-jupyter

docs-serve:
	poetry run mkdocs serve

docs-build:
	poetry run mkdocs build

docs-deploy:
	@echo 🚀 DEPLOY to Github Pages
	poetry run mkdocs gh-deploy --force

docs-deploy-ci:
	@echo 🚀 DEPLOY to Github Pages
	poetry run mkdocs gh-deploy --force

dependency-graph:
	poetry run pydeps --noshow --max-bacon 2 -o dependency-graph.svg src/electionguard

dependency-graph-ci:
	sudo apt install graphviz
	poetry run pydeps --noshow --max-bacon 2 -o dependency-graph.svg src/electionguard

# Sample Data
fetch-sample-data:
	@echo ⬇️ FETCH Sample Data
ifeq ($(OS), Windows)
	choco install wget
	choco install unzip
endif
	wget -O sample-data.zip https://github.com/microsoft/electionguard/releases/download/v1.0/sample-data.zip
	unzip -o sample-data.zip

generate-sample-data:
	@echo 🔁 GENERATE Sample Data
	poetry run python3 src/electionguard_tools/scripts/sample_generator.py -m "hamilton-general" -n $(SAMPLE_BALLOT_COUNT) -s $(SAMPLE_BALLOT_SPOIL_RATE)

# Publish
publish:
	poetry publish

publish-ci:
	@echo 🚀 PUBLISH
	poetry publish --username __token__ --password $(PYPI_TOKEN)

publish-test:
	poetry publish --repository testpypi

publish-test-ci:
	@echo 🚀 PUBLISH TEST
	poetry publish --repository testpypi --username __token__ --password $(TEST_PYPI_TOKEN)

# Release
release-zip-ci:
	@echo 📁 ZIP RELEASE ARTIFACTS
	mv dist electionguard
	mv dependency-graph.svg electionguard
	zip -r electionguard.zip electionguard

release-notes:
	@echo 📝 GENERATE RELEASE NOTES
	export MILESTONE_NUM=$(cat ${GITHUB_EVENT_PATH} | jq '.milestone.number')
	export MILESTONE_URL=$(cat ${GITHUB_EVENT_PATH} | jq '.milestone.url')
	export MILESTONE_TITLE=$(cat ${GITHUB_EVENT_PATH} | jq '.milestone.title')
	export MILESTONE_DESCRIPTION=$(cat ${GITHUB_EVENT_PATH} | jq '.milestone.description')
	touch release_notes.md
	echo "# ${MILESTONE_TITLE}" >> release_notes.md
	echo "${MILESTONE_DESCRIPTION}" >> release_notes.md
	echo -en "\n" >> release_notes.md
	echo "## Issues" >> release_notes.md
	curl "${GITHUB_API_URL}/${GITHUB_REPOSITORY}/issues?milestone=${MILESTONE_NUM}&state=all" | jq '.[].title' | while read i; do echo "[$i](${MILESTONE_URL})" >> release_notes.md; done

egui:
ifeq "${EG_DB_PASSWORD}" ""
	@echo "Set the EG_DB_PASSWORD environment variable"
	exit 1
endif
	poetry run egui

start-db:
ifeq "${EG_DB_PASSWORD}" ""
	@echo "Set the EG_DB_PASSWORD environment variable"
	exit 1
endif
	docker compose --env-file ./.env -f src/electionguard_db/docker-compose.db.yml up -d

stop-db:
	docker compose --env-file ./.env -f src/electionguard_db/docker-compose.db.yml down

build-egui:
	docker build -t egui -f ./src/electionguard_gui/Dockerfile .

start-egui: build-egui
ifeq "${EG_DB_PASSWORD}" ""
	@echo "Set the EG_DB_PASSWORD environment variable"
	exit 1
endif
	docker compose --env-file ./.env -f src/electionguard_gui/docker-compose.yml up -d

stop-egui:
	docker compose --env-file ./.env -f src/electionguard_gui/docker-compose.yml down

eg-e2e-simple-election:
	poetry run eg e2e --guardian-count=2 --quorum=2 --manifest=data/election_manifest_simple.json --ballots=data/plaintext_ballots_simple.json --spoil-id=25a7111b-4334-425a-87c1-f7a49f42b3a2 --output-record="./election_record.zip"

eg-setup-simple-election:
	poetry run eg setup --guardian-count=2 --quorum=2 --manifest=data/election_manifest_simple.json  --package-dir=../data/out/public_encryption_package --keys-dir=../data/out/test_data_private_guardian_data


================================================
FILE: README.md
================================================
![Microsoft Defending Democracy Program: ElectionGuard Python][banner image]

# 🗳 ElectionGuard Python

[![ElectionGuard Specification 0.95.0](https://img.shields.io/badge/🗳%20ElectionGuard%20Specification-0.95.0-green)](https://www.electionguard.vote) ![Github Package Action](https://github.com/microsoft/electionguard-python/workflows/Release%20Build/badge.svg) [![](https://img.shields.io/pypi/v/electionguard)](https://pypi.org/project/electionguard/) [![](https://img.shields.io/pypi/dm/electionguard)](https://pypi.org/project/electionguard/) [![Language grade: Python](https://img.shields.io/lgtm/grade/python/g/microsoft/electionguard-python.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/microsoft/electionguard-python/context:python) [![Total alerts](https://img.shields.io/lgtm/alerts/g/microsoft/electionguard-python.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/microsoft/electionguard-python/alerts/) [![Documentation Status](https://readthedocs.org/projects/electionguard-python/badge/?version=latest)](https://electionguard-python.readthedocs.io) [![license](https://img.shields.io/github/license/microsoft/electionguard)](https://github.com/microsoft/electionguard-python/blob/main/LICENSE)

This repository is a "reference implementation" of ElectionGuard written in Python 3. This implementation can be used to conduct End-to-End Verifiable Elections as well as privacy-enhanced risk-limiting audits. Components of this library can also be used to construct "Verifiers" to validate the results of an ElectionGuard election.

## 📁 In This Repository

| File/folder                                             | Description                                    |
| ------------------------------------------------------- | ---------------------------------------------- |
| [docs](/docs)                                           | Documentation for using the library.           |
| [src/electionguard](/src/electionguard)                 | ElectionGuard library.                         |
| [src/electionguard_tools](/src/electionguard_tools)     | Tools for testing and sample data.             |
| [src/electionguard_verifier](/src/electionguard_verify) | Verifier to validate the validity of a ballot. |
| [stubs](/stubs)                                         | Type annotations for external libraries.       |
| [tests](/tests)                                         | Tests to exercise this codebase.               |
| [CONTRIBUTING.md](/CONTRIBUTING.md)                     | Guidelines for contributing.                   |
| [README.md](/README.md)                                 | This README file.                              |
| [LICENSE](/LICENSE)                                     | The license for ElectionGuard-Python.          |
| [data](/data)                                           | Sample election data.                          |

## ❓ What Is ElectionGuard?

ElectionGuard is an open source software development kit (SDK) that makes voting more secure, transparent and accessible. The ElectionGuard SDK leverages homomorphic encryption to ensure that votes recorded by electronic systems of any type remain encrypted, secure, and secret. Meanwhile, ElectionGuard also allows verifiable and accurate tallying of ballots by any 3rd party organization without compromising secrecy or security.

Learn More in the [ElectionGuard Repository](https://github.com/microsoft/electionguard)

## 🦸 How Can I use ElectionGuard?

ElectionGuard supports a variety of use cases. The Primary use case is to generate verifiable end-to-end (E2E) encrypted elections. The ElectionGuard process can also be used for other use cases such as privacy enhanced risk-limiting audits (RLAs).

## 💻 Requirements

- [Python 3.9+](https://www.python.org/downloads/) is <ins>**required**</ins> to develop this SDK. If developer uses multiple versions of python, [pyenv](https://github.com/pyenv/pyenv) is suggested to assist version management.
- [GNU Make](https://www.gnu.org/software/make/manual/make.html) is used to simplify the commands and GitHub Actions. This approach is recommended to simplify the command line experience. This is built in for MacOS and Linux. For Windows, setup is simpler with [Chocolatey](https://chocolatey.org/install) and installing the provided [make package](https://chocolatey.org/packages/make). The other Windows option is [manually installing make](http://gnuwin32.sourceforge.net/packages/make.htm).
- [Gmpy2](https://gmpy2.readthedocs.io/en/latest/) is used for [Arbitrary-precision arithmetic](https://en.wikipedia.org/wiki/Arbitrary-precision_arithmetic) which
  has its own [installation requirements (native C libraries)](https://gmpy2.readthedocs.io/en/latest/intro.html#installation) on Linux and MacOS. **⚠️ Note:** _This is not required for Windows since the gmpy2 precompiled libraries are provided._
- [poetry 2.2.1](https://python-poetry.org/) is used to configure the python environment. Installation instructions can be found [here](https://python-poetry.org/docs/#installation).

## 🚀 Quick Start

Using [**make**](https://www.gnu.org/software/make/manual/make.html), the entire [GitHub Action workflow][pull request workflow] can be run with one command:

```
make
```

The unit and integration tests can also be run with make:

```
make test
```

A complete end-to-end election example can be run independently by executing:

```
make test-example
```

For more detailed build and run options, see the [documentation][build and run].

## 📄 Documentation

Overviews:

- [GitHub Pages](https://microsoft.github.io/electionguard-python/)
- [Read the Docs](https://electionguard-python.readthedocs.io/)

Sections:

- [Design and Architecture]
- [Build and Run]
- [Project Workflow]
- [Election Manifest]

Step-by-Step Process:

0. [Configure Election]
1. [Key Ceremony]
2. [Encrypt Ballots]
3. [Cast and Spoil]
4. [Decrypt Tally]
5. [Publish and Verify]

## Contributing

This project encourages community contributions for development, testing, documentation, code review, and performance analysis, etc. For more information on how to contribute, see [the contribution guidelines][contributing]

### Code of Conduct

This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.

### Reporting Issues

Please report any bugs, feature requests, or enhancements using the [GitHub Issue Tracker](https://github.com/microsoft/electionguard-python/issues). Please do not report any security vulnerabilities using the Issue Tracker. Instead, please report them to the Microsoft Security Response Center (MSRC) at [https://msrc.microsoft.com/create-report](https://msrc.microsoft.com/create-report). See the [Security Documentation][security] for more information.

### Have Questions?

Electionguard would love for you to ask questions out in the open using GitHub Issues. If you really want to email the ElectionGuard team, reach out at electionguard@microsoft.com.

## License

This repository is licensed under the [MIT License]

## Thanks! 🎉

A huge thank you to those who helped to contribute to this project so far, including:

**[Josh Benaloh _(Microsoft)_](https://www.microsoft.com/en-us/research/people/benaloh/)**

<a href="https://www.microsoft.com/en-us/research/people/benaloh/"><img src="https://www.microsoft.com/en-us/research/wp-content/uploads/2016/09/avatar_user__1473484671-180x180.jpg" title="Josh Benaloh" width="80" height="80"></a>

**[Keith Fung](https://github.com/keithrfung) [_(InfernoRed Technology)_](https://infernored.com/)**

<a href="https://github.com/keithrfung"><img src="https://avatars2.githubusercontent.com/u/10125297?v=4" title="keithrfung" width="80" height="80"></a>

**[Matt Wilhelm](https://github.com/AddressXception) [_(InfernoRed Technology)_](https://infernored.com/)**

<a href="https://github.com/AddressXception"><img src="https://avatars0.githubusercontent.com/u/6232853?s=460&u=8fec95386acad6109ad71a2aad2d097b607ebd6a&v=4" title="AddressXception" width="80" height="80"></a>

**[Dan S. Wallach](https://www.cs.rice.edu/~dwallach/) [_(Rice University)_](https://www.rice.edu/)**

<a href="https://www.cs.rice.edu/~dwallach/"><img src="https://avatars2.githubusercontent.com/u/743029?v=4" title="danwallach" width="80" height="80"></a>

<!-- Links -->

[banner image]: https://raw.githubusercontent.com/microsoft/electionguard-python/main/images/electionguard-banner.svg
[pull request workflow]: https://github.com/microsoft/electionguard-python/blob/main/.github/workflows/pull_request.yml
[contributing]: https://github.com/microsoft/electionguard-python/blob/main/CONTRIBUTING.md
[security]: https://github.com/microsoft/electionguard-python/blob/main/SECURITY.md
[design and architecture]: https://github.com/microsoft/electionguard-python/blob/main/docs/Design_and_Architecture.md
[build and run]: https://github.com/microsoft/electionguard-python/blob/main/docs/Build_and_Run.md
[project workflow]: https://github.com/microsoft/electionguard-python/blob/main/docs/Project_Workflow.md
[election manifest]: https://github.com/microsoft/electionguard-python/blob/main/docs/Election_Manifest.md
[configure election]: https://github.com/microsoft/electionguard-python/blob/main/docs/0_Configure_Election.md
[key ceremony]: https://github.com/microsoft/electionguard-python/blob/main/docs/1_Key_Ceremony.md
[encrypt ballots]: https://github.com/microsoft/electionguard-python/blob/main/docs/2_Encrypt_Ballots.md
[cast and spoil]: https://github.com/microsoft/electionguard-python/blob/main/docs/3_Cast_and_Spoil.md
[decrypt tally]: https://github.com/microsoft/electionguard-python/blob/main/docs/4_Decrypt_Tally.md
[publish and verify]: https://github.com/microsoft/electionguard-python/blob/main/docs/5_Publish_and_Verify.md
[mit license]: https://github.com/microsoft/electionguard-python/blob/main/LICENSE


================================================
FILE: SECURITY.md
================================================
<!-- BEGIN MICROSOFT SECURITY.MD V0.0.3 BLOCK -->

## Security

Microsoft takes the security of our software products and services seriously, which includes all source code repositories managed through our GitHub organizations, which include [Microsoft](https://github.com/Microsoft), [Azure](https://github.com/Azure), [DotNet](https://github.com/dotnet), [AspNet](https://github.com/aspnet), [Xamarin](https://github.com/xamarin), and [our GitHub organizations](https://opensource.microsoft.com/).

If you believe you have found a security vulnerability in any Microsoft-owned repository that meets Microsoft's [Microsoft's definition of a security vulnerability](https://docs.microsoft.com/en-us/previous-versions/tn-archive/cc751383(v=technet.10)) of a security vulnerability, please report it to us as described below.

## Reporting Security Issues

**Please do not report security vulnerabilities through public GitHub issues.**

Instead, please report them to the Microsoft Security Response Center (MSRC) at [https://msrc.microsoft.com/create-report](https://msrc.microsoft.com/create-report).

If you prefer to submit without logging in, send email to [secure@microsoft.com](mailto:secure@microsoft.com).  If possible, encrypt your message with our PGP key; please download it from the the [Microsoft Security Response Center PGP Key page](https://www.microsoft.com/en-us/msrc/pgp-key-msrc).

You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://www.microsoft.com/msrc).

Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue:

  * Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.)
  * Full paths of source file(s) related to the manifestation of the issue
  * The location of the affected source code (tag/branch/commit or direct URL)
  * Any special configuration required to reproduce the issue
  * Step-by-step instructions to reproduce the issue
  * Proof-of-concept or exploit code (if possible)
  * Impact of the issue, including how an attacker might exploit the issue

This information will help us triage your report more quickly.

If you are reporting for a bug bounty, more complete reports can contribute to a higher bounty award. Please visit our [Microsoft Bug Bounty Program](https://microsoft.com/msrc/bounty) page for more details about our active programs.

## Preferred Languages

We prefer all communications to be in English.

## Policy

Microsoft follows the principle of [Coordinated Vulnerability Disclosure](https://www.microsoft.com/en-us/msrc/cvd).

<!-- END MICROSOFT SECURITY.MD BLOCK -->


================================================
FILE: data/ballot_in_simple.json
================================================
{
  "object_id": "some-external-id-string-123",
  "style_id": "jefferson-county-ballot-style",
  "contests": [
    {
      "object_id": "justice-supreme-court",
      "sequence_order": 0,
      "ballot_selections": [
        {
          "object_id": "john-adams-selection",
          "sequence_order": 0,
          "vote": 1
        },
        {
          "object_id": "write-in-selection",
          "sequence_order": 3,
          "vote": 1,
          "extended_data": {
            "value": "Susan B. Anthony",
            "length": 16
          }
        }
      ]
    }
  ]
}


================================================
FILE: data/election_manifest_simple.json
================================================
{
  "spec_version": "v0.95",
  "geopolitical_units": [
    {
      "object_id": "jefferson-county",
      "name": "Jefferson County",
      "type": "county",
      "contact_information": {
        "address_line": ["1234 Samuel Adams Way", "Jefferson, Hamilton 999999"],
        "name": "Jefferson County Clerk",
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@jefferson.hamilton.state.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ]
      }
    },
    {
      "object_id": "harrison-township",
      "name": "Harrison Township",
      "type": "township",
      "contact_information": {
        "address_line": ["1234 Thorton Drive", "Harrison, Hamilton 999999"],
        "name": "Harrison Town Hall",
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@harrison.hamilton.state.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ]
      }
    },
    {
      "object_id": "harrison-township-precinct-east",
      "name": "Harrison Township Precinct",
      "type": "township",
      "contact_information": {
        "address_line": ["1234 Thorton Drive", "Harrison, Hamilton 999999"],
        "name": "Harrison Town Hall",
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@harrison.hamilton.state.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ]
      }
    },
    {
      "object_id": "rutledge-elementary",
      "name": "Rutledge Elementary School district",
      "type": "school",
      "contact_information": {
        "address_line": ["1234 Wolcott Parkway", "Harrison, Hamilton 999999"],
        "name": "Rutledge Elementary School",
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@harrison.hamilton.state.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ]
      }
    }
  ],
  "parties": [
    {
      "object_id": "whig",
      "abbreviation": "WHI",
      "color": "AAAAAA",
      "logo_uri": "http://some/path/to/whig.svg",
      "name": {
        "text": [
          {
            "value": "Whig Party",
            "language": "en"
          }
        ]
      }
    },
    {
      "object_id": "federalist",
      "abbreviation": "FED",
      "color": "CCCCCC",
      "logo_uri": "http://some/path/to/federalist.svg",
      "name": {
        "text": [
          {
            "value": "Federalist Party",
            "language": "en"
          }
        ]
      }
    },
    {
      "object_id": "democratic-republican",
      "abbreviation": "DEMREP",
      "color": "EEEEEE",
      "logo_uri": "http://some/path/to/democratic-repulbican.svg",
      "name": {
        "text": [
          {
            "value": "Democratic Republican Party",
            "language": "en"
          }
        ]
      }
    }
  ],
  "candidates": [
    {
      "object_id": "benjamin-franklin",
      "name": {
        "text": [
          {
            "value": "Benjamin Franklin",
            "language": "en"
          }
        ]
      },
      "party_id": "whig"
    },
    {
      "object_id": "john-adams",
      "name": {
        "text": [
          {
            "value": "John Adams",
            "language": "en"
          }
        ]
      },
      "party_id": "federalist"
    },
    {
      "object_id": "john-hancock",
      "name": {
        "text": [
          {
            "value": "John Hancock",
            "language": "en"
          }
        ]
      },
      "party_id": "democratic-republican"
    },
    {
      "object_id": "write-in",
      "name": {
        "text": [
          {
            "value": "Write In Candidate",
            "language": "en"
          },
          {
            "value": "Escribir en la candidata",
            "language": "es"
          }
        ]
      },
      "is_write_in": true
    },
    {
      "object_id": "referendum-pineapple-affirmative",
      "name": {
        "text": [
          {
            "value": "Pineapple should be banned on pizza",
            "language": "en"
          }
        ]
      }
    },
    {
      "object_id": "referendum-pineapple-negative",
      "name": {
        "text": [
          {
            "value": "Pineapple should not be banned on pizza",
            "language": "en"
          }
        ]
      }
    }
  ],
  "contests": [
    {
      "object_id": "justice-supreme-court",
      "sequence_order": 1,
      "ballot_selections": [
        {
          "object_id": "john-adams-selection",
          "sequence_order": 1,
          "candidate_id": "john-adams"
        },
        {
          "object_id": "benjamin-franklin-selection",
          "sequence_order": 2,
          "candidate_id": "benjamin-franklin"
        },
        {
          "object_id": "john-hancock-selection",
          "sequence_order": 3,
          "candidate_id": "john-hancock"
        },
        {
          "object_id": "write-in-selection",
          "sequence_order": 4,
          "candidate_id": "write-in"
        }
      ],
      "ballot_title": {
        "text": [
          {
            "value": "Justice of the Supreme Court",
            "language": "en"
          },
          {
            "value": "Juez de la corte suprema",
            "language": "es"
          }
        ]
      },
      "ballot_subtitle": {
        "text": [
          {
            "value": "Please choose up to two candidates",
            "language": "en"
          },
          {
            "value": "Uno",
            "language": "es"
          }
        ]
      },
      "vote_variation": "n_of_m",
      "electoral_district_id": "jefferson-county",
      "name": "Justice of the Supreme Court",
      "number_elected": 2,
      "votes_allowed": 2
    },
    {
      "object_id": "referendum-pineapple",
      "sequence_order": 2,
      "ballot_selections": [
        {
          "object_id": "referendum-pineapple-affirmative-selection",
          "sequence_order": 1,
          "candidate_id": "referendum-pineapple-affirmative"
        },
        {
          "object_id": "referendum-pineapple-negative-selection",
          "sequence_order": 2,
          "candidate_id": "referendum-pineapple-negative"
        }
      ],
      "ballot_title": {
        "text": [
          {
            "value": "Should pineapple be banned on pizza?",
            "language": "en"
          },
          {
            "value": "¿Debería prohibirse la piña en la pizza?",
            "language": "es"
          }
        ]
      },
      "ballot_subtitle": {
        "text": [
          {
            "value": "The township considers this issue to be very important",
            "language": "en"
          },
          {
            "value": "El municipio considera que esta cuestión es muy importante",
            "language": "es"
          }
        ]
      },
      "vote_variation": "one_of_m",
      "electoral_district_id": "harrison-township",
      "name": "The Pineapple Question",
      "number_elected": 1,
      "votes_allowed": 1
    }
  ],
  "ballot_styles": [
    {
      "object_id": "jefferson-county-ballot-style",
      "geopolitical_unit_ids": ["jefferson-county"]
    },
    {
      "object_id": "harrison-township-ballot-style",
      "geopolitical_unit_ids": ["jefferson-county", "harrison-township"]
    },
    {
      "object_id": "harrison-township-precinct-east-ballot-style",
      "geopolitical_unit_ids": [
        "jefferson-county",
        "harrison-township",
        "harrison-township-precinct-east",
        "rutledge-elementary"
      ]
    },
    {
      "object_id": "rutledge-elementary-ballot-style",
      "geopolitical_unit_ids": [
        "jefferson-county",
        "harrison-township",
        "rutledge-elementary"
      ]
    }
  ],
  "name": {
    "text": [
      {
        "value": "Jefferson County Spring Primary",
        "language": "en"
      },
      {
        "value": "Primaria de primavera del condado de Jefferson",
        "language": "es"
      }
    ]
  },
  "contact_information": {
    "address_line": ["1234 Paul Revere Run", "Jefferson, Hamilton 999999"],
    "name": "Hamilton State Election Commission",
    "email": [
      {
        "annotation": "press",
        "value": "inquiries@hamilton.state.gov"
      },
      {
        "annotation": "federal",
        "value": "commissioner@hamilton.state.gov"
      }
    ],
    "phone": [
      {
        "annotation": "domestic",
        "value": "123-456-7890"
      },
      {
        "annotation": "international",
        "value": "+1-123-456-7890"
      }
    ]
  },
  "start_date": "2020-03-01T08:00:00-05:00",
  "end_date": "2020-03-01T20:00:00-05:00",
  "election_scope_id": "jefferson-county-primary",
  "type": "primary"
}


================================================
FILE: data/manifest-full.json
================================================
{
  "election_scope_id": "jefferson-county-primary",
  "spec_version": "1.0",
  "type": "primary",
  "start_date": "2020-03-01T08:00:00-05:00",
  "end_date": "2020-03-01T20:00:00-05:00",
  "geopolitical_units": [
    {
      "object_id": "jefferson-county",
      "name": "Jefferson County",
      "type": "county",
      "contact_information": {
        "address_line": [
          "1234 Samuel Adams Way",
          "Jefferson, Hamilton 999999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@jefferson.hamilton.state.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "Jefferson County Clerk"
      }
    },
    {
      "object_id": "harrison-township",
      "name": "Harrison Township",
      "type": "township",
      "contact_information": {
        "address_line": [
          "1234 Thorton Drive",
          "Harrison, Hamilton 999999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@harrison.hamilton.state.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "Harrison Town Hall"
      }
    },
    {
      "object_id": "harrison-township-precinct-east",
      "name": "Harrison Township Precinct",
      "type": "township",
      "contact_information": {
        "address_line": [
          "1234 Thorton Drive",
          "Harrison, Hamilton 999999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@harrison.hamilton.state.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "Harrison Town Hall"
      }
    },
    {
      "object_id": "rutledge-elementary",
      "name": "Rutledge Elementary School district",
      "type": "school",
      "contact_information": {
        "address_line": [
          "1234 Wolcott Parkway",
          "Harrison, Hamilton 999999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@harrison.hamilton.state.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "Rutledge Elementary School"
      }
    }
  ],
  "parties": [
    {
      "object_id": "whig",
      "name": {
        "text": [
          {
            "value": "Whig Party",
            "language": "en"
          }
        ]
      },
      "abbreviation": "WHI",
      "color": "AAAAAA",
      "logo_uri": "http://some/path/to/whig.svg"
    },
    {
      "object_id": "federalist",
      "name": {
        "text": [
          {
            "value": "Federalist Party",
            "language": "en"
          }
        ]
      },
      "abbreviation": "FED",
      "color": "CCCCCC",
      "logo_uri": "http://some/path/to/federalist.svg"
    },
    {
      "object_id": "democratic-republican",
      "name": {
        "text": [
          {
            "value": "Democratic Republican Party",
            "language": "en"
          }
        ]
      },
      "abbreviation": "DEMREP",
      "color": "EEEEEE",
      "logo_uri": "http://some/path/to/democratic-repulbican.svg"
    }
  ],
  "candidates": [
    {
      "object_id": "benjamin-franklin",
      "name": {
        "text": [
          {
            "value": "Benjamin Franklin",
            "language": "en"
          }
        ]
      },
      "party_id": "whig",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "john-adams",
      "name": {
        "text": [
          {
            "value": "John Adams",
            "language": "en"
          }
        ]
      },
      "party_id": "federalist",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "john-hancock",
      "name": {
        "text": [
          {
            "value": "John Hancock",
            "language": "en"
          }
        ]
      },
      "party_id": "democratic-republican",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "write-in",
      "name": {
        "text": [
          {
            "value": "Write In Candidate",
            "language": "en"
          },
          {
            "value": "Escribir en la candidata",
            "language": "es"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": true
    },
    {
      "object_id": "referendum-pineapple-affirmative",
      "name": {
        "text": [
          {
            "value": "Pineapple should be banned on pizza",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "referendum-pineapple-negative",
      "name": {
        "text": [
          {
            "value": "Pineapple should not be banned on pizza",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    }
  ],
  "contests": [
    {
      "object_id": "justice-supreme-court",
      "sequence_order": 0,
      "electoral_district_id": "jefferson-county",
      "vote_variation": "n_of_m",
      "number_elected": 2,
      "votes_allowed": 2,
      "name": "Justice of the Supreme Court",
      "ballot_selections": [
        {
          "object_id": "john-adams-selection",
          "sequence_order": 0,
          "candidate_id": "john-adams"
        },
        {
          "object_id": "benjamin-franklin-selection",
          "sequence_order": 1,
          "candidate_id": "benjamin-franklin"
        },
        {
          "object_id": "john-hancock-selection",
          "sequence_order": 2,
          "candidate_id": "john-hancock"
        },
        {
          "object_id": "write-in-selection",
          "sequence_order": 3,
          "candidate_id": "write-in"
        }
      ],
      "ballot_title": {
        "text": [
          {
            "value": "Justice of the Supreme Court",
            "language": "en"
          },
          {
            "value": "Juez de la corte suprema",
            "language": "es"
          }
        ]
      },
      "ballot_subtitle": {
        "text": [
          {
            "value": "Please choose up to two candidates",
            "language": "en"
          },
          {
            "value": "Uno",
            "language": "es"
          }
        ]
      }
    },
    {
      "object_id": "referendum-pineapple",
      "sequence_order": 1,
      "electoral_district_id": "harrison-township",
      "vote_variation": "one_of_m",
      "number_elected": 1,
      "votes_allowed": 1,
      "name": "The Pineapple Question",
      "ballot_selections": [
        {
          "object_id": "referendum-pineapple-affirmative-selection",
          "sequence_order": 0,
          "candidate_id": "referendum-pineapple-affirmative"
        },
        {
          "object_id": "referendum-pineapple-negative-selection",
          "sequence_order": 1,
          "candidate_id": "referendum-pineapple-negative"
        }
      ],
      "ballot_title": {
        "text": [
          {
            "value": "Should pineapple be banned on pizza?",
            "language": "en"
          },
          {
            "value": "\u00bfDeber\u00eda prohibirse la pi\u00f1a en la pizza?",
            "language": "es"
          }
        ]
      },
      "ballot_subtitle": {
        "text": [
          {
            "value": "The township considers this issue to be very important",
            "language": "en"
          },
          {
            "value": "El municipio considera que esta cuesti\u00f3n es muy importante",
            "language": "es"
          }
        ]
      }
    }
  ],
  "ballot_styles": [
    {
      "object_id": "jefferson-county-ballot-style",
      "geopolitical_unit_ids": [
        "jefferson-county"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "harrison-township-ballot-style",
      "geopolitical_unit_ids": [
        "jefferson-county",
        "harrison-township"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "harrison-township-precinct-east-ballot-style",
      "geopolitical_unit_ids": [
        "jefferson-county",
        "harrison-township",
        "harrison-township-precinct-east",
        "rutledge-elementary"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "rutledge-elementary-ballot-style",
      "geopolitical_unit_ids": [
        "jefferson-county",
        "harrison-township",
        "rutledge-elementary"
      ],
      "party_ids": null,
      "image_uri": null
    }
  ],
  "name": {
    "text": [
      {
        "value": "Jefferson County Spring Primary",
        "language": "en"
      },
      {
        "value": "Primaria de primavera del condado de Jefferson",
        "language": "es"
      }
    ]
  },
  "contact_information": {
    "address_line": [
      "1234 Paul Revere Run",
      "Jefferson, Hamilton 999999"
    ],
    "email": [
      {
        "annotation": "press",
        "value": "inquiries@hamilton.state.gov"
      },
      {
        "annotation": "federal",
        "value": "commissioner@hamilton.state.gov"
      }
    ],
    "phone": [
      {
        "annotation": "domestic",
        "value": "123-456-7890"
      },
      {
        "annotation": "international",
        "value": "+1-123-456-7890"
      }
    ],
    "name": "Hamilton State Election Commission"
  }
}

================================================
FILE: data/manifest-hamilton-general.json
================================================
{
  "election_scope_id": "hamilton-county-general-election",
  "spec_version": "1.0",
  "type": "general",
  "start_date": "2020-03-01T08:00:00-05:00",
  "end_date": "2020-03-01T20:00:00-05:00",
  "geopolitical_units": [
    {
      "object_id": "hamilton-county",
      "name": "Hamilton County",
      "type": "county",
      "contact_information": {
        "address_line": [
          "1234 Samuel Adams Way",
          "Hamilton, Ozark 99999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@hamiltoncounty.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "Hamilton County Clerk"
      }
    },
    {
      "object_id": "congress-district-5",
      "name": "Congressional District 5",
      "type": "congressional",
      "contact_information": {
        "address_line": [
          "1234 Somerville Gateway",
          "Medford, Ozark 999999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@congressional-district-5.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "Medford Town Hall"
      }
    },
    {
      "object_id": "congress-district-7",
      "name": "Congressional District 7",
      "type": "congressional",
      "contact_information": {
        "address_line": [
          "1234 Somerville Gateway",
          "Arlington, Ozark 999999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@congressional-district-7.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "Arlington Town Hall"
      }
    },
    {
      "object_id": "lacroix-township-precinct-1",
      "name": "LaCroix Township Precinct 1",
      "type": "precinct",
      "contact_information": {
        "address_line": [
          "1234 Thorton Drive",
          "LaCroix, Ozark 99999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@lacrox.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "LaCroix Town Hall"
      }
    },
    {
      "object_id": "lacroix-exeter-utility-district",
      "name": "Exeter Utility District",
      "type": "utility",
      "contact_information": {
        "address_line": [
          "1234 Watt Drive",
          "LaCroix, Ozark 99999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@exeter-utility.com"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "Exeter Utility District coordinator"
      }
    },
    {
      "object_id": "arlington-township-precinct-1",
      "name": "Arlington Township Precinct 1",
      "type": "precinct",
      "contact_information": {
        "address_line": [
          "1234 Pahk Avenue",
          "Arlinton, Ozark 99999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@arlington-township.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "Arlington Town Hall"
      }
    },
    {
      "object_id": "pismo-beach-school-district-precinct-1",
      "name": "Pismo Beach School District Precinct 1",
      "type": "school",
      "contact_information": {
        "address_line": [
          "1234 Pismo Beach Elementary",
          "Arlington, Ozark 99999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@pismo-beach-school.edu"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "Pismo Beah Elementary"
      }
    },
    {
      "object_id": "somerset-school-district-precinct-1",
      "name": "Somerset School District",
      "type": "school",
      "contact_information": {
        "address_line": [
          "1234 Somerset Avenue",
          "Arlinton, Ozark 99999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@somerset-elementary.edu"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "Someset Elementary"
      }
    },
    {
      "object_id": "harris-township",
      "name": "Harris Township",
      "type": "township",
      "contact_information": {
        "address_line": [
          "1234 Pahk Avenue",
          "Harris, Ozark 99999"
        ],
        "email": [
          {
            "annotation": "inquiries",
            "value": "inquiries@harris-township.gov"
          }
        ],
        "phone": [
          {
            "annotation": "domestic",
            "value": "123-456-7890"
          }
        ],
        "name": "harris Town Hall"
      }
    }
  ],
  "parties": [
    {
      "object_id": "whig",
      "name": {
        "text": [
          {
            "value": "Whig Party",
            "language": "en"
          }
        ]
      },
      "abbreviation": "WHI",
      "color": "AAAAAA",
      "logo_uri": "http://some/path/to/whig.svg"
    },
    {
      "object_id": "federalist",
      "name": {
        "text": [
          {
            "value": "Federalist Party",
            "language": "en"
          }
        ]
      },
      "abbreviation": "FED",
      "color": "BBBBBB",
      "logo_uri": "http://some/path/to/federalist.svg"
    },
    {
      "object_id": "peoples",
      "name": {
        "text": [
          {
            "value": "People's Party",
            "language": "en"
          }
        ]
      },
      "abbreviation": "PPL",
      "color": "CCCCCC",
      "logo_uri": "http://some/path/to/people-s.svg"
    },
    {
      "object_id": "liberty",
      "name": {
        "text": [
          {
            "value": "Liberty Party",
            "language": "en"
          }
        ]
      },
      "abbreviation": "LIB",
      "color": "DDDDDD",
      "logo_uri": "http://some/path/to/liberty.svg"
    },
    {
      "object_id": "constitution",
      "name": {
        "text": [
          {
            "value": "Constitution Party",
            "language": "en"
          }
        ]
      },
      "abbreviation": "CONST",
      "color": "EEEEEE",
      "logo_uri": "http://some/path/to/democratic-repulbican.svg"
    },
    {
      "object_id": "labor",
      "name": {
        "text": [
          {
            "value": "Labor Party",
            "language": "en"
          }
        ]
      },
      "abbreviation": "LBR",
      "color": "FFFFFF",
      "logo_uri": "http://some/path/to/laobr.svg"
    },
    {
      "object_id": "independent",
      "name": {
        "text": [
          {
            "value": "Independent",
            "language": "en"
          }
        ]
      },
      "abbreviation": "IND",
      "color": "000000",
      "logo_uri": "http://some/path/to/independent.svg"
    }
  ],
  "candidates": [
    {
      "object_id": "barchi-hallaren",
      "name": {
        "text": [
          {
            "value": "Joseph Barchi and Joseph Hallaren",
            "language": "en"
          }
        ]
      },
      "party_id": "whig",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "cramer-vuocolo",
      "name": {
        "text": [
          {
            "value": "Adam Cramer and Greg Vuocolo",
            "language": "en"
          }
        ]
      },
      "party_id": "federalist",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "court-blumhardt",
      "name": {
        "text": [
          {
            "value": "Daniel Court and Amy Blumhardt",
            "language": "en"
          }
        ]
      },
      "party_id": "peoples",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "boone-lian",
      "name": {
        "text": [
          {
            "value": "Alvin Boone and James Lian",
            "language": "en"
          }
        ]
      },
      "party_id": "liberty",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "hildebrand-garritty",
      "name": {
        "text": [
          {
            "value": "Ashley Hildebrand-McDougall and James Garritty",
            "language": "en"
          }
        ]
      },
      "party_id": "constitution",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "patterson-lariviere",
      "name": {
        "text": [
          {
            "value": "Martin Patterson and Clay Lariviere",
            "language": "en"
          }
        ]
      },
      "party_id": "labor",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "franz",
      "name": {
        "text": [
          {
            "value": "Charlene Franz",
            "language": "en"
          }
        ]
      },
      "party_id": "federalist",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "harris",
      "name": {
        "text": [
          {
            "value": "Gerald Harris",
            "language": "en"
          }
        ]
      },
      "party_id": "peoples",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "bargmann",
      "name": {
        "text": [
          {
            "value": "Linda Bargmann",
            "language": "en"
          }
        ]
      },
      "party_id": "constitution",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "abcock",
      "name": {
        "text": [
          {
            "value": "Barbara Abcock",
            "language": "en"
          }
        ]
      },
      "party_id": "liberty",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "steel-loy",
      "name": {
        "text": [
          {
            "value": "Carrie Steel-Loy",
            "language": "en"
          }
        ]
      },
      "party_id": "labor",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "sharp",
      "name": {
        "text": [
          {
            "value": "Frederick Sharp",
            "language": "en"
          }
        ]
      },
      "party_id": "constitution",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "wallace",
      "name": {
        "text": [
          {
            "value": "Alex Wallace",
            "language": "en"
          }
        ]
      },
      "party_id": "independent",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "williams",
      "name": {
        "text": [
          {
            "value": "Barbara Williams",
            "language": "en"
          }
        ]
      },
      "party_id": "peoples",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "sharp-althea",
      "name": {
        "text": [
          {
            "value": "Althea Sharp",
            "language": "en"
          }
        ]
      },
      "party_id": "whig",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "alpern",
      "name": {
        "text": [
          {
            "value": "Douglas Alpern",
            "language": "en"
          }
        ]
      },
      "party_id": "federalist",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "windbeck",
      "name": {
        "text": [
          {
            "value": "Ann Windbeck",
            "language": "en"
          }
        ]
      },
      "party_id": "peoples",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "greher",
      "name": {
        "text": [
          {
            "value": "Mike Greher",
            "language": "en"
          }
        ]
      },
      "party_id": "constitution",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "alexander",
      "name": {
        "text": [
          {
            "value": "Patricia Alexander",
            "language": "en"
          }
        ]
      },
      "party_id": "whig",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "mitchell",
      "name": {
        "text": [
          {
            "value": "Kenneth Mitchell",
            "language": "en"
          }
        ]
      },
      "party_id": "federalist",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "lee",
      "name": {
        "text": [
          {
            "value": "Stan Lee",
            "language": "en"
          }
        ]
      },
      "party_id": "independent",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "ash",
      "name": {
        "text": [
          {
            "value": "Henry Ash",
            "language": "en"
          }
        ]
      },
      "party_id": "liberty",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "kennedy",
      "name": {
        "text": [
          {
            "value": "Karen Kennedy",
            "language": "en"
          }
        ]
      },
      "party_id": "independent",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "jackson",
      "name": {
        "text": [
          {
            "value": "Van Jackson",
            "language": "en"
          }
        ]
      },
      "party_id": "labor",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "brown",
      "name": {
        "text": [
          {
            "value": "Debbie Brown",
            "language": "en"
          }
        ]
      },
      "party_id": "peoples",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "teller",
      "name": {
        "text": [
          {
            "value": "Joseph Teller",
            "language": "en"
          }
        ]
      },
      "party_id": "peoples",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "ward",
      "name": {
        "text": [
          {
            "value": "Greg Ward",
            "language": "en"
          }
        ]
      },
      "party_id": "independent",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "murphy",
      "name": {
        "text": [
          {
            "value": "Lou Murphy",
            "language": "en"
          }
        ]
      },
      "party_id": "federalist",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "newman",
      "name": {
        "text": [
          {
            "value": "Jane Newman",
            "language": "en"
          }
        ]
      },
      "party_id": "whig",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "callanann",
      "name": {
        "text": [
          {
            "value": "Jack Callanann",
            "language": "en"
          }
        ]
      },
      "party_id": "labor",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "york",
      "name": {
        "text": [
          {
            "value": "Esther York",
            "language": "en"
          }
        ]
      },
      "party_id": "labor",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "chandler",
      "name": {
        "text": [
          {
            "value": "Glenn Chandler",
            "language": "en"
          }
        ]
      },
      "party_id": "labor",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "solis",
      "name": {
        "text": [
          {
            "value": "Andrea Solis",
            "language": "en"
          }
        ]
      },
      "party_id": "labor",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "keller",
      "name": {
        "text": [
          {
            "value": "Amos Keller",
            "language": "en"
          }
        ]
      },
      "party_id": "constitution",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "rangel",
      "name": {
        "text": [
          {
            "value": "Davitra Rangel",
            "language": "en"
          }
        ]
      },
      "party_id": "peoples",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "argent",
      "name": {
        "text": [
          {
            "value": "Camille Argent",
            "language": "en"
          }
        ]
      },
      "party_id": "liberty",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "witherspoon-smithson",
      "name": {
        "text": [
          {
            "value": "Chloe Witherspoon-Smithson",
            "language": "en"
          }
        ]
      },
      "party_id": "independent",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "bainbridge",
      "name": {
        "text": [
          {
            "value": "Clayton Bainbridge",
            "language": "en"
          }
        ]
      },
      "party_id": "peoples",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "hennessey",
      "name": {
        "text": [
          {
            "value": "Charlene Hennessey",
            "language": "en"
          }
        ]
      },
      "party_id": "whig",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "savoy",
      "name": {
        "text": [
          {
            "value": "Eric Savoy",
            "language": "en"
          }
        ]
      },
      "party_id": "labor",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "tawa",
      "name": {
        "text": [
          {
            "value": "Susan Tawa",
            "language": "en"
          }
        ]
      },
      "party_id": "constitution",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "tawa-mary",
      "name": {
        "text": [
          {
            "value": "Mary Tawa",
            "language": "en"
          }
        ]
      },
      "party_id": "independent",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "altman",
      "name": {
        "text": [
          {
            "value": "Valarie Altman",
            "language": "en"
          }
        ]
      },
      "party_id": "peoples",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "moore",
      "name": {
        "text": [
          {
            "value": "Helen Moore",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "white",
      "name": {
        "text": [
          {
            "value": "John White",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "smallberries",
      "name": {
        "text": [
          {
            "value": "John Smallberries",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "warfin",
      "name": {
        "text": [
          {
            "value": "John Warfin",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "norberg",
      "name": {
        "text": [
          {
            "value": "Chris Norberg",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "parks",
      "name": {
        "text": [
          {
            "value": "Abigail Parks",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "savannah",
      "name": {
        "text": [
          {
            "value": "Harmony Savannah",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "summers",
      "name": {
        "text": [
          {
            "value": "Buffy Summers",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "chase",
      "name": {
        "text": [
          {
            "value": "Cordelia Chase",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "osborne",
      "name": {
        "text": [
          {
            "value": "Daniel Osborne",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "rosenberg",
      "name": {
        "text": [
          {
            "value": "Willow Rosenberg",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "head",
      "name": {
        "text": [
          {
            "value": "Anthony Stewart Head",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "marsters",
      "name": {
        "text": [
          {
            "value": "James Marsters",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "write-in-1",
      "name": {
        "text": [
          {
            "value": "Write In Candidate",
            "language": "en"
          },
          {
            "value": "Escribir en la candidata",
            "language": "es"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": true
    },
    {
      "object_id": "write-in-2",
      "name": {
        "text": [
          {
            "value": "Write In Candidate",
            "language": "en"
          },
          {
            "value": "Escribir en la candidata",
            "language": "es"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": true
    },
    {
      "object_id": "write-in-3",
      "name": {
        "text": [
          {
            "value": "Write In Candidate",
            "language": "en"
          },
          {
            "value": "Escribir en la candidata",
            "language": "es"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": true
    },
    {
      "object_id": "ozark-chief-justice-retain-demergue-affirmative",
      "name": {
        "text": [
          {
            "value": "Retain",
            "language": "en"
          },
          {
            "value": "Conservar",
            "language": "es"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "ozark-chief-justice-retain-demergue-negative",
      "name": {
        "text": [
          {
            "value": "Reject",
            "language": "en"
          },
          {
            "value": "Rechazar",
            "language": "es"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "exeter-utility-district-referendum-affirmative",
      "name": {
        "text": [
          {
            "value": "Yes",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "exeter-utility-district-referendum-negative",
      "name": {
        "text": [
          {
            "value": "No",
            "language": "en"
          }
        ]
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    }
  ],
  "contests": [
    {
      "object_id": "president-vice-president-contest",
      "sequence_order": 0,
      "electoral_district_id": "hamilton-county",
      "vote_variation": "one_of_m",
      "number_elected": 1,
      "votes_allowed": 1,
      "name": "President and Vice President of the United States",
      "ballot_selections": [
        {
          "object_id": "barchi-hallaren-selection",
          "sequence_order": 0,
          "candidate_id": "barchi-hallaren"
        },
        {
          "object_id": "cramer-vuocolo-selection",
          "sequence_order": 1,
          "candidate_id": "cramer-vuocolo"
        },
        {
          "object_id": "court-blumhardt-selection",
          "sequence_order": 2,
          "candidate_id": "court-blumhardt"
        },
        {
          "object_id": "boone-lian-selection",
          "sequence_order": 3,
          "candidate_id": "boone-lian"
        },
        {
          "object_id": "hildebrand-garritty-selection",
          "sequence_order": 4,
          "candidate_id": "hildebrand-garritty"
        },
        {
          "object_id": "patterson-lariviere-selection",
          "sequence_order": 5,
          "candidate_id": "patterson-lariviere"
        },
        {
          "object_id": "write-in-selection-president",
          "sequence_order": 6,
          "candidate_id": "write-in"
        }
      ],
      "ballot_title": {
        "text": [
          {
            "value": "President and Vice President of the United States",
            "language": "en"
          },
          {
            "value": "Presidente y Vicepresidente de los Estados Unidos",
            "language": "es"
          }
        ]
      },
      "ballot_subtitle": {
        "text": [
          {
            "value": "Vote for one",
            "language": "en"
          },
          {
            "value": "Votar por uno",
            "language": "es"
          }
        ]
      }
    },
    {
      "object_id": "ozark-governor",
      "sequence_order": 1,
      "electoral_district_id": "hamilton-county",
      "vote_variation": "one_of_m",
      "number_elected": 1,
      "votes_allowed": 1,
      "name": "Governor of the Commonwealth of Ozark",
      "ballot_selections": [
        {
          "object_id": "franz-selection",
          "sequence_order": 0,
          "candidate_id": "franz"
        },
        {
          "object_id": "harris-selection",
          "sequence_order": 1,
          "candidate_id": "harris"
        },
        {
          "object_id": "bargmann-selection",
          "sequence_order": 2,
          "candidate_id": "bargmann"
        },
        {
          "object_id": "abcock-selection",
          "sequence_order": 3,
          "candidate_id": "abcock"
        },
        {
          "object_id": "steel-loy-selection",
          "sequence_order": 4,
          "candidate_id": "steel-loy"
        },
        {
          "object_id": "sharp-selection",
          "sequence_order": 5,
          "candidate_id": "sharp"
        },
        {
          "object_id": "walace-selection",
          "sequence_order": 6,
          "candidate_id": "wallace"
        },
        {
          "object_id": "williams-selection",
          "sequence_order": 7,
          "candidate_id": "williams"
        },
        {
          "object_id": "alpern-selection",
          "sequence_order": 9,
          "candidate_id": "alpern"
        },
        {
          "object_id": "windbeck-selection",
          "sequence_order": 10,
          "candidate_id": "windbeck"
        },
        {
          "object_id": "sharp-althea-selection",
          "sequence_order": 11,
          "candidate_id": "sharp-althea"
        },
        {
          "object_id": "greher-selection",
          "sequence_order": 12,
          "candidate_id": "greher"
        },
        {
          "object_id": "alexander-selection",
          "sequence_order": 13,
          "candidate_id": "alexander"
        },
        {
          "object_id": "mitchell-selection",
          "sequence_order": 14,
          "candidate_id": "mitchell"
        },
        {
          "object_id": "lee-selection",
          "sequence_order": 15,
          "candidate_id": "lee"
        },
        {
          "object_id": "ash-selection",
          "sequence_order": 16,
          "candidate_id": "ash"
        },
        {
          "object_id": "kennedy-selection",
          "sequence_order": 17,
          "candidate_id": "kennedy"
        },
        {
          "object_id": "jackson-selection",
          "sequence_order": 18,
          "candidate_id": "jackson"
        },
        {
          "object_id": "brown-selection",
          "sequence_order": 19,
          "candidate_id": "brown"
        },
        {
          "object_id": "teller-selection",
          "sequence_order": 20,
          "candidate_id": "teller"
        },
        {
          "object_id": "ward-selection",
          "sequence_order": 21,
          "candidate_id": "ward"
        },
        {
          "object_id": "murphy-selection",
          "sequence_order": 22,
          "candidate_id": "murphy"
        },
        {
          "object_id": "newman-selection",
          "sequence_order": 23,
          "candidate_id": "newman"
        },
        {
          "object_id": "callanann-selection",
          "sequence_order": 24,
          "candidate_id": "callanann"
        },
        {
          "object_id": "york-selection",
          "sequence_order": 25,
          "candidate_id": "york"
        },
        {
          "object_id": "chandler-selection",
          "sequence_order": 26,
          "candidate_id": "chandler"
        },
        {
          "object_id": "write-in-selection-governor",
          "sequence_order": 27,
          "candidate_id": "write-in"
        }
      ],
      "ballot_title": {
        "text": [
          {
            "value": "Governor of the Commonwealth of Ozark",
            "language": "en"
          },
          {
            "value": "Gobernador de la Mancomunidad de Ozark",
            "language": "es"
          }
        ]
      },
      "ballot_subtitle": {
        "text": [
          {
            "value": "Vote for one",
            "language": "en"
          },
          {
            "value": "Votar por uno",
            "language": "es"
          }
        ]
      }
    },
    {
      "object_id": "congress-district-5-contest",
      "sequence_order": 2,
      "electoral_district_id": "congress-district-5",
      "vote_variation": "one_of_m",
      "number_elected": 1,
      "votes_allowed": 1,
      "name": "Congressional District 5",
      "ballot_selections": [
        {
          "object_id": "soliz-selection",
          "sequence_order": 0,
          "candidate_id": "soliz"
        },
        {
          "object_id": "keller-selection",
          "sequence_order": 1,
          "candidate_id": "keller"
        },
        {
          "object_id": "rangel-selection",
          "sequence_order": 2,
          "candidate_id": "rengel"
        },
        {
          "object_id": "argent-selection",
          "sequence_order": 3,
          "candidate_id": "argent"
        },
        {
          "object_id": "witherspoon-smithson-selection",
          "sequence_order": 4,
          "candidate_id": "witherspoon-smithson"
        },
        {
          "object_id": "write-in-selection-us-congress-district-5",
          "sequence_order": 5,
          "candidate_id": "write-in"
        }
      ],
      "ballot_title": {
        "text": [
          {
            "value": "House of Representatives Congressional District 5",
            "language": "en"
          },
          {
            "value": "C\u00e1mara de Representantes de Distrito 5 del Congreso de Ozark",
            "language": "es"
          }
        ]
      },
      "ballot_subtitle": {
        "text": [
          {
            "value": "Vote for one",
            "language": "en"
          },
          {
            "value": "Votar por uno",
            "language": "es"
          }
        ]
      }
    },
    {
      "object_id": "congress-district-7-contest",
      "sequence_order": 3,
      "electoral_district_id": "congress-district-7",
      "vote_variation": "one_of_m",
      "number_elected": 1,
      "votes_allowed": 1,
      "name": "Congressional District 7",
      "ballot_selections": [
        {
          "object_id": "bainbridge-selection",
          "sequence_order": 0,
          "candidate_id": "bainbridge"
        },
        {
          "object_id": "hennessey-selection",
          "sequence_order": 1,
          "candidate_id": "hennessey"
        },
        {
          "object_id": "savoy-selection",
          "sequence_order": 2,
          "candidate_id": "savoy"
        },
        {
          "object_id": "tawa-selection",
          "sequence_order": 3,
          "candidate_id": "tawa"
        },
        {
          "object_id": "tawa-mary-selection",
          "sequence_order": 4,
          "candidate_id": "tawa-mary"
        },
        {
          "object_id": "write-in-selection-us-congress-district-7",
          "sequence_order": 5,
          "candidate_id": "write-in"
        }
      ],
      "ballot_title": {
        "text": [
          {
            "value": "House of Representatives Ozark Congressional District 7",
            "language": "en"
          },
          {
            "value": "C\u00e1mara de Representantes de Distrito 7 del Congreso de Ozark",
            "language": "es"
          }
        ]
      },
      "ballot_subtitle": {
        "text": [
          {
            "value": "Vote for one",
            "language": "en"
          },
          {
            "value": "Votar por uno",
            "language": "es"
          }
        ]
      }
    },
    {
      "object_id": "pismo-beach-school-board-contest",
      "sequence_order": 4,
      "electoral_district_id": "pismo-beach-school-district-precinct-1",
      "vote_variation": "n_of_m",
      "number_elected": 3,
      "votes_allowed": 3,
      "name": "Pismo Beach School Board",
      "ballot_selections": [
        {
          "object_id": "moore-selection",
          "sequence_order": 0,
          "candidate_id": "moore"
        },
        {
          "object_id": "white-selection",
          "sequence_order": 1,
          "candidate_id": "white"
        },
        {
          "object_id": "smallberries-selection",
          "sequence_order": 2,
          "candidate_id": "smallberries"
        },
        {
          "object_id": "warfin-selection",
          "sequence_order": 3,
          "candidate_id": "warfin"
        },
        {
          "object_id": "norberg-selection",
          "sequence_order": 4,
          "candidate_id": "norberg"
        },
        {
          "object_id": "parks-selection",
          "sequence_order": 5,
          "candidate_id": "parks"
        },
        {
          "object_id": "savannah-selection",
          "sequence_order": 6,
          "candidate_id": "savannah"
        },
        {
          "object_id": "write-in-selection-1-pismo-beach-school-board",
          "sequence_order": 7,
          "candidate_id": "write-in-1"
        },
        {
          "object_id": "write-in-selection-2-pismo-beach-school-board",
          "sequence_order": 8,
          "candidate_id": "write-in-2"
        },
        {
          "object_id": "write-in-selection-3-pismo-beach-school-board",
          "sequence_order": 9,
          "candidate_id": "write-in-3"
        }
      ],
      "ballot_title": {
        "text": [
          {
            "value": "Pismo Beach School Board",
            "language": "en"
          },
          {
            "value": "Junta Escolar de Pismo Beach",
            "language": "es"
          }
        ]
      },
      "ballot_subtitle": {
        "text": [
          {
            "value": "Vote for up to 3",
            "language": "en"
          },
          {
            "value": "Vote por hasta 3",
            "language": "es"
          }
        ]
      }
    },
    {
      "object_id": "somerset-school-board-contest",
      "sequence_order": 5,
      "electoral_district_id": "somerset-school-district-precinct-1",
      "vote_variation": "n_of_m",
      "number_elected": 2,
      "votes_allowed": 2,
      "name": "Somerset School Board",
      "ballot_selections": [
        {
          "object_id": "summers-selection",
          "sequence_order": 0,
          "candidate_id": "summers"
        },
        {
          "object_id": "chase-selection",
          "sequence_order": 1,
          "candidate_id": "chase"
        },
        {
          "object_id": "osborne-selection",
          "sequence_order": 2,
          "candidate_id": "osborne"
        },
        {
          "object_id": "rosenberg-selection",
          "sequence_order": 3,
          "candidate_id": "rosenberg"
        },
        {
          "object_id": "head-selection",
          "sequence_order": 4,
          "candidate_id": "head"
        },
        {
          "object_id": "marsters-selection",
          "sequence_order": 5,
          "candidate_id": "marsters"
        },
        {
          "object_id": "write-in-selection-1-somerset-school-board",
          "sequence_order": 6,
          "candidate_id": "write-in-1"
        },
        {
          "object_id": "write-in-selection-2-somerset-school-board",
          "sequence_order": 7,
          "candidate_id": "write-in-2"
        }
      ],
      "ballot_title": {
        "text": [
          {
            "value": "Pismo Beach School Board",
            "language": "en"
          },
          {
            "value": "Junta Escolar de Somerset",
            "language": "es"
          }
        ]
      },
      "ballot_subtitle": {
        "text": [
          {
            "value": "Vote for up to 2",
            "language": "en"
          },
          {
            "value": "Vote por hasta 2",
            "language": "es"
          }
        ]
      }
    },
    {
      "object_id": "arlington-chief-justice-retain-demergue",
      "sequence_order": 6,
      "electoral_district_id": "arlington-township-precinct-1",
      "vote_variation": "one_of_m",
      "number_elected": 1,
      "votes_allowed": 1,
      "name": "Retain Robert Demergue as Chief Justice?",
      "ballot_selections": [
        {
          "object_id": "ozark-chief-justice-retain-demergue-affirmative-selection",
          "sequence_order": 0,
          "candidate_id": "ozark-chief-justice-retain-demergue-affirmative"
        },
        {
          "object_id": "ozark-chief-justice-retain-demergue-negative-selection",
          "sequence_order": 1,
          "candidate_id": "ozark-chief-justice-retain-demergue-negative"
        }
      ],
      "ballot_title": {
        "text": [
          {
            "value": "Retain Robert Demergue as Chief Justice?",
            "language": "en"
          },
          {
            "value": "\u00bfRetener a Robert Demergue como Presidente del Tribunal Supremo?",
            "language": "es"
          }
        ]
      },
      "ballot_subtitle": {
        "text": [
          {
            "value": "Choose 'Accept' or 'Reject'",
            "language": "en"
          },
          {
            "value": "Elija 'Aceptar' o 'Rechazar'",
            "language": "es"
          }
        ]
      }
    },
    {
      "object_id": "exeter-utility-district-referendum-contest",
      "sequence_order": 7,
      "electoral_district_id": "lacroix-exeter-utility-district",
      "vote_variation": "one_of_m",
      "number_elected": 1,
      "votes_allowed": 1,
      "name": "Capital Projects Levy",
      "ballot_selections": [
        {
          "object_id": "exeter-utility-district-referendum-affirmative-selection",
          "sequence_order": 0,
          "candidate_id": "exeter-utility-district-referendum-affirmative"
        },
        {
          "object_id": "exeter-utility-district-referendum-selection",
          "sequence_order": 1,
          "candidate_id": "exeter-utility-district-referendum-negative"
        }
      ],
      "ballot_title": {
        "text": [
          {
            "value": "Levy Lift to Maintain Public Safety and Other Core Utility Services",
            "language": "en"
          },
          {
            "value": "Levy Lift para Mantener la Seguridad P\u00fablica y Otros Servicios B\u00e1sicos",
            "language": "es"
          }
        ]
      },
      "ballot_subtitle": {
        "text": [
          {
            "value": "Should this Proposition be approved?",
            "language": "en"
          },
          {
            "value": "Uno",
            "language": "es"
          }
        ]
      }
    }
  ],
  "ballot_styles": [
    {
      "object_id": "congress-district-7-hamilton-county",
      "geopolitical_unit_ids": [
        "hamilton-county",
        "congress-district-7"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "congress-district-7-lacroix",
      "geopolitical_unit_ids": [
        "hamilton-county",
        "congress-district-7",
        "lacroix-township-precinct-1"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "congress-district-7-lacroix-exeter",
      "geopolitical_unit_ids": [
        "hamilton-county",
        "congress-district-7",
        "lacroix-township-precinct-1",
        "lacroix-exeter-utility-district"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "congress-district-7-arlington",
      "geopolitical_unit_ids": [
        "hamilton-county",
        "congress-district-7",
        "arlington-township-precinct-1"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "congress-district-7-arlington-pismo-beach",
      "geopolitical_unit_ids": [
        "hamilton-county",
        "congress-district-7",
        "arlington-township-precinct-1",
        "pismo-beach-school-district-precinct-1"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "congress-district-7-arlington-somerset",
      "geopolitical_unit_ids": [
        "hamilton-county",
        "congress-district-7",
        "arlington-township-precinct-1",
        "somerset-school-district-precinct-1"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "congress-district-5-hamilton-county",
      "geopolitical_unit_ids": [
        "hamilton-county",
        "congress-district-5"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "congress-district-5-lacroix",
      "geopolitical_unit_ids": [
        "hamilton-county",
        "congress-district-5",
        "lacroix-township-precinct-1"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "congress-district-5-harris",
      "geopolitical_unit_ids": [
        "hamilton-county",
        "congress-district-5",
        "harris-township"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "congress-district-5-arlington-pismo-beach",
      "geopolitical_unit_ids": [
        "hamilton-county",
        "congress-district-5",
        "arlington-township-precinct-1",
        "pismo-beach-school-district-precinct-1"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "congress-district-5-arlington-somerset",
      "geopolitical_unit_ids": [
        "hamilton-county",
        "congress-district-5",
        "arlington-township-precinct-1",
        "somerset-school-district-precinct-1"
      ],
      "party_ids": null,
      "image_uri": null
    }
  ],
  "name": {
    "text": [
      {
        "value": "Hamiltion County General Election",
        "language": "en"
      },
      {
        "value": "Elecci\u00f3n general del condado de Hamilton",
        "language": "es"
      }
    ]
  },
  "contact_information": {
    "address_line": [
      "1234 Paul Revere Run",
      "Hamilton, Ozark 99999"
    ],
    "email": [
      {
        "annotation": "press",
        "value": "inquiries@hamilton.state.gov"
      },
      {
        "annotation": "federal",
        "value": "commissioner@hamilton.state.gov"
      }
    ],
    "phone": [
      {
        "annotation": "domestic",
        "value": "123-456-7890"
      },
      {
        "annotation": "international",
        "value": "+1-123-456-7890"
      }
    ],
    "name": "Hamilton State Election Commission"
  }
}

================================================
FILE: data/manifest-minimal.json
================================================
{
  "election_scope_id": "franklin-minimal-referendum-manifest",
  "spec_version": "1.0",
  "type": "general",
  "start_date": "2020-03-01T08:00:00-05:00",
  "end_date": "2020-03-03T19:00:00-05:00",
  "geopolitical_units": [
    {
      "object_id": "franklin-county",
      "name": "Franklin County",
      "type": "municipality",
      "contact_information": null
    }
  ],
  "parties": [
    {
      "object_id": "N/A",
      "name": {
        "text": []
      },
      "abbreviation": null,
      "color": null,
      "logo_uri": null
    }
  ],
  "candidates": [
    {
      "object_id": "referendum-pineapple-affirmative",
      "name": {
        "text": []
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "referendum-pineapple-negative",
      "name": {
        "text": []
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    }
  ],
  "contests": [
    {
      "object_id": "referendum-pineapple",
      "sequence_order": 0,
      "electoral_district_id": "franklin-county",
      "vote_variation": "one_of_m",
      "number_elected": 1,
      "votes_allowed": 1,
      "name": "Referendum for Banning Pineapple on Pizza",
      "ballot_selections": [
        {
          "object_id": "referendum-pineapple-affirmative-selection",
          "sequence_order": 0,
          "candidate_id": "referendum-pineapple-affirmative"
        },
        {
          "object_id": "referendum-pineapple-negative-selection",
          "sequence_order": 1,
          "candidate_id": "referendum-pineapple-negative"
        }
      ],
      "ballot_title": null,
      "ballot_subtitle": null
    }
  ],
  "ballot_styles": [
    {
      "object_id": "ballot-style-01",
      "geopolitical_unit_ids": [
        "franklin-county"
      ],
      "party_ids": null,
      "image_uri": null
    }
  ],
  "name": {
    "text": [
      {
        "value": "Franklin County Minimal General Election March 2020",
        "language": "en"
      },
      {
        "value": "Elecciones generales m\u00ednimas del condado de Franklin marzo de 2020",
        "language": "es"
      }
    ]
  },
  "contact_information": null
}

================================================
FILE: data/manifest-small.json
================================================
{
  "election_scope_id": "franklin-county-general-march2020",
  "spec_version": "1.0",
  "type": "general",
  "start_date": "2020-03-01T08:00:00-05:00",
  "end_date": "2020-03-03T19:00:00-05:00",
  "geopolitical_units": [
    {
      "object_id": "franklin-county",
      "name": "Franklin County",
      "type": "county",
      "contact_information": null
    },
    {
      "object_id": "ozark-school-district",
      "name": "Ozark School District in Franklin County",
      "type": "school",
      "contact_information": null
    }
  ],
  "parties": [
    {
      "object_id": "party-whig",
      "name": {
        "text": []
      },
      "abbreviation": "WHI",
      "color": null,
      "logo_uri": null
    },
    {
      "object_id": "party-federalist",
      "name": {
        "text": []
      },
      "abbreviation": "FED",
      "color": null,
      "logo_uri": null
    },
    {
      "object_id": "party-democratic-republican",
      "name": {
        "text": []
      },
      "abbreviation": "DR",
      "color": null,
      "logo_uri": null
    }
  ],
  "candidates": [
    {
      "object_id": "benjamin-franklin",
      "name": {
        "text": []
      },
      "party_id": "party-whig",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "john-adams",
      "name": {
        "text": []
      },
      "party_id": "party-federalist",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "john-hancock",
      "name": {
        "text": []
      },
      "party_id": "party-democratic-republican",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "samuel-adams",
      "name": {
        "text": []
      },
      "party_id": "party-democratic-republican",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "thomas-jefferson",
      "name": {
        "text": []
      },
      "party_id": "party-democratic-republican",
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "write-in",
      "name": {
        "text": []
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": true
    },
    {
      "object_id": "referendum-pineapple-affirmative",
      "name": {
        "text": []
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    },
    {
      "object_id": "referendum-pineapple-negative",
      "name": {
        "text": []
      },
      "party_id": null,
      "image_uri": null,
      "is_write_in": null
    }
  ],
  "contests": [
    {
      "object_id": "congressional-race-01",
      "sequence_order": 0,
      "electoral_district_id": "franklin-county",
      "vote_variation": "one_of_m",
      "number_elected": 1,
      "votes_allowed": 1,
      "name": "Representative to US Congress",
      "ballot_selections": [
        {
          "object_id": "john-hancock-selection",
          "sequence_order": 0,
          "candidate_id": "john-hancock"
        },
        {
          "object_id": "benjamin-franklin-selection",
          "sequence_order": 1,
          "candidate_id": "benjamin-franklin"
        },
        {
          "object_id": "write-in-selection",
          "sequence_order": 2,
          "candidate_id": "write-in"
        }
      ],
      "ballot_title": null,
      "ballot_subtitle": null
    },
    {
      "object_id": "referendum-pineapple",
      "sequence_order": 1,
      "electoral_district_id": "franklin-county",
      "vote_variation": "one_of_m",
      "number_elected": 1,
      "votes_allowed": 1,
      "name": "The Pineapple Question",
      "ballot_selections": [
        {
          "object_id": "referendum-pineapple-affirmative-selection",
          "sequence_order": 0,
          "candidate_id": "referendum-pineapple-affirmative"
        },
        {
          "object_id": "referendum-pineapple-negative-selection",
          "sequence_order": 1,
          "candidate_id": "referendum-pineapple-negative"
        }
      ],
      "ballot_title": null,
      "ballot_subtitle": null
    },
    {
      "object_id": "ozark-school-board-race",
      "sequence_order": 2,
      "electoral_district_id": "ozark-school-district",
      "vote_variation": "n_of_m",
      "number_elected": 2,
      "votes_allowed": 2,
      "name": "Ozark School Board",
      "ballot_selections": [
        {
          "object_id": "john-adams-selection",
          "sequence_order": 0,
          "candidate_id": "john-adams"
        },
        {
          "object_id": "samuel-adams-selection",
          "sequence_order": 1,
          "candidate_id": "samuel-adams"
        },
        {
          "object_id": "thomas-jefferson-selection",
          "sequence_order": 2,
          "candidate_id": "thomas-jefferson"
        }
      ],
      "ballot_title": null,
      "ballot_subtitle": null
    }
  ],
  "ballot_styles": [
    {
      "object_id": "franklin-county-no-schooldistrict",
      "geopolitical_unit_ids": [
        "franklin-county"
      ],
      "party_ids": null,
      "image_uri": null
    },
    {
      "object_id": "franklin-county-ozark-schools",
      "geopolitical_unit_ids": [
        "franklin-county",
        "ozark-school-district"
      ],
      "party_ids": null,
      "image_uri": null
    }
  ],
  "name": {
    "text": [
      {
        "value": "Franklin County Small General Election March 2020",
        "language": "en"
      },
      {
        "value": "Peque\u00f1as elecciones generales del condado de Franklin marzo de 2020",
        "language": "es"
      }
    ]
  },
  "contact_information": null
}

================================================
FILE: data/plaintext_ballots_simple.json
================================================
[
  {
    "object_id": "1048ce32-f1b1-4b05-b7fb-8c615ac842ee",
    "style_id": "jefferson-county-ballot-style",
    "contests": [
      {
        "object_id": "justice-supreme-court",
        "ballot_selections": [
          {
            "object_id": "john-adams-selection",
            "vote": 1
          },
          {
            "object_id": "write-in-selection",
            "vote": 1,
            "extended_data": {
              "value": "Susan B. Anthony",
              "length": 16
            }
          }
        ]
      }
    ]
  },
  {
    "object_id": "03a29d15-667c-4ac8-afd7-549f19b8e4eb",
    "style_id": "jefferson-county-ballot-style",
    "contests": [
      {
        "object_id": "justice-supreme-court",
        "ballot_selections": [
          {
            "object_id": "john-adams-selection",
            "vote": 1
          },
          {
            "object_id": "write-in-selection",
            "vote": 1,
            "extended_data": {
              "value": "Susan B. Anthony",
              "length": 16
            }
          }
        ]
      }
    ]
  },
  {
    "object_id": "25a7111b-4334-425a-87c1-f7a49f42b3a2",
    "style_id": "jefferson-county-ballot-style",
    "contests": [
      {
        "object_id": "justice-supreme-court",
        "ballot_selections": [
          {
            "object_id": "john-adams-selection",
            "vote": 1
          },
          {
            "object_id": "benjamin-franklin-selection",
            "vote": 1
          }
        ]
      }
    ]
  },
  {
    "object_id": "69aeacb4-64c6-4205-9bb2-5fb6b3b3ea58",
    "style_id": "harrison-township-ballot-style",
    "contests": [
      {
        "object_id": "justice-supreme-court",
        "ballot_selections": [
          {
            "object_id": "john-adams-selection",
            "vote": 1
          },
          {
            "object_id": "john-hancock-selection",
            "vote": 1
          }
        ]
      }
    ]
  },
  {
    "object_id": "5a150c74-a2cb-47f6-b575-165ba8a4ce53",
    "style_id": "harrison-township-ballot-style",
    "contests": [
      {
        "object_id": "justice-supreme-court",
        "ballot_selections": [
          {
            "object_id": "john-adams-selection",
            "vote": 1
          },
          {
            "object_id": "john-hancock-selection",
            "vote": 1
          }
        ]
      },
      {
        "object_id": "referendum-pineapple",
        "ballot_selections": [
          {
            "object_id": "referendum-pineapple-affirmative-selection",
            "vote": 1
          }
        ]
      }
    ]
  },
  {
    "object_id": "9fee0e77-cfd2-401a-a210-93bbc4dd30ef",
    "style_id": "harrison-township-ballot-style",
    "contests": [
      {
        "object_id": "justice-supreme-court",
        "ballot_selections": [
          {
            "object_id": "john-adams-selection",
            "vote": 1
          },
          {
            "object_id": "write-in-selection",
            "vote": 1,
            "extended_data": {
              "value": "Susan B. Anthony",
              "length": 16
            }
          }
        ]
      },
      {
        "object_id": "referendum-pineapple",
        "ballot_selections": [
          {
            "object_id": "referendum-pineapple-negative-selection",
            "vote": 1
          }
        ]
      }
    ]
  }
]


================================================
FILE: data/plaintext_two_ballots_minimal.json
================================================
[
  {
    "object_id": "external-ballot-id-1234",
    "style_id": "ballot-style-01",
    "contests": [
      {
        "object_id": "referendum-pineapple",
        "ballot_selections": [
          {
            "object_id": "referendum-pineapple-affirmative-selection",
            "vote": 1
          }
        ]
      }
    ]
  },
  {
    "object_id": "external-ballot-id-3457",
    "style_id": "ballot-style-01",
    "contests": [
      {
        "object_id": "referendum-pineapple",
        "ballot_selections": [
          {
            "object_id": "referendum-pineapple-negative-selection",
            "vote": 1
          }
        ]
      }
    ]
  }
]


================================================
FILE: data/plaintext_two_ballots_small.json
================================================
[
  {
    "object_id": "external-ballot-id-2345",
    "style_id": "franklin-county-ozark-schools",
    "contests": [
      {
        "object_id": "referendum-pineapple",
        "ballot_selections": [
          {
            "object_id": "referendum-pineapple-affirmative-selection",
            "vote": 1
          }
        ]
      },
      {
        "object_id": "congressional-race-01",
        "ballot_selections": [
          {
            "object_id": "john-hancock-selection",
            "vote": 1
          }
        ]
      },
      {
        "object_id": "ozark-school-board-race",
        "ballot_selections": [
          {
            "object_id": "samuel-adams-selection",
            "vote": 1
          },
          {
            "object_id": "thomas-jefferson-selection",
            "vote": 1
          }
        ]
      }
    ]
  },
  {
    "object_id": "external-ballot-id-9876",
    "style_id": "franklin-county-no-schooldistrict",
    "contests": [
      {
        "object_id": "referendum-pineapple",
        "ballot_selections": [
          {
            "object_id": "referendum-pineapple-affirmative-selection",
            "vote": 1
          }
        ]
      },
      {
        "object_id": "congressional-race-01",
        "ballot_selections": [
          {
            "object_id": "benjamin-franklin-selection",
            "vote": 1
          }
        ]
      }
    ]
  }
]


================================================
FILE: docs/0_Configure_Election.ipynb
================================================
{
 "cells": [
  {
   "cell_type": "markdown",
   "source": [
    "# Election Configuration\n",
    "\n",
    "An election in ElectionGuard is defined as a set of metadata and cryptographic artifacts necessary to encrypt, conduct, tally, decrypt, and verify an election. The Data format used for election metadata is based on the [NIST Election Common Standard Data Specification](https://www.nist.gov/itl/voting/interoperability) but includes some modifications to support the end-to-end cryptography of ElectionGuard.\n",
    "\n",
    "Election metadata is described in a specific format parseable into an `Manifest` and it's validity is checked to ensure that it is of an appropriate structure to conduct an End-to-End Verified ElectionGuard Election. ElectionGuard only verifies the components of the election metadata that are necessary to encrypt and decrypt the election. Some components of the election metadata are not checked for structural validity, but are used when generating a hash representation of the `Manifest`.\n",
    "\n",
    "From an `Manifest` we derive an `InternalManifest` that includes a subset of the elements from the `Manifest` required to verify ballots are correct. Additionally a `CiphertextElectionContext` is created during the [Key Ceremony](/1_Key_Ceremony.md) that includes the cryptographic artifacts necessary for encrypting ballots.\n",
    "\n",
    "## Glossary\n",
    "\n",
    "- **Election Manifest** The election metadata in json format that is parsed into an Election Description\n",
    "- **Election Description** The election metadata that describes the structure and type of the election, including geopolitical units, contests, candidates, and ballot styles, etc.\n",
    "- **Internal Election Description** The subset of the `Manifest` required by ElectionGuard to validate ballots are correctly associated with an election. This component mutates the state of the Election Description.\n",
    "- **Ciphertext Election Context** The cryptographic context of an election that is configured during the `Key Ceremony`\n",
    "- **Description Hash** a Hash representation of the original Manifest.\n",
    "\n",
    "## Process\n",
    "\n",
    "1. Define an election according to the `Manifest` requirements.\n",
    "2. Use the [NIST Common Standard Data Specification](https://www.nist.gov/itl/voting/interoperability) as a guide, but note the differences in [election.py](https://github.com/microsoft/electionguard-python/tree/main/src/electionguard.election.py) and the provided [sample manifest](https://github.com/microsoft/electionguard-python/tree/main/data/election_manifest_simple.json).\n",
    "3. Parse the `Manifest` into the application.\n",
    "4. Define the encryption parameters necessary for conducting an election (see `Key Ceremony`).\n",
    "5. Create the Pubic Key either from a single secret, or from the Key Ceremony.\n",
    "6. Build the `InternalManifest` and `CiphertextElectionContext` from the `Manifest` and `ElGamalKeyPair.public_key`.\n",
    "\n",
    "## Usage Example"
   ],
   "metadata": {}
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "source": [
    "import os\n",
    "from electionguard.election import CiphertextElectionContext\n",
    "from electionguard.election_builder import ElectionBuilder\n",
    "from electionguard.elgamal import ElGamalKeyPair, elgamal_keypair_from_secret\n",
    "from electionguard.manifest import Manifest, InternalManifest\n",
    "\n",
    "# Open an election manifest file\n",
    "with open(os.path.join(some_path, \"election-manifest.json\"), \"r\") as manifest:\n",
    "    string_representation = manifest.read()\n",
    "    election_description = Manifest.from_json(string_representation)\n",
    "\n",
    "# Create an election builder instance, and configure it for a single public-private keypair.\n",
    "# in a real election, you would configure this for a group of guardians.  See Key Ceremony for more information.\n",
    "builder = ElectionBuilder(\n",
    "    number_of_guardians=1,  # since we will generate a single public-private keypair, we set this to 1\n",
    "    quorum=1,  # since we will generate a single public-private keypair, we set this to 1\n",
    "    description=election_description,\n",
    ")\n",
    "\n",
    "# Generate an ElGamal Keypair from a secret.  In a real election you would use the Key Ceremony instead.\n",
    "some_secret_value: int = 12345\n",
    "keypair: ElGamalKeyPair = elgamal_keypair_from_secret(some_secret_value)\n",
    "\n",
    "builder.set_public_key(keypair.public_key)\n",
    "\n",
    "# get an `InternalElectionDescription` and `CiphertextElectionContext`\n",
    "# that are used for the remainder of the election.\n",
    "(internal_manifest, context) = builder.build()"
   ],
   "outputs": [],
   "metadata": {
    "attributes": {
     "classes": [
      "code-cell"
     ],
     "id": ""
    }
   }
  },
  {
   "cell_type": "markdown",
   "source": [
    "## Constants\n",
    "\n",
    "The election constants are the four constants that sit underneath most of the mathematical operations. The election constants can be configured, but there is a standard set which is recommended for most use cases. These can be found in `constants.py`.\n",
    "\n",
    "**⚠️ Warning ⚠️**\n",
    "\n",
    "There are some test constants used for testing code, but these are never to be used in any production system. The small and extra small constants are unlikely to be used except in rare cases for property testing due to collisions that will happen for smaller number sets."
   ],
   "metadata": {}
  }
 ],
 "metadata": {
  "language_info": {
   "name": "python"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}

================================================
FILE: docs/1_Key_Ceremony.md
================================================
# Key Ceremony

The ElectionGuard Key Ceremony is the process used by Election Officials to share encryption keys for an election. Before an election, a fixed number of Guardians are selection to hold the private keys needed to decrypt the election results. A Quorum count of Guardians can also be specified to compensate for guardians who may be missing at the time of Decryption. For instance, 5 Guardians may be selected to hold the keys, but only 3 of them are required to decrypt the election results.

Guardians are typically Election Officials, Trustees Canvass Board Members, Government Officials or other trusted authorities who are responsible and accountable for conducting the election.

## Summary

The Key Ceremony is broken into several high-level steps. Each Guardian must _announce_ their _attendance_ in the key ceremony, generate their own public-private key pairs, and then _share_ those key pairs with the Quorum. Then the data that is shared is mathematically verified using Non-Interactive Zero Knowledge Proofs, and finally a _joint public key_ is created to encrypt ballots in the election.

### Attendance

Guardians exchange all public keys and ensure each fellow guardian has received an election public key ensuring at all guardians are in attendance.

### Key Sharing

Guardians generate a partial key backup for each guardian and share with that designated key with that guardian. Then each designated guardian sends a verification back to the sender. The sender then publishes to the group when all verifications are received.

### Joint Key

The final step is to publish the joint election key after all keys and backups have been shared.

## Glossary

- **Guardian** A guardian of the election who holds the ability to partially decrypt the election results
- **Key Ceremony Mediator** A mediator to mediate communication (if needed) of information such as keys between the guardians
- **Election Key Pair:** Pair of keys (public & secret) used to encrypt/decrypt election
- **Election Partial Key Backup:** A point on a secret polynomial and commitments to verify this point for a designated guardian.
- **Election Polynomial:** The election polynomial is the mathematical expression that each Guardian defines to solve for his or her private key. A different point associated with the polynomial is shared with each of the other guardians so that the guardians can come together to derive the polynomial function and solve for the private key.
- **Joint Key:** Combined public key from election public keys of each guardian
- **Quorum:** Quantity of guardians (k) that is required to decrypt the election and is fewer than the total number of guardians available (n)

## Process

This is a detailed description of the entire Key Ceremony Process

1. The ceremony details are decided upon. These include a `number_of_guardians` and `quorum` of guardians required for decryption.
2. Each guardian creates a unique `id` and `sequence_order`.
3. Each guardian must generate their `election key pair` _(ElGamal key pair)_. This will generate a corresponding Schnorr `proof` and `polynomial` used for generating `election partial key backups` for sharing.
4. Each guardian must give the other guardians their `election public key` directly or through a mediator.
5. Each guardian must check if all `election public keys` are received.
6. Each guardian must generate `election partial key backup` for each other guardian. The guardian will use their `polynomial` and the designated guardian's `sequence_order` to create the value.
7. Each guardian must send each encrypted `election partial key backup` to the designated guardian directly or through a `mediator`.
8. Each guardian checks if all encrypted `election partial key backups` have been received by their recipient guardian directly or through a mediator.
9. Each recipient guardian decrypts each received encrypted `election partial key backup`
10. Each recipient guardian verifies each `election partial key backup` and sends confirmation of verification
    - If the proof verifies, continue
    - If the proof fails
      1. Sender guardian publishes the `election partial key backup` value sent to recipient as a `election partial key challenge` to all the other guardians
      2. Alternate guardian (outside sender or original recipient) attempts to verify key
         - If the proof verifies, continue
         - If the proof fails again, the accused (sender guardian) should be evicted and process should be restarted with new guardian.
11. On receipt of all verifications of `election partial private keys` by all guardians, generate and publish `joint key` from election public keys.

## Files

- [`key_ceremony.py`](https://github.com/microsoft/electionguard-python/tree/main/src/electionguard/key_ceremony.py)
- [`guardian.py`](https://github.com/microsoft/electionguard-python/tree/main/src/electionguard/guardian.py)
- [`key_ceremony_mediator.py`](https://github.com/microsoft/electionguard-python/tree/main/src/electionguard/key_ceremony_mediator.py)

## Usage Example

This example demonstrates a convenience method to generate guardians for an election

```python

NUMBER_OF_GUARDIANS: int
QUORUM: int

details: CeremonyDetails
guardians: List[Guardian]

# Setup Guardians
for i in range(NUMBER_OF_GUARDIANS):
  guardians.append(
    Guardian.from_nonce(f"some_guardian_id_{str(i)}", i, NUMBER_OF_GUARDIANS, QUORUM)
  )

mediator = KeyCeremonyMediator(details)

# Attendance (Public Key Share)
for guardian in guardians:
  mediator.announce(guardian)

# Orchestation (Private Key Share)
orchestrated = mediator.orchestrate()

# Verify (Prove the guardians acted in good faith)
verified = mediator.verify()

# Publish the Joint Public Key
joint_public_key = mediator.publish_joint_key()

```

## Implementation Considerations

ElectionGuard can be run without the key ceremony. The key ceremony is the recommended process to generate keys for live end-to-end verifiable elections, however this process may not be necessary for other use cases such as privacy preserving risk limiting audits.


================================================
FILE: docs/2_Encrypt_Ballots.md
================================================
# Encrypt Ballots

The primary function of ElectionGuard is to encrypt ballots.  Ballots are encrypted on a uniquely identified device within the context of a specific election.  The election public key is used to encrypt ballots.  A _master nonce_ value is generated for each ballot and the nonce is used to derive other nonce values for encrypting the selection on each ballot.

## Glossary

- **Plaintext Ballot** - The plaintext representation of a voter's selections
- **Ciphertext Ballot** - The encrypted representation of a voter's selections
- **Master Nonce** - A random number used to derive encryptions in a `CiphertextBallot`
- **Verification Code or Ballot Code** - A unique hash value generated by an _Encryption Device_ to anonymously identify a ballot
- **Encryption Device** The device that is doing the encryption

## Process

1. Verify the ballot is well-formed against the _Election Metadata_ (`InternalManifest`)
2. Generate a random master nonce value to use as a secret when encrypting the ballot
3. Using the metadata of the election and the master nonce, encrypt each selection on the ballot
4. For each selection on the ballot, generate a disjunctive Non-Interactive Zero-Knowledge Proof that the encryption is either an encryption of zero or one
5. For each contest on the ballot, generate a Non-Interactive Zero-Knowledge Proof that the sum of all encrypted ballots is equal to the selection limit on the contest
6. Generate a verification code for the ballot

## Usage Example

```python

internal_manifest: InternalManifest
context: CiphertextElectionContext
ballot: PlaintextBallot

# Configure an encryption device
device = EncryptionDevice(generate_device_uuid(), "Session", 12345, "polling-place-one")
encrypter = EncryptionMediator(internal_manifest, context, device)

# Encrypt the ballot
encrypted_ballot: CiphertextBallot = encrypter.encrypt(ballot)

```

## Implementation Considerations

When encrypting a ballot, a new ballot object is created that is associated with the plaintext ballot.  The encrypted representation includes all of the encryptions, hash values, nonce values, and proofs generated at each step.  For the primary end-to-end election workflow, consumers of this API should separate the `nonce` values from the `CiphertextBallot` prior to publishing the encrypted ballot representation.  


================================================
FILE: docs/3_Cast_and_Spoil.md
================================================
# Cast and Spoil Ballots

Each ballot that is completed by a voter must be either cast or spoiled.  A cast ballot is a ballot that the voter accepts as valid and wishes to include in the official election tally.  A spoiled ballot, also referred to as a challenged ballot, is a ballot that the voter does not accept as valid and wishes to exclude from the official election tally.

ElectionGuard includes a mechanism to mark a specific ballot as either cast or spoiled.  Cast ballots are included in the tally record, while spoiled ballots are not.  Spoiled ballots are decrypted into plaintext and published along with the rest of the election record.

## Jurisdictional Differences

Depending on the jurisdiction conducting an election the process of casting and spoiling ballots may be handled differently. For this reason, there are multiple ways to interact with the `BallotBox` and `Tally`.

- By calling [accept_ballot](###-Function-Example) - Ballots can be marked cast or spoiled manually.
- By using the [Ballot Box](###-Class-Example) - Ballots can be marked cast or spoiled using a stateful class.

### Unknown Ballots

In some jurisdictions, there is a limit on the number of ballots that may be marked as spoiled.  If this is the case, you may use the `BallotBoxState.UNKNOWN` state, or extend the enumeration to support your specific use case.

## Encrypted Tally

Once all of the ballots are marked as _cast_ or _spoiled_, all of the encryptions of each option are homomorphically combined to form an encryption of the total number of times that each option was selected in the election.  

> This process is completed only for cast ballot.

> The spoiled ballots are simply marked for inclusion in the election results.

## Glossary

- **Ciphertext Ballot** An encrypted representation of a voter's filled-in ballot.
- **Submitted Ballot** A wrapper around the `CiphertextBallot` that represents a ballot that is submitted for inclusion in election results and is either: cast or spoiled.
- **Ballot Box** A stateful collection of ballots that are either cast or spoiled.
- **Ballot Store** A repository for retaining cast and spoiled ballots.
- **Cast Ballot** A ballot which a voter has accepted as valid to be included in the official election tally.
- **Spoiled Ballot** A ballot which a voter did not accept as valid and is not included in the tally.
- **Unknown Ballot** A ballot which may not yet be determined as cast or spoiled, or that may have been spoiled but is otherwise not published in the election results.
- **Homomorphic Tally** An encrypted representation of every selection on every ballot that was cast.  This representation is stored in a `CiphertextTally` object.

## Process

1. Each ballot is loaded into memory (if it is not already).
2. Each ballot is verified to be correct according to the specific election metadata and encryption context.
3. Each ballot is `submitted` and identified as either being `cast` or `spoiled`.
4. The collection of cast and spoiled ballots is cached in the `DataStore`.
5. All ballots are tallied.  The `cast` ballots are combined to create a `CiphertextTally` The spoiled ballots are cached for decryption later.

## Ballot Box

The ballot box can be interacted with via a stateful class that caches the election context, or via stateless functions.  The following examples demonstrate some ways to interact with the ballot box.

Depending on the specific election workflow, the `BallotBox`class  may not be used for a given election.  For instance, in one case a ballot can be **submitted** directly on an electronic device, in which case there is no `BallotBox`.  In a different workflow, a ballot may be explicitly cast or spoiled in a later step, such as after printing for voter review.

In all cases, a ballot must be marked as either `cast` or `spoiled` to be included in a tally result.

### Class Example

```python

from electionguard.ballot_box import BallotBox

internal_manifest: InternalManifest
encryption: CiphertextElection
store: DataStore
ballots_to_cast: List[CiphertextBallot]
ballots_to_spoil: List[CiphertextBallot]

# The Ballot Box is a thin wrapper around the `accept_ballot` function method
ballot_box = BallotBox(internal_manifest, encryption, store)

# Cast the ballots
for ballot in ballots_to_cast:
    submitted_ballot = ballot_box.cast(ballot)
    # The ballot is both returned, and placed into the ballot store
    assert(store.get(submitted_ballot.object_id) == submitted_ballot)

# Spoil the ballots
for ballot in ballots_to_spoil:
    assert(ballot_box.spoil(ballot) is not None)

```

### Function Example

``` python

from electionguard.ballot_box import accept_ballot

internal_manifest: InternalManifest
encryption: CiphertextElection
store: DataStore
ballots_to_cast: List[CiphertextBallot]
ballots_to_spoil: List[CiphertextBallot]

for ballot in ballots_to_cast:
    submitted_ballot = accept_ballot(
        ballot, BallotBoxState.CAST, internal_manifest, encryption, store
    )

for ballot in ballots_to_spoil:
    submitted_ballot = accept_ballot(
        ballot, BallotBoxState.SPOILED, internal_manifest, encryption, store
    )

```

## Tally

Generating the encrypted `CiphertextTally` can be completed by creating a `CiphertextTally` stateful class and manually marshalling each cast and spoiled ballot.  Using this method is preferable when the collection of ballots is very large

For convenience, stateless functions are also provided to automatically generate the `CiphertextTally` from a `DataStore`.  This method is preferred when the collection of ballots is arbitrarily small, or when the `DataStore` is overloaded with a custom implementation.

### Using the Stateful Class

```python

internal_manifest: InternalManifest
context: CiphertextElectionContext

ballots: List[SubmittedBallot]

tally = CiphertextTally(internal_manifest, context)

for ballot in ballots:
    assert(tally.append(ballot))

```

### Functional Method

```python

internal_manifest: InternalManifest
context: CiphertextElectionContext
store: DataStore

tally = tally_ballots(store, internal_manifest, context)
assert(tally is not None)

```


================================================
FILE: docs/4_Decrypt_Tally.md
================================================
# Decryption

At the conclusion of voting, all of the cast ballots are published in their encrypted form in the election record together with the proofs that the ballots are well-formed. Additionally, all of the encryptions of each option are homomorphically-combined to form an encryption of the total number of times that each option was selected. The homomorphically-combined encryptions are decrypted to generate the election tally. Individual cast ballots are not decrypted. Individual spoiled ballots are decrypted and the plaintext values are published along with the encrypted representations and the proofs.

In order to decrypt the homomorphically-combined encryption of each selection, each `Guardian` participating in the decryption must compute a specific `Decryption Share` of the decryption.

It is preferable that all guardians be present for decryption, however in the event that guardians cannot be present, Electionguard includes a mechanism to decrypt with the `Quorum of Guardians`.

During the [Key Ceremony](1_Key_Ceremony.md) a `Quorum of Guardians` is defined that represents the minimum number of guardians that must be present to decrypt the election. If the decryption is to proceed with a `Quorum of Guardians` greater than or equal to the `Quorum` count, but fewer than the total number of guardians, then a subset of the `Available Guardians` must also each construct a `Partial Decryption Share` for the missing `Missing Guardian`, in addition to providing their own `Decryption Share`.

It is important to note that mathematically not every present guardian has to compute a `Partial Decryption Share` for every `Missing Guardian`. Only the `Quorum Count` of guardians are necessary to construct `Partial Decryption Shares` in order to compensate for any Missing Guardian.

In this implementation, we take an approach that utilizes all Available Guardians to compensate for Missing Guardians. When it is determined that guardians are missing, all available guardians each calculate a `Partial Decryption Share` for the missing guardian and publish the result. A `Quorum of Guardians` count of available `Partial Decryption Shares` is randomly selected from the pool of available partial decryption shares for a given` Missing Guardian`. If more than one guardian is missing, we randomly choose to ignore the `Partial Decryption Share` provided by one of the Available Guardians whose partial decryption share was chosen for the previous Missing Guardian, and randomly select again from the pool of available Partial Decryption Shares. This ensures that all available guardians have the opportunity to participate in compensating for Missing Guardians.

## Glossary

- **Guardian** A guardian of the election who holds the ability to partially decrypt the election results
- **Decryption Share** A guardian's partial share of a decryption
- **Encrypted Tally** The homomorphically-combined and encrypted representation of all selections made for each option on every contest in the election. See [Ballot Box]() for more information.
- **Key Ceremony** The process conducted at the beginning of the election to create the joint encryption context for encrypting ballots during the election. See [Key Ceremony](1_Key_Ceremony.md) for more information.
- **Quorum of Guardians** The minimum count (_threshold_) of guardians that must be present in order to successfully decrypt the election results.
- **Available Guardian** A guardian that has announced as _present_ for the decryption phase
- **Missing Guardian** A guardian who was configured during the `Key Ceremony` but who is not present for the decryption of the election results.
- **Compensated Decryption Share** - a partial decryption share value computed by an available guardian to compensate for a missing guardian so that the missing guardian's share can be generated and the election results can be successfully decrypted.
- **Decryption Mediator** - A component or actor responsible for composing each guardian's partial decryptions or compensated decryptions into the plaintext tally

## Process

1. Each `Guardian` that will participate in the decryption process computes a `Decryption Share` of the _Ciphertext Tally_.
2. Each `Guardian` also computes a Chaum-Pedersen proof of correctness of their `Decryption Share`.

### Decryption when All Guardians are Present

3. If all guardians are present, the Decryption Shares are combined to generate a tally for each option on every contest

### Decryption when some Guardians are Missing

_warning: The functionality described in this segment is still a 🚧 Work In Progress_

When one or more of the Guardians are missing, any subset of the Guardians that are present can use the information they have about the other guardian's private keys to reconstruct the partial decryption shares for the missing guardians.

4. Each `Available Guardian` computes a `Partial Decryption Share` for each `Missing Guardian`
5. at least a `Quorum` count of `Partial Decryption Shares` are chosen from the values generated in the previous step for a specific `Missing guardian`
6. Each chosen `Available Guardian` uses its `Partial Decryption Share` to compute a share of the missing partial decryption.
7. the process is re-run until all Missing Guardians are compensated for.
8. The `Compensated Decryption Shares` are combined to _reconstruct_ the missing `TallyDecryptionShare`
9. finally, all of the `DecryptionShares` are combined to generate a tally for each option on every contest

## Challenged/Spoiled Ballots

If a ballot is not to be included in the vote count, it is considered challenged, or [Spoiled](https://en.wikipedia.org/wiki/Spoilt_vote). Every ballot spoiled in an election is individually verifiably decrypted in exactly the same way that the aggregate ballot of tallies is decrypted. Since spoiled ballots are not included as part of the vote count, they are included in the Election Record with their plaintext values included along with the encrypted representations.

Spoiling ballots is an important part of the ElectionGuard process as it allows voters to explicitly generate challenge ballots that are verifiable as part of the Election Record.

## Usage Example

Here is a simple example of how to execute the decryption process.

```python

internal_manifest: InternalManifest       # Load the election manifest
context: CiphertextElectionContext          # Load the election encryption context
encrypted_Tally: CiphertextTally            # Provide a tally from the previous step

available_guardians: List[Guardian]         # Provite the list of guardians who will participate
missing_guardians: List[str]                # Provide a list of guardians who will not participate

mediator = DecryptionMediator(internal_manifest, context, encrypted_tally)

# Loop through the available guardians and annouce their presence
for guardian in available_guardians:
    if (mediator.announce(guardian) is None):
        break

# loop through the missing guardians and compensate for them
for guardian in missing_guardians:
    if (mediator.compensate(guardian) is None):
        break

# Generate the plaintext tally
plaintext_tally = mediator.get_plaintext_tally()

# The plaintext tally automatically includes the election tally and the spoiled ballots
contest_tallies = plaintext_tally.contests
spoiled_ballots = plaintext_tally.spoiled_ballots

```

## Implementation Considerations

In certain use cases where the `Key Ceremony` is not used, ballots and tallies can be decrypted directly using the secret key of the election. See the [Tally Tests](https://github.com/microsoft/electionguard-python/tree/main/tests/test_tally.md) for an example of how to decrypt the tally using the secret key.


================================================
FILE: docs/5_Publish_and_Verify.md
================================================
# Publish and Verify

## Publish

Publishing the election artifacts helps ensure third parties can verify the election. Refer to the specification on the specific details. Below is a breakdown of the objects within the repository. These are files that should be published at the close of the election so others can verify the election.

**Election Artifacts**

```py
manifest: Manifest                        # Manifest
constants: ElectionConstants              # Constants
context: CiphertextElectionContext        # Encryption context
devices: List[EncryptionDevice]           # Encryption devices
guardian_records: List[GuardianRecord]    # Record of public guardian information
submitted_ballots: List[SubmittedBallot]  # Encrypted submitted ballots
challenge_ballots: List[PlaintextTally]   # Decrypted challenge ballots
ciphertext_tally: CiphertextTally         # Encrypted tally
plaintext_tally: PlaintextTally           # Decrypted tally
```

These classes have been defined as `dataclass` to ensure that `asdict` can be used. This ensures ease of serialization to dictionaries within python, but allows customization for those wishing to use custom serialization. `electionguard_tools` includes `export.py` which can be used as an example.

## Verify

The election artifacts provide a means to begin validation. Start with deserializing the election artifacts to their original classes.


================================================
FILE: docs/Build_and_Run.md
================================================
# Build and Run

These instructions can be used to build and run the project.

## Setup

### 1. Initialize dev environment

```
make environment
```

OR

```
poetry install --dev
```

### 2. Install the `electionguard` module in edit mode

```
make install
```

OR

```
poetry run python -m pip install -e .
```

!!! warning "Note: gmpy2 Windows Installation"

    **Recommended: Use Windows Subsystem for Linux (WSL)**

    _WSL supports the generic workflow for installtion._

    1. Install [WSL](https://docs.microsoft.com/en-us/windows/wsl/install). 
    2. Return to **1. Initialize dev environment**

    **Alternative: Install pre-compiled binary**

    _Poetry does not support `pip install --find-links`, so the `pyproject.toml` must be edited and utilize a local pre-compiled binary of the gmpy2 package._

    1. Determine if 64-bit:
        _The 32 vs 64 bit is based on your installed python version NOT your system._
        This code snippet will read true for 64 bit.
    ```py
    python -c 'from sys import maxsize; print(maxsize > 2**32)'
    ```
    2. Download [pre-compiled binary](https://www.lfd.uci.edu/~gohlke/pythonlibs/#gmpy) into project folder
    3. Within `pyproject.toml`, replace `gmpy2` reference with direct path to downloaded file.
    ```py
    gmpy2 = { path = "./packages/gmpy2-2.0.8-cp39-cp39-win_amd64.whl" }
    ```
    3. Run `make install`


### 3. Validate import of module _(Optional)_

```
make validate
```

OR

```
poetry run python -c 'import electionguard; print(electionguard.__package__ + " successfully imported")'
```

## Running

### Option 1: Code Coverage

```
make coverage
```

OR

```
poetry run coverage report
```

### Option 2: Run tests in VS Code

Install recommended test explorer extensions and run unit tests through tool.

**⚠️ Note:** For Windows, be sure to select the [virtual environment Python interpreter](https://docs.microsoft.com/en-us/visualstudio/python/installing-python-interpreters).

### Option 3: Run test command

```
make test
```

OR

```
poetry run python -m pytest /tests
```


================================================
FILE: docs/Design_and_Architecture.md
================================================
# Design & Architecture

This describes the design and architecture of the `electionguard-python` project.

## Design

### ✅ Simplicity

Simplicity is the first and foremost goal of the code. The intent is for others to be able to **easily transliterate the code to any other programming language** with little more than structures and functions. This simplicity applies to all aspects of the code design, including naming.

### ✅ Extendable and Interpretable

The library is intentionally general-purpose to support the different use cases of "end to end verifiable" voting systems. Different projects may wish to use different layers of the library, including math primitives, encryption functions, and more.

### ✅ Object Oriented Design (OOD) & Functional Methods

An additional goal is to build a familiar object oriented design with underlying functional style methods. This allows users to simply construct objects in an OOP fashion or directly call the underlying methods in a functional way. This design also facilitates easy testing and composition.

Class methods are used for simplicity, but sophistication with regard to inheritance, object encapsulation, or design patterns is intentionally avoided. These class methods usually rely on the aforementioned functional methods unless the class contains state.

### ✅ Immutable

The library prefers immutable objects where possible to encourage simple data structures.

### ✅ Dataclasses

`dataclass` is used frequently to simplify constructors. This follows the simplicity aspect, but also ensures easier serialization without being prescriptive on which library to use.

### ✅ Concurrency

While this library is not explicitly engineered to _use_ concurrency, it's definitely meant to work properly when the caller wants to run more than one thing at a time. This means there is no global, mutable state in the library with the exception of a discrete-log function doing internal memoization, itself explicitly written to be thread-safe.

### ✅ Union Classes

For both naming purposes and usability, union classes are generally preferred. This can alleviate issues with [multiple inheritance](#multiple-inheritance)

### 🚫 Exceptions

To allow for easier transliteration, the library will not raise exception across the API boundary since this is not available in all languages. Instead, the library will have a variety of functions that indicate failures by returning `None`; the caller is expected to check if the result is `None` before any further processing. Python 3 `typing` calls this sort of result `Optional`.This tactic also indicates all exceptions raised are expected to be from bugs.

### 🚫 Multiple Inheritance

Although a handy python feature, for implementation simplicity this feature is not used and should be avoided.

## Architecture

### 🤝 Approachable

The python setup is designed to be as approachable as possible from the environment to the continuous integration.

#### Setup

The library contains a `Pipfile` that can be used with `pipenv`to ensure the correct dependencies are included, as well as a `setup.py` to install the package itself. There is also a `Makefile` which allows for simple `make` commands to ease new developers into the build process. If the user is a new developer, the recommendation is starting with [Visual Studio Code](https://code.visualstudio.com/) since there are many default settings and recommended extensions in the repository.

#### Folder Structure

The folder structure is kept to a bare minimum. The ElectionGuard library is located in `src/electionguard` and tests are in `tests`. Standalone applications or other pieces should be in separate subdirectories. For example, the `tests/bench` directory contains a simple Chaum-Pedersen proof computation benchmark.

#### Commands

To simplify the command structure, [make](https://www.gnu.org/software/make/manual/make.html) is used. A `Makefile` sits in the root directory and contains useful commands that can be used to run setup. These are shown in use in the [continuous integration](#continuous-integration).

### 🧹 Clean Code

The library uses several tools to assist developers in maintaining clean code. Visual Studio Code is recommended for easier setup.

#### Typing

The library uses Python 3 **type hints** throughout and ensures return types are defined. **[Mypy](https://mypy.readthedocs.io/en/stable/)** is used to statically check the typing.

#### Linting

[Pylint]() is used for typing; settings are in the `.pylinrc` file.

#### Formatting

[Black]() is used for auto-formatting and checking the formatting of the python code. Settings are in the `pyproject.toml` file.

### 🧪 Testing

The goal of the project is 100% code coverage with an understanding that there are some limitations.

#### Property Based

Property testing is helpful for [testing certain properties](https://fsharpforfunandprofit.com/posts/property-based-testing-2/). The library uses [Hypothesis](https://hypothesis.readthedocs.io/en/stable/) property-based testing to vigorously exercise the library. The library includes generator functions for all the core datatypes, making them easy to randomly generate.

### 🚀 Continuous Integration

GitHub Actions are being used for continuous integration. Cross-platform is a primary goal and the workflows provided demonstrate how a developer can build in Linux, MacOS, and Windows.

The run workflows can be seen on the GitHub repo page or a user can navigate to `.github/workflows` to inspect them.

### 📦 Math Library

[gmpy2](https://gmpy2.readthedocs.io/en/latest/index.html) is a multiprecision numeric library that was chosen over Python's built-ins `int` type for its speed necessary for encryption performance. The current version used is `2.0.8` which is the most stable version. This is necessary for cross-platform since the library uses precompiled libraries for Windows due to reliance on `gmp`. The gmpy2 options are chosen over the native Python equivalents as shown below.

- **Integers:** `int` -> [`mpz`](https://gmpy2.readthedocs.io/en/latest/mpz.html)
- **Exponents:** `pow` -> `powmod`

With the use of **mypy** for typing and the lack of type presence in [Typeshed](https://github.com/python/typeshed) for gmpy2, the library provides a stub in `stubs/gmpy2.pyi` to ensure the code compiles without warnings.


================================================
FILE: docs/Election_Manifest.md
================================================
# Overview

There are many types of elections. We need a base set of data that shows how these different types of elections are handled in an ElectionGuard end-to-end verifiable election (or ballot comparison audits).

We worked with InfernoRed, VotingWorks, and Dan Wallach of Rice University (thanks folks!) to develop a set of conventions, tests, and sample data (based on a starting dataset sample from the Center for Civic Design) that demonstrate how to encode the information necessary to conduct an election into a format that ElectionGuard can use. The election terms and structure are based whenever possible on the [NIST SP-1500-101 Election Event Logging Common Data Format Specification](https://pages.nist.gov/ElectionEventLogging/index.html) (with a prettier and (mostly) more functional implementation [here](https://developers.google.com/elections-data/reference) and a [PDF for version 2](https://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.1500-100r2.pdf)).  The information captured by the NIST standard is codified into an `election manifest` that defines common elements when conducting an election, such as locations, candidates, parties, contests, and ballot styles.

ElectionGuard uses the data contained in the Election Manifest to associate ballots with specific ballot styles and to verify the accuracy of data at different stages of the election process.  Note that not all of the data contained in the Election Manifest impacts the computations of tallies and zero-knowledge proofs used in the published election data that demonstrates end-to-end verifiability; however it is important to include as much data as possible in order to distinguish one election from another. With a well-defined Election Manifest, improperly formatted ballot encryption requests will fail with error messages at the moment of initial encryption; the enforcement of any logic or behavior to prevent overvoting or other malformed ballot submissions are handled by the encrypting device, not ElectionGuard.

In addition, since json files do not accommodate comments, all notations and exceptions are documented in this readme.

## Election Data Structure

[Elections are characterized into types by NIST](https://developers.google.com/elections-data/reference/election-type) as shown in the table below

election type | description
------------- | ----------------
general  | For an election held typically on the national day for elections.
partisan-primary-closed | For a primary election that is for a specific party where voter eligibility is based on registration.
partisan-primary-open | For a primary election that is for a specific party where voter declares desired party or chooses in private.
primary | For a primary election without a specified type, such as a nonpartisan primary.
runoff | For an election to decide a prior contest that ended with no candidate receiving a majority of the votes.
special | For an election held out of sequence for special circumstances, for example, to fill a vacated office.
other | Used when the election type is not listed in this enumeration. If used, include a specific value of the OtherType element.

We present two sample manifests: `general` and `partisan-primary-closed`. The core distinction between the two samples is the role of party: in general elections voters can choose to vote for candidates from any party in a contest, regardless of party affiliation. In partisan primaries voters can only vote in contests germane to their party declaration or affiliation. As such, `special`, `runoff`, and `primary` election types will follow the `general` pattern, and `partisan-primary-open` will follow the `partisan-primary-closed` pattern. Open `primary` elections can follow either pattern as determined by their governing rules and regulations. (As noted above, ElectionGuard expects properly-formed ballots; e.g., it would error and fail to encrypt a ballot in an `open-primary-closed` election if a contest with an incorrect party affiliation were submitted (as indicated by the ).)

## Ballot Styles and Geography

At least in the United States, many complications are introduced by voting simultaneously on election contests that apply in specific geographies and  jurisdictions. For example, a single election could include contests for congress, state assembly, school, and utility districts, each with their own geographic boundaries, many that do not respect town or county lines.  The ElectionGuard Election Manifest data format is flexible to accommodate most situations, but it is usually up to the election commission and the external system to determine what each component of the manifest actually means.

In the following examples, we will work through the process of defining different election types at a high level and describe the process of building the election manifest.

### Geographic and Ballot Style Breakdown

Each election can be thought of as a list of contests that are relevant to a certain group of people in a specific place. 
 In order to determine who is supposed to vote on which contests, we first need to define the geographic jurisdictions where the election is taking place.  [The NIST Guidelines](<https://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.1500-100r2.pdf>) present an excellent discussion of the geographic interplay of different contests. The diagram from page 12 is presented below.

![](https://res.cloudinary.com/electionguard/image/upload/v1586960923/nist-election-model-uml.png)

As the diagram shows, congressional,  state assembly, school district and other geographic boundaries project onto towns and municipalities in different ways. Elections manage this complexity by creating unique ballot _styles_ that present to voters only the contests that pertain to them. Different jurisdictions use terms such as wards, precincts, and districts to describe the areas of overlap that guide ballot style creation. We will use `precinct` but `ward` and `district` could be used instead.

### Contests, Candidates and Parties

In most cases, a resident of a specific _precinct_ or location will expect to see a certain list of contests that are relevant to them.  A contest is a specific collection of available choices (_selections_) from which the voter may choose some subset.  For the ElectionGuard Election Manifest, each possible selection in a contest must be associated with a candidate, even for Referendum-style contests.  If a contest also supports write-in values, then a write-in candidate is also defined.  Candidates may also be associated with specific parties, but this is not required for all election types.

## Introducing Hamilton County, OZ

To help disambiguate, let's explore an example.

### Geographic Jurisdictions

Hamilton County includes 3 townships: LaCroix, Arlington, Harris.  The town of LaCroix also has a utility district that comprises its own precinct for special referendums. Arlington has two distinct school districts.  The county is also split into two congressional districts, district 5 and district 7.  Harris township is entirely within Congressional District 5, but both LaCroix and Arlington are split between congressional districts 5 and 7.

![Hamilton County Electoral Map](https://res.cloudinary.com/electionguard/image/upload/v1593617785/hamilton-county-district-map_xxki0z.png)

#### Building the Geographic Jurisdiction Mapping (Geopolitical Units)

The Election Manifest includes an array of objects called `geopoliticalUnits` (a.k.a. _gpUnit_).  Each _Geopolitical Unit_ must include the following fields:
- **objectId** - a unique identifier for the gpUnit.  This value is used to map a contest to a specific jurisdiction
- **name** - the friendly name of the gp Unit
- **type** - they _type_ of jurisdiction (one of the [Reporting Unit Types](https://developers.google.com/elections-data/reference/reporting-unit-type))
- **contact information** - the contact info for the geopolitical unit

Geopolitical units are polygons on a map represented by legal jurisdictions.  In our example Election Manifest for hamilton County, there is one geopolitical unit for each jurisdictional boundary in the image above:
- Hamilton County
- Congressional District 5
- congressional District 7
- LaCroix Township
- Exeter Utility District (within LaCroix Township)
- Harris Township
- Arlington Township
- Pismo Beach School District (within Arlington Township)
- Somerset School District (within Arlington Township)

When defining the geopolitical units for an election, we define all of the possible geopolitical units for an election; even if there are no contests for a specific jurisdiction.  This way, if contests are added or removed during the setup phase, you do not also have to remember to update the list of geopolitical units.  Alternatively, you can define only the GP Units for which there are contests.

### The General Election Contests

A **general election** will occur in Hamilton County.  The county is voting along with the rest of the province, and the county is responsible for tabulating its own election results.  This means that the _Election Scope_ is defined at the county level.

For the `general` election, the following sets of contests (and associated geographic boundaries) obtain:

1. **The National Contests** - President and Vice President.  This contest demonstrates a "vote for the ticket" and allows write-ins
2. **Province Contests** - Governor - this contest demonstrates a long list of candidate names
3. **Congressional Contests** - Congress Districts 5 and 7 - these contests demonstrate how to split a district using multiple ballot styles
4. **Township Contests** - Retain Chief Justice - This contest demonstrates a contest that applies to a specific town whose boundaries are split across multiple ballot styles
4. **School District Contests** - School Board - these contests demonstrate contests with multiple selections (_n-of-m_) and allow write-ins
School Board, and Utility district referendum to show ballot style splits
5. **Utility District Contest** - Utility District - This contest demonstrates a referendum-style contest with long descriptions and display language translation into Spanish

Each contest must be associated with exactly **ONE** `electoralDistrictId`.  The `electoralDistrictId` field on the contest is populated with the `objectId` of the associated _Geopolitical Unit_ (e.g. the Contest `congress-district-7-contest` has the `electoralDistrictId` `congress-district-7`

Each contest must also define a `sequenceOrder`.  the _sequence order_ is an indexing mechanism used internally.  _It is not the sequence that the contests are displayed to the user_.  The order in which contests are displayed to the user is up to the implementing application.

### The General Election Ballot Styles

A ballot style is the set of contests that a specific voter should see on their ballot for a given location.  The ballot style is associated to the set of geopolitical units relevant to a specific point on a map.  Since each contest is also associated with a geopolitical unit, a mapping is created between a point on a map and the contests that are relevant to that point.

For instance, a voter that lives in the _Exeter Utility District_ should see contests that are relevant to Congressional District 7, LaCroix Township and the Exeter Utility District.  

| Geopolitical Units are overlapping polygons, and ballot styles are the list of polygons relevant to a specific point on the map.

Similar to Geopolitical Units, we define all of the possible ballot styles for an election in our example, even if there are no contests specific to a ballot style.  This is subjective and the behavior may be different for the integrating system:
- Congressional District 7 Outside Any Township
- Congressional District 7 LaCroix Township
- Congressional District 7 LaCroix Township Exeter Utility District
- Congressional District 7 Arlington Township
- Congressional District 7 Arlington Township Pismo Beach School district
- Congressional District 7 Arlington Township Somerset School district
- Congressional District 5 Outside Any Township
- Congressional District 5 LaCroix Township
- Congressional District 5 Harris Township
- Congressional District 5 Arlington Township Pismo Beach School district
- Congressional District 5 Arlington Township Somerset School district

By defining all of the possible ballot styles and all of the possible geopolitical units, we ensure that if a contest is added or removed, we only have to make sure the contest is correct.  We do not have to modify the list of geopolitical units or ballot styles.

## Data Flexibility

The relationship between a ballot style and the contests that are displayed on it are subjective to the implementing application.  This example is just one way to define this relationship that is purposefully verbose.  For instance, in our example we define a geopolitical unit as a set of overlapping polygons, and a ballot style as the intersection of those polygons at a specific point.  This is a top-down approach.  Alternatively, we could have defined a geopolitical unit as the intersection area of those polygons and mapped one ballot style to each geopolitical unit 1 to 1.

for instance, instead of defining a single GP Unit each for:
- Congressional District 5, 
- Congressional District 7, 
- LaCroix Township,
- Exeter Utility district, etc; 

we could have instead defined the GP Units as:
- Congressional District 5 No Township
- Congressional District 7 No Township
- Congressional District 5 inside LaCroix
- Congressional District 5 Inside LaCroix and Exeter, etc.

Then, instead of each Ballot Style having multiple GP Units, each ballot style would have applied to exactly one GP Unit.

### Data Validation

When the election Manifest is loaded into ElectionGuard, its validity is checked semantically against the data format required to conduct an ElectionGuard Election. Specifically, we check that:
- Each Geopolitical Unit has a unique objectId
- Each Ballot Style maps to at least one valid Geopolitical Unit
- Each Party has a unique objectId
- Each Candidate either does not have a party, or is associated with a valid party
- Each Contest has a unique Sequence Order
- Each contest is associated with exactly one valid geopolitical unit
- Each contest has a valid number of selections for the number of seats in the contest
- Each selection on each contest is associated with a valid Candidate

as long as the election manifest format matches the validation criteria, the election can proceed as an ElectionGuard election.

## Frequently Asked Questions

Q: What if my ballot styles are not associated with geopolitical units?
A: There are a few ways to handle this.  In most cases, you can simply map the ballot style 1 to 1 to the geopolitical unit.  for instance, if `ballot-style-1` includes `contest-1` then you may create `geopolitical-unit-1` and associate both the ballot style and the contest to that geopolitical unit.

This documentation is under review and subject to change.  Please do not hesitate to open a github issue if you have questions, or find errors or omissions.


================================================
FILE: docs/Project_Workflow.md
================================================
# Project Workflow

## ✨ Start an Iteration
Each iteration on this repository will be tracked by a GitHub **[Milestone](https://help.github.com/en/github/managing-your-work-on-github/about-milestones)**. The completion of the milestone will queue a GitHub **[Release](https://help.github.com/en/github/administering-a-repository/managing-releases-in-a-repository)**. Issues will be added to the milestones to indicate work needed. After completion, this milestone can then act as a list of work contained within a release. 

## 🔀 Pull Request

### Attach Issue
Each pull request **MUST** be attached to an issue. On the surface, this ensures that closing a pull request will close an issue. This also ensures the issue can be included in the milestone. For this repository, the use of issues assists the team to use the [project board]() to track the progress towards a milestone.  

### Validation
Each pull request is validated by the [Pull Request Validation](https://github.com/microsoft/electionguard-python/blob/main/.github/workflows/pull_request.yml) GitHub [Action](https://help.github.com/en/actions). This action can be viewed from the PR or from the actions to inspect the details. 

### Review
All pull requests require a review from a **Contributor** but any reviewers are welcome.

## 🏁 Create a Release
At the end of an iteration aka when a milestone is complete, a release can be created. 

### Steps
1. Raise version number in `setup.py`
2. Close Milestone 
3. Edit Release details _(optional)_

### Release Workflow

Closing the milestone queues the [Release Build](https://github.com/microsoft/electionguard-python/blob/main/.github/workflows/release.yml) GitHub [Action](https://help.github.com/en/actions). This action is designed to reduce the effort by maintainers and give the community an open view of the package flow.

- Build package
- Create dependency graph
- Upload package to PyPi
- Validate PyPi package
- Upload package and graph to GitHub Workflow
- Create Release
- Upload zipped package and graph to Release
- Update GitHub Pages Documentation

================================================
FILE: docs/Tablet Setup.md
================================================
# Setup Surface Go 3 Tablet

This documentation is a reference on how to setup a brand new computer (in this case a Surface Go 3) to use the Python repository to run the Admin and Guardian GUIs for an election. Some steps, such as "Turn Off S Mode" might not apply to the computer you are setting up. All usernames and passwords are set to xxx in this document and should be set to valid values for your own purpose.

## Setup Windows
* When prompted for email address use
    * xxxx@xxxx.com
    * xxxx
* skip protecting account
* skip hello setup
* pin xxxx
* default privacy
* skip customization
* decline office 365
* installs Win11 (30 min or so)

## Turn Off S Mode
* settings -> system -> activation
* opens windows store
* hit Get button and wait for it to complete

## Windows Updates
* Do all the updates (a lot of updates)
* Change to best performance mode
    * Settings -> System -> Power and Battery
    * Power Mode -> Best Performance

## Install Hyper-V and Linux (admin only)
* Go to Settings
* Search for features
* Go to optional features
* More Windows Features
* Install WSL, Virtual Machine Platform and Windows Hypervisor Platform settings
* Restart windows
* Go to windows store and install ubuntu
* When running it the first time it will give a link to install a new kernel for WSL2
* Run ubuntu and setup a user
    * Username: xxxx
    * Password: xxxx

## Docker Installation (admin only)
* Get docker desktop and install.
* In the settings (gear icon) make the following changes:
    * Make sure that "Start Docker Desktop when you log in" is on
    * Make sure that "Use the WSL 2 based engine" is on

## Developer Tools
* Command prompt -> python3 (install from windows store)
* Install chrome (does not need to be set to current browser)
* Install VS Code
* Git
    * https://git-scm.com/download/win
* Install chocolatey using powershell command from https://chocolatey.org/install
* Install make
    * choco install make	
* Install poetry (powershell) https://python-poetry.org/docs
    * Add to path (See "Set Environment Variables" below on steps to get to the path)

## Download Python Source Code
* Open a Command prompt and use the following commands
    * mkdir code
    * cd code
    * git clone https://github.com/microsoft/electionguard-python


## Terminal Settings
* Open up Terminal
    * Go to settings in Terminal
    * Default Profile => Command Prompt
    * Profiles (left) -> Defaults 
        * Run this profile as Admin -> on
        * Starting Starting directory to be directory where source code is downloaded
    * Hit "Save" button at the bottom of the window

## User Interface Changes
* Change touch keyboard to traditional instead of default
* Go into resize (using the gear icon) and set the zoom to 200 (max value)

## Set Environment Variables
* Go to Settings
* Search for environment
* Select "Edit the system environment variables"
* Select the button "Environment Variables"
* Select "New…"
* Create the following settings
    * EG_DB_PASSWORD = xxxx
    * EG_DB_HOST = 10.10.0.100
    * EG_IS_ADMIN = true for an admin and false if guardian
    * admin only - EG_DB_DIR = ./database 

## Set Python Code
* Open Terminal and run the following commands
    * make environment
        * There will be an error at the end.  This is normal
    * poetry run eg 
        * should show the help for the eg command



================================================
FILE: docs/index.md
================================================
![Microsoft Defending Democracy Program: ElectionGuard Python](https://github.com/microsoft/electionguard-python/blob/main/images/electionguard-banner.svg?raw=true)

# 🗳 ElectionGuard Python

[![ElectionGuard Specification 0.95.0](https://img.shields.io/badge/🗳%20ElectionGuard%20Specification-0.95.0-green)](https://www.electionguard.vote) ![Github Package Action](https://github.com/microsoft/electionguard-python/workflows/Release%20Build/badge.svg) [![](https://img.shields.io/pypi/v/electionguard)](https://pypi.org/project/electionguard/) [![](https://img.shields.io/pypi/dm/electionguard)](https://pypi.org/project/electionguard/) [![Language grade: Python](https://img.shields.io/lgtm/grade/python/g/microsoft/electionguard-python.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/microsoft/electionguard-python/context:python) [![Total alerts](https://img.shields.io/lgtm/alerts/g/microsoft/electionguard-python.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/microsoft/electionguard-python/alerts/) [![Documentation Status](https://readthedocs.org/projects/electionguard-python/badge/?version=latest)](https://electionguard-python.readthedocs.io) [![license](https://img.shields.io/github/license/microsoft/electionguard)](https://github.com/microsoft/electionguard-python/blob/main/LICENSE)

This repository is a "reference implementation" of ElectionGuard written in Python 3. This implementation can be used to conduct End-to-End Verifiable Elections as well as privacy-enhanced risk-limiting audits. Components of this library can also be used to construct "Verifiers" to validate the results of an ElectionGuard election.

## 📁 In This Repository

| File/folder                 | Description                                   |
| --------------------------- | --------------------------------------------- |
| docs                        | Documentation for using the library.          |
| src/electionguard           | ElectionGuard library.                        |
| src/electionguard_tools     | Tools for testing and sample data.            |
| src/electionguard_verifier  | Verifier to validate the validity of a ballot.|
| stubs                       | Type annotations for external libraries.      |
| tests                       | Tests to exercise this codebase.              |
| CONTRIBUTING.md             | Guidelines for contributing.                  |
| README.md                   | This README file.                             |
| LICENSE                     | The license for ElectionGuard-Python.         |
| data                        | Sample election data.                         |

<br/>

## ❓ What Is ElectionGuard?

ElectionGuard is an open source software development kit (SDK) that makes voting more secure, transparent and accessible. The ElectionGuard SDK leverages homomorphic encryption to ensure that votes recorded by electronic systems of any type remain encrypted, secure, and secret. Meanwhile, ElectionGuard also allows verifiable and accurate tallying of ballots by any 3rd party organization without compromising secrecy or security.

Learn More in the [ElectionGuard Repository](https://github.com/microsoft/electionguard)

## 🦸 How Can I use ElectionGuard?

ElectionGuard supports a variety of use cases. The Primary use case is to generate verifiable end-to-end (E2E) encrypted elections. The ElectionGuard process can also be used for other use cases such as privacy enhanced risk-limiting audits (RLAs).

## 💻 Requirements

- [Python 3.9+](https://www.python.org/downloads/) is <ins>**required**</ins> to develop this SDK. If developer uses multiple versions of python, [pyenv](https://github.com/pyenv/pyenv) is suggested to assist version management.
- [GNU Make](https://www.gnu.org/software/make/manual/make.html) is used to simplify the commands and GitHub Actions. This approach is recommended to simplify the command line experience. This is built in for MacOS and Linux. For Windows, setup is simpler with [Chocolatey](https://chocolatey.org/install) and installing the provided [make package](https://chocolatey.org/packages/make). The other Windows option is [manually installing make](http://gnuwin32.sourceforge.net/packages/make.htm).
- [Gmpy2](https://gmpy2.readthedocs.io/en/latest/) is used for [Arbitrary-precision arithmetic](https://en.wikipedia.org/wiki/Arbitrary-precision_arithmetic) which
  has its own [installation requirements (native C libraries)](https://gmpy2.readthedocs.io/en/latest/intro.html#installation) on Linux and MacOS. **⚠️ Note:** _This is not required for Windows since the gmpy2 precompiled libraries are provided._
- [poetry 2.2.1](https://python-poetry.org/) is used to configure the python environment. Installation instructions can be found [here](https://python-poetry.org/docs/#installation).

## 🚀 Quick Start

Using [**make**](https://www.gnu.org/software/make/manual/make.html), the entire [GitHub Action workflow][pull request workflow] can be run with one command:

```
make
```

The unit and integration tests can also be run with make:

```
make test
```

A complete end-to-end election example can be run independently by executing:

```
make test-example
```

For more detailed build and run options, see the [documentation](Build_and_Run.md).

## 📄 Documentation

Sections:

- [Design and Architecture](Design_and_Architecture.md)
- [Build and Run](Build_and_Run.md)
- [Project Workflow](Project_Workflow.md)
- [Election Manifest](Election_Manifest.md)

Step-by-Step Process:

0. [Configure Election](0_Configure_Election.ipynb)
1. [Key Ceremony](1_Key_Ceremony.md)
2. [Encrypt Ballots](2_Encrypt_Ballots.md)
3. [Cast and Spoil](3_Cast_and_Spoil.md)
4. [Decrypt Tally](4_Decrypt_Tally.md)
5. [Publish and Verify](5_Publish_and_Verify.md)

## ❓Questions

Electionguard would love for you to ask questions out in the open using GitHub Issues. If you really want to email the ElectionGuard team, reach out at electionguard@microsoft.com.


================================================
FILE: mkdocs.yml
================================================
site_name: ElectionGuard Python
site_url: https://electionguard-python.readthedocs.io/
# site_description:
site_author: Microsoft
# google_analytics:
# remote_branch: for gh-deploy to GithubPages
# remote_name: for gh-deploy to Github Pages
copyright: "© Microsoft 2020"
docs_dir: "docs"
repo_url: https://github.com/microsoft/electionguard-python/
nav:
  - Home: index.md
  - Design and Architecture: Design_and_Architecture.md
  - Build and Run: Build_and_Run.md
  - Project Workflow: Project_Workflow.md
  - Election Manifest: Election_Manifest.md
  - Steps:
      - 0. Configure Election: 0_Configure_Election.ipynb
      - 1. Key Ceremony: 1_Key_Ceremony.md
      - 2. Encrypt Ballots: 2_Encrypt_Ballots.md
      - 3. Cast and Spoil: 3_Cast_and_Spoil.md
      - 4. Decrypt Tally: 4_Decrypt_Tally.md
      - 5. Publish and Verify: 5_Publish_and_Verify.md
theme: readthedocs
plugins:
  - mkdocs-jupyter
markdown_extensions:
- admonition
- pymdownx.details
- pymdownx.superfences


================================================
FILE: pyproject.toml
================================================
[project]
name = "electionguard"
version = "1.4.0"
requires-python = ">=3.9.5,<4.0.0"
description = "ElectionGuard: Support for e2e verified elections."
license = "MIT"
authors = [{"name" = "Microsoft", "email" = "electionguard@microsoft.com"}]
maintainers = []
readme = "README.md"
keywords = []
classifiers = [
    "Development Status :: 5 - Production/Stable",
    "Intended Audience :: Developers",
    "Operating System :: Unix",
    "Operating System :: POSIX",
    "Operating System :: MacOS",
    "Operating System :: Microsoft :: Windows",
    "Programming Language :: Python",
    "Topic :: Utilities"
]
dependencies = [
  "gmpy2>=2.0.8,<3.0.0",
  "psutil>=5.7.2",
  "pydantic==2.13.0",
  "click>=8.1.0,<9.0.0",
  "dacite>=1.6.0,<2.0.0",
  "python-dateutil>=2.8.2,<3.0.0",
  "types-python-dateutil>=2.8.14,<3.0.0",
  "Eel[jinja2]>=0.14.0,<1.0.0",
  "pymongo>=4.1.1,<5.0.0",
  "dependency-injector>=4.39.1,<5.0.0",
  "pytest-mock>=3.8.2,<4.0.0",
]

[project.urls]
homepage = "https://microsoft.github.io/electionguard-python"
repository = "https://github.com/microsoft/electionguard-python"
documentation = "https://microsoft.github.io/electionguard-python"
"GitHub Pages" = "https://microsoft.github.io/electionguard-python"
"Read the Docs" = "https://electionguard-python.readthedocs.io"
"Releases" = "https://github.com/microsoft/electionguard-python/releases"
"Milestones" = "https://github.com/microsoft/electionguard-python/milestones"
"Issue Tracker" = "https://github.com/microsoft/electionguard-python/issues"

[tool.poetry]
packages = [
  { include = "electionguard", from = "src" },
  { include = "electionguard_tools", from = "src" },
  { include = "electionguard_cli", from = "src" },
  { include = "electionguard_gui", from = "src" },
]

[tool.poetry.group.dev.dependencies]
atomicwrites = "*"
black = "25.11.0"
coverage = "*"
docutils = "*"
hypothesis = ">=5.15.1"
ipython = "^7.31.1"
ipykernel = "^6.4.1"
jeepney = "*"
jupyter-black = "^0.3.1"
mkdocs = "^1.6.1"
mkdocs-jupyter = "^0.26.2"
mkinit = "^0.3.3"
mypy = "1.19.1"
pydeps = "*"
pylint = "*"
pytest = "*"
secretstorage = "*"
twine = "*"
typish = '*'

[project.scripts]
eg = 'electionguard_cli.start:cli'
egui = 'electionguard_gui.start:run'

[tool.black]
target-version = ['py39']

[tool.pylint.basic]
extension-pkg-whitelist = "pydantic"

[tool.pylint.format]
max-line-length = 120

# FIXME: Pylint should not require this many exceptions
[tool.pylint.messages_control]
disable = '''
  duplicate-code,
  fixme,
  invalid-name,
  missing-module-docstring,
  missing-function-docstring,
  no-value-for-parameter,
  redefined-builtin,
  broad-exception-raised,
  too-few-public-methods,
  too-many-arguments,
  too-many-branches,
  too-many-function-args,
  too-many-lines,
  too-many-locals,
  too-many-nested-blocks,
  too-many-positional-arguments,
  unnecessary-lambda,
  '''

[tool.coverage.run]
branch = true
source = ["src/electionguard"]

[tool.coverage.html]
directory = "coverage_html_report"

[build-system]
requires = ["poetry-core>=2.0.0"]
build-backend = "poetry.core.masonry.api"

[tool.mypy]
python_version = "3.9"
warn_return_any = true
warn_unused_configs = true
disallow_untyped_defs = true
ignore_missing_imports = true
show_column_numbers = true


================================================
FILE: src/electionguard/__init__.py
================================================
import importlib.metadata

# <AUTOGEN_INIT>
from electionguard import ballot
from electionguard import ballot_box
from electionguard import ballot_code
from electionguard import ballot_compact
from electionguard import ballot_validator
from electionguard import big_integer
from electionguard import byte_padding
from electionguard import chaum_pedersen
from electionguard import constants
from electionguard import data_store
from electionguard import decrypt_with_secrets
from electionguard import decrypt_with_shares
from electionguard import decryption
from electionguard import decryption_mediator
from electionguard import decryption_share
from electionguard import discrete_log
from electionguard import election
from electionguard import election_object_base
from electionguard import election_polynomial
from electionguard import elgamal
from electionguard import encrypt
from electionguard import group
from electionguard import guardian
from electionguard import hash
from electionguard import hmac
from electionguard import key_ceremony
from electionguard import key_ceremony_mediator
from electionguard import logs
from electionguard import manifest
from electionguard import nonces
from electionguard import proof
from electionguard import scheduler
from electionguard import schnorr
from electionguard import serialize
from electionguard import singleton
from electionguard import tally
from electionguard import type
from electionguard import utils

from electionguard.ballot import (
    BallotBoxState,
    CiphertextBallot,
    CiphertextBallotContest,
    CiphertextBallotSelection,
    CiphertextContest,
    CiphertextSelection,
    PlaintextBallot,
    PlaintextBallotContest,
    PlaintextBallotSelection,
    SubmittedBallot,
    create_ballot_hash,
    make_ciphertext_ballot,
    make_ciphertext_ballot_contest,
    make_ciphertext_ballot_selection,
    make_ciphertext_submitted_ballot,
)
from electionguard.ballot_box import (
    BallotBox,
    cast_ballot,
    get_ballots,
    spoil_ballot,
    submit_ballot,
    submit_ballot_to_box,
)
from electionguard.ballot_code import (
    get_ballot_code,
    get_hash_for_device,
)
from electionguard.ballot_compact import (
    CompactPlaintextBallot,
    CompactSubmittedBallot,
    NO_VOTE,
    YES_VOTE,
    compress_plaintext_ballot,
    compress_submitted_ballot,
    expand_compact_plaintext_ballot,
    expand_compact_submitted_ballot,
)
from electionguard.ballot_validator import (
    ballot_is_valid_for_election,
    ballot_is_valid_for_style,
    contest_is_valid_for_style,
    selection_is_valid_for_style,
)
from electionguard.big_integer import (
    BigInteger,
    bytes_to_hex,
)
from electionguard.byte_padding import (
    DataSize,
    TruncationError,
    add_padding,
    remove_padding,
    to_padded_bytes,
)
from electionguard.chaum_pedersen import (
    ChaumPedersenProof,
    ConstantChaumPedersenProof,
    DisjunctiveChaumPedersenProof,
    make_chaum_pedersen,
    make_constant_chaum_pedersen,
    make_disjunctive_chaum_pedersen,
    make_disjunctive_chaum_pedersen_one,
    make_disjunctive_chaum_pedersen_zero,
)
from electionguard.constants import (
    EXTRA_SMALL_TEST_CONSTANTS,
    ElectionConstants,
    LARGE_TEST_CONSTANTS,
    MEDIUM_TEST_CONSTANTS,
    PrimeOption,
    SMALL_TEST_CONSTANTS,
    STANDARD_CONSTANTS,
    create_constants,
    get_cofactor,
    get_constants,
    get_generator,
    get_large_prime,
    get_small_prime,
)
from electionguard.data_store import (
    DataStore,
    ReadOnlyDataStore,
)
from electionguard.decrypt_with_secrets import (
    decrypt_ballot_with_nonce,
    decrypt_ballot_with_secret,
    decrypt_contest_with_nonce,
    decrypt_contest_with_secret,
    decrypt_selection_with_nonce,
    decrypt_selection_with_secret,
)
from electionguard.decrypt_with_shares import (
    decrypt_ballot,
    decrypt_contest_with_decryption_shares,
    decrypt_selection_with_decryption_shares,
    decrypt_tally,
)
from electionguard.decryption import (
    RecoveryPublicKey,
    compute_compensated_decryption_share,
    compute_compensated_decryption_share_for_ballot,
    compute_compensated_decryption_share_for_contest,
    compute_compensated_decryption_share_for_selection,
    compute_decryption_share,
    compute_decryption_share_for_ballot,
    compute_decryption_share_for_contest,
    compute_decryption_share_for_selection,
    compute_lagrange_coefficients_for_guardian,
    compute_lagrange_coefficients_for_guardians,
    compute_recovery_public_key,
    decrypt_backup,
    decrypt_with_threshold,
    partially_decrypt,
    reconstruct_decryption_contest,
    reconstruct_decryption_share,
    reconstruct_decryption_share_for_ballot,
)
from electionguard.decryption_mediator import (
    DecryptionMediator,
)
from electionguard.decryption_share import (
    CiphertextCompensatedDecryptionContest,
    CiphertextCompensatedDecryptionSelection,
    CiphertextDecryptionContest,
    CiphertextDecryptionSelection,
    CompensatedDecryptionShare,
    DecryptionShare,
    ProofOrRecovery,
    create_ciphertext_decryption_selection,
    get_shares_for_selection,
)
from electionguard.discrete_log import (
    DiscreteLog,
    DiscreteLogCache,
    DiscreteLogExponentError,
    DiscreteLogNotFoundError,
    compute_discrete_log,
    compute_discrete_log_async,
    compute_discrete_log_cache,
    precompute_discrete_log_cache,
)
from electionguard.election import (
    CiphertextElectionContext,
    Configuration,
    make_ciphertext_election_context,
)
from electionguard.election_object_base import (
    ElectionObjectBase,
    OrderedObjectBase,
    list_eq,
    sequence_order_sort,
)
from electionguard.election_polynomial import (
    Coefficient,
    ElectionPolynomial,
    LagrangeCoefficientsRecord,
    PublicCommitment,
    SecretCoefficient,
    compute_lagrange_coefficient,
    compute_polynomial_coordinate,
    generate_polynomial,
    verify_polynomial_coordinate,
)
from electionguard.elgamal import (
    ElGamalCiphertext,
    ElGamalKeyPair,
    ElGamalPublicKey,
    ElGamalSecretKey,
    HashedElGamalCiphertext,
    elgamal_add,
    elgamal_combine_public_keys,
    elgamal_encrypt,
    elgamal_keypair_from_secret,
    elgamal_keypair_random,
    hashed_elgamal_encrypt,
)
from electionguard.encrypt import (
    ContestData,
    EncryptionDevice,
    EncryptionMediator,
    contest_from,
    encrypt_ballot,
    encrypt_ballot_contests,
    encrypt_contest,
    encrypt_selection,
    generate_device_uuid,
    selection_from,
)
from electionguard.group import (
    BaseElement,
    ElementModP,
    ElementModPOrQ,
    ElementModPOrQorInt,
    ElementModPorInt,
    ElementModQ,
    ElementModQorInt,
    a_minus_b_q,
    a_plus_bc_q,
    add_q,
    div_p,
    div_q,
    g_pow_p,
    hex_to_p,
    hex_to_q,
    int_to_p,
    int_to_q,
    mult_inv_p,
    mult_p,
    mult_q,
    negate_q,
    pow_p,
    pow_q,
    rand_q,
    rand_range_q,
)
from electionguard.guardian import (
    Guardian,
    GuardianRecord,
    PrivateGuardianRecord,
    get_valid_ballot_shares,
    publish_guardian_record,
)
from electionguard.hash import (
    CryptoHashCheckable,
    CryptoHashable,
    CryptoHashableAll,
    CryptoHashableT,
    hash_elems,
)
from electionguard.hmac import (
    get_hmac,
)
from electionguard.key_ceremony import (
    CeremonyDetails,
    CoordinateData,
    ElectionJointKey,
    ElectionKeyPair,
    ElectionPartialKeyBackup,
    ElectionPartialKeyChallenge,
    ElectionPartialKeyVerification,
    ElectionPublicKey,
    combine_election_public_keys,
    generate_election_key_pair,
    generate_election_partial_key_backup,
    generate_election_partial_key_challenge,
    get_backup_seed,
    verify_election_partial_key_backup,
    verify_election_partial_key_challenge,
)
from electionguard.key_ceremony_mediator import (
    BackupVerificationState,
    GuardianPair,
    KeyCeremonyMediator,
)
from electionguard.logs import (
    ElectionGuardLog,
    FORMAT,
    LOG,
    get_file_handler,
    get_stream_handler,
    log_add_handler,
    log_critical,
    log_debug,
    log_error,
    log_handlers,
    log_info,
    log_remove_handler,
    log_warning,
)
from electionguard.manifest import (
    AnnotatedString,
    BallotStyle,
    Candidate,
    CandidateContestDescription,
    ContactInformation,
    ContestDescription,
    ContestDescriptionWithPlaceholders,
    ElectionType,
    GeopoliticalUnit,
    InternalManifest,
    InternationalizedText,
    Language,
    Manifest,
    Party,
    ReferendumContestDescription,
    ReportingUnitType,
    SUPPORTED_VOTE_VARIATIONS,
    SelectionDescription,
    SpecVersion,
    VoteVariationType,
    contest_description_with_placeholders_from,
    generate_placeholder_selection_from,
    generate_placeholder_selections_from,
    get_i8n_value,
)
from electionguard.nonces import (
    Nonces,
)
from electionguard.proof import (
    Proof,
    ProofUsage,
)
from electionguard.scheduler import (
    Scheduler,
)
from electionguard.schnorr import (
    SchnorrProof,
    make_schnorr_proof,
)
from electionguard.serialize import (
    construct_path,
    from_file,
    from_file_wrapper,
    from_
Download .txt
gitextract_dl9na5eh/

├── .github/
│   ├── ISSUE_TEMPLATE/
│   │   ├── bug_report.yml
│   │   ├── config.yml
│   │   └── enhancement.yml
│   ├── pull_request_template.md
│   └── workflows/
│       ├── pull_request.yml
│       └── release.yml
├── .gitignore
├── .vscode/
│   └── extensions.json
├── CODE_OF_CONDUCT.md
├── CONTRIBUTING.md
├── LICENSE
├── Makefile
├── README.md
├── SECURITY.md
├── data/
│   ├── ballot_in_simple.json
│   ├── election_manifest_simple.json
│   ├── manifest-full.json
│   ├── manifest-hamilton-general.json
│   ├── manifest-minimal.json
│   ├── manifest-small.json
│   ├── plaintext_ballots_simple.json
│   ├── plaintext_two_ballots_minimal.json
│   └── plaintext_two_ballots_small.json
├── docs/
│   ├── 0_Configure_Election.ipynb
│   ├── 1_Key_Ceremony.md
│   ├── 2_Encrypt_Ballots.md
│   ├── 3_Cast_and_Spoil.md
│   ├── 4_Decrypt_Tally.md
│   ├── 5_Publish_and_Verify.md
│   ├── Build_and_Run.md
│   ├── Design_and_Architecture.md
│   ├── Election_Manifest.md
│   ├── Project_Workflow.md
│   ├── Tablet Setup.md
│   └── index.md
├── mkdocs.yml
├── pyproject.toml
├── src/
│   ├── electionguard/
│   │   ├── __init__.py
│   │   ├── ballot.py
│   │   ├── ballot_box.py
│   │   ├── ballot_code.py
│   │   ├── ballot_compact.py
│   │   ├── ballot_validator.py
│   │   ├── big_integer.py
│   │   ├── byte_padding.py
│   │   ├── chaum_pedersen.py
│   │   ├── constants.py
│   │   ├── data_store.py
│   │   ├── decrypt_with_secrets.py
│   │   ├── decrypt_with_shares.py
│   │   ├── decryption.py
│   │   ├── decryption_mediator.py
│   │   ├── decryption_share.py
│   │   ├── discrete_log.py
│   │   ├── election.py
│   │   ├── election_object_base.py
│   │   ├── election_polynomial.py
│   │   ├── elgamal.py
│   │   ├── encrypt.py
│   │   ├── group.py
│   │   ├── guardian.py
│   │   ├── hash.py
│   │   ├── hmac.py
│   │   ├── key_ceremony.py
│   │   ├── key_ceremony_mediator.py
│   │   ├── logs.py
│   │   ├── manifest.py
│   │   ├── nonces.py
│   │   ├── proof.py
│   │   ├── py.typed
│   │   ├── scheduler.py
│   │   ├── schnorr.py
│   │   ├── serialize.py
│   │   ├── singleton.py
│   │   ├── tally.py
│   │   ├── type.py
│   │   └── utils.py
│   ├── electionguard_cli/
│   │   ├── __init__.py
│   │   ├── cli_models/
│   │   │   ├── __init__.py
│   │   │   ├── cli_decrypt_results.py
│   │   │   ├── cli_election_inputs_base.py
│   │   │   ├── e2e_build_election_results.py
│   │   │   ├── encrypt_results.py
│   │   │   ├── mark_results.py
│   │   │   └── submit_results.py
│   │   ├── cli_steps/
│   │   │   ├── __init__.py
│   │   │   ├── cli_step_base.py
│   │   │   ├── decrypt_step.py
│   │   │   ├── election_builder_step.py
│   │   │   ├── encrypt_votes_step.py
│   │   │   ├── input_retrieval_step_base.py
│   │   │   ├── key_ceremony_step.py
│   │   │   ├── mark_ballots_step.py
│   │   │   ├── output_step_base.py
│   │   │   ├── print_results_step.py
│   │   │   ├── submit_ballots_step.py
│   │   │   └── tally_step.py
│   │   ├── e2e/
│   │   │   ├── __init__.py
│   │   │   ├── e2e_command.py
│   │   │   ├── e2e_election_builder_step.py
│   │   │   ├── e2e_input_retrieval_step.py
│   │   │   ├── e2e_inputs.py
│   │   │   ├── e2e_publish_step.py
│   │   │   └── submit_votes_step.py
│   │   ├── encrypt_ballots/
│   │   │   ├── __init__.py
│   │   │   ├── encrypt_ballot_inputs.py
│   │   │   ├── encrypt_ballots_election_builder_step.py
│   │   │   ├── encrypt_ballots_input_retrieval_step.py
│   │   │   ├── encrypt_ballots_publish_step.py
│   │   │   └── encrypt_command.py
│   │   ├── import_ballots/
│   │   │   ├── __init__.py
│   │   │   ├── import_ballot_inputs.py
│   │   │   ├── import_ballots_command.py
│   │   │   ├── import_ballots_election_builder_step.py
│   │   │   ├── import_ballots_input_retrieval_step.py
│   │   │   └── import_ballots_publish_step.py
│   │   ├── mark_ballots/
│   │   │   ├── __init__.py
│   │   │   ├── mark_ballot_inputs.py
│   │   │   ├── mark_ballots_election_builder_step.py
│   │   │   ├── mark_ballots_input_retrieval_step.py
│   │   │   ├── mark_ballots_publish_step.py
│   │   │   └── mark_command.py
│   │   ├── setup_election/
│   │   │   ├── __init__.py
│   │   │   ├── output_setup_files_step.py
│   │   │   ├── setup_election_builder_step.py
│   │   │   ├── setup_election_command.py
│   │   │   ├── setup_input_retrieval_step.py
│   │   │   └── setup_inputs.py
│   │   ├── start.py
│   │   └── submit_ballots/
│   │       ├── __init__.py
│   │       ├── submit_ballot_inputs.py
│   │       ├── submit_ballots_election_builder_step.py
│   │       ├── submit_ballots_input_retrieval_step.py
│   │       ├── submit_ballots_publish_step.py
│   │       └── submit_command.py
│   ├── electionguard_db/
│   │   ├── docker-compose.db.yml
│   │   └── mongo-init.js
│   ├── electionguard_gui/
│   │   ├── .dockerignore
│   │   ├── Dockerfile
│   │   ├── __init__.py
│   │   ├── components/
│   │   │   ├── __init__.py
│   │   │   ├── component_base.py
│   │   │   ├── create_decryption_component.py
│   │   │   ├── create_election_component.py
│   │   │   ├── create_key_ceremony_component.py
│   │   │   ├── election_list_component.py
│   │   │   ├── export_election_record_component.py
│   │   │   ├── export_encryption_package_component.py
│   │   │   ├── guardian_home_component.py
│   │   │   ├── key_ceremony_details_component.py
│   │   │   ├── upload_ballots_component.py
│   │   │   ├── view_decryption_component.py
│   │   │   ├── view_election_component.py
│   │   │   ├── view_spoiled_ballot_component.py
│   │   │   └── view_tally_component.py
│   │   ├── containers.py
│   │   ├── docker-compose.yml
│   │   ├── eel_utils.py
│   │   ├── main_app.py
│   │   ├── models/
│   │   │   ├── __init__.py
│   │   │   ├── decryption_dto.py
│   │   │   ├── election_dto.py
│   │   │   ├── key_ceremony_dto.py
│   │   │   └── key_ceremony_states.py
│   │   ├── services/
│   │   │   ├── __init__.py
│   │   │   ├── authorization_service.py
│   │   │   ├── ballot_upload_service.py
│   │   │   ├── configuration_service.py
│   │   │   ├── db_serialization_service.py
│   │   │   ├── db_service.py
│   │   │   ├── db_watcher_service.py
│   │   │   ├── decryption_service.py
│   │   │   ├── decryption_stages/
│   │   │   │   ├── __init__.py
│   │   │   │   ├── decryption_s1_join_service.py
│   │   │   │   ├── decryption_s2_announce_service.py
│   │   │   │   └── decryption_stage_base.py
│   │   │   ├── directory_service.py
│   │   │   ├── eel_log_service.py
│   │   │   ├── election_service.py
│   │   │   ├── export_service.py
│   │   │   ├── guardian_service.py
│   │   │   ├── gui_setup_input_retrieval_step.py
│   │   │   ├── key_ceremony_service.py
│   │   │   ├── key_ceremony_stages/
│   │   │   │   ├── __init__.py
│   │   │   │   ├── key_ceremony_s1_join_service.py
│   │   │   │   ├── key_ceremony_s2_announce_service.py
│   │   │   │   ├── key_ceremony_s3_make_backup_service.py
│   │   │   │   ├── key_ceremony_s4_share_backup_service.py
│   │   │   │   ├── key_ceremony_s5_verify_backup_service.py
│   │   │   │   ├── key_ceremony_s6_publish_key_service.py
│   │   │   │   └── key_ceremony_stage_base.py
│   │   │   ├── key_ceremony_state_service.py
│   │   │   ├── plaintext_ballot_service.py
│   │   │   ├── service_base.py
│   │   │   └── version_service.py
│   │   ├── start.py
│   │   └── web/
│   │       ├── components/
│   │       │   ├── admin/
│   │       │   │   ├── admin-home-component.js
│   │       │   │   ├── create-decryption-component.js
│   │       │   │   ├── create-election-component.js
│   │       │   │   ├── create-key-ceremony-component.js
│   │       │   │   ├── export-election-record-component.js
│   │       │   │   ├── export-encryption-package-component.js
│   │       │   │   ├── upload-ballots-component.js
│   │       │   │   ├── upload-ballots-legacy-component.js
│   │       │   │   ├── upload-ballots-success-component.js
│   │       │   │   ├── upload-ballots-wizard-component.js
│   │       │   │   ├── view-decryption-admin-component.js
│   │       │   │   ├── view-election-component.js
│   │       │   │   ├── view-key-ceremony-component.js
│   │       │   │   ├── view-spoiled-ballot-component.js
│   │       │   │   └── view-tally-component.js
│   │       │   ├── guardian/
│   │       │   │   ├── decryption-list-component.js
│   │       │   │   ├── guardian-home-component.js
│   │       │   │   ├── view-decryption-guardian-component.js
│   │       │   │   └── view-key-ceremony-component.js
│   │       │   └── shared/
│   │       │       ├── election-list-component.js
│   │       │       ├── footer-component.js
│   │       │       ├── home-component.js
│   │       │       ├── key-ceremony-details-component.js
│   │       │       ├── key-ceremony-list-component.js
│   │       │       ├── login-component.js
│   │       │       ├── navbar-component.js
│   │       │       ├── not-found-component.js
│   │       │       ├── spinner-component.js
│   │       │       └── view-plaintext-ballot-component.js
│   │       ├── css/
│   │       │   ├── bootstrap-icons.css
│   │       │   ├── bootstrap-overrides.css
│   │       │   ├── eg-styles.css
│   │       │   └── spinner.css
│   │       ├── index.html
│   │       ├── js/
│   │       │   └── vue.esm-browser.prod.js
│   │       ├── services/
│   │       │   ├── authorization-service.js
│   │       │   └── router-service.js
│   │       └── site.webmanifest
│   ├── electionguard_tools/
│   │   ├── __init__.py
│   │   ├── factories/
│   │   │   ├── __init__.py
│   │   │   ├── ballot_factory.py
│   │   │   └── election_factory.py
│   │   ├── helpers/
│   │   │   ├── __init__.py
│   │   │   ├── election_builder.py
│   │   │   ├── export.py
│   │   │   ├── key_ceremony_orchestrator.py
│   │   │   ├── tally_accumulate.py
│   │   │   └── tally_ceremony_orchestrator.py
│   │   ├── scripts/
│   │   │   ├── __init__.py
│   │   │   └── sample_generator.py
│   │   └── strategies/
│   │       ├── __init__.py
│   │       ├── election.py
│   │       ├── elgamal.py
│   │       └── group.py
│   └── electionguard_verify/
│       ├── __init__.py
│       └── verify.py
├── stubs/
│   └── gmpy2.pyi
└── tests/
    ├── __init__.py
    ├── base_test_case.py
    ├── bench/
    │   ├── __init__.py
    │   └── bench_chaum_pedersen.py
    ├── integration/
    │   ├── __init__.py
    │   ├── test_create_schema.py
    │   ├── test_end_to_end_election.py
    │   ├── test_functional_key_ceremony.py
    │   └── test_hamilton_county_election.py
    ├── property/
    │   ├── __init__.py
    │   ├── test_ballot.py
    │   ├── test_chaum_pedersen.py
    │   ├── test_decrypt_with_secrets.py
    │   ├── test_decryption_mediator.py
    │   ├── test_discrete_log.py
    │   ├── test_elgamal.py
    │   ├── test_encrypt.py
    │   ├── test_encrypt_hypotheses.py
    │   ├── test_group.py
    │   ├── test_hash.py
    │   ├── test_nonces.py
    │   ├── test_schnorr.py
    │   ├── test_tally.py
    │   └── test_verify.py
    └── unit/
        ├── __init__.py
        ├── electionguard/
        │   ├── __init__.py
        │   ├── test_ballot.py
        │   ├── test_ballot_box.py
        │   ├── test_ballot_code.py
        │   ├── test_ballot_compact.py
        │   ├── test_constants.py
        │   ├── test_decrypt_with_shares.py
        │   ├── test_decryption.py
        │   ├── test_election_polynomial.py
        │   ├── test_elgamal.py
        │   ├── test_encrypt.py
        │   ├── test_guardian.py
        │   ├── test_hmac.py
        │   ├── test_key_ceremony.py
        │   ├── test_key_ceremony_mediator.py
        │   ├── test_logs.py
        │   ├── test_manifest.py
        │   ├── test_scheduler.py
        │   ├── test_singleton.py
        │   └── test_utils.py
        └── electionguard_gui/
            ├── __init__.py
            ├── test_decryption_dto.py
            ├── test_eel_utils.py
            ├── test_election_dto.py
            └── test_plaintext_ballot_service.py
Download .txt
SYMBOL INDEX (1879 symbols across 217 files)

FILE: src/electionguard/ballot.py
  class PlaintextBallotSelection (line 51) | class PlaintextBallotSelection(ElectionObjectBase):
    method is_valid (line 76) | def is_valid(self, expected_object_id: str) -> bool:
    method __eq__ (line 95) | def __eq__(self, other: Any) -> bool:
    method __ne__ (line 104) | def __ne__(self, other: Any) -> bool:
  class CiphertextSelection (line 109) | class CiphertextSelection(Protocol):
  class CiphertextBallotSelection (line 127) | class CiphertextBallotSelection(
    method is_valid_encryption (line 172) | def is_valid_encryption(
    method crypto_hash_with (line 217) | def crypto_hash_with(self, encryption_seed: ElementModQ) -> ElementModQ:
  function _ciphertext_ballot_selection_crypto_hash_with (line 233) | def _ciphertext_ballot_selection_crypto_hash_with(
  function make_ciphertext_ballot_selection (line 239) | def make_ciphertext_ballot_selection(
  class PlaintextBallotContest (line 290) | class PlaintextBallotContest(ElectionObjectBase):
    method selected_ids (line 310) | def selected_ids(self) -> List[SelectionId]:
    method total_selected (line 318) | def total_selected(self) -> int:
    method total_votes (line 327) | def total_votes(self) -> int:
    method write_ins (line 332) | def write_ins(self) -> Optional[Dict[SelectionId, str]]:
    method valid (line 340) | def valid(self, description: ContestDescription) -> None:
    method is_valid (line 387) | def is_valid(
    method __eq__ (line 439) | def __eq__(self, other: Any) -> bool:
    method __ne__ (line 444) | def __ne__(self, other: Any) -> bool:
  class CiphertextContest (line 449) | class CiphertextContest(OrderedObjectBase):
  class CiphertextBallotContest (line 462) | class CiphertextBallotContest(OrderedObjectBase, CryptoHashCheckable):
    method __eq__ (line 502) | def __eq__(self, other: Any) -> bool:
    method __ne__ (line 513) | def __ne__(self, other: Any) -> bool:
    method aggregate_nonce (line 516) | def aggregate_nonce(self) -> Optional[ElementModQ]:
    method crypto_hash_with (line 524) | def crypto_hash_with(self, encryption_seed: ElementModQ) -> ElementModQ:
    method elgamal_accumulate (line 539) | def elgamal_accumulate(self) -> ElGamalCiphertext:
    method is_valid_encryption (line 546) | def is_valid_encryption(
  function _ciphertext_ballot_elgamal_accumulate (line 604) | def _ciphertext_ballot_elgamal_accumulate(
  function _ciphertext_ballot_context_crypto_hash (line 610) | def _ciphertext_ballot_context_crypto_hash(
  function _ciphertext_ballot_contest_aggregate_nonce (line 628) | def _ciphertext_ballot_contest_aggregate_nonce(
  function make_ciphertext_ballot_contest (line 643) | def make_ciphertext_ballot_contest(
  class PlaintextBallot (line 696) | class PlaintextBallot(ElectionObjectBase):
    method is_valid (line 708) | def is_valid(self, expected_ballot_style_id: str) -> bool:
    method __eq__ (line 725) | def __eq__(self, other: Any) -> bool:
    method __ne__ (line 732) | def __ne__(self, other: Any) -> bool:
  class CiphertextBallot (line 738) | class CiphertextBallot(ElectionObjectBase, CryptoHashCheckable):
    method __eq__ (line 774) | def __eq__(self, other: Any) -> bool:
    method __ne__ (line 788) | def __ne__(self, other: Any) -> bool:
    method nonce_seed (line 792) | def nonce_seed(
    method hashed_ballot_nonce (line 801) | def hashed_ballot_nonce(self) -> Optional[ElementModQ]:
    method crypto_hash_with (line 815) | def crypto_hash_with(self, encryption_seed: ElementModQ) -> ElementModQ:
    method is_valid_encryption (line 833) | def is_valid_encryption(
  class BallotBoxState (line 890) | class BallotBoxState(Enum):
  class SubmittedBallot (line 910) | class SubmittedBallot(CiphertextBallot):
    method __eq__ (line 924) | def __eq__(self, other: Any) -> bool:
    method __ne__ (line 931) | def __ne__(self, other: Any) -> bool:
  function make_ciphertext_ballot (line 935) | def make_ciphertext_ballot(
  function create_ballot_hash (line 982) | def create_ballot_hash(
  function make_ciphertext_submitted_ballot (line 993) | def make_ciphertext_submitted_ballot(

FILE: src/electionguard/ballot_box.py
  class BallotBox (line 19) | class BallotBox:
    method cast (line 26) | def cast(self, ballot: CiphertextBallot) -> Optional[SubmittedBallot]:
    method spoil (line 36) | def spoil(self, ballot: CiphertextBallot) -> Optional[SubmittedBallot]:
  function submit_ballot_to_box (line 47) | def submit_ballot_to_box(
  function get_ballots (line 80) | def get_ballots(
  function submit_ballot (line 91) | def submit_ballot(
  function cast_ballot (line 110) | def cast_ballot(ballot: CiphertextBallot) -> SubmittedBallot:
  function spoil_ballot (line 121) | def spoil_ballot(ballot: CiphertextBallot) -> SubmittedBallot:

FILE: src/electionguard/ballot_code.py
  function get_hash_for_device (line 5) | def get_hash_for_device(
  function get_ballot_code (line 20) | def get_ballot_code(

FILE: src/electionguard/ballot_compact.py
  class CompactPlaintextBallot (line 29) | class CompactPlaintextBallot:
  class CompactSubmittedBallot (line 39) | class CompactSubmittedBallot:
  function compress_plaintext_ballot (line 50) | def compress_plaintext_ballot(ballot: PlaintextBallot) -> CompactPlainte...
  function compress_submitted_ballot (line 60) | def compress_submitted_ballot(
  function expand_compact_submitted_ballot (line 76) | def expand_compact_submitted_ballot(
  function expand_compact_plaintext_ballot (line 112) | def expand_compact_plaintext_ballot(
  function _get_compact_selections (line 123) | def _get_compact_selections(ballot: PlaintextBallot) -> List[bool]:
  function _get_compact_write_ins (line 131) | def _get_compact_write_ins(ballot: PlaintextBallot) -> Dict[int, str]:
  function _get_plaintext_contests (line 142) | def _get_plaintext_contests(
  function _get_ballot_style_contests (line 174) | def _get_ballot_style_contests(

FILE: src/electionguard/ballot_validator.py
  function ballot_is_valid_for_election (line 11) | def ballot_is_valid_for_election(
  function selection_is_valid_for_style (line 38) | def selection_is_valid_for_style(
  function contest_is_valid_for_style (line 59) | def contest_is_valid_for_style(
  function ballot_is_valid_for_style (line 90) | def ballot_is_valid_for_style(

FILE: src/electionguard/big_integer.py
  function _hex_to_int (line 10) | def _hex_to_int(input: str) -> int:
  function _int_to_hex (line 17) | def _int_to_hex(input: int) -> str:
  function bytes_to_hex (line 28) | def bytes_to_hex(input: bytes) -> str:
  function _convert_to_element (line 35) | def _convert_to_element(data: Union[int, str]) -> Tuple[str, int]:
  class BigInteger (line 46) | class BigInteger(str):
    method __new__ (line 51) | def __new__(cls, data: Union[int, str]):  # type: ignore
    method value (line 58) | def value(self) -> mpz:
    method __int__ (line 62) | def __int__(self) -> int:
    method __eq__ (line 66) | def __eq__(self, other: Any) -> bool:
    method __ne__ (line 72) | def __ne__(self, other: Any) -> bool:
    method __lt__ (line 76) | def __lt__(self, other: Any) -> bool:
    method __le__ (line 82) | def __le__(self, other: Any) -> bool:
    method __gt__ (line 86) | def __gt__(self, other: Any) -> bool:
    method __ge__ (line 92) | def __ge__(self, other: Any) -> bool:
    method __hash__ (line 96) | def __hash__(self) -> int:
    method to_hex (line 100) | def to_hex(self) -> str:
    method to_hex_bytes (line 106) | def to_hex_bytes(self) -> bytes:

FILE: src/electionguard/byte_padding.py
  class DataSize (line 10) | class DataSize(IntEnum):
  class TruncationError (line 16) | class TruncationError(ValueError):
  function to_padded_bytes (line 20) | def to_padded_bytes(data: str, size: DataSize = DataSize.Bytes_512) -> b...
  function add_padding (line 30) | def add_padding(
  function remove_padding (line 50) | def remove_padding(padded: bytes, size: DataSize = DataSize.Bytes_512) -...

FILE: src/electionguard/chaum_pedersen.py
  class DisjunctiveChaumPedersenProof (line 25) | class DisjunctiveChaumPedersenProof(Proof):
    method __post_init__ (line 51) | def __post_init__(self) -> None:
    method is_valid (line 54) | def is_valid(
  class ChaumPedersenProof (line 142) | class ChaumPedersenProof(Proof):
    method __post_init__ (line 158) | def __post_init__(self) -> None:
    method is_valid (line 161) | def is_valid(
  class ConstantChaumPedersenProof (line 259) | class ConstantChaumPedersenProof(Proof):
    method __post_init__ (line 277) | def __post_init__(self) -> None:
    method is_valid (line 280) | def is_valid(
  function make_disjunctive_chaum_pedersen (line 370) | def make_disjunctive_chaum_pedersen(
  function make_disjunctive_chaum_pedersen_zero (line 400) | def make_disjunctive_chaum_pedersen_zero(
  function make_disjunctive_chaum_pedersen_one (line 436) | def make_disjunctive_chaum_pedersen_one(
  function make_chaum_pedersen (line 473) | def make_chaum_pedersen(
  function make_constant_chaum_pedersen (line 504) | def make_constant_chaum_pedersen(

FILE: src/electionguard/constants.py
  class ElectionConstants (line 12) | class ElectionConstants:
  function create_constants (line 28) | def create_constants(
  class PrimeOption (line 60) | class PrimeOption(Enum):
  function get_constants (line 67) | def get_constants() -> ElectionConstants:
  function get_large_prime (line 81) | def get_large_prime() -> int:
  function get_small_prime (line 85) | def get_small_prime() -> int:
  function get_cofactor (line 89) | def get_cofactor() -> int:
  function get_generator (line 93) | def get_generator() -> int:

FILE: src/electionguard/data_store.py
  class DataStore (line 19) | class DataStore(Generic[_T, _U]):
    method __init__ (line 28) | def __init__(self) -> None:
    method __iter__ (line 31) | def __iter__(self) -> Iterator:
    method all (line 34) | def all(self) -> List[_U]:
    method clear (line 40) | def clear(self) -> None:
    method get (line 46) | def get(self, key: _T) -> Optional[_U]:
    method items (line 54) | def items(self) -> Iterable[Tuple[_T, _U]]:
    method keys (line 61) | def keys(self) -> Iterable[_T]:
    method __len__ (line 68) | def __len__(self) -> int:
    method pop (line 75) | def pop(self, key: _T) -> Optional[_U]:
    method set (line 84) | def set(self, key: _T, value: _U) -> None:
    method values (line 92) | def values(self) -> Iterable[_U]:
  class ReadOnlyDataStore (line 100) | class ReadOnlyDataStore(Generic[_T, _U], Mapping):
    method __init__ (line 105) | def __init__(self, data: DataStore[_T, _U]):
    method __getitem__ (line 108) | def __getitem__(self, key: _T) -> Optional[_U]:
    method __len__ (line 111) | def __len__(self) -> int:
    method __iter__ (line 114) | def __iter__(self) -> Iterator:
    method __eq__ (line 117) | def __eq__(self, other: object) -> bool:

FILE: src/electionguard/decrypt_with_secrets.py
  function decrypt_selection_with_secret (line 26) | def decrypt_selection_with_secret(
  function decrypt_selection_with_nonce (line 62) | def decrypt_selection_with_nonce(
  function decrypt_contest_with_secret (line 117) | def decrypt_contest_with_secret(
  function decrypt_contest_with_nonce (line 170) | def decrypt_contest_with_nonce(
  function decrypt_ballot_with_secret (line 241) | def decrypt_ballot_with_secret(
  function decrypt_ballot_with_nonce (line 291) | def decrypt_ballot_with_nonce(

FILE: src/electionguard/decrypt_with_shares.py
  function decrypt_tally (line 29) | def decrypt_tally(
  function decrypt_ballot (line 73) | def decrypt_ballot(
  function decrypt_contest_with_decryption_shares (line 117) | def decrypt_contest_with_decryption_shares(
  function decrypt_selection_with_decryption_shares (line 158) | def decrypt_selection_with_decryption_shares(

FILE: src/electionguard/decryption.py
  function compute_decryption_share (line 48) | def compute_decryption_share(
  function compute_compensated_decryption_share (line 90) | def compute_compensated_decryption_share(
  function compute_decryption_share_for_ballot (line 140) | def compute_decryption_share_for_ballot(
  function compute_compensated_decryption_share_for_ballot (line 181) | def compute_compensated_decryption_share_for_ballot(
  function compute_decryption_share_for_contest (line 230) | def compute_decryption_share_for_contest(
  function compute_compensated_decryption_share_for_contest (line 269) | def compute_compensated_decryption_share_for_contest(
  function compute_decryption_share_for_selection (line 323) | def compute_decryption_share_for_selection(
  function compute_compensated_decryption_share_for_selection (line 360) | def compute_compensated_decryption_share_for_selection(
  function partially_decrypt (line 424) | def partially_decrypt(
  function decrypt_backup (line 460) | def decrypt_backup(
  function decrypt_with_threshold (line 487) | def decrypt_with_threshold(
  function compute_recovery_public_key (line 524) | def compute_recovery_public_key(
  function reconstruct_decryption_share (line 541) | def reconstruct_decryption_share(
  function reconstruct_decryption_share_for_ballot (line 580) | def reconstruct_decryption_share_for_ballot(
  function reconstruct_decryption_contest (line 620) | def reconstruct_decryption_contest(
  function compute_lagrange_coefficients_for_guardians (line 674) | def compute_lagrange_coefficients_for_guardians(
  function compute_lagrange_coefficients_for_guardian (line 689) | def compute_lagrange_coefficients_for_guardian(

FILE: src/electionguard/decryption_mediator.py
  class DecryptionMediator (line 25) | class DecryptionMediator:
    method __init__ (line 49) | def __init__(self, id: MediatorId, context: CiphertextElectionContext):
    method announce (line 63) | def announce(
    method announce_missing (line 92) | def announce_missing(self, missing_guardian_key: ElectionPublicKey) ->...
    method validate_missing_guardians (line 107) | def validate_missing_guardians(
    method announcement_complete (line 138) | def announcement_complete(self) -> bool:
    method get_available_guardians (line 159) | def get_available_guardians(self) -> List[ElectionPublicKey]:
    method get_missing_guardians (line 166) | def get_missing_guardians(self) -> List[ElectionPublicKey]:
    method receive_tally_compensation_share (line 173) | def receive_tally_compensation_share(
    method receive_ballot_compensation_shares (line 183) | def receive_ballot_compensation_shares(
    method get_lagrange_coefficients (line 195) | def get_lagrange_coefficients(self) -> Dict[GuardianId, ElementModQ]:
    method reconstruct_shares_for_tally (line 200) | def reconstruct_shares_for_tally(self, ciphertext_tally: CiphertextTal...
    method reconstruct_shares_for_ballots (line 224) | def reconstruct_shares_for_ballots(
    method get_plaintext_tally (line 258) | def get_plaintext_tally(
    method get_plaintext_ballots (line 280) | def get_plaintext_ballots(
    method _save_tally_share (line 313) | def _save_tally_share(
    method _save_ballot_shares (line 319) | def _save_ballot_shares(
    method _mark_available (line 333) | def _mark_available(self, guardian_key: ElectionPublicKey) -> None:
    method _mark_missing (line 342) | def _mark_missing(self, guardian_key: ElectionPublicKey) -> None:
    method _ready_to_decrypt (line 346) | def _ready_to_decrypt(self, shares: Dict[GuardianId, DecryptionShare])...
  function _filter_by_missing_guardian (line 353) | def _filter_by_missing_guardian(

FILE: src/electionguard/decryption_share.py
  class CiphertextCompensatedDecryptionSelection (line 16) | class CiphertextCompensatedDecryptionSelection(ElectionObjectBase):
  class CiphertextDecryptionSelection (line 53) | class CiphertextDecryptionSelection(ElectionObjectBase):
    method is_valid (line 90) | def is_valid(
  function create_ciphertext_decryption_selection (line 160) | def create_ciphertext_decryption_selection(
  class CiphertextDecryptionContest (line 195) | class CiphertextDecryptionContest(ElectionObjectBase):
  class CiphertextCompensatedDecryptionContest (line 217) | class CiphertextCompensatedDecryptionContest(ElectionObjectBase):
  class DecryptionShare (line 244) | class DecryptionShare(ElectionObjectBase):
  class CompensatedDecryptionShare (line 266) | class CompensatedDecryptionShare(ElectionObjectBase):
  function get_shares_for_selection (line 293) | def get_shares_for_selection(

FILE: src/electionguard/discrete_log.py
  class DiscreteLogExponentError (line 19) | class DiscreteLogExponentError(ValueError):
    method __init__ (line 22) | def __init__(self, exponent: int, max_exponent: int = _DLOG_MAX_EXPONE...
  class DiscreteLogNotFoundError (line 28) | class DiscreteLogNotFoundError(ValueError):
    method __init__ (line 31) | def __init__(self, element: BaseElement) -> None:
  function compute_discrete_log (line 35) | def compute_discrete_log(
  function compute_discrete_log_async (line 62) | async def compute_discrete_log_async(
  function precompute_discrete_log_cache (line 93) | def precompute_discrete_log_cache(
  function compute_discrete_log_cache (line 121) | def compute_discrete_log_cache(
  class DiscreteLog (line 152) | class DiscreteLog(Singleton):
    method get_cache (line 162) | def get_cache(self) -> DiscreteLogCache:
    method set_max_exponent (line 165) | def set_max_exponent(self, max_exponent: int) -> None:
    method set_lazy_evaluation (line 168) | def set_lazy_evaluation(self, lazy_evaluation: bool) -> None:
    method precompute_cache (line 171) | def precompute_cache(self, exponent: int) -> None:
    method precompute_cache_async (line 176) | async def precompute_cache_async(self, exponent: int) -> None:
    method discrete_log (line 182) | def discrete_log(self, element: ElementModP) -> int:
    method discrete_log_async (line 188) | async def discrete_log_async(self, element: ElementModP) -> int:

FILE: src/electionguard/election.py
  class Configuration (line 16) | class Configuration:
  class CiphertextElectionContext (line 33) | class CiphertextElectionContext:
    method get_extended_data_field (line 79) | def get_extended_data_field(self, field_name: str) -> Optional[str]:
  function make_ciphertext_election_context (line 87) | def make_ciphertext_election_context(

FILE: src/electionguard/election_object_base.py
  class ElectionObjectBase (line 8) | class ElectionObjectBase:
  class OrderedObjectBase (line 15) | class OrderedObjectBase(ElectionObjectBase):
  function sequence_order_sort (line 30) | def sequence_order_sort(unsorted: List[_Orderable_T]) -> List[_Orderable...
  function list_eq (line 35) | def list_eq(

FILE: src/electionguard/election_polynomial.py
  class Coefficient (line 27) | class Coefficient:
  class ElectionPolynomial (line 43) | class ElectionPolynomial:
    method get_commitments (line 54) | def get_commitments(self) -> List[PublicCommitment]:
    method get_proofs (line 58) | def get_proofs(self) -> List[SchnorrProof]:
  function generate_polynomial (line 63) | def generate_polynomial(
  function compute_polynomial_coordinate (line 88) | def compute_polynomial_coordinate(
  class LagrangeCoefficientsRecord (line 110) | class LagrangeCoefficientsRecord:
  function compute_lagrange_coefficient (line 120) | def compute_lagrange_coefficient(coordinate: int, *degrees: int) -> Elem...
  function verify_polynomial_coordinate (line 134) | def verify_polynomial_coordinate(

FILE: src/electionguard/elgamal.py
  class ElGamalKeyPair (line 31) | class ElGamalKeyPair:
  class ElGamalCiphertext (line 39) | class ElGamalCiphertext:
    method __eq__ (line 52) | def __eq__(self, other: Any) -> bool:
    method decrypt_known_product (line 57) | def decrypt_known_product(self, product: ElementModP) -> int:
    method decrypt (line 66) | def decrypt(self, secret_key: ElGamalSecretKey) -> int:
    method decrypt_known_nonce (line 75) | def decrypt_known_nonce(
    method partial_decrypt (line 87) | def partial_decrypt(self, secret_key: ElGamalSecretKey) -> ElementModP:
    method crypto_hash (line 98) | def crypto_hash(self) -> ElementModQ:
  class HashedElGamalCiphertext (line 106) | class HashedElGamalCiphertext:
    method decrypt (line 122) | def decrypt(
  function elgamal_keypair_from_secret (line 161) | def elgamal_keypair_from_secret(a: ElementModQ) -> Optional[ElGamalKeyPa...
  function elgamal_keypair_random (line 174) | def elgamal_keypair_random() -> ElGamalKeyPair:
  function elgamal_combine_public_keys (line 183) | def elgamal_combine_public_keys(keys: Iterable[ElGamalPublicKey]) -> ElG...
  function elgamal_encrypt (line 193) | def elgamal_encrypt(
  function hashed_elgamal_encrypt (line 220) | def hashed_elgamal_encrypt(
  function _get_chunks (line 266) | def _get_chunks(message: bytes) -> tuple[list[bytes], int]:
  function elgamal_add (line 280) | def elgamal_add(*ciphertexts: ElGamalCiphertext) -> ElGamalCiphertext:

FILE: src/electionguard/encrypt.py
  class ContestData (line 47) | class ContestData:
    method from_bytes (line 55) | def from_bytes(cls: Type[_T], data: bytes) -> _T:
    method to_bytes (line 58) | def to_bytes(self) -> bytes:
  class EncryptionDevice (line 63) | class EncryptionDevice:
    method get_hash (line 80) | def get_hash(self) -> ElementModQ:
    method get_timestamp (line 89) | def get_timestamp(self) -> int:
  class EncryptionMediator (line 96) | class EncryptionMediator:
    method __init__ (line 107) | def __init__(
    method encrypt (line 117) | def encrypt(self, ballot: PlaintextBallot) -> Optional[CiphertextBallot]:
  function generate_device_uuid (line 131) | def generate_device_uuid() -> int:
  function selection_from (line 139) | def selection_from(
  function contest_from (line 162) | def contest_from(description: ContestDescription) -> PlaintextBallotCont...
  function encrypt_selection (line 179) | def encrypt_selection(
  function encrypt_contest (line 261) | def encrypt_contest(
  function encrypt_ballot (line 430) | def encrypt_ballot(
  function encrypt_ballot_contests (line 515) | def encrypt_ballot_contests(

FILE: src/electionguard/group.py
  class BaseElement (line 20) | class BaseElement(BigInteger, ABC):
    method __new__ (line 23) | def __new__(cls, data: Union[int, str], check_within_bounds: bool = Tr...
    method get_upper_bound (line 32) | def get_upper_bound(cls) -> int:
    method is_in_bounds (line 36) | def is_in_bounds(self) -> bool:
    method is_in_bounds_no_zero (line 44) | def is_in_bounds_no_zero(self) -> bool:
  class ElementModQ (line 53) | class ElementModQ(BaseElement):
    method get_upper_bound (line 57) | def get_upper_bound(cls) -> int:
  class ElementModP (line 62) | class ElementModP(BaseElement):
    method get_upper_bound (line 66) | def get_upper_bound(cls) -> int:
    method is_valid_residue (line 70) | def is_valid_residue(self) -> bool:
  function _get_mpz (line 91) | def _get_mpz(input: Union[BaseElement, int]) -> mpz:
  function hex_to_q (line 98) | def hex_to_q(input: str) -> Optional[ElementModQ]:
  function int_to_q (line 110) | def int_to_q(input: int) -> Optional[ElementModQ]:
  function hex_to_p (line 122) | def hex_to_p(input: str) -> Optional[ElementModP]:
  function int_to_p (line 134) | def int_to_p(input: int) -> Optional[ElementModP]:
  function add_q (line 146) | def add_q(*elems: ElementModQorInt) -> ElementModQ:
  function a_minus_b_q (line 155) | def a_minus_b_q(a: ElementModQorInt, b: ElementModQorInt) -> ElementModQ:
  function div_p (line 162) | def div_p(a: ElementModPOrQorInt, b: ElementModPOrQorInt) -> ElementModP:
  function div_q (line 169) | def div_q(a: ElementModPOrQorInt, b: ElementModPOrQorInt) -> ElementModQ:
  function negate_q (line 176) | def negate_q(a: ElementModQorInt) -> ElementModQ:
  function a_plus_bc_q (line 182) | def a_plus_bc_q(
  function mult_inv_p (line 192) | def mult_inv_p(e: ElementModPOrQorInt) -> ElementModP:
  function pow_p (line 203) | def pow_p(b: ElementModPOrQorInt, e: ElementModPOrQorInt) -> ElementModP:
  function pow_q (line 215) | def pow_q(b: ElementModQorInt, e: ElementModQorInt) -> ElementModQ:
  function mult_p (line 227) | def mult_p(*elems: ElementModPOrQorInt) -> ElementModP:
  function mult_q (line 240) | def mult_q(*elems: ElementModPOrQorInt) -> ElementModQ:
  function g_pow_p (line 253) | def g_pow_p(e: ElementModPOrQorInt) -> ElementModP:
  function rand_q (line 262) | def rand_q() -> ElementModQ:
  function rand_range_q (line 271) | def rand_range_q(start: ElementModQorInt) -> ElementModQ:

FILE: src/electionguard/guardian.py
  class GuardianRecord (line 41) | class GuardianRecord:
  function publish_guardian_record (line 74) | def publish_guardian_record(election_public_key: ElectionPublicKey) -> G...
  class PrivateGuardianRecord (line 92) | class PrivateGuardianRecord:
  class Guardian (line 116) | class Guardian:
    method __init__ (line 150) | def __init__(
    method id (line 192) | def id(self) -> GuardianId:
    method sequence_order (line 196) | def sequence_order(self) -> int:
    method from_public_key (line 200) | def from_public_key(
    method from_nonce (line 217) | def from_nonce(
    method from_private_record (line 233) | def from_private_record(
    method publish (line 250) | def publish(self) -> GuardianRecord:
    method export_private_data (line 254) | def export_private_data(self) -> PrivateGuardianRecord:
    method set_ceremony_details (line 265) | def set_ceremony_details(self, number_of_guardians: int, quorum: int) ...
    method decrypt_backup (line 274) | def decrypt_backup(self, backup: ElectionPartialKeyBackup) -> Optional...
    method share_key (line 286) | def share_key(self) -> ElectionPublicKey:
    method save_guardian_key (line 294) | def save_guardian_key(self, key: ElectionPublicKey) -> None:
    method all_guardian_keys_received (line 302) | def all_guardian_keys_received(self) -> bool:
    method generate_election_partial_key_backups (line 313) | def generate_election_partial_key_backups(self) -> bool:
    method share_election_partial_key_backup (line 331) | def share_election_partial_key_backup(
    method share_election_partial_key_backups (line 342) | def share_election_partial_key_backups(self) -> List[ElectionPartialKe...
    method save_election_partial_key_backup (line 350) | def save_election_partial_key_backup(
    method all_election_partial_key_backups_received (line 360) | def all_election_partial_key_backups_received(self) -> bool:
    method verify_election_partial_key_backup (line 372) | def verify_election_partial_key_backup(
    method publish_election_backup_challenge (line 393) | def publish_election_backup_challenge(
    method verify_election_partial_key_challenge (line 409) | def verify_election_partial_key_challenge(
    method save_election_partial_key_verification (line 420) | def save_election_partial_key_verification(
    method all_election_partial_key_backups_verified (line 432) | def all_election_partial_key_backups_verified(self) -> bool:
    method publish_joint_key (line 447) | def publish_joint_key(self) -> Optional[ElementModP]:
    method share_other_guardian_key (line 464) | def share_other_guardian_key(
    method compute_tally_share (line 470) | def compute_tally_share(
    method compute_ballot_shares (line 486) | def compute_ballot_shares(
    method compute_compensated_tally_share (line 506) | def compute_compensated_tally_share(
    method compute_compensated_ballot_shares (line 538) | def compute_compensated_ballot_shares(
  function get_valid_ballot_shares (line 581) | def get_valid_ballot_shares(

FILE: src/electionguard/hash.py
  class CryptoHashable (line 24) | class CryptoHashable(Protocol):
    method crypto_hash (line 30) | def crypto_hash(self) -> ElementModQ:
  class CryptoHashCheckable (line 37) | class CryptoHashCheckable(Protocol):
    method crypto_hash_with (line 43) | def crypto_hash_with(self, encryption_seed: ElementModQ) -> ElementModQ:
  function hash_elems (line 61) | def hash_elems(*a: CryptoHashableAll) -> ElementModQ:

FILE: src/electionguard/hmac.py
  function get_hmac (line 10) | def get_hmac(
  function _fix_message_length (line 30) | def _fix_message_length(msg: bytes, length: int, start: int = 0) -> bytes:

FILE: src/electionguard/key_ceremony.py
  class ElectionPublicKey (line 30) | class ElectionPublicKey:
  class ElectionKeyPair (line 61) | class ElectionKeyPair:
    method share (line 84) | def share(self) -> ElectionPublicKey:
  class ElectionJointKey (line 96) | class ElectionJointKey:
  class ElectionPartialKeyBackup (line 114) | class ElectionPartialKeyBackup:
  class CeremonyDetails (line 139) | class CeremonyDetails:
  class ElectionPartialKeyVerification (line 147) | class ElectionPartialKeyVerification:
  class ElectionPartialKeyChallenge (line 157) | class ElectionPartialKeyChallenge:
  class CoordinateData (line 173) | class CoordinateData:
    method from_bytes (line 179) | def from_bytes(cls: Type[_T], data: bytes) -> _T:
    method to_bytes (line 182) | def to_bytes(self) -> bytes:
  function generate_election_key_pair (line 186) | def generate_election_key_pair(
  function generate_election_partial_key_backup (line 204) | def generate_election_partial_key_backup(
  function get_backup_seed (line 239) | def get_backup_seed(receiver_guardian_id: str, sequence_order: int) -> E...
  function verify_election_partial_key_backup (line 243) | def verify_election_partial_key_backup(
  function generate_election_partial_key_challenge (line 282) | def generate_election_partial_key_challenge(
  function verify_election_partial_key_challenge (line 302) | def verify_election_partial_key_challenge(
  function combine_election_public_keys (line 323) | def combine_election_public_keys(

FILE: src/electionguard/key_ceremony_mediator.py
  class GuardianPair (line 17) | class GuardianPair:
  class BackupVerificationState (line 25) | class BackupVerificationState:
  class KeyCeremonyMediator (line 33) | class KeyCeremonyMediator:
    method __init__ (line 53) | def __init__(self, id: MediatorId, ceremony_details: CeremonyDetails):
    method announce (line 68) | def announce(self, key: ElectionPublicKey) -> None:
    method all_guardians_announced (line 75) | def all_guardians_announced(self) -> bool:
    method share_announced (line 84) | def share_announced(
    method receive_backups (line 100) | def receive_backups(self, backups: List[ElectionPartialKeyBackup]) -> ...
    method all_backups_available (line 109) | def all_backups_available(self) -> bool:
    method share_backups (line 119) | def share_backups(
    method receive_backup_verifications (line 134) | def receive_backup_verifications(
    method get_verification_state (line 145) | def get_verification_state(self) -> BackupVerificationState:
    method all_backups_verified (line 153) | def all_backups_verified(self) -> bool:
    method verify_challenge (line 157) | def verify_challenge(
    method publish_joint_key (line 169) | def publish_joint_key(self) -> Optional[ElectionJointKey]:
    method reset (line 179) | def reset(self, ceremony_details: CeremonyDetails) -> None:
    method _receive_election_public_key (line 191) | def _receive_election_public_key(self, public_key: ElectionPublicKey) ...
    method _get_announced_guardians (line 198) | def _get_announced_guardians(self) -> Iterable[GuardianId]:
    method _receive_election_partial_key_backup (line 202) | def _receive_election_partial_key_backup(
    method _all_election_partial_key_backups_available (line 216) | def _all_election_partial_key_backups_available(self) -> bool:
    method _share_election_partial_key_backups_to_guardian (line 227) | def _share_election_partial_key_backups_to_guardian(
    method _receive_election_partial_key_verification (line 246) | def _receive_election_partial_key_verification(
    method _all_election_partial_key_verifications_received (line 259) | def _all_election_partial_key_verifications_received(self) -> bool:
    method _check_verification_of_election_partial_key_backups (line 273) | def _check_verification_of_election_partial_key_backups(

FILE: src/electionguard/logs.py
  class ElectionGuardLog (line 13) | class ElectionGuardLog(Singleton):
    method __init__ (line 21) | def __init__(self) -> None:
    method __get_call_info (line 32) | def __get_call_info() -> Tuple[str, str, int]:
    method __formatted_message (line 47) | def __formatted_message(self, message: str) -> str:
    method set_stream_log_level (line 52) | def set_stream_log_level(self, Level: int) -> None:
    method add_handler (line 59) | def add_handler(self, handler: logging.Handler) -> None:
    method remove_handler (line 65) | def remove_handler(self, handler: logging.Handler) -> None:
    method handlers (line 71) | def handlers(self) -> List[logging.Handler]:
    method debug (line 77) | def debug(self, message: str, *args: Any, **kwargs: Any) -> None:
    method info (line 83) | def info(self, message: str, *args: Any, **kwargs: Any) -> None:
    method warn (line 89) | def warn(self, message: str, *args: Any, **kwargs: Any) -> None:
    method error (line 95) | def error(self, message: str, *args: Any, **kwargs: Any) -> None:
    method critical (line 101) | def critical(self, message: str, *args: Any, **kwargs: Any) -> None:
  function get_stream_handler (line 108) | def get_stream_handler(log_level: int) -> logging.StreamHandler:
  function get_file_handler (line 118) | def get_file_handler(log_level: int, filename: str) -> logging.FileHandler:
  function log_add_handler (line 138) | def log_add_handler(handler: logging.Handler) -> None:
  function log_remove_handler (line 145) | def log_remove_handler(handler: logging.Handler) -> None:
  function log_handlers (line 152) | def log_handlers() -> List[logging.Handler]:
  function log_debug (line 159) | def log_debug(msg: str, *args: Any, **kwargs: Any) -> None:
  function log_info (line 166) | def log_info(msg: str, *args: Any, **kwargs: Any) -> None:
  function log_warning (line 173) | def log_warning(msg: str, *args: Any, **kwargs: Any) -> None:
  function log_error (line 180) | def log_error(msg: str, *args: Any, **kwargs: Any) -> None:
  function log_critical (line 187) | def log_critical(msg: str, *args: Any, **kwargs: Any) -> None:

FILE: src/electionguard/manifest.py
  class ElectionType (line 14) | class ElectionType(Enum):
  class ReportingUnitType (line 31) | class ReportingUnitType(Enum):
  class VoteVariationType (line 69) | class VoteVariationType(Enum):
  class AnnotatedString (line 101) | class AnnotatedString(CryptoHashable):
    method __init__ (line 112) | def __init__(
    method crypto_hash (line 120) | def crypto_hash(self) -> ElementModQ:
  class Language (line 130) | class Language(CryptoHashable):
    method __init__ (line 141) | def __init__(
    method crypto_hash (line 149) | def crypto_hash(self) -> ElementModQ:
  class InternationalizedText (line 159) | class InternationalizedText(CryptoHashable):
    method __init__ (line 169) | def __init__(
    method crypto_hash (line 175) | def crypto_hash(self) -> ElementModQ:
  class ContactInformation (line 185) | class ContactInformation(CryptoHashable):
    method __init__ (line 198) | def __init__(
    method crypto_hash (line 210) | def crypto_hash(self) -> ElementModQ:
  class GeopoliticalUnit (line 219) | class GeopoliticalUnit(ElectionObjectBase, CryptoHashable):
    method crypto_hash (line 230) | def crypto_hash(self) -> ElementModQ:
  class BallotStyle (line 241) | class BallotStyle(ElectionObjectBase, CryptoHashable):
    method crypto_hash (line 250) | def crypto_hash(self) -> ElementModQ:
  class Party (line 261) | class Party(ElectionObjectBase, CryptoHashable):
    method get_party_id (line 272) | def get_party_id(self) -> str:
    method crypto_hash (line 278) | def crypto_hash(self) -> ElementModQ:
  class Candidate (line 293) | class Candidate(ElectionObjectBase, CryptoHashable):
    method get_candidate_id (line 309) | def get_candidate_id(self) -> str:
    method crypto_hash (line 315) | def crypto_hash(self) -> ElementModQ:
  class SelectionDescription (line 324) | class SelectionDescription(OrderedObjectBase, CryptoHashable):
    method crypto_hash (line 340) | def crypto_hash(self) -> ElementModQ:
  class ContestDescription (line 350) | class ContestDescription(OrderedObjectBase, CryptoHashable):
    method __eq__ (line 387) | def __eq__(self, other: Any) -> bool:
    method crypto_hash (line 401) | def crypto_hash(self) -> ElementModQ:
    method is_valid (line 423) | def is_valid(self) -> bool:
  class CandidateContestDescription (line 496) | class CandidateContestDescription(ContestDescription):
  class ReferendumContestDescription (line 508) | class ReferendumContestDescription(ContestDescription):
  class ContestDescriptionWithPlaceholders (line 518) | class ContestDescriptionWithPlaceholders(ContestDescription):
    method is_valid (line 530) | def is_valid(self) -> bool:
    method is_placeholder (line 541) | def is_placeholder(self, selection: SelectionDescription) -> bool:
    method selection_for (line 548) | def selection_for(self, selection_id: str) -> Optional[SelectionDescri...
  class SpecVersion (line 570) | class SpecVersion(Enum):
  class Manifest (line 579) | class Manifest(CryptoHashable):
    method __init__ (line 608) | def __init__(
    method __eq__ (line 636) | def __eq__(self, other: Any) -> bool:
    method crypto_hash (line 652) | def crypto_hash(self) -> ElementModQ:
    method is_valid (line 670) | def is_valid(self) -> bool:
    method _get_candidate_name (line 812) | def _get_candidate_name(self, candidate: Candidate, lang: str) -> str:
    method _get_candidate_names (line 817) | def _get_candidate_names(self, lang: str) -> Dict[str, str]:
    method _get_selections_with_candidate_id (line 823) | def _get_selections_with_candidate_id(self) -> Dict[str, str]:
    method _replace_candidate_ids_with_names (line 830) | def _replace_candidate_ids_with_names(
    method get_selection_names (line 838) | def get_selection_names(self, lang: str) -> Dict[str, str]:
    method get_contest_names (line 848) | def get_contest_names(self) -> Dict[str, str]:
    method get_name (line 856) | def get_name(self) -> str:
  class InternalManifest (line 864) | class InternalManifest:
    method __post_init__ (line 881) | def __post_init__(self, manifest: Manifest) -> None:
    method contest_for (line 889) | def contest_for(
    method get_ballot_style (line 905) | def get_ballot_style(self, ballot_style_id: str) -> BallotStyle:
    method get_contests_for (line 914) | def get_contests_for(
    method _generate_contests_with_placeholders (line 933) | def _generate_contests_with_placeholders(
  function contest_description_with_placeholders_from (line 954) | def contest_description_with_placeholders_from(
  function generate_placeholder_selection_from (line 978) | def generate_placeholder_selection_from(
  function generate_placeholder_selections_from (line 1005) | def generate_placeholder_selections_from(
  function get_i8n_value (line 1028) | def get_i8n_value(name: InternationalizedText, lang: str, default_val: s...

FILE: src/electionguard/nonces.py
  class Nonces (line 8) | class Nonces(Sequence[ElementModQ]):
    method __init__ (line 20) | def __init__(self, seed: ElementModQ, *headers: Union[str, ElementModP...
    method __getitem__ (line 28) | def __getitem__(self, index: int) -> ElementModQ:
    method __getitem__ (line 32) | def __getitem__(self, index: slice) -> List[ElementModQ]:
    method __getitem__ (line 35) | def __getitem__(
    method __len__ (line 46) | def __len__(self) -> int:
    method get_with_headers (line 49) | def get_with_headers(self, item: int, *headers: str) -> ElementModQ:

FILE: src/electionguard/proof.py
  class ProofUsage (line 6) | class ProofUsage(Enum):
  class Proof (line 15) | class Proof:
    method __init__ (line 21) | def __init__(self) -> None:

FILE: src/electionguard/scheduler.py
  class Scheduler (line 17) | class Scheduler(Singleton, AbstractContextManager):
    method __init__ (line 29) | def __init__(self) -> None:
    method __enter__ (line 33) | def __enter__(self) -> Scheduler:
    method __exit__ (line 37) | def __exit__(self, exc_type: Any, exc_value: Any, exc_traceback: Any) ...
    method _open (line 40) | def _open(self) -> None:
    method close (line 49) | def close(self) -> None:
    method cpu_count (line 55) | def cpu_count() -> int:
    method schedule (line 59) | def schedule(
    method safe_starmap (line 80) | def safe_starmap(
    method safe_map (line 98) | def safe_map(pool: Pool, task: Callable, arguments: Iterable[Any]) -> ...

FILE: src/electionguard/schnorr.py
  class SchnorrProof (line 18) | class SchnorrProof(Proof):
    method __post_init__ (line 33) | def __post_init__(self) -> None:
    method is_valid (line 36) | def is_valid(self) -> bool:
  function make_schnorr_proof (line 79) | def make_schnorr_proof(keypair: ElGamalKeyPair, r: ElementModQ) -> Schno...

FILE: src/electionguard/serialize.py
  function padded_encode (line 46) | def padded_encode(data: Any, size: DataSize = DataSize.Bytes_512) -> bytes:
  function padded_decode (line 50) | def padded_decode(
  function construct_path (line 56) | def construct_path(
  function from_raw (line 67) | def from_raw(type_: Type[_T], raw: Union[str, bytes]) -> _T:
  function from_list_raw (line 73) | def from_list_raw(type_: Type[_T], raw: Union[str, bytes]) -> List[_T]:
  function to_raw (line 83) | def to_raw(data: Any) -> str:
  function from_file_wrapper (line 89) | def from_file_wrapper(type_: Type[_T], file: TextIOWrapper) -> _T:
  function from_file (line 96) | def from_file(type_: Type[_T], path: Union[str, Path]) -> _T:
  function from_list_in_file (line 104) | def from_list_in_file(type_: Type[_T], path: Union[str, Path]) -> List[_T]:
  function from_list_in_file_wrapper (line 115) | def from_list_in_file_wrapper(type_: Type[_T], file: TextIOWrapper) -> L...
  function to_file (line 125) | def to_file(
  function get_schema (line 145) | def get_schema(_type: Any) -> str:

FILE: src/electionguard/singleton.py
  class Singleton (line 4) | class Singleton:
    method get_instance (line 10) | def get_instance() -> Any:
    method __init__ (line 16) | def __init__(self) -> None:

FILE: src/electionguard/tally.py
  class PlaintextTallySelection (line 26) | class PlaintextTallySelection(ElectionObjectBase):
  class CiphertextTallySelection (line 41) | class CiphertextTallySelection(ElectionObjectBase, CiphertextSelection):
    method elgamal_accumulate (line 62) | def elgamal_accumulate(
  class PlaintextTallyContest (line 74) | class PlaintextTallyContest(ElectionObjectBase):
  class CiphertextTallyContest (line 83) | class CiphertextTallyContest(OrderedObjectBase):
    method accumulate_contest (line 99) | def accumulate_contest(
    method _accumulate_selections (line 150) | def _accumulate_selections(
  class PlaintextTally (line 172) | class PlaintextTally(ElectionObjectBase):
  class PublishedCiphertextTally (line 181) | class PublishedCiphertextTally(ElectionObjectBase):
  class CiphertextTally (line 190) | class CiphertextTally(ElectionObjectBase, Container, Sized):
    method __post_init__ (line 208) | def __post_init__(self) -> None:
    method __len__ (line 213) | def __len__(self) -> int:
    method __contains__ (line 216) | def __contains__(self, item: object) -> bool:
    method append (line 228) | def append(
    method batch_append (line 259) | def batch_append(
    method cast (line 304) | def cast(self) -> int:
    method spoiled (line 310) | def spoiled(self) -> int:
    method publish (line 316) | def publish(self) -> PublishedCiphertextTally:
    method _accumulate (line 320) | def _accumulate(
    method _add_cast (line 328) | def _add_cast(
    method _add_spoiled (line 353) | def _add_spoiled(self, ballot: SubmittedBallot) -> bool:
    method _build_tally_collection (line 362) | def _build_tally_collection(
    method _execute_accumulate (line 390) | def _execute_accumulate(
  function tally_ballot (line 424) | def tally_ballot(
  function tally_ballots (line 444) | def tally_ballots(

FILE: src/electionguard/utils.py
  class ContestErrorType (line 16) | class ContestErrorType(Enum):
  class ContestException (line 25) | class ContestException(Exception):
    method __init__ (line 30) | def __init__(
  class OverVoteException (line 42) | class OverVoteException(ContestException):
    method __init__ (line 47) | def __init__(self, contest_id: ContestId, overvoted_ids: List[Selectio...
  class UnderVoteException (line 52) | class UnderVoteException(ContestException):
    method __init__ (line 55) | def __init__(self, contest_id: ContestId):
  class NullVoteException (line 59) | class NullVoteException(ContestException):
    method __init__ (line 62) | def __init__(self, contest_id: ContestId):
  function get_optional (line 66) | def get_optional(optional: Optional[_T]) -> _T:
  function match_optional (line 76) | def match_optional(
  function get_or_else_optional (line 89) | def get_or_else_optional(optional: Optional[_T], alt_value: _T) -> _T:
  function get_or_else_optional_func (line 99) | def get_or_else_optional_func(optional: Optional[_T], func: Callable[[],...
  function flatmap_optional (line 109) | def flatmap_optional(
  function to_hex_bytes (line 121) | def to_hex_bytes(data: bytes) -> bytes:
  function to_ticks (line 129) | def to_ticks(date_time: datetime) -> int:
  function to_iso_date_string (line 145) | def to_iso_date_string(date_time: datetime) -> str:
  function space_between_capitals (line 160) | def space_between_capitals(base: str) -> str:

FILE: src/electionguard_cli/cli_models/cli_decrypt_results.py
  class CliDecryptResults (line 9) | class CliDecryptResults:

FILE: src/electionguard_cli/cli_models/cli_election_inputs_base.py
  class CliElectionInputsBase (line 7) | class CliElectionInputsBase(ABC):

FILE: src/electionguard_cli/cli_models/e2e_build_election_results.py
  class BuildElectionResults (line 8) | class BuildElectionResults:

FILE: src/electionguard_cli/cli_models/encrypt_results.py
  class EncryptResults (line 8) | class EncryptResults:

FILE: src/electionguard_cli/cli_models/mark_results.py
  class MarkResults (line 5) | class MarkResults:
    method __init__ (line 8) | def __init__(

FILE: src/electionguard_cli/cli_models/submit_results.py
  class SubmitResults (line 5) | class SubmitResults:
    method __init__ (line 8) | def __init__(

FILE: src/electionguard_cli/cli_steps/cli_step_base.py
  class CliStepBase (line 5) | class CliStepBase:
    method print_header (line 17) | def print_header(self, s: str) -> None:
    method print_section (line 23) | def print_section(self, s: Optional[str]) -> None:
    method print_value (line 27) | def print_value(self, name: str, value: Any) -> None:
    method print_warning (line 30) | def print_warning(self, s: str) -> None:

FILE: src/electionguard_cli/cli_steps/decrypt_step.py
  class DecryptStep (line 15) | class DecryptStep(CliStepBase):
    method _get_lagrange_coefficients (line 18) | def _get_lagrange_coefficients(
    method decrypt (line 28) | def decrypt(

FILE: src/electionguard_cli/cli_steps/election_builder_step.py
  class ElectionBuilderStep (line 12) | class ElectionBuilderStep(CliStepBase):
    method _build_election (line 15) | def _build_election(

FILE: src/electionguard_cli/cli_steps/encrypt_votes_step.py
  class EncryptVotesStep (line 20) | class EncryptVotesStep(CliStepBase):
    method encrypt (line 23) | def encrypt(
    method _get_encrypter (line 36) | def _get_encrypter(
    method _encrypt_votes (line 46) | def _encrypt_votes(
    method _encrypt_ballots (line 60) | def _encrypt_ballots(

FILE: src/electionguard_cli/cli_steps/input_retrieval_step_base.py
  class InputRetrievalStepBase (line 19) | class InputRetrievalStepBase(CliStepBase):
    method _get_manifest (line 22) | def _get_manifest(self, manifest_file: TextIOWrapper) -> Manifest:
    method _get_manifest_raw (line 29) | def _get_manifest_raw(self, manifest_raw: str) -> Manifest:
    method __print_manifest (line 36) | def __print_manifest(self, manifest: Manifest) -> None:
    method _get_context (line 46) | def _get_context(context_file: TextIOWrapper) -> CiphertextElectionCon...
    method _get_ballots (line 50) | def _get_ballots(ballots_path: str, ballot_type: Type[_T]) -> List[_T]:
    method _get_ballot (line 64) | def _get_ballot(ballots_dir: str, filename: str, ballot_type: Type[_T]...

FILE: src/electionguard_cli/cli_steps/key_ceremony_step.py
  class KeyCeremonyStep (line 15) | class KeyCeremonyStep(CliStepBase):
    method run_key_ceremony (line 18) | def run_key_ceremony(self, guardians: List[Guardian]) -> ElectionJoint...

FILE: src/electionguard_cli/cli_steps/mark_ballots_step.py
  class MarkBallotsStep (line 8) | class MarkBallotsStep(CliStepBase):
    method mark (line 11) | def mark(

FILE: src/electionguard_cli/cli_steps/output_step_base.py
  class OutputStepBase (line 11) | class OutputStepBase(CliStepBase):
    method _export_private_keys (line 16) | def _export_private_keys(self, output_keys: str, guardians: List[Guard...
    method _get_guardian_records (line 33) | def _get_guardian_records(
    method _export_file (line 38) | def _export_file(

FILE: src/electionguard_cli/cli_steps/print_results_step.py
  class PrintResultsStep (line 12) | class PrintResultsStep(CliStepBase):
    method _print_tally (line 15) | def _print_tally(
    method _print_spoiled_ballots (line 30) | def _print_spoiled_ballots(
    method print_election_results (line 47) | def print_election_results(

FILE: src/electionguard_cli/cli_steps/submit_ballots_step.py
  class SubmitBallotsStep (line 12) | class SubmitBallotsStep(CliStepBase):
    method submit (line 15) | def submit(

FILE: src/electionguard_cli/cli_steps/tally_step.py
  class TallyStep (line 12) | class TallyStep(CliStepBase):
    method get_from_ballots (line 15) | def get_from_ballots(
    method get_from_ballot_store (line 28) | def get_from_ballot_store(
    method _get_tally (line 36) | def _get_tally(
    method _get_spoiled_ballots (line 51) | def _get_spoiled_ballots(self, ballot_store: DataStore) -> List[Submit...

FILE: src/electionguard_cli/e2e/e2e_command.py
  function E2eCommand (line 77) | def E2eCommand(

FILE: src/electionguard_cli/e2e/e2e_election_builder_step.py
  class E2eElectionBuilderStep (line 7) | class E2eElectionBuilderStep(ElectionBuilderStep):
    method build_election_with_key (line 10) | def build_election_with_key(

FILE: src/electionguard_cli/e2e/e2e_input_retrieval_step.py
  class E2eInputRetrievalStep (line 17) | class E2eInputRetrievalStep(InputRetrievalStepBase):
    method get_inputs (line 20) | def get_inputs(

FILE: src/electionguard_cli/e2e/e2e_inputs.py
  class E2eInputs (line 11) | class E2eInputs(CliElectionInputsBase):
    method __init__ (line 14) | def __init__(

FILE: src/electionguard_cli/e2e/e2e_publish_step.py
  class E2ePublishStep (line 15) | class E2ePublishStep(OutputStepBase):
    method export (line 18) | def export(
    method _export_election_record (line 38) | def _export_election_record(
    method _export_private_keys_e2e (line 66) | def _export_private_keys_e2e(self, election_inputs: E2eInputs) -> None:

FILE: src/electionguard_cli/e2e/submit_votes_step.py
  class SubmitVotesStep (line 18) | class SubmitVotesStep(CliStepBase):
    method submit (line 21) | def submit(
    method _cast_and_spoil (line 39) | def _cast_and_spoil(

FILE: src/electionguard_cli/encrypt_ballots/encrypt_ballot_inputs.py
  class EncryptBallotInputs (line 12) | class EncryptBallotInputs(CliElectionInputsBase):
    method __init__ (line 15) | def __init__(

FILE: src/electionguard_cli/encrypt_ballots/encrypt_ballots_election_builder_step.py
  class EncryptBallotsElectionBuilderStep (line 6) | class EncryptBallotsElectionBuilderStep(ElectionBuilderStep):
    method build_election_with_context (line 10) | def build_election_with_context(

FILE: src/electionguard_cli/encrypt_ballots/encrypt_ballots_input_retrieval_step.py
  class EncryptBallotsInputRetrievalStep (line 12) | class EncryptBallotsInputRetrievalStep(InputRetrievalStepBase):
    method get_inputs (line 15) | def get_inputs(

FILE: src/electionguard_cli/encrypt_ballots/encrypt_ballots_publish_step.py
  class EncryptBallotsPublishStep (line 9) | class EncryptBallotsPublishStep(OutputStepBase):
    method publish (line 12) | def publish(self, encrypt_results: EncryptResults, out_dir: str) -> None:

FILE: src/electionguard_cli/encrypt_ballots/encrypt_command.py
  function EncryptBallotsCommand (line 35) | def EncryptBallotsCommand(

FILE: src/electionguard_cli/import_ballots/import_ballot_inputs.py
  class ImportBallotInputs (line 14) | class ImportBallotInputs(CliElectionInputsBase):
    method __init__ (line 17) | def __init__(

FILE: src/electionguard_cli/import_ballots/import_ballots_command.py
  function ImportBallotsCommand (line 57) | def ImportBallotsCommand(

FILE: src/electionguard_cli/import_ballots/import_ballots_election_builder_step.py
  class ImportBallotsElectionBuilderStep (line 6) | class ImportBallotsElectionBuilderStep(ElectionBuilderStep):
    method build_election_with_context (line 10) | def build_election_with_context(

FILE: src/electionguard_cli/import_ballots/import_ballots_input_retrieval_step.py
  class ImportBallotsInputRetrievalStep (line 21) | class ImportBallotsInputRetrievalStep(InputRetrievalStepBase):
    method get_inputs (line 24) | def get_inputs(
    method _get_encryption_devices (line 56) | def _get_encryption_devices(
    method _get_guardians_from_keys (line 67) | def _get_guardians_from_keys(
    method _load_private_record (line 86) | def _load_private_record(guardian_dir: str, filename: str) -> PrivateG...
    method _get_guardian (line 91) | def _get_guardian(

FILE: src/electionguard_cli/import_ballots/import_ballots_publish_step.py
  class ImportBallotsPublishStep (line 16) | class ImportBallotsPublishStep(OutputStepBase):
    method publish (line 19) | def publish(

FILE: src/electionguard_cli/mark_ballots/mark_ballot_inputs.py
  class MarkBallotInputs (line 9) | class MarkBallotInputs(CliElectionInputsBase):
    method __init__ (line 12) | def __init__(

FILE: src/electionguard_cli/mark_ballots/mark_ballots_election_builder_step.py
  class MarkBallotsElectionBuilderStep (line 6) | class MarkBallotsElectionBuilderStep(ElectionBuilderStep):
    method build_election_with_context (line 10) | def build_election_with_context(

FILE: src/electionguard_cli/mark_ballots/mark_ballots_input_retrieval_step.py
  class MarkBallotsInputRetrievalStep (line 11) | class MarkBallotsInputRetrievalStep(InputRetrievalStepBase):
    method get_inputs (line 14) | def get_inputs(

FILE: src/electionguard_cli/mark_ballots/mark_ballots_publish_step.py
  class MarkBallotsPublishStep (line 9) | class MarkBallotsPublishStep(OutputStepBase):
    method publish (line 12) | def publish(self, marked_ballots: MarkResults, out_dir: str) -> None:

FILE: src/electionguard_cli/mark_ballots/mark_command.py
  function MarkBallotsCommand (line 31) | def MarkBallotsCommand(

FILE: src/electionguard_cli/setup_election/output_setup_files_step.py
  class OutputSetupFilesStep (line 21) | class OutputSetupFilesStep(OutputStepBase):
    method output (line 24) | def output(
    method _export_context (line 39) | def _export_context(
    method _export_constants (line 46) | def _export_constants(self, out_dir: str) -> str:
    method _export_manifest (line 50) | def _export_manifest(self, setup_inputs: SetupInputs, out_dir: str) ->...
    method _export_guardian_records (line 58) | def _export_guardian_records(self, setup_inputs: SetupInputs, out_dir:...
    method _export_guardian_private_keys (line 69) | def _export_guardian_private_keys(self, inputs: SetupInputs, keys_dir:...

FILE: src/electionguard_cli/setup_election/setup_election_builder_step.py
  class SetupElectionBuilderStep (line 8) | class SetupElectionBuilderStep(ElectionBuilderStep):
    method build_election_for_setup (line 12) | def build_election_for_setup(

FILE: src/electionguard_cli/setup_election/setup_election_command.py
  function SetupElectionCommand (line 51) | def SetupElectionCommand(

FILE: src/electionguard_cli/setup_election/setup_input_retrieval_step.py
  class SetupInputRetrievalStep (line 13) | class SetupInputRetrievalStep(InputRetrievalStepBase):
    method get_inputs (line 16) | def get_inputs(

FILE: src/electionguard_cli/setup_election/setup_inputs.py
  class SetupInputs (line 9) | class SetupInputs(CliElectionInputsBase):
    method __init__ (line 15) | def __init__(

FILE: src/electionguard_cli/start.py
  function cli (line 12) | def cli() -> None:

FILE: src/electionguard_cli/submit_ballots/submit_ballot_inputs.py
  class SubmitBallotInputs (line 12) | class SubmitBallotInputs(CliElectionInputsBase):
    method __init__ (line 15) | def __init__(

FILE: src/electionguard_cli/submit_ballots/submit_ballots_election_builder_step.py
  class SubmitBallotsElectionBuilderStep (line 6) | class SubmitBallotsElectionBuilderStep(ElectionBuilderStep):
    method build_election_with_context (line 10) | def build_election_with_context(

FILE: src/electionguard_cli/submit_ballots/submit_ballots_input_retrieval_step.py
  class SubmitBallotsInputRetrievalStep (line 12) | class SubmitBallotsInputRetrievalStep(InputRetrievalStepBase):
    method get_inputs (line 15) | def get_inputs(

FILE: src/electionguard_cli/submit_ballots/submit_ballots_publish_step.py
  class SubmitBallotsPublishStep (line 9) | class SubmitBallotsPublishStep(OutputStepBase):
    method publish (line 12) | def publish(self, submit_results: SubmitResults, out_dir: str) -> None:

FILE: src/electionguard_cli/submit_ballots/submit_command.py
  function SubmitBallotsCommand (line 38) | def SubmitBallotsCommand(

FILE: src/electionguard_gui/components/component_base.py
  class ComponentBase (line 10) | class ComponentBase(ABC):
    method init (line 16) | def init(
    method expose (line 25) | def expose(self) -> None:
    method handle_error (line 29) | def handle_error(self, error: Exception) -> dict[str, Any]:

FILE: src/electionguard_gui/components/create_decryption_component.py
  class CreateDecryptionComponent (line 9) | class CreateDecryptionComponent(ComponentBase):
    method __init__ (line 15) | def __init__(
    method expose (line 23) | def expose(self) -> None:
    method get_suggested_decryption_name (line 27) | def get_suggested_decryption_name(self, election_id: str) -> dict[str,...
    method create_decryption (line 37) | def create_decryption(

FILE: src/electionguard_gui/components/create_election_component.py
  class CreateElectionComponent (line 24) | class CreateElectionComponent(ComponentBase):
    method __init__ (line 36) | def __init__(
    method expose (line 52) | def expose(self) -> None:
    method get_keys (line 56) | def get_keys(self) -> dict[str, Any]:
    method create_election (line 65) | def create_election(
    method _zip (line 133) | def _zip(self, dir_to_zip: str, zip_file_to_make: str) -> str:

FILE: src/electionguard_gui/components/create_key_ceremony_component.py
  class CreateKeyCeremonyComponent (line 10) | class CreateKeyCeremonyComponent(ComponentBase):
    method __init__ (line 16) | def __init__(
    method expose (line 25) | def expose(self) -> None:
    method create_key_ceremony (line 28) | def create_key_ceremony(

FILE: src/electionguard_gui/components/election_list_component.py
  class ElectionListComponent (line 8) | class ElectionListComponent(ComponentBase):
    method __init__ (line 13) | def __init__(self, election_service: ElectionService) -> None:
    method expose (line 16) | def expose(self) -> None:
    method get_elections (line 19) | def get_elections(self) -> dict[str, Any]:

FILE: src/electionguard_gui/components/export_election_record_component.py
  class ExportElectionRecordComponent (line 19) | class ExportElectionRecordComponent(ComponentBase):
    method __init__ (line 28) | def __init__(
    method expose (line 38) | def expose(self) -> None:
    method get_election_record_export_locations (line 42) | def get_election_record_export_locations(self) -> dict[str, Any]:
    method export_election_record (line 51) | def export_election_record(

FILE: src/electionguard_gui/components/export_encryption_package_component.py
  class ExportEncryptionPackageComponent (line 11) | class ExportEncryptionPackageComponent(ComponentBase):
    method __init__ (line 16) | def __init__(self, election_service: ElectionService) -> None:
    method expose (line 19) | def expose(self) -> None:
    method get_encryption_package_export_locations (line 23) | def get_encryption_package_export_locations(self) -> dict[str, Any]:
    method export_encryption_package (line 31) | def export_encryption_package(

FILE: src/electionguard_gui/components/guardian_home_component.py
  class GuardianHomeComponent (line 13) | class GuardianHomeComponent(ComponentBase):
    method __init__ (line 20) | def __init__(
    method expose (line 31) | def expose(self) -> None:
    method get_decryptions (line 37) | def get_decryptions(self) -> dict[str, Any]:
    method get_key_ceremonies (line 43) | def get_key_ceremonies(self) -> dict[str, Any]:
    method watch_db_collections (line 51) | def watch_db_collections(self) -> None:
    method stop_watching_db_collections (line 65) | def stop_watching_db_collections(self) -> None:
  function notify_ui_db_changed (line 70) | def notify_ui_db_changed(collection: str, _: str) -> None:

FILE: src/electionguard_gui/components/key_ceremony_details_component.py
  class KeyCeremonyDetailsComponent (line 31) | class KeyCeremonyDetailsComponent(ComponentBase):
    method __init__ (line 40) | def __init__(
    method expose (line 67) | def expose(self) -> None:
    method watch_key_ceremony (line 72) | def watch_key_ceremony(self, key_ceremony_id: str) -> None:
    method stop_watching_key_ceremony (line 90) | def stop_watching_key_ceremony(self) -> None:
    method on_key_ceremony_changed (line 93) | def on_key_ceremony_changed(self, _: str, key_ceremony_id: str) -> None:
    method join_key_ceremony (line 125) | def join_key_ceremony(self, key_ceremony_id: str) -> None:
    method get_ceremony (line 134) | def get_ceremony(self, db: Database, id: str) -> KeyCeremonyDto:

FILE: src/electionguard_gui/components/upload_ballots_component.py
  class UploadBallotsComponent (line 14) | class UploadBallotsComponent(ComponentBase):
    method __init__ (line 20) | def __init__(
    method expose (line 28) | def expose(self) -> None:
    method create_ballot_upload (line 35) | def create_ballot_upload(
    method upload_ballot (line 67) | def upload_ballot(
    method is_wizard_supported (line 116) | def is_wizard_supported(self) -> bool:
    method scan_drives (line 120) | def scan_drives(self) -> dict[str, Any]:
    method parse_drive (line 136) | def parse_drive(self, drive: str) -> dict[str, Any]:
    method upload_ballots (line 158) | def upload_ballots(self, election_id: str) -> dict[str, Any]:
    method create_ballot_from_file (line 200) | def create_ballot_from_file(
    method create_ballot_upload_from_file (line 214) | def create_ballot_upload_from_file(
  function update_upload_status (line 224) | def update_upload_status(status: str) -> None:

FILE: src/electionguard_gui/components/view_decryption_component.py
  class ViewDecryptionComponent (line 19) | class ViewDecryptionComponent(ComponentBase):
    method __init__ (line 28) | def __init__(
    method expose (line 42) | def expose(self) -> None:
    method watch_decryption (line 48) | def watch_decryption(self, decryption_id: str) -> None:
    method stop_watching_decryption (line 60) | def stop_watching_decryption(self) -> None:
    method on_decryption_changed (line 63) | def on_decryption_changed(self, _: str, decryption_id: str) -> None:
    method try_run_stage_2 (line 77) | def try_run_stage_2(self, db: Database, decryption: DecryptionDto) -> ...
    method get_decryption (line 86) | def get_decryption(self, decryption_id: str, is_refresh: bool) -> dict...
    method join_decryption (line 99) | def join_decryption(self, decryption_id: str) -> dict[str, Any]:
  function refresh_decryption (line 110) | def refresh_decryption(result: dict[str, Any]) -> None:

FILE: src/electionguard_gui/components/view_election_component.py
  class ViewElectionComponent (line 8) | class ViewElectionComponent(ComponentBase):
    method __init__ (line 13) | def __init__(self, election_service: ElectionService) -> None:
    method expose (line 16) | def expose(self) -> None:
    method get_election (line 19) | def get_election(self, election_id: str) -> dict[str, Any]:

FILE: src/electionguard_gui/components/view_spoiled_ballot_component.py
  class ViewSpoiledBallotComponent (line 15) | class ViewSpoiledBallotComponent(ComponentBase):
    method __init__ (line 21) | def __init__(
    method expose (line 27) | def expose(self) -> None:
    method get_spoiled_ballot (line 30) | def get_spoiled_ballot(
  function get_spoiled_ballot_by_id (line 57) | def get_spoiled_ballot_by_id(

FILE: src/electionguard_gui/components/view_tally_component.py
  class ViewTallyComponent (line 14) | class ViewTallyComponent(ComponentBase):
    method __init__ (line 20) | def __init__(
    method expose (line 26) | def expose(self) -> None:
    method get_tally (line 29) | def get_tally(self, decryption_id: str) -> dict[str, Any]:

FILE: src/electionguard_gui/containers.py
  class Container (line 54) | class Container(containers.DeclarativeContainer):

FILE: src/electionguard_gui/eel_utils.py
  function eel_fail (line 6) | def eel_fail(message: str) -> dict[str, Any]:
  function eel_success (line 10) | def eel_success(result: Any = None) -> dict[str, Any]:
  function utc_to_str (line 14) | def utc_to_str(utc_dt: Optional[datetime]) -> str:
  function convert_utc_to_local (line 23) | def convert_utc_to_local(utc_dt: datetime) -> datetime:

FILE: src/electionguard_gui/main_app.py
  class MainApp (line 32) | class MainApp:
    method __init__ (line 40) | def __init__(
    method start (line 91) | def start(self) -> None:
    method on_close (line 121) | def on_close(self, _page: str, _open_sockets: list) -> None:

FILE: src/electionguard_gui/models/decryption_dto.py
  class GuardianDecryptionShare (line 13) | class GuardianDecryptionShare:
    method __init__ (line 16) | def __init__(
  class DecryptionDto (line 38) | class DecryptionDto:
    method __init__ (line 63) | def __init__(self, decryption: dict[str, Any]):
    method get_status (line 88) | def get_status(self) -> str:
    method to_id_name_dict (line 95) | def to_id_name_dict(self) -> dict[str, Any]:
    method to_dict (line 101) | def to_dict(self) -> dict[str, Any]:
    method get_decryption_shares (line 122) | def get_decryption_shares(self) -> list[GuardianDecryptionShare]:
    method set_can_join (line 133) | def set_can_join(self, auth_service: AuthorizationService) -> None:
    method get_plaintext_tally (line 139) | def get_plaintext_tally(self) -> PlaintextTally:
    method get_plaintext_spoiled_ballots (line 144) | def get_plaintext_spoiled_ballots(self) -> list[PlaintextTally]:
    method get_lagrange_coefficients (line 150) | def get_lagrange_coefficients(self) -> LagrangeCoefficientsRecord:
    method get_ciphertext_tally (line 155) | def get_ciphertext_tally(self) -> PublishedCiphertextTally:
  function _get_list (line 161) | def _get_list(decryption: dict[str, Any], name: str) -> list:
  function _get_dict (line 168) | def _get_dict(decryption: dict[str, Any], name: str) -> dict:
  function _get_int (line 175) | def _get_int(decryption: dict[str, Any], name: str, default: int) -> int:

FILE: src/electionguard_gui/models/election_dto.py
  class ElectionDto (line 13) | class ElectionDto:
    method __init__ (line 33) | def __init__(self, election: dict[str, Any]):
    method to_id_name_dict (line 51) | def to_id_name_dict(self) -> dict[str, Any]:
    method _get_manifest_field (line 57) | def _get_manifest_field(self, field: str) -> Any:
    method to_dict (line 60) | def to_dict(self) -> dict[str, Any]:
    method get_manifest (line 96) | def get_manifest(self) -> Manifest:
    method get_context (line 101) | def get_context(self) -> CiphertextElectionContext:
    method get_encryption_devices (line 106) | def get_encryption_devices(self) -> list[EncryptionDevice]:
    method get_guardian_records (line 117) | def get_guardian_records(self) -> list[GuardianRecord]:
    method get_guardian_sequence_order (line 122) | def get_guardian_sequence_order(self, guardian_id: str) -> int:
    method sum_ballots (line 128) | def sum_ballots(self) -> int:
  function _get_list (line 132) | def _get_list(election: dict[str, Any], name: str) -> list:

FILE: src/electionguard_gui/models/key_ceremony_dto.py
  class KeyCeremonyDto (line 19) | class KeyCeremonyDto:
    method __init__ (line 22) | def __init__(self, key_ceremony: Any):
    method to_id_name_dict (line 40) | def to_id_name_dict(self) -> dict[str, Any]:
    method to_dict (line 46) | def to_dict(self) -> dict[str, Any]:
    method find_key (line 79) | def find_key(self, guardian_id: str) -> ElectionPublicKey:
    method get_backup_count_for_user (line 86) | def get_backup_count_for_user(self, user_id: str) -> int:
    method get_verification_count_for_user (line 90) | def get_verification_count_for_user(self, user_id: str) -> int:
    method get_verifications (line 99) | def get_verifications(self) -> List[ElectionPartialKeyVerification]:
    method get_shared_backups_for_guardian (line 104) | def get_shared_backups_for_guardian(
    method get_backups (line 115) | def get_backups(self) -> List[ElectionPartialKeyBackup]:
    method find_other_keys_for_user (line 118) | def find_other_keys_for_user(self, user_id: str) -> List[ElectionPubli...
    method joint_key_exists (line 128) | def joint_key_exists(self) -> bool:
    method get_joint_key (line 131) | def get_joint_key(self) -> ElectionJointKey:
    method set_can_join (line 137) | def set_can_join(self, auth_service: AuthorizationService) -> None:
  function _dict_to_verification (line 144) | def _dict_to_verification(verification: Any) -> ElectionPartialKeyVerifi...
  function _dict_to_backup (line 153) | def _dict_to_backup(backup: Any) -> ElectionPartialKeyBackup:
  function _dict_to_election_public_key (line 166) | def _dict_to_election_public_key(key: Any) -> ElectionPublicKey:

FILE: src/electionguard_gui/models/key_ceremony_states.py
  class KeyCeremonyStates (line 4) | class KeyCeremonyStates(Enum):

FILE: src/electionguard_gui/services/authorization_service.py
  class AuthorizationService (line 8) | class AuthorizationService(ServiceBase):
    method __init__ (line 13) | def __init__(self, config_service: ConfigurationService) -> None:
    method expose (line 19) | def expose(self) -> None:
    method get_required_user_id (line 24) | def get_required_user_id(self) -> str:
    method get_user_id (line 29) | def get_user_id(self) -> Optional[str]:
    method set_user_id (line 32) | def set_user_id(self, user_id: str) -> None:
    method is_admin (line 35) | def is_admin(self) -> bool:

FILE: src/electionguard_gui/services/ballot_upload_service.py
  class BallotUploadService (line 12) | class BallotUploadService(ServiceBase):
    method __init__ (line 18) | def __init__(
    method create (line 24) | def create(
    method add_ballot (line 44) | def add_ballot(
    method increment_ballot_count (line 65) | def increment_ballot_count(self, db: Database, ballot_upload_id: str) ...
    method any_ballot_exists (line 72) | def any_ballot_exists(self, db: Database, election_id: str, object_id:...
    method get_ballots (line 81) | def get_ballots(
    method get_submitted_ballot_with_retry (line 111) | def get_submitted_ballot_with_retry(
    method get_submitted_ballot (line 130) | def get_submitted_ballot(
  class RetryException (line 157) | class RetryException(Exception):

FILE: src/electionguard_gui/services/configuration_service.py
  class ConfigurationService (line 13) | class ConfigurationService:
    method get_mode (line 17) | def get_mode(self) -> Optional[str]:
    method get_port (line 21) | def get_port(self) -> int:
    method get_host (line 24) | def get_host(self) -> str:
    method get_db_password (line 27) | def get_db_password(self) -> str:
    method get_db_host (line 30) | def get_db_host(self, default: str) -> str:
    method get_is_admin (line 33) | def get_is_admin(self) -> bool:
    method _get_param (line 36) | def _get_param(self, param_name: str) -> str:
    method _get_param_or_default (line 43) | def _get_param_or_default(self, param_name: str, default: str) -> str:

FILE: src/electionguard_gui/services/db_serialization_service.py
  function public_key_to_dict (line 10) | def public_key_to_dict(key: ElectionPublicKey) -> dict[str, Any]:
  function backup_to_dict (line 29) | def backup_to_dict(backup: ElectionPartialKeyBackup) -> dict[str, Any]:
  function verification_to_dict (line 43) | def verification_to_dict(
  function joint_key_to_dict (line 54) | def joint_key_to_dict(

FILE: src/electionguard_gui/services/db_service.py
  class DbService (line 11) | class DbService(ServiceBase):
    method __init__ (line 16) | def __init__(
    method get_db (line 30) | def get_db(self) -> Database:
    method verify_db_connection (line 40) | def verify_db_connection(self) -> None:

FILE: src/electionguard_gui/services/db_watcher_service.py
  class DbWatcherService (line 10) | class DbWatcherService(ServiceBase):
    method __init__ (line 18) | def __init__(self, log_service: EelLogService) -> None:
    method notify_changed (line 28) | def notify_changed(self, db: Database, collection: str, id: str) -> None:
    method watch_database (line 33) | def watch_database(
    method stop_watching (line 68) | def stop_watching(self) -> None:

FILE: src/electionguard_gui/services/decryption_service.py
  class DecryptionService (line 19) | class DecryptionService(ServiceBase):
    method __init__ (line 26) | def __init__(
    method create (line 36) | def create(
    method notify_changed (line 69) | def notify_changed(self, db: Database, decryption_id: str) -> None:
    method name_exists (line 72) | def name_exists(self, db: Database, name: str) -> Any:
    method get (line 77) | def get(self, db: Database, decryption_id: str) -> DecryptionDto:
    method get_decryption_count (line 86) | def get_decryption_count(self, db: Database, election_id: str) -> int:
    method get_active (line 93) | def get_active(self, db: Database) -> List[DecryptionDto]:
    method append_guardian_joined (line 105) | def append_guardian_joined(
    method set_decryption_completed (line 140) | def set_decryption_completed(
  function to_ballot_share_raw (line 170) | def to_ballot_share_raw(ballot_share: Optional[DecryptionShare]) -> Opti...

FILE: src/electionguard_gui/services/decryption_stages/decryption_s1_join_service.py
  class DecryptionS1JoinService (line 12) | class DecryptionS1JoinService(DecryptionStageBase):
    method run (line 15) | def run(self, db: Database, decryption: DecryptionDto) -> None:
  function _update_decrypt_status (line 60) | def _update_decrypt_status(status: str) -> None:

FILE: src/electionguard_gui/services/decryption_stages/decryption_s2_announce_service.py
  class DecryptionS2AnnounceService (line 13) | class DecryptionS2AnnounceService(DecryptionStageBase):
    method should_run (line 16) | def should_run(self, db: Database, decryption: DecryptionDto) -> bool:
    method run (line 22) | def run(self, db: Database, decryption: DecryptionDto) -> None:
  function _get_lagrange_coefficients (line 92) | def _get_lagrange_coefficients(
  function _update_decrypt_status (line 98) | def _update_decrypt_status(status: str) -> None:

FILE: src/electionguard_gui/services/decryption_stages/decryption_stage_base.py
  class DecryptionStageBase (line 20) | class DecryptionStageBase(ABC):
    method __init__ (line 31) | def __init__(
    method should_run (line 50) | def should_run(self, db: Database, decryption: DecryptionDto) -> bool:
    method run (line 53) | def run(self, db: Database, decryption: DecryptionDto) -> None:
  function get_tally (line 57) | def get_tally(

FILE: src/electionguard_gui/services/directory_service.py
  function get_export_dir (line 7) | def get_export_dir() -> str:
  function get_data_dir (line 11) | def get_data_dir() -> str:
  function _get_egui_mnt_subdir (line 15) | def _get_egui_mnt_subdir(subdir_name: str) -> str:
  function _get_egui_mnt_dir (line 22) | def _get_egui_mnt_dir() -> str:

FILE: src/electionguard_gui/services/eel_log_service.py
  class EelLogService (line 18) | class EelLogService(ServiceBase):
    method __init__ (line 22) | def __init__(self) -> None:
    method trace (line 30) | def trace(self, message: str, *args: Any, **kwargs: Any) -> None:
    method debug (line 33) | def debug(self, message: str, *args: Any, **kwargs: Any) -> None:
    method info (line 36) | def info(self, message: str, *args: Any, **kwargs: Any) -> None:
    method warn (line 39) | def warn(self, message: str, *args: Any, **kwargs: Any) -> None:
    method error (line 42) | def error(self, message: str, exception: Exception) -> None:
    method fatal (line 49) | def fatal(self, message: str, exception: Exception) -> None:

FILE: src/electionguard_gui/services/election_service.py
  class ElectionService (line 16) | class ElectionService(ServiceBase):
    method __init__ (line 22) | def __init__(
    method create_election (line 28) | def create_election(
    method get (line 74) | def get(self, db: Database, election_id: str) -> ElectionDto:
    method get_all (line 81) | def get_all(self, db: Database) -> list[ElectionDto]:
    method append_ballot_upload (line 86) | def append_ballot_upload(
    method append_decryption (line 116) | def append_decryption(
    method increment_ballot_upload_ballot_count (line 135) | def increment_ballot_upload_ballot_count(

FILE: src/electionguard_gui/services/export_service.py
  function get_export_locations (line 5) | def get_export_locations() -> list[str]:
  function get_removable_drives (line 13) | def get_removable_drives() -> list[str]:
  function _get_download_path (line 19) | def _get_download_path() -> str:

FILE: src/electionguard_gui/services/guardian_service.py
  class GuardianService (line 14) | class GuardianService(ServiceBase):
    method __init__ (line 19) | def __init__(self, log_service: EelLogService) -> None:
    method save_guardian (line 22) | def save_guardian(self, guardian: Guardian, key_ceremony: KeyCeremonyD...
    method _load_guardian (line 31) | def _load_guardian(
    method load_guardian_from_decryption (line 48) | def load_guardian_from_decryption(
    method load_guardian_from_key_ceremony (line 60) | def load_guardian_from_key_ceremony(
    method load_other_keys (line 70) | def load_other_keys(
  function make_guardian (line 80) | def make_guardian(
  function make_mediator (line 91) | def make_mediator(key_ceremony: KeyCeremonyDto) -> KeyCeremonyMediator:
  function announce_guardians (line 99) | def announce_guardians(

FILE: src/electionguard_gui/services/gui_setup_input_retrieval_step.py
  class GuiSetupInputRetrievalStep (line 8) | class GuiSetupInputRetrievalStep(SetupInputRetrievalStep):
    method get_gui_inputs (line 11) | def get_gui_inputs(

FILE: src/electionguard_gui/services/key_ceremony_service.py
  class KeyCeremonyService (line 25) | class KeyCeremonyService(ServiceBase):
    method __init__ (line 32) | def __init__(
    method create (line 42) | def create(
    method notify_changed (line 65) | def notify_changed(self, db: Database, key_ceremony_id: str) -> None:
    method get (line 68) | def get(self, db: Database, id: str) -> KeyCeremonyDto:
    method append_guardian_joined (line 76) | def append_guardian_joined(
    method append_key (line 84) | def append_key(
    method append_other_key (line 92) | def append_other_key(self, db: Database, key_ceremony_id: str, keys: A...
    method append_backups (line 98) | def append_backups(
    method append_shared_backups (line 110) | def append_shared_backups(
    method append_verifications (line 121) | def append_verifications(
    method append_joint_key (line 135) | def append_joint_key(
    method set_complete (line 147) | def set_complete(
    method get_completed (line 157) | def get_completed(self, db: Database) -> List[KeyCeremonyDto]:
    method get_active (line 161) | def get_active(self, db: Database) -> List[KeyCeremonyDto]:
    method exists (line 165) | def exists(self, db: Database, key_ceremony_name: str) -> bool:
  function get_guardian_number (line 172) | def get_guardian_number(key_ceremony: KeyCeremonyDto, guardian_id: str) ...

FILE: src/electionguard_gui/services/key_ceremony_stages/key_ceremony_s1_join_service.py
  class KeyCeremonyS1JoinService (line 11) | class KeyCeremonyS1JoinService(KeyCeremonyStageBase):
    method run (line 14) | def run(self, db: Database, key_ceremony: KeyCeremonyDto) -> None:

FILE: src/electionguard_gui/services/key_ceremony_stages/key_ceremony_s2_announce_service.py
  class KeyCeremonyS2AnnounceService (line 17) | class KeyCeremonyS2AnnounceService(KeyCeremonyStageBase):
    method should_run (line 20) | def should_run(
    method run (line 27) | def run(self, db: Database, key_ceremony: KeyCeremonyDto) -> None:
    method announce (line 35) | def announce(self, key_ceremony: KeyCeremonyDto) -> List[dict[str, Any]]:

FILE: src/electionguard_gui/services/key_ceremony_stages/key_ceremony_s3_make_backup_service.py
  class KeyCeremonyS3MakeBackupService (line 9) | class KeyCeremonyS3MakeBackupService(KeyCeremonyStageBase):
    method should_run (line 12) | def should_run(
    method run (line 25) | def run(self, db: Database, key_ceremony: KeyCeremonyDto) -> None:

FILE: src/electionguard_gui/services/key_ceremony_stages/key_ceremony_s4_share_backup_service.py
  class KeyCeremonyS4ShareBackupService (line 15) | class KeyCeremonyS4ShareBackupService(KeyCeremonyStageBase):
    method should_run (line 21) | def should_run(
    method run (line 27) | def run(self, db: Database, key_ceremony: KeyCeremonyDto) -> None:
    method share_backups (line 36) | def share_backups(self, key_ceremony: KeyCeremonyDto) -> List[Any]:

FILE: src/electionguard_gui/services/key_ceremony_stages/key_ceremony_s5_verify_backup_service.py
  class KeyCeremonyS5VerifyBackupService (line 11) | class KeyCeremonyS5VerifyBackupService(KeyCeremonyStageBase):
    method should_run (line 14) | def should_run(
    method run (line 29) | def run(self, db: Database, key_ceremony: KeyCeremonyDto) -> None:

FILE: src/electionguard_gui/services/key_ceremony_stages/key_ceremony_s6_publish_key_service.py
  class KeyCeremonyS6PublishKeyService (line 13) | class KeyCeremonyS6PublishKeyService(KeyCeremonyStageBase):
    method should_run (line 19) | def should_run(
    method run (line 25) | def run(self, db: Database, key_ceremony: KeyCeremonyDto) -> None:

FILE: src/electionguard_gui/services/key_ceremony_stages/key_ceremony_stage_base.py
  class KeyCeremonyStageBase (line 16) | class KeyCeremonyStageBase(ABC):
    method __init__ (line 26) | def __init__(
    method should_run (line 43) | def should_run(
    method run (line 49) | def run(self, db: Database, key_ceremony: KeyCeremonyDto) -> None:

FILE: src/electionguard_gui/services/key_ceremony_state_service.py
  class KeyCeremonyStateService (line 7) | class KeyCeremonyStateService(ServiceBase):
    method __init__ (line 12) | def __init__(self, log_service: EelLogService) -> None:
    method get_key_ceremony_state (line 16) | def get_key_ceremony_state(self, key_ceremony: KeyCeremonyDto) -> KeyC...
  function get_key_ceremony_status (line 58) | def get_key_ceremony_status(state: KeyCeremonyStates) -> str:

FILE: src/electionguard_gui/services/plaintext_ballot_service.py
  function get_plaintext_ballot_report (line 8) | def get_plaintext_ballot_report(
  function _get_tally_report (line 22) | def _get_tally_report(
  function _get_contest_details (line 46) | def _get_contest_details(
  function _get_selection_parties (line 80) | def _get_selection_parties(manifest: Manifest) -> dict[str, str]:
  function _get_candidate_write_ins (line 98) | def _get_candidate_write_ins(manifest: Manifest) -> dict[str, bool]:
  function _get_selections_report (line 115) | def _get_selections_report(

FILE: src/electionguard_gui/services/service_base.py
  class ServiceBase (line 4) | class ServiceBase(ABC):
    method init (line 7) | def init(self) -> None:
    method expose (line 10) | def expose(self) -> None:

FILE: src/electionguard_gui/services/version_service.py
  class VersionService (line 9) | class VersionService(ServiceBase):
    method __init__ (line 14) | def __init__(self, log_service: EelLogService) -> None:
    method expose (line 17) | def expose(self) -> None:
    method get_version (line 20) | def get_version(self) -> Optional[str]:

FILE: src/electionguard_gui/start.py
  function run (line 4) | def run() -> None:

FILE: src/electionguard_gui/web/components/admin/admin-home-component.js
  method data (line 9) | data() {
  method mounted (line 15) | async mounted() {

FILE: src/electionguard_gui/web/components/admin/create-decryption-component.js
  method data (line 9) | data() {
  method createDecryption (line 17) | async createDecryption() {
  method mounted (line 34) | async mounted() {

FILE: src/electionguard_gui/web/components/admin/create-election-component.js
  method data (line 5) | data() {
  method createElection (line 18) | async createElection() {
  method keyChanged (line 44) | keyChanged() {
  method mounted (line 50) | async mounted() {

FILE: src/electionguard_gui/web/components/admin/create-key-ceremony-component.js
  method data (line 8) | data() {
  method startCeremony (line 18) | startCeremony() {

FILE: src/electionguard_gui/web/components/admin/export-election-record-component.js
  method data (line 9) | data() {
  method exportRecord (line 19) | async exportRecord() {
  method mounted (line 39) | async mounted() {

FILE: src/electionguard_gui/web/components/admin/export-encryption-package-component.js
  method data (line 9) | data() {
  method exportPackage (line 19) | async exportPackage() {
  method mounted (line 37) | async mounted() {

FILE: src/electionguard_gui/web/components/admin/upload-ballots-component.js
  method data (line 13) | data() {
  method mounted (line 22) | async mounted() {

FILE: src/electionguard_gui/web/components/admin/upload-ballots-legacy-component.js
  method data (line 10) | data() {
  method uploadBallots (line 22) | async uploadBallots() {
  method uploadDeviceFile (line 44) | async uploadDeviceFile() {
  method uploadBallotFiles (line 59) | async uploadBallotFiles(uploadId, ballotFiles) {
  method mounted (line 99) | mounted() {

FILE: src/electionguard_gui/web/components/admin/upload-ballots-wizard-component.js
  method data (line 9) | data() {
  method mounted (line 77) | async mounted() {

FILE: src/electionguard_gui/web/components/admin/view-decryption-admin-component.js
  method data (line 9) | data() {
  method mounted (line 65) | async mounted() {
  method unmounted (line 75) | unmounted() {

FILE: src/electionguard_gui/web/components/admin/view-election-component.js
  method data (line 9) | data() {
  method mounted (line 44) | async mounted() {

FILE: src/electionguard_gui/web/components/admin/view-spoiled-ballot-component.js
  method data (line 11) | data() {
  method mounted (line 24) | async mounted() {

FILE: src/electionguard_gui/web/components/admin/view-tally-component.js
  method data (line 10) | data() {
  method mounted (line 23) | async mounted() {

FILE: src/electionguard_gui/web/components/guardian/decryption-list-component.js
  method data (line 7) | data() {

FILE: src/electionguard_gui/web/components/guardian/guardian-home-component.js
  method data (line 13) | data() {
  method mounted (line 64) | async mounted() {
  method unmounted (line 74) | unmounted() {

FILE: src/electionguard_gui/web/components/guardian/view-decryption-guardian-component.js
  method data (line 10) | data() {
  method mounted (line 56) | async mounted() {
  method unmounted (line 63) | unmounted() {

FILE: src/electionguard_gui/web/components/shared/election-list-component.js
  method data (line 5) | data() {
  method mounted (line 19) | async mounted() {

FILE: src/electionguard_gui/web/components/shared/footer-component.js
  method data (line 2) | data() {
  method mounted (line 7) | async mounted() {

FILE: src/electionguard_gui/web/components/shared/home-component.js
  method data (line 10) | data() {

FILE: src/electionguard_gui/web/components/shared/key-ceremony-details-component.js
  method data (line 8) | data() {
  method mounted (line 33) | mounted() {
  method unmounted (line 38) | unmounted() {

FILE: src/electionguard_gui/web/components/shared/key-ceremony-list-component.js
  method data (line 10) | data() {

FILE: src/electionguard_gui/web/components/shared/login-component.js
  method data (line 8) | data() {
  method createUser (line 14) | async createUser() {

FILE: src/electionguard_gui/web/js/vue.esm-browser.prod.js
  function e (line 1) | function e(e,t){const n=Object.create(null),o=e.split(",");for(let r=0;r...
  function o (line 1) | function o(e){return!!e||""===e}
  function r (line 1) | function r(e){if(E(e)){const t={};for(let n=0;n<e.length;n++){const o=e[...
  function l (line 1) | function l(e){const t={};return e.split(s).forEach((e=>{if(e){const n=e....
  function c (line 1) | function c(e){let t="";if(P(e))t=e;else if(E(e))for(let n=0;n<e.length;n...
  function a (line 1) | function a(e){if(!e)return null;let{class:t,style:n}=e;return t&&!P(t)&&...
  function d (line 1) | function d(e,t){if(e===t)return!0;let n=R(e),o=R(t);if(n||o)return!(!n||...
  function h (line 1) | function h(e,t){return e.findIndex((e=>d(e,t)))}
  class ne (line 1) | class ne{constructor(e=!1){this.active=!0,this.effects=[],this.cleanups=...
    method constructor (line 1) | constructor(e=!1){this.active=!0,this.effects=[],this.cleanups=[],!e&&...
    method run (line 1) | run(e){if(this.active){const t=te;try{return te=this,e()}finally{te=t}}}
    method on (line 1) | on(){te=this}
    method off (line 1) | off(){te=this.parent}
    method stop (line 1) | stop(e){if(this.active){let t,n;for(t=0,n=this.effects.length;t<n;t++)...
  function oe (line 1) | function oe(e){return new ne(e)}
  function re (line 1) | function re(e,t=te){t&&t.active&&t.effects.push(e)}
  function se (line 1) | function se(){return te}
  function ie (line 1) | function ie(e){te&&te.cleanups.push(e)}
  class ge (line 1) | class ge{constructor(e,t=null,n){this.fn=e,this.scheduler=t,this.active=...
    method constructor (line 1) | constructor(e,t=null,n){this.fn=e,this.scheduler=t,this.active=!0,this...
    method run (line 1) | run(){if(!this.active)return this.fn();let e=de,t=be;for(;e;){if(e===t...
    method stop (line 1) | stop(){de===this?this.deferStop=!0:this.active&&(ve(this),this.onStop&...
  function ve (line 1) | function ve(e){const{deps:t}=e;if(t.length){for(let n=0;n<t.length;n++)t...
  function ye (line 1) | function ye(e,t){e.effect&&(e=e.effect.fn);const n=new ge(e);t&&(w(n,t),...
  function _e (line 1) | function _e(e){e.effect.stop()}
  function xe (line 1) | function xe(){Se.push(be),be=!1}
  function Ce (line 1) | function Ce(){const e=Se.pop();be=void 0===e||e}
  function we (line 1) | function we(e,t,n){if(be&&de){let t=ue.get(e);t||ue.set(e,t=new Map);let...
  function ke (line 1) | function ke(e,t){let n=!1;pe<=30?ae(e)||(e.n|=fe,n=!ce(e)):n=!e.has(de),...
  function Te (line 1) | function Te(e,t,n,o,r,s){const i=ue.get(e);if(!i)return;let l=[];if("cle...
  function Ne (line 1) | function Ne(e,t){const n=E(e)?e:[...e];for(const o of n)o.computed&&Ee(o...
  function Ee (line 1) | function Ee(e,t){(e!==de||e.allowRecurse)&&(e.scheduler?e.scheduler():e....
  function Ve (line 1) | function Ve(){const e={};return["includes","indexOf","lastIndexOf"].forE...
  function Ie (line 1) | function Ie(e=!1,t=!1){return function(n,o,r){if("__v_isReactive"===o)re...
  function Be (line 1) | function Be(e=!1){return function(t,n,o,r){let s=t[n];if(xt(s)&&Rt(s)&&!...
  function ze (line 1) | function ze(e,t,n=!1,o=!1){const r=kt(e=e.__v_raw),s=kt(t);n||(t!==s&&we...
  function Ke (line 1) | function Ke(e,t=!1){const n=this.__v_raw,o=kt(n),r=kt(e);return t||(e!==...
  function Ge (line 1) | function Ge(e,t=!1){return e=e.__v_raw,!t&&we(kt(e),0,he),Reflect.get(e,...
  function qe (line 1) | function qe(e){e=kt(e);const t=kt(this);return We(t).has.call(t,e)||(t.a...
  function Je (line 1) | function Je(e,t){t=kt(t);const n=kt(this),{has:o,get:r}=We(n);let s=o.ca...
  function Ye (line 1) | function Ye(e){const t=kt(this),{has:n,get:o}=We(t);let r=n.call(t,e);r|...
  function Ze (line 1) | function Ze(){const e=kt(this),t=0!==e.size,n=e.clear();return t&&Te(e,"...
  function Qe (line 1) | function Qe(e,t){return function(n,o){const r=this,s=r.__v_raw,i=kt(s),l...
  function Xe (line 1) | function Xe(e,t,n){return function(...o){const r=this.__v_raw,s=kt(r),i=...
  function et (line 1) | function et(e){return function(...t){return"delete"!==e&&this}}
  function tt (line 1) | function tt(){const e={get(e){return ze(this,e)},get size(){return Ge(th...
  function it (line 1) | function it(e,t){const n=t?e?st:rt:e?ot:nt;return(t,o,r)=>"__v_isReactiv...
  function mt (line 1) | function mt(e){return e.__v_skip||!Object.isExtensible(e)?0:function(e){...
  function gt (line 1) | function gt(e){return xt(e)?e:bt(e,!1,Le,lt,pt)}
  function vt (line 1) | function vt(e){return bt(e,!1,Ue,ct,ft)}
  function yt (line 1) | function yt(e){return bt(e,!0,je,at,dt)}
  function _t (line 1) | function _t(e){return bt(e,!0,De,ut,ht)}
  function bt (line 1) | function bt(e,t,n,o,r){if(!M(e))return e;if(e.__v_raw&&(!t||!e.__v_isRea...
  function St (line 1) | function St(e){return xt(e)?St(e.__v_raw):!(!e||!e.__v_isReactive)}
  function xt (line 1) | function xt(e){return!(!e||!e.__v_isReadonly)}
  function Ct (line 1) | function Ct(e){return!(!e||!e.__v_isShallow)}
  function wt (line 1) | function wt(e){return St(e)||xt(e)}
  function kt (line 1) | function kt(e){const t=e&&e.__v_raw;return t?kt(t):e}
  function Tt (line 1) | function Tt(e){return Q(e,"__v_skip",!0),e}
  function $t (line 1) | function $t(e){be&&de&&ke((e=kt(e)).dep||(e.dep=le()))}
  function Ot (line 1) | function Ot(e,t){(e=kt(e)).dep&&Ne(e.dep)}
  function Rt (line 1) | function Rt(e){return!(!e||!0!==e.__v_isRef)}
  function Ft (line 1) | function Ft(e){return At(e,!1)}
  function Pt (line 1) | function Pt(e){return At(e,!0)}
  function At (line 1) | function At(e,t){return Rt(e)?e:new Mt(e,t)}
  class Mt (line 1) | class Mt{constructor(e,t){this.__v_isShallow=t,this.dep=void 0,this.__v_...
    method constructor (line 1) | constructor(e,t){this.__v_isShallow=t,this.dep=void 0,this.__v_isRef=!...
    method value (line 1) | get value(){return $t(this),this._value}
    method value (line 1) | set value(e){e=this.__v_isShallow?e:kt(e),Y(e,this._rawValue)&&(this._...
  function Vt (line 1) | function Vt(e){Ot(e)}
  function It (line 1) | function It(e){return Rt(e)?e.value:e}
  function Lt (line 1) | function Lt(e){return St(e)?e:new Proxy(e,Bt)}
  class jt (line 1) | class jt{constructor(e){this.dep=void 0,this.__v_isRef=!0;const{get:t,se...
    method constructor (line 1) | constructor(e){this.dep=void 0,this.__v_isRef=!0;const{get:t,set:n}=e(...
    method value (line 1) | get value(){return this._get()}
    method value (line 1) | set value(e){this._set(e)}
  function Ut (line 1) | function Ut(e){return new jt(e)}
  function Dt (line 1) | function Dt(e){const t=E(e)?new Array(e.length):{};for(const n in e)t[n]...
  class Ht (line 1) | class Ht{constructor(e,t,n){this._object=e,this._key=t,this._defaultValu...
    method constructor (line 1) | constructor(e,t,n){this._object=e,this._key=t,this._defaultValue=n,thi...
    method value (line 1) | get value(){const e=this._object[this._key];return void 0===e?this._de...
    method value (line 1) | set value(e){this._object[this._key]=e}
  function Wt (line 1) | function Wt(e,t,n){const o=e[t];return Rt(o)?o:new Ht(e,t,n)}
  class zt (line 1) | class zt{constructor(e,t,n,o){this._setter=t,this.dep=void 0,this.__v_is...
    method constructor (line 1) | constructor(e,t,n,o){this._setter=t,this.dep=void 0,this.__v_isRef=!0,...
    method value (line 1) | get value(){const e=kt(this);return $t(e),!e._dirty&&e._cacheable||(e....
    method value (line 1) | set value(e){this._setter(e)}
  function Gt (line 1) | function Gt(e,...t){xe();const n=Kt.length?Kt[Kt.length-1].component:nul...
  function qt (line 1) | function qt(e){const t=[],n=Object.keys(e);return n.slice(0,3).forEach((...
  function Jt (line 1) | function Jt(e,t,n){return P(t)?(t=JSON.stringify(t),n?t:[`${e}=${t}`]):"...
  function Yt (line 1) | function Yt(e,t,n,o){let r;try{r=o?e(...o):e()}catch(s){Qt(s,t,n)}return r}
  function Zt (line 1) | function Zt(e,t,n,o){if(F(e)){const r=Yt(e,t,n,o);return r&&V(r)&&r.catc...
  function Qt (line 1) | function Qt(e,t,n,o=!0){if(t){let o=t.parent;const r=t.proxy,s=n;for(;o;...
  function dn (line 1) | function dn(e){const t=pn||un;return e?t.then(this?e.bind(this):e):t}
  function hn (line 1) | function hn(e){tn.length&&tn.includes(e,Xt&&e.allowRecurse?nn+1:nn)||e==...
  function mn (line 1) | function mn(){Xt||en||(en=!0,pn=un.then(Sn))}
  function gn (line 1) | function gn(e,t,n,o){E(e)?n.push(...e):t&&t.includes(e,e.allowRecurse?o+...
  function vn (line 1) | function vn(e){gn(e,cn,ln,an)}
  function yn (line 1) | function yn(e,t=null){if(on.length){for(fn=t,rn=[...new Set(on)],on.leng...
  function _n (line 1) | function _n(e){if(yn(),ln.length){const e=[...new Set(ln)];if(ln.length=...
  function Sn (line 1) | function Sn(e){en=!1,Xt=!0,yn(e),tn.sort(((e,t)=>bn(e)-bn(t)));try{for(n...
  function wn (line 1) | function wn(e,t){var n,o;if(xn=e,xn)xn.enabled=!0,Cn.forEach((({event:e,...
  function kn (line 1) | function kn(e,t,...n){if(e.isUnmounted)return;const o=e.vnode.props||v;l...
  function Tn (line 1) | function Tn(e,t,n=!1){const o=t.emitsCache,r=o.get(e);if(void 0!==r)retu...
  function Nn (line 1) | function Nn(e,t){return!(!e||!x(t))&&(t=t.slice(2).replace(/Once$/,""),N...
  function On (line 1) | function On(e){const t=En;return En=e,$n=e&&e.type.__scopeId||null,t}
  function Rn (line 1) | function Rn(e){$n=e}
  function Fn (line 1) | function Fn(){$n=null}
  function An (line 1) | function An(e,t=En,n){if(!t)return e;if(e._n)return e;const o=(...n)=>{o...
  function Mn (line 1) | function Mn(e){const{type:t,vnode:n,proxy:o,withProxy:r,props:s,propsOpt...
  function Bn (line 1) | function Bn(e,t,n){const o=Object.keys(t);if(o.length!==Object.keys(e).l...
  function Ln (line 1) | function Ln({vnode:e,parent:t},n){for(;t&&t.subTree===e;)(e=t.vnode).el=...
  method process (line 1) | process(e,t,n,o,r,s,i,l,c,a){null==e?function(e,t,n,o,r,s,i,l,c){const{p...
  function Dn (line 1) | function Dn(e,t){const n=e.props&&e.props[t];F(n)&&n()}
  function Hn (line 1) | function Hn(e,t,n,o,r,s,i,l,c,a,u=!1){const{p:p,m:f,um:d,n:h,o:{parentNo...
  function Wn (line 1) | function Wn(e){let t;if(F(e)){const n=Qr&&e._c;n&&(e._d=!1,Yr()),e=e(),n...
  function zn (line 1) | function zn(e,t){t&&t.pendingBranch?E(e)?t.effects.push(...e):t.effects....
  function Kn (line 1) | function Kn(e,t){e.activeBranch=t;const{vnode:n,parentComponent:o}=e,r=n...
  function Gn (line 1) | function Gn(e,t){if(Cs){let n=Cs.provides;const o=Cs.parent&&Cs.parent.p...
  function qn (line 1) | function qn(e,t,n=!1){const o=Cs||En;if(o){const r=null==o.parent?o.vnod...
  function Jn (line 1) | function Jn(e,t){return eo(e,null,t)}
  function Yn (line 1) | function Yn(e,t){return eo(e,null,{flush:"post"})}
  function Zn (line 1) | function Zn(e,t){return eo(e,null,{flush:"sync"})}
  function Xn (line 1) | function Xn(e,t,n){return eo(e,t,n)}
  function eo (line 1) | function eo(e,t,{immediate:n,deep:o,flush:r}=v){const s=Cs;let i,l,c=!1,...
  function to (line 1) | function to(e,t,n){const o=this.proxy,r=P(e)?e.includes(".")?no(o,e):()=...
  function no (line 1) | function no(e,t){const n=t.split(".");return()=>{let t=e;for(let e=0;e<n...
  function oo (line 1) | function oo(e,t){if(!M(e)||e.__v_skip)return e;if((t=t||new Set).has(e))...
  function ro (line 1) | function ro(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leaving...
  method setup (line 1) | setup(e,{slots:t}){const n=ws(),o=ro();let r;return()=>{const s=t.defaul...
  function lo (line 1) | function lo(e,t){const{leavingVNodes:n}=e;let o=n.get(t.type);return o||...
  function co (line 1) | function co(e,t,n,o){const{appear:r,mode:s,persisted:i=!1,onBeforeEnter:...
  function ao (line 1) | function ao(e){if(yo(e))return(e=fs(e)).children=null,e}
  function uo (line 1) | function uo(e){return yo(e)?e.children?e.children[0]:void 0:e}
  function po (line 1) | function po(e,t){6&e.shapeFlag&&e.component?po(e.component.subTree,t):12...
  function fo (line 1) | function fo(e,t=!1,n){let o=[],r=0;for(let s=0;s<e.length;s++){let i=e[s...
  function ho (line 1) | function ho(e){return F(e)?{setup:e,name:e.name}:e}
  function go (line 1) | function go(e){F(e)&&(e={loader:e});const{loader:t,loadingComponent:n,er...
  function vo (line 1) | function vo(e,{vnode:{ref:t,props:n,children:o}}){const r=us(e,n,o);retu...
  method setup (line 1) | setup(e,{slots:t}){const n=ws(),o=n.ctx,r=new Map,s=new Set;let i=null;c...
  function bo (line 1) | function bo(e,t){return E(e)?e.some((e=>bo(e,t))):P(e)?e.split(",").incl...
  function So (line 1) | function So(e,t){Co(e,"a",t)}
  function xo (line 1) | function xo(e,t){Co(e,"da",t)}
  function Co (line 1) | function Co(e,t,n=Cs){const o=e.__wdc||(e.__wdc=()=>{let t=n;for(;t;){if...
  function wo (line 1) | function wo(e,t,n,o){const r=No(t,e,o,!0);Ao((()=>{k(o[t],r)}),n)}
  function ko (line 1) | function ko(e){let t=e.shapeFlag;256&t&&(t-=256),512&t&&(t-=512),e.shape...
  function To (line 1) | function To(e){return 128&e.shapeFlag?e.ssContent:e}
  function No (line 1) | function No(e,t,n=Cs,o=!1){if(n){const r=n[e]||(n[e]=[]),s=t.__weh||(t._...
  function Bo (line 1) | function Bo(e,t=Cs){No("ec",e,t)}
  function Lo (line 1) | function Lo(e,t){const n=En;if(null===n)return e;const o=Vs(n)||n.proxy,...
  function jo (line 1) | function jo(e,t,n,o){const r=e.dirs,s=t&&t.dirs;for(let i=0;i<r.length;i...
  function Uo (line 1) | function Uo(e,t){return zo("components",e,!0,t)||e}
  function Ho (line 1) | function Ho(e){return P(e)?zo("components",e,!1)||e:e||Do}
  function Wo (line 1) | function Wo(e){return zo("directives",e)}
  function zo (line 1) | function zo(e,t,n=!0,o=!1){const r=En||Cs;if(r){const n=r.type;if("compo...
  function Ko (line 1) | function Ko(e,t){return e&&(e[t]||e[z(t)]||e[q(z(t))])}
  function Go (line 1) | function Go(e,t,n,o){let r;const s=n&&n[o];if(E(e)||P(e)){r=new Array(e....
  function qo (line 1) | function qo(e,t){for(let n=0;n<t.length;n++){const o=t[n];if(E(o))for(le...
  function Jo (line 1) | function Jo(e,t,n={},o,r){if(En.isCE||En.parent&&mo(En.parent)&&En.paren...
  function Yo (line 1) | function Yo(e){return e.some((e=>!os(e)||e.type!==Kr&&!(e.type===Wr&&!Yo...
  function Zo (line 1) | function Zo(e){const t={};for(const n in e)t[J(n)]=e[n];return t}
  method get (line 1) | get({_:e},t){const{ctx:n,setupState:o,data:r,props:s,accessCache:i,type:...
  method set (line 1) | set({_:e},t,n){const{data:o,setupState:r,ctx:s}=e;return r!==v&&N(r,t)?(...
  method has (line 1) | has({_:{data:e,setupState:t,accessCache:n,ctx:o,appContext:r,propsOption...
  method defineProperty (line 1) | defineProperty(e,t,n){return null!=n.get?e._.accessCache[t]=0:N(n,"value...
  method get (line 1) | get(e,t){if(t!==Symbol.unscopables)return er.get(e,t,e)}
  function or (line 1) | function or(e){const t=ir(e),n=e.proxy,o=e.ctx;nr=!1,t.beforeCreate&&rr(...
  function rr (line 1) | function rr(e,t,n){Zt(E(e)?e.map((e=>e.bind(t.proxy))):e.bind(t.proxy),t...
  function sr (line 1) | function sr(e,t,n,o){const r=o.includes(".")?no(n,o):()=>n[o];if(P(e)){c...
  function ir (line 1) | function ir(e){const t=e.type,{mixins:n,extends:o}=t,{mixins:r,optionsCa...
  function lr (line 1) | function lr(e,t,n,o=!1){const{mixins:r,extends:s}=t;s&&lr(e,s,n,!0),r&&r...
  function ar (line 1) | function ar(e,t){return t?e?function(){return w(F(e)?e.call(this,this):e...
  function ur (line 1) | function ur(e){if(E(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[...
  function pr (line 1) | function pr(e,t){return e?[...new Set([].concat(e,t))]:t}
  function fr (line 1) | function fr(e,t){return e?w(w(Object.create(null),e),t):t}
  function dr (line 1) | function dr(e,t,n,o){const[r,s]=e.propsOptions;let i,l=!1;if(t)for(let c...
  function hr (line 1) | function hr(e,t,n,o,r,s){const i=e[n];if(null!=i){const e=N(i,"default")...
  function mr (line 1) | function mr(e,t,n=!1){const o=t.propsCache,r=o.get(e);if(r)return r;cons...
  function gr (line 1) | function gr(e){return"$"!==e[0]}
  function vr (line 1) | function vr(e){const t=e&&e.toString().match(/^\s*function (\w+)/);retur...
  function yr (line 1) | function yr(e,t){return vr(e)===vr(t)}
  function _r (line 1) | function _r(e,t){return E(t)?t.findIndex((t=>yr(t,e))):F(t)&&yr(t,e)?0:-1}
  function kr (line 1) | function kr(){return{app:null,config:{isNativeTag:b,performance:!1,globa...
  function Nr (line 1) | function Nr(e,t){return function(n,o=null){F(n)||(n=Object.assign({},n))...
  function Er (line 1) | function Er(e,t,n,o,r=!1){if(E(e))return void e.forEach(((e,s)=>Er(e,t&&...
  function Fr (line 1) | function Fr(e){const{mt:t,p:n,o:{patchProp:o,createText:r,nextSibling:s,...
  function Ar (line 1) | function Ar(e){return Vr(e)}
  function Mr (line 1) | function Mr(e){return Vr(e,Fr)}
  function Vr (line 1) | function Vr(e,t){(ee||(ee="undefined"!=typeof globalThis?globalThis:"und...
  function Ir (line 1) | function Ir({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}
  function Br (line 1) | function Br(e,t,n=!1){const o=e.children,r=t.children;if(E(o)&&E(r))for(...
  function Dr (line 1) | function Dr(e,t,n,{o:{insert:o},m:r},s=2){0===s&&o(e.targetAnchor,t,n);c...
  method process (line 1) | process(e,t,n,o,r,s,i,l,c,a){const{mc:u,pc:p,pbc:f,o:{insert:d,querySele...
  method remove (line 1) | remove(e,t,n,o,{um:r,o:{remove:s}},i){const{shapeFlag:l,children:c,ancho...
  function Yr (line 1) | function Yr(e=!1){qr.push(Jr=e?null:[])}
  function Zr (line 1) | function Zr(){qr.pop(),Jr=qr[qr.length-1]||null}
  function Xr (line 1) | function Xr(e){Qr+=e}
  function es (line 1) | function es(e){return e.dynamicChildren=Qr>0?Jr||y:null,Zr(),Qr>0&&Jr&&J...
  function ts (line 1) | function ts(e,t,n,o,r,s){return es(as(e,t,n,o,r,s,!0))}
  function ns (line 1) | function ns(e,t,n,o,r){return es(us(e,t,n,o,r,!0))}
  function os (line 1) | function os(e){return!!e&&!0===e.__v_isVNode}
  function rs (line 1) | function rs(e,t){return e.type===t.type&&e.key===t.key}
  function ss (line 1) | function ss(e){}
  function as (line 1) | function as(e,t=null,n=null,o=0,r=null,s=(e===Wr?0:1),i=!1,l=!1){const c...
  function ps (line 1) | function ps(e){return e?wt(e)||is in e?w({},e):e:null}
  function fs (line 1) | function fs(e,t,n=!1){const{props:o,ref:r,patchFlag:s,children:i}=e,l=t?...
  function ds (line 1) | function ds(e=" ",t=0){return us(zr,null,e,t)}
  function hs (line 1) | function hs(e,t){const n=us(Gr,null,e);return n.staticCount=t,n}
  function ms (line 1) | function ms(e="",t=!1){return t?(Yr(),ns(Kr,null,e)):us(Kr,null,e)}
  function gs (line 1) | function gs(e){return null==e||"boolean"==typeof e?us(Kr):E(e)?us(Wr,nul...
  function vs (line 1) | function vs(e){return null===e.el||e.memo?e:fs(e)}
  function ys (line 1) | function ys(e,t){let n=0;const{shapeFlag:o}=e;if(null==t)t=null;else if(...
  function _s (line 1) | function _s(...e){const t={};for(let n=0;n<e.length;n++){const o=e[n];fo...
  function bs (line 1) | function bs(e,t,n,o=null){Zt(e,t,7,[n,o])}
  function Ns (line 1) | function Ns(e){return 4&e.vnode.shapeFlag}
  function Rs (line 1) | function Rs(e,t,n){F(t)?e.render=t:M(t)&&(e.setupState=Lt(t)),As(e,n)}
  function Fs (line 1) | function Fs(e){Es=e,$s=e=>{e.render._rc&&(e.withProxy=new Proxy(e.ctx,tr...
  function As (line 1) | function As(e,t,n){const o=e.type;if(!e.render){if(!t&&Es&&!o.render){co...
  function Ms (line 1) | function Ms(e){const t=t=>{e.exposed=t||{}};let n;return{get attrs(){ret...
  function Vs (line 1) | function Vs(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Pro...
  function Bs (line 1) | function Bs(e,t=!0){return F(e)?e.displayName||e.name:e.name||t&&e.__name}
  function Ls (line 1) | function Ls(e,t,n=!1){let o=Bs(t);if(!o&&t.__file){const e=t.__file.matc...
  function Us (line 1) | function Us(){return null}
  function Ds (line 1) | function Ds(){return null}
  function Hs (line 1) | function Hs(e){}
  function Ws (line 1) | function Ws(e,t){return null}
  function zs (line 1) | function zs(){return Gs().slots}
  function Ks (line 1) | function Ks(){return Gs().attrs}
  function Gs (line 1) | function Gs(){const e=ws();return e.setupContext||(e.setupContext=Ms(e))}
  function qs (line 1) | function qs(e,t){const n=E(e)?e.reduce(((e,t)=>(e[t]={},e)),{}):e;for(co...
  function Js (line 1) | function Js(e,t){const n={};for(const o in e)t.includes(o)||Object.defin...
  function Ys (line 1) | function Ys(e){const t=ws();let n=e();return Ts(),V(n)&&(n=n.catch((e=>{...
  function Zs (line 1) | function Zs(e,t,n){const o=arguments.length;return 2===o?M(t)&&!E(t)?os(...
  function ei (line 1) | function ei(){}
  function ti (line 1) | function ti(e,t,n,o){const r=n[o];if(r&&ni(r,e))return r;const s=t();ret...
  function ni (line 1) | function ni(e,t){const n=e.memo;if(n.length!=t.length)return!1;for(let o...
  method setScopeId (line 1) | setScopeId(e,t){e.setAttribute(t,"")}
  method cloneNode (line 1) | cloneNode(e){const t=e.cloneNode(!0);return"_value"in e&&(t._value=e._va...
  method insertStaticContent (line 1) | insertStaticContent(e,t,n,o,r,s){const i=n?n.previousSibling:t.lastChild...
  function pi (line 1) | function pi(e,t,n){if(E(n))n.forEach((n=>pi(e,t,n)));else if(null==n&&(n...
  function bi (line 1) | function bi(e,t,n,o){e.addEventListener(t,n,o)}
  function Si (line 1) | function Si(e,t,n,o,r=null){const s=e._vei||(e._vei={}),i=s[t];if(o&&i)i...
  function wi (line 1) | function wi(e,t){const n=ho(e);class o extends Ni{constructor(e){super(n...
  class Ni (line 1) | class Ni extends Ti{constructor(e,t={},n){super(),this._def=e,this._prop...
    method constructor (line 1) | constructor(e,t={},n){super(),this._def=e,this._props=t,this._instance...
    method connectedCallback (line 1) | connectedCallback(){this._connected=!0,this._instance||this._resolveDe...
    method disconnectedCallback (line 1) | disconnectedCallback(){this._connected=!1,dn((()=>{this._connected||(k...
    method _resolveDef (line 1) | _resolveDef(){if(this._resolved)return;this._resolved=!0;for(let n=0;n...
    method _setAttr (line 1) | _setAttr(e){let t=this.getAttribute(e);this._numberProps&&this._number...
    method _getProp (line 1) | _getProp(e){return this._props[e]}
    method _setProp (line 1) | _setProp(e,t,n=!0,o=!0){t!==this._props[e]&&(this._props[e]=t,o&&this....
    method _update (line 1) | _update(){kl(this._createVNode(),this.shadowRoot)}
    method _createVNode (line 1) | _createVNode(){const e=us(this._def,w({},this._props));return this._in...
    method _applyStyles (line 1) | _applyStyles(e){e&&e.forEach((e=>{const t=document.createElement("styl...
  function Ei (line 1) | function Ei(e="$style"){{const t=ws();if(!t)return v;const n=t.type.__cs...
  function $i (line 1) | function $i(e){const t=ws();if(!t)return;const n=()=>Oi(t.subTree,e(t.pr...
  function Oi (line 1) | function Oi(e,t){if(128&e.shapeFlag){const n=e.suspense;e=n.activeBranch...
  function Ri (line 1) | function Ri(e,t){if(1===e.nodeType){const n=e.style;for(const e in t)n.s...
  function Ii (line 1) | function Ii(e){const t={};for(const w in e)w in Pi||(t[w]=e[w]);if(!1===...
  function Bi (line 1) | function Bi(e){return X(e)}
  function Li (line 1) | function Li(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.add(t))),(e._...
  function ji (line 1) | function ji(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.remove(t)));c...
  function Ui (line 1) | function Ui(e){requestAnimationFrame((()=>{requestAnimationFrame(e)}))}
  function Hi (line 1) | function Hi(e,t,n,o){const r=e._endId=++Di,s=()=>{r===e._endId&&o()};if(...
  function Wi (line 1) | function Wi(e,t){const n=window.getComputedStyle(e),o=e=>(n[e]||"").spli...
  function zi (line 1) | function zi(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(....
  function Ki (line 1) | function Ki(e){return 1e3*Number(e.slice(0,-1).replace(",","."))}
  function Gi (line 1) | function Gi(){return document.body.offsetHeight}
  method setup (line 1) | setup(e,{slots:t}){const n=ws(),o=ro();let r,s;return Fo((()=>{if(!r.len...
  function Zi (line 1) | function Zi(e){const t=e.el;t._moveCb&&t._moveCb(),t._enterCb&&t._enterC...
  function Qi (line 1) | function Qi(e){Ji.set(e,e.el.getBoundingClientRect())}
  function Xi (line 1) | function Xi(e){const t=qi.get(e),n=Ji.get(e),o=t.left-n.left,r=t.top-n.t...
  function tl (line 1) | function tl(e){e.target.composing=!0}
  function nl (line 1) | function nl(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchE...
  method created (line 1) | created(e,{modifiers:{lazy:t,trim:n,number:o}},r){e._assign=el(r);const ...
  method mounted (line 1) | mounted(e,{value:t}){e.value=null==t?"":t}
  method beforeUpdate (line 1) | beforeUpdate(e,{value:t,modifiers:{lazy:n,trim:o,number:r}},s){if(e._ass...
  method created (line 1) | created(e,t,n){e._assign=el(n),bi(e,"change",(()=>{const t=e._modelValue...
  method beforeUpdate (line 1) | beforeUpdate(e,t,n){e._assign=el(n),sl(e,t,n)}
  function sl (line 1) | function sl(e,{value:t,oldValue:n},o){e._modelValue=t,E(t)?e.checked=h(t...
  method created (line 1) | created(e,{value:t},n){e.checked=d(t,n.props.value),e._assign=el(n),bi(e...
  method beforeUpdate (line 1) | beforeUpdate(e,{value:t,oldValue:n},o){e._assign=el(o),t!==n&&(e.checked...
  method created (line 1) | created(e,{value:t,modifiers:{number:n}},o){const r=O(t);bi(e,"change",(...
  method mounted (line 1) | mounted(e,{value:t}){cl(e,t)}
  method beforeUpdate (line 1) | beforeUpdate(e,t,n){e._assign=el(n)}
  method updated (line 1) | updated(e,{value:t}){cl(e,t)}
  function cl (line 1) | function cl(e,t){const n=e.multiple;if(!n||E(t)||O(t)){for(let o=0,r=e.o...
  function al (line 1) | function al(e){return"_value"in e?e._value:e.value}
  function ul (line 1) | function ul(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}
  method created (line 1) | created(e,t,n){fl(e,t,n,null,"created")}
  method mounted (line 1) | mounted(e,t,n){fl(e,t,n,null,"mounted")}
  method beforeUpdate (line 1) | beforeUpdate(e,t,n,o){fl(e,t,n,o,"beforeUpdate")}
  method updated (line 1) | updated(e,t,n,o){fl(e,t,n,o,"updated")}
  function fl (line 1) | function fl(e,t,n,o,r){const s=function(e,t){switch(e){case"SELECT":retu...
  method beforeMount (line 1) | beforeMount(e,{value:t},{transition:n}){e._vod="none"===e.style.display?...
  method mounted (line 1) | mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)}
  method updated (line 1) | updated(e,{value:t,oldValue:n},{transition:o}){!t!=!n&&(o?t?(o.beforeEnt...
  method beforeUnmount (line 1) | beforeUnmount(e,{value:t}){_l(e,t)}
  function _l (line 1) | function _l(e,t){e.style.display=t?e._vod:"none"}
  function Cl (line 1) | function Cl(){return Sl||(Sl=Ar(bl))}
  function wl (line 1) | function wl(){return Sl=xl?Sl:Mr(bl),xl=!0,Sl}
  function $l (line 1) | function $l(e){if(P(e)){return document.querySelector(e)}return e}
  method devtools (line 1) | get devtools(){return xn}
  function Fl (line 1) | function Fl(e){throw e}
  function Pl (line 1) | function Pl(e){}
  function Al (line 1) | function Al(e,t,n,o){const r=new SyntaxError(String(e));return r.code=e,...
  function xc (line 1) | function xc(e,t,n,o,r,s,i,l=!1,c=!1,a=!1,u=Sc){return e&&(l?(e.helper(jl...
  function Cc (line 1) | function Cc(e,t=Sc){return{type:17,loc:t,elements:e}}
  function wc (line 1) | function wc(e,t=Sc){return{type:15,loc:t,properties:e}}
  function kc (line 1) | function kc(e,t){return{type:16,loc:Sc,key:P(e)?Tc(e,!0):e,value:t}}
  function Tc (line 1) | function Tc(e,t=!1,n=Sc,o=0){return{type:4,loc:n,content:e,isStatic:t,co...
  function Nc (line 1) | function Nc(e,t=Sc){return{type:8,loc:t,children:e}}
  function Ec (line 1) | function Ec(e,t=[],n=Sc){return{type:14,loc:n,callee:e,arguments:t}}
  function $c (line 1) | function $c(e,t,n=!1,o=!1,r=Sc){return{type:18,params:e,returns:t,newlin...
  function Oc (line 1) | function Oc(e,t,n,o=!0){return{type:19,test:e,consequent:t,alternate:n,n...
  function Pc (line 1) | function Pc(e){return Fc(e,"Teleport")?Vl:Fc(e,"Suspense")?Il:Fc(e,"Keep...
  function jc (line 1) | function jc(e,t,n){const o={source:e.source.slice(t,t+n),start:Uc(e.star...
  function Uc (line 1) | function Uc(e,t,n=t.length){return Dc(w({},e),t,n)}
  function Dc (line 1) | function Dc(e,t,n=t.length){let o=0,r=-1;for(let s=0;s<n;s++)10===t.char...
  function Hc (line 1) | function Hc(e,t,n=!1){for(let o=0;o<e.props.length;o++){const r=e.props[...
  function Wc (line 1) | function Wc(e,t,n=!1,o=!1){for(let r=0;r<e.props.length;r++){const s=e.p...
  function zc (line 1) | function zc(e,t){return!(!e||!Rc(e)||e.content!==t)}
  function Kc (line 1) | function Kc(e){return 5===e.type||2===e.type}
  function Gc (line 1) | function Gc(e){return 7===e.type&&"slot"===e.name}
  function qc (line 1) | function qc(e){return 1===e.type&&3===e.tagType}
  function Jc (line 1) | function Jc(e){return 1===e.type&&2===e.tagType}
  function Yc (line 1) | function Yc(e,t){return e||t?Hl:Wl}
  function Zc (line 1) | function Zc(e,t){return e||t?Ul:Dl}
  function Xc (line 1) | function Xc(e,t=[]){if(e&&!P(e)&&14===e.type){const n=e.callee;if(!P(n)&...
  function ea (line 1) | function ea(e,t,n){let o,r,s=13===e.type?e.props:e.arguments[2],i=[];if(...
  function ta (line 1) | function ta(e,t){return`_${t}_${e.replace(/[^\w]/g,((t,n)=>"-"===t?"_":e...
  function na (line 1) | function na(e,{helper:t,removeHelper:n,inSSR:o}){e.isBlock||(e.isBlock=!...
  function ia (line 1) | function ia(e,t={}){const n=function(e,t){const n=w({},sa);let o;for(o i...
  function la (line 1) | function la(e,t,n){const o=xa(n),r=o?o.ns:0,s=[];for(;!Na(e,t,n);){const...
  function ca (line 1) | function ca(e,t){if(2===t.type){const n=xa(e);if(n&&2===n.type&&n.loc.en...
  function aa (line 1) | function aa(e,t){wa(e,9);const n=la(e,3,t);return 0===e.source.length||w...
  function ua (line 1) | function ua(e){const t=ba(e);let n;const o=/--(\!)?>/.exec(e.source);if(...
  function pa (line 1) | function pa(e){const t=ba(e),n="?"===e.source[1]?1:2;let o;const r=e.sou...
  function fa (line 1) | function fa(e,t){const n=e.inPre,o=e.inVPre,r=xa(t),s=ha(e,0,r),i=e.inPr...
  function ha (line 1) | function ha(e,t,n){const o=ba(e),r=/^<\/?([a-z][^\t\r\n\f />]*)/i.exec(e...
  function ma (line 1) | function ma(e,t){const n=[],o=new Set;for(;e.source.length>0&&!Ca(e.sour...
  function ga (line 1) | function ga(e,t){const n=ba(e),o=/^[^\t\r\n\f />][^\t\r\n\f />=]*/.exec(...
  function va (line 1) | function va(e,t){const[n,o]=e.options.delimiters,r=e.source.indexOf(o,n....
  function ya (line 1) | function ya(e,t){const n=3===t?["]]>"]:["<",e.options.delimiters[0]];let...
  function _a (line 1) | function _a(e,t,n){const o=e.source.slice(0,t);return wa(e,t),2!==n&&3!=...
  function ba (line 1) | function ba(e){const{column:t,line:n,offset:o}=e;return{column:t,line:n,...
  function Sa (line 1) | function Sa(e,t,n){return{start:t,end:n=n||ba(e),source:e.originalSource...
  function xa (line 1) | function xa(e){return e[e.length-1]}
  function Ca (line 1) | function Ca(e,t){return e.startsWith(t)}
  function wa (line 1) | function wa(e,t){const{source:n}=e;Dc(e,n,t),e.source=n.slice(t)}
  function ka (line 1) | function ka(e){const t=/^[\t\r\n\f ]+/.exec(e.source);t&&wa(e,t[0].length)}
  function Ta (line 1) | function Ta(e,t,n){return Uc(t,e.originalSource.slice(t.offset,n),n)}
  function Na (line 1) | function Na(e,t,n){const o=e.source;switch(t){case 0:if(Ca(o,"</"))for(l...
  function Ea (line 1) | function Ea(e,t){return Ca(e,"</")&&e.slice(2,2+t.length).toLowerCase()=...
  function $a (line 1) | function $a(e,t){Ra(e,t,Oa(e,e.children[0]))}
  function Oa (line 1) | function Oa(e,t){const{children:n}=e;return 1===n.length&&1===t.type&&!J...
  function Ra (line 1) | function Ra(e,t,n=!1){const{children:o}=e,r=o.length;let s=0;for(let i=0...
  function Fa (line 1) | function Fa(e,t){const{constantCache:n}=t;switch(e.type){case 1:if(0!==e...
  function Aa (line 1) | function Aa(e,t){if(14===e.type&&!P(e.callee)&&Pa.has(e.callee)){const n...
  function Ma (line 1) | function Ma(e,t){let n=3;const o=Va(e);if(o&&15===o.type){const{properti...
  function Va (line 1) | function Va(e){const t=e.codegenNode;if(13===t.type)return t.props}
  function Ia (line 1) | function Ia(e){const t=e.patchFlag;return t?parseInt(t,10):void 0}
  function Ba (line 1) | function Ba(e,{filename:t="",prefixIdentifiers:n=!1,hoistStatic:o=!1,cac...
  function La (line 1) | function La(e,t){const n=Ba(e,t);ja(e,n),t.hoistStatic&&$a(e,n),t.ssr||f...
  function ja (line 1) | function ja(e,t){t.currentNode=e;const{nodeTransforms:n}=t,o=[];for(let ...
  function Ua (line 1) | function Ua(e,t){const n=P(e)?t=>t===e:t=>e.test(t);return(e,o)=>{if(1==...
  function Ha (line 1) | function Ha(e,t={}){const n=function(e,{mode:t="function",prefixIdentifi...
  function Wa (line 1) | function Wa(e,t,{helper:n,push:o,newline:r,isTS:s}){const i=n("component...
  function za (line 1) | function za(e,t){const n=e.length>3||!1;t.push("["),n&&t.indent(),Ka(e,t...
  function Ka (line 1) | function Ka(e,t,n=!1,o=!0){const{push:r,newline:s}=t;for(let i=0;i<e.len...
  function Ga (line 1) | function Ga(e,t){if(P(e))t.push(e);else if(A(e))t.push(t.helper(e));else...
  function qa (line 1) | function qa(e,t){const{content:n,isStatic:o}=e;t.push(o?JSON.stringify(n...
  function Ja (line 1) | function Ja(e,t){for(let n=0;n<e.children.length;n++){const o=e.children...
  function Ya (line 1) | function Ya(e,t){const{push:n}=t;if(8===e.type)n("["),Ja(e,t),n("]");els...
  function Qa (line 1) | function Qa(e,t){const n=3===e.tagType;return{type:10,loc:e.loc,conditio...
  function Xa (line 1) | function Xa(e,t,n){return e.condition?Oc(e.condition,eu(e,t,n),Ec(n.help...
  function eu (line 1) | function eu(e,t,n){const{helper:o}=n,r=kc("key",Tc(`${t}`,!1,Sc,2)),{chi...
  function su (line 1) | function su(e,t){const n=e.loc,o=e.content,r=o.match(nu);if(!r)return;co...
  function iu (line 1) | function iu(e,t,n){return Tc(t,!1,jc(e,n,t.length))}
  function lu (line 1) | function lu({value:e,key:t,index:n},o=[]){return function(e){let t=e.len...
  function pu (line 1) | function pu(e,t,n=uu){t.helper(mc);const{children:o,loc:r}=e,s=[],i=[];l...
  function fu (line 1) | function fu(e,t){return wc([kc("name",e),kc("fn",t)])}
  function du (line 1) | function du(e){for(let t=0;t<e.length;t++){const n=e[t];switch(n.type){c...
  function hu (line 1) | function hu(e){return 2!==e.type&&12!==e.type||(2===e.type?!!e.content.t...
  function vu (line 1) | function vu(e,t,n=e.props,o,r,s=!1){const{tag:i,loc:l,children:c}=e;let ...
  function yu (line 1) | function yu(e){const t=new Map,n=[];for(let o=0;o<e.length;o++){const r=...
  function _u (line 1) | function _u(e,t){17===e.value.type?e.value.elements.push(t.value):e.valu...
  function bu (line 1) | function bu(e){return"component"===e||"Component"===e}
  function Ou (line 1) | function Ou(e=[]){return{props:e}}
  function Pu (line 1) | function Pu(e,t={}){const n=t.onError||Fl,o="module"===t.mode;!0===t.pre...
  method getNamespace (line 1) | getNamespace(e,t){let n=t?t.ns:0;if(t&&2===n)if("annotation-xml"===t.tag...
  method getTextMode (line 1) | getTextMode({tag:e,ns:t}){if(0===t){if("textarea"===e||"title"===e)retur...
  function rp (line 1) | function rp(e,t){if(!P(e)){if(!e.nodeType)return _;e=e.innerHTML}const n...

FILE: src/electionguard_gui/web/services/authorization-service.js
  method getUserId (line 4) | async getUserId() {
  method setUserId (line 10) | async setUserId(id) {
  method isAdmin (line 14) | async isAdmin() {

FILE: src/electionguard_gui/web/services/router-service.js
  method getUrl (line 26) | getUrl(route, params) {
  method goTo (line 30) | goTo(route, params) {
  method getRouteByUrl (line 34) | getRouteByUrl(url) {
  method getRoute (line 37) | getRoute(path) {
  method getElectionUrl (line 124) | getElectionUrl(electionId) {

FILE: src/electionguard_tools/factories/ballot_factory.py
  class BallotFactory (line 35) | class BallotFactory:
    method get_random_selection_from (line 42) | def get_random_selection_from(
    method get_random_contest_from (line 52) | def get_random_contest_from(
    method get_fake_ballot (line 97) | def get_fake_ballot(
    method generate_fake_plaintext_ballots_for_election (line 126) | def generate_fake_plaintext_ballots_for_election(
    method get_simple_ballot_from_file (line 159) | def get_simple_ballot_from_file(self) -> PlaintextBallot:
    method get_simple_ballots_from_file (line 162) | def get_simple_ballots_from_file(self) -> List[PlaintextBallot]:
    method _get_ballot_from_file (line 166) | def _get_ballot_from_file(filename: str) -> PlaintextBallot:
    method _get_ballots_from_file (line 170) | def _get_ballots_from_file(filename: str) -> List[PlaintextBallot]:
  function get_selection_well_formed (line 176) | def get_selection_well_formed(
  function get_selection_poorly_formed (line 197) | def get_selection_poorly_formed(

FILE: src/electionguard_tools/factories/election_factory.py
  class AllPublicElectionData (line 63) | class AllPublicElectionData:
  class AllPrivateElectionData (line 74) | class AllPrivateElectionData:
  class ElectionFactory (line 80) | class ElectionFactory:
    method get_simple_manifest_from_file (line 85) | def get_simple_manifest_from_file(self) -> Manifest:
    method get_manifest_from_filename (line 89) | def get_manifest_from_filename(self, filename: str) -> Manifest:
    method get_manifest_from_file (line 94) | def get_manifest_from_file(spec_version: str, sample_manifest: str) ->...
    method get_hamilton_manifest_from_file (line 109) | def get_hamilton_manifest_from_file() -> Manifest:
    method get_sample_manifest_with_encryption_context (line 116) | def get_sample_manifest_with_encryption_context(
    method get_fake_manifest (line 156) | def get_fake_manifest() -> Manifest:
    method get_fake_ciphertext_election (line 235) | def get_fake_ciphertext_election(
    method get_fake_ballot (line 246) | def get_fake_ballot(
    method _get_manifest_from_file (line 265) | def _get_manifest_from_file(filename: str) -> Manifest:
    method get_encryption_device (line 269) | def get_encryption_device() -> EncryptionDevice:
  function get_selection_description_well_formed (line 280) | def get_selection_description_well_formed(
  function get_contest_description_well_formed (line 301) | def get_contest_description_well_formed(

FILE: src/electionguard_tools/helpers/election_builder.py
  class ElectionBuilder (line 18) | class ElectionBuilder:
    method __post_init__ (line 43) | def __post_init__(self) -> None:
    method set_public_key (line 46) | def set_public_key(
    method set_commitment_hash (line 57) | def set_commitment_hash(self, commitment_hash: ElementModQ) -> Electio...
    method add_extended_data_field (line 66) | def add_extended_data_field(self, name: str, value: str) -> ElectionBu...
    method build (line 77) | def build(

FILE: src/electionguard_tools/helpers/export.py
  function export_record (line 51) | def export_record(
  function export_private_data (line 100) | def export_private_data(

FILE: src/electionguard_tools/helpers/key_ceremony_orchestrator.py
  class KeyCeremonyOrchestrator (line 9) | class KeyCeremonyOrchestrator:
    method create_guardians (line 13) | def create_guardians(ceremony_details: CeremonyDetails) -> List[Guardi...
    method perform_full_ceremony (line 25) | def perform_full_ceremony(
    method perform_round_1 (line 35) | def perform_round_1(
    method perform_round_2 (line 49) | def perform_round_2(
    method perform_round_3 (line 64) | def perform_round_3(
    method fail_round_3 (line 83) | def fail_round_3(

FILE: src/electionguard_tools/helpers/tally_accumulate.py
  function accumulate_plaintext_ballots (line 5) | def accumulate_plaintext_ballots(ballots: List[PlaintextBallot]) -> Dict...

FILE: src/electionguard_tools/helpers/tally_ceremony_orchestrator.py
  class TallyCeremonyOrchestrator (line 12) | class TallyCeremonyOrchestrator:
    method perform_decryption_setup (line 16) | def perform_decryption_setup(
    method perform_compensated_decryption_setup (line 36) | def perform_compensated_decryption_setup(
    method announcement (line 60) | def announcement(
    method exchange_compensated_decryption_shares (line 99) | def exchange_compensated_decryption_shares(

FILE: src/electionguard_tools/scripts/sample_generator.py
  class ElectionSampleDataGenerator (line 45) | class ElectionSampleDataGenerator:
    method __init__ (line 56) | def __init__(self) -> None:
    method generate (line 62) | def generate(

FILE: src/electionguard_tools/strategies/election.py
  function human_names (line 150) | def human_names(draw: _DrawType) -> str:
  function election_types (line 162) | def election_types(draw: _DrawType) -> ElectionType:
  function reporting_unit_types (line 172) | def reporting_unit_types(draw: _DrawType) -> ReportingUnitType:
  function contact_infos (line 182) | def contact_infos(draw: _DrawType) -> ContactInformation:
  function two_letter_codes (line 196) | def two_letter_codes(draw: _DrawType, min_size: int = 2, max_size: int =...
  function languages (line 214) | def languages(draw: _DrawType) -> Language:
  function language_human_names (line 224) | def language_human_names(draw: _DrawType) -> Language:
  function internationalized_texts (line 234) | def internationalized_texts(draw: _DrawType) -> InternationalizedText:
  function internationalized_human_names (line 244) | def internationalized_human_names(draw: _DrawType) -> InternationalizedT...
  function annotated_strings (line 256) | def annotated_strings(draw: _DrawType) -> AnnotatedString:
  function annotated_emails (line 268) | def annotated_emails(draw: _DrawType) -> AnnotatedString:
  function ballot_styles (line 278) | def ballot_styles(
  function party_lists (line 305) | def party_lists(draw: _DrawType, num_parties: int) -> List[Party]:
  function geopolitical_units (line 329) | def geopolitical_units(draw: _DrawType) -> GeopoliticalUnit:
  function candidates (line 343) | def candidates(draw: _DrawType, party_list: Optional[List[Party]]) -> Ca...
  function _candidate_to_selection_description (line 365) | def _candidate_to_selection_description(
  function candidate_contest_descriptions (line 380) | def candidate_contest_descriptions(
  function contest_descriptions_room_for_overvoting (line 437) | def contest_descriptions_room_for_overvoting(
  function referendum_contest_descriptions (line 466) | def referendum_contest_descriptions(
  function contest_descriptions (line 503) | def contest_descriptions(
  function election_descriptions (line 527) | def election_descriptions(
  function plaintext_voted_ballots (line 581) | def plaintext_voted_ballots(
  function plaintext_voted_ballot (line 596) | def plaintext_voted_ballot(
  function ciphertext_elections (line 649) | def ciphertext_elections(
  function elections_and_ballots (line 689) | def elections_and_ballots(

FILE: src/electionguard_tools/strategies/elgamal.py
  function elgamal_keypairs (line 14) | def elgamal_keypairs(draw: _DrawType) -> Optional[ElGamalKeyPair]:

FILE: src/electionguard_tools/strategies/group.py
  function elements_mod_q (line 19) | def elements_mod_q(draw: _DrawType) -> ElementModQ:
  function elements_mod_q_no_zero (line 29) | def elements_mod_q_no_zero(draw: _DrawType) -> ElementModQ:
  function elements_mod_p (line 39) | def elements_mod_p(draw: _DrawType) -> ElementModP:
  function elements_mod_p_no_zero (line 49) | def elements_mod_p_no_zero(draw: _DrawType) -> ElementModP:

FILE: src/electionguard_verify/verify.py
  class Verification (line 16) | class Verification:
  function verify_ballot (line 26) | def verify_ballot(
  function verify_decryption (line 48) | def verify_decryption(
  function verify_aggregation (line 71) | def verify_aggregation(

FILE: stubs/gmpy2.pyi
  class mpz (line 10) | class mpz(int):
    method __new__ (line 11) | def __new__(
    method bit_clear (line 14) | def bit_clear(self, n: int) -> mpz: ...
    method bit_flip (line 15) | def bit_flip(self, n: int) -> mpz: ...
    method bit_length (line 16) | def bit_length(self, *args: int, **kwargs: Any) -> int: ...
    method bit_scan0 (line 17) | def bit_scan0(self, n: int = ...) -> int: ...
    method bit_scan1 (line 18) | def bit_scan1(self, n: int = ...) -> int: ...
    method bit_set (line 19) | def bit_set(self, n: int) -> mpz: ...
    method bit_test (line 20) | def bit_test(self, n: int) -> bool: ...
    method digits (line 21) | def digits(self) -> str: ...
    method is_divisible (line 22) | def is_divisible(self, d: int) -> bool: ...
    method is_even (line 23) | def is_even(self) -> bool: ...
    method is_odd (line 24) | def is_odd(self) -> bool: ...
    method is_power (line 25) | def is_power(self) -> bool: ...
    method is_prime (line 26) | def is_prime(self) -> bool: ...
    method is_square (line 27) | def is_square(self) -> bool: ...
    method num_digits (line 28) | def num_digits(self, base: int = ...) -> int: ...
    method __abs__ (line 29) | def __abs__(self) -> mpz: ...
    method __add__ (line 30) | def __add__(self, other: int) -> mpz: ...
    method __and__ (line 31) | def __and__(self, other: int) -> mpz: ...
    method __bool__ (line 32) | def __bool__(self) -> bool: ...
    method __ceil__ (line 33) | def __ceil__(self) -> mpz: ...
    method __divmod__ (line 34) | def __divmod__(self, other: int) -> Tuple[int, int]: ...
    method __eq__ (line 35) | def __eq__(self, other: object) -> bool: ...
    method __float__ (line 36) | def __float__(self) -> mpz: ...  # maybe not mpz?
    method __floor__ (line 37) | def __floor__(self) -> mpz: ...
    method __floordiv__ (line 38) | def __floordiv__(self, other: int) -> mpz: ...
    method __format__ (line 39) | def __format__(self, *args: Any, **kwargs: Any) -> str: ...
    method __ge__ (line 40) | def __ge__(self, other: int) -> bool: ...
    method __getitem__ (line 41) | def __getitem__(self, index: int) -> mpz: ...
    method __gt__ (line 42) | def __gt__(self, other: int) -> bool: ...
    method __hash__ (line 43) | def __hash__(self) -> int: ...
    method __iadd__ (line 44) | def __iadd__(self, other: int) -> mpz: ...
    method __ifloordiv__ (line 45) | def __ifloordiv__(self, other: int) -> mpz: ...
    method __ilshift__ (line 46) | def __ilshift__(self, other: int) -> mpz: ...
    method __imod__ (line 47) | def __imod__(self, other: int) -> mpz: ...
    method __imul__ (line 48) | def __imul__(self, other: int) -> mpz: ...
    method __index__ (line 49) | def __index__(self) -> int: ...
    method __int__ (line 50) | def __int__(self) -> int: ...
    method __invert__ (line 51) | def __invert__(self) -> mpz: ...
    method __irshift__ (line 52) | def __irshift__(self, other: int) -> mpz: ...
    method __isub__ (line 53) | def __isub__(self, other: int) -> mpz: ...
    method __le__ (line 54) | def __le__(self, other: int) -> bool: ...
    method __len__ (line 55) | def __len__(self) -> int: ...
    method __lshift__ (line 56) | def __lshift__(self, other: int) -> mpz: ...
    method __lt__ (line 57) | def __lt__(self, other: int) -> bool: ...
    method __mod__ (line 58) | def __mod__(self, other: int) -> mpz: ...
    method __mul__ (line 59) | def __mul__(self, other: int) -> mpz: ...
    method __ne__ (line 60) | def __ne__(self, other: object) -> bool: ...
    method __neg__ (line 61) | def __neg__(self) -> mpz: ...
    method __or__ (line 62) | def __or__(self, other: int) -> mpz: ...
    method __pos__ (line 63) | def __pos__(self) -> bool: ...
    method __pow__ (line 64) | def __pow__(self, other: int, __modulo: Optional[int] = ...) -> Any: ....
    method __radd__ (line 65) | def __radd__(self, other: int) -> mpz: ...
    method __rand__ (line 66) | def __rand__(self, other: int) -> mpz: ...
    method __rdivmod__ (line 67) | def __rdivmod__(self, other: int) -> Tuple[int, int]: ...
    method __rfloordiv__ (line 68) | def __rfloordiv__(self, other: int) -> mpz: ...
    method __rlshift__ (line 69) | def __rlshift__(self, other: int) -> mpz: ...
    method __rmod__ (line 70) | def __rmod__(self, other: int) -> mpz: ...
    method __rmul__ (line 71) | def __rmul__(self, other: int) -> mpz: ...
    method __ror__ (line 72) | def __ror__(self, other: int) -> mpz: ...
    method __rpow__ (line 73) | def __rpow__(self, other: int, __modulo: Optional[int] = ...) -> Any: ...
    method __rrshift__ (line 74) | def __rrshift__(self, other: int) -> mpz: ...
    method __rshift__ (line 75) | def __rshift__(self, other: int) -> mpz: ...
    method __rsub__ (line 76) | def __rsub__(self, other: int) -> mpz: ...
    method __rtruediv__ (line 77) | def __rtruediv__(self, other: float) -> float: ...
    method __rxor__ (line 78) | def __rxor__(self, other: int) -> mpz: ...
    method __sizeof__ (line 79) | def __sizeof__(self) -> int: ...
    method __sub__ (line 80) | def __sub__(self, other: int) -> mpz: ...
    method __truediv__ (line 81) | def __truediv__(self, other: float) -> float: ...
    method __trunc__ (line 82) | def __trunc__(self) -> mpz: ...
    method __xor__ (line 83) | def __xor__(self, other: int) -> mpz: ...
  function invert (line 85) | def invert(x: mpz, m: mpz) -> mpz: ...
  function powmod (line 86) | def powmod(a: int, e: int, p: int) -> mpz: ...
  function to_binary (line 87) | def to_binary(a: mpz) -> bytes: ...
  function from_binary (line 88) | def from_binary(b: bytes) -> mpz: ...

FILE: tests/base_test_case.py
  class BaseTestCase (line 9) | class BaseTestCase(TestCase):
    method __inject_fixtures (line 16) | def __inject_fixtures(self, mocker):
    method setUpClass (line 20) | def setUpClass(cls):
    method tearDownClass (line 30) | def tearDownClass(cls):

FILE: tests/bench/bench_chaum_pedersen.py
  class BenchInput (line 21) | class BenchInput:
  function chaum_pedersen_bench (line 29) | def chaum_pedersen_bench(bi: BenchInput) -> Tuple[float, float]:
  function identity (line 47) | def identity(x: int) -> int:

FILE: tests/integration/test_create_schema.py
  class TestCreateSchema (line 24) | class TestCreateSchema(TestCase):
    method test_create_schema (line 33) | def test_create_schema(self) -> None:

FILE: tests/integration/test_end_to_end_election.py
  class TestEndToEndElection (line 85) | class TestEndToEndElection(BaseTestCase):
    method test_end_to_end_election (line 130) | def test_end_to_end_election(self) -> None:
    method step_0_configure_election (line 141) | def step_0_configure_election(self) -> None:
    method step_1_key_ceremony (line 179) | def step_1_key_ceremony(self) -> None:
    method step_2_encrypt_votes (line 298) | def step_2_encrypt_votes(self) -> None:
    method step_3_cast_and_spoil (line 333) | def step_3_cast_and_spoil(self) -> None:
    method step_4_decrypt_tally (line 358) | def step_4_decrypt_tally(self) -> None:
    method compare_results (line 438) | def compare_results(self) -> None:
    method step_5_publish (line 502) | def step_5_publish(self) -> None:
    method deserialize_data (line 553) | def deserialize_data(self) -> None:
    method _assert_message (line 638) | def _assert_message(
    method assertEqualAsDicts (line 649) | def assertEqualAsDicts(self, first: object, second: object) -> None:

FILE: tests/integration/test_functional_key_ceremony.py
  class TestKeyCeremony (line 20) | class TestKeyCeremony(BaseTestCase):
    method test_key_ceremony (line 47) | def test_key_ceremony(self) -> None:
    method _guardian_generates_keys (line 86) | def _guardian_generates_keys(
    method _guardian_share_keys (line 98) | def _guardian_share_keys(self, guardian_id: GuardianId) -> None:
    method _guardian_generates_backups (line 105) | def _guardian_generates_backups(self, sender_id: str) -> None:
    method _guardian_shares_backups (line 126) | def _guardian_shares_backups(self, sender_id: GuardianId) -> None:
    method _guardian_verifies_backups (line 137) | def _guardian_verifies_backups(self, verifier_id: str) -> None:
    method _guardian_shares_verifications (line 153) | def _guardian_shares_verifications(self, verifier_id: str) -> None:
    method _guardian_checks_returned_verifications (line 166) | def _guardian_checks_returned_verifications(self, key_owner_id: Guardi...
    method _guardian_challenges (line 176) | def _guardian_challenges(self, guardian_ids: List[GuardianId]) -> None:
    method _publish_joint_key (line 217) | def _publish_joint_key(self) -> None:

FILE: tests/integration/test_hamilton_county_election.py
  class TestHamiltonCountyElection (line 10) | class TestHamiltonCountyElection(BaseTestCase):
    method test_manifest_is_valid (line 15) | def test_manifest_is_valid(self) -> None:

FILE: tests/property/test_ballot.py
  class TestBallot (line 13) | class TestBallot(BaseTestCase):
    method test_ballot_is_valid (line 16) | def test_ballot_is_valid(self):
    method test_plaintext_ballot_selection_is_valid (line 41) | def test_plaintext_ballot_selection_is_valid(
    method test_plaintext_ballot_selection_is_invalid (line 61) | def test_plaintext_ballot_selection_is_invalid(

FILE: tests/property/test_chaum_pedersen.py
  class TestDisjunctiveChaumPedersen (line 27) | class TestDisjunctiveChaumPedersen(BaseTestCase):
    method test_djcp_proofs_simple (line 30) | def test_djcp_proofs_simple(self):
    method test_djcp_proof_invalid_inputs (line 55) | def test_djcp_proof_invalid_inputs(self):
    method test_djcp_proof_zero (line 77) | def test_djcp_proof_zero(
    method test_djcp_proof_one (line 96) | def test_djcp_proof_one(
    method test_djcp_proof_broken (line 115) | def test_djcp_proof_broken(
  class TestChaumPedersen (line 132) | class TestChaumPedersen(BaseTestCase):
    method test_cp_proofs_simple (line 135) | def test_cp_proofs_simple(self):
    method test_cp_proof (line 167) | def test_cp_proof(
  class TestConstantChaumPedersen (line 194) | class TestConstantChaumPedersen(BaseTestCase):
    method test_ccp_proofs_simple_encryption_of_zero (line 197) | def test_ccp_proofs_simple_encryption_of_zero(self):
    method test_ccp_proofs_simple_encryption_of_one (line 211) | def test_ccp_proofs_simple_encryption_of_one(self):
    method test_ccp_proof (line 237) | def test_ccp_proof(

FILE: tests/property/test_decrypt_with_secrets.py
  class TestDecryptWithSecrets (line 50) | class TestDecryptWithSecrets(BaseTestCase):
    method test_decrypt_selection_valid_input_succeeds (line 66) | def test_decrypt_selection_valid_input_succeeds(
    method test_decrypt_selection_valid_input_tampered_fails (line 121) | def test_decrypt_selection_valid_input_tampered_fails(
    method test_decrypt_selection_tampered_nonce_fails (line 201) | def test_decrypt_selection_tampered_nonce_fails(
    method test_decrypt_contest_valid_input_succeeds (line 248) | def test_decrypt_contest_valid_input_succeeds(
    method test_decrypt_contest_invalid_input_fails (line 409) | def test_decrypt_contest_invalid_input_fails(
    method test_decrypt_ballot_valid_input_succeeds (line 506) | def test_decrypt_ballot_valid_input_succeeds(self, keypair: ElGamalKey...
    method test_decrypt_ballot_valid_input_missing_nonce_fails (line 674) | def test_decrypt_ballot_valid_input_missing_nonce_fails(

FILE: tests/property/test_decryption_mediator.py
  class TestDecryptionMediator (line 53) | class TestDecryptionMediator(BaseTestCase):
    method setUp (line 63) | def setUp(self):
    method test_announce (line 194) | def test_announce(self):
    method test_get_plaintext_with_all_guardians_present (line 226) | def test_get_plaintext_with_all_guardians_present(self):
    method test_get_plaintext_with_a_missing_guardian (line 269) | def test_get_plaintext_with_a_missing_guardian(self):
    method test_get_plaintext_tally_with_all_guardians_present (line 323) | def test_get_plaintext_tally_with_all_guardians_present(
    method _generate_encrypted_tally (line 359) | def _generate_encrypted_tally(
  function _convert_to_selections (line 384) | def _convert_to_selections(tally: PlaintextTally) -> Dict[str, int]:

FILE: tests/property/test_discrete_log.py
  function _discrete_log_uncached (line 24) | def _discrete_log_uncached(e: ElementModP) -> int:
  class TestDiscreteLogFunctions (line 37) | class TestDiscreteLogFunctions(BaseTestCase):
    method test_uncached (line 41) | def test_uncached(self, exp: int) -> None:
    method test_cached (line 53) | def test_cached(self, exp: int) -> None:
    method test_cached_one (line 66) | def test_cached_one(self) -> None:
    method test_cached_one_async (line 75) | def test_cached_one_async(self) -> None:
    method test_precompute_discrete_log (line 93) | def test_precompute_discrete_log(self, exponent: int) -> None:
  class TestDiscreteLogClass (line 107) | class TestDiscreteLogClass(BaseTestCase):
    method test_precompute (line 111) | def test_precompute(self, exponent: int) -> None:
    method test_cached (line 127) | def test_cached(self, exp: int) -> None:
    method test_cached_one (line 138) | def test_cached_one(self) -> None:
    method test_cached_one_async (line 149) | def test_cached_one_async(self) -> None:

FILE: tests/property/test_elgamal.py
  class TestElGamal (line 40) | class TestElGamal(BaseTestCase):
    method test_simple_elgamal_encryption_decryption (line 43) | def test_simple_elgamal_encryption_decryption(self) -> None:
    method test_elgamal_encrypt_requires_nonzero_nonce (line 69) | def test_elgamal_encrypt_requires_nonzero_nonce(
    method test_elgamal_keypair_from_secret_requires_key_greater_than_one (line 74) | def test_elgamal_keypair_from_secret_requires_key_greater_than_one(sel...
    method test_elgamal_encryption_decryption_inverses (line 79) | def test_elgamal_encryption_decryption_inverses(
    method test_elgamal_encryption_decryption_with_known_nonce_inverses (line 88) | def test_elgamal_encryption_decryption_with_known_nonce_inverses(
    method test_elgamal_generated_keypairs_are_within_range (line 97) | def test_elgamal_generated_keypairs_are_within_range(
    method test_elgamal_add_homomorphic_accumulation_decrypts_successfully (line 111) | def test_elgamal_add_homomorphic_accumulation_decrypts_successfully(
    method test_elgamal_add_requires_args (line 126) | def test_elgamal_add_requires_args(self) -> None:
    method test_elgamal_keypair_produces_valid_residue (line 130) | def test_elgamal_keypair_produces_valid_residue(self, keypair) -> None:
    method test_elgamal_keypair_random (line 133) | def test_elgamal_keypair_random(self) -> None:
    method test_elgamal_combine_public_keys (line 144) | def test_elgamal_combine_public_keys(self) -> None:
    method test_gmpy2_parallelism_is_safe (line 158) | def test_gmpy2_parallelism_is_safe(self) -> None:
    method test_hashed_elgamal_encryption (line 190) | def test_hashed_elgamal_encryption(self) -> None:

FILE: tests/property/test_encrypt.py
  class TestEncrypt (line 64) | class TestEncrypt(BaseTestCase):
    method test_encrypt_simple_selection_succeeds (line 67) | def test_encrypt_simple_selection_succeeds(self):
    method test_encrypt_simple_selection_malformed_data_fails (line 97) | def test_encrypt_simple_selection_malformed_data_fails(self):
    method test_encrypt_selection_valid_input_succeeds (line 146) | def test_encrypt_selection_valid_input_succeeds(
    method test_encrypt_selection_valid_input_tampered_encryption_fails (line 189) | def test_encrypt_selection_valid_input_tampered_encryption_fails(
    method test_encrypt_contest_valid_input_succeeds (line 260) | def test_encrypt_contest_valid_input_succeeds(
    method test_encrypt_contest_valid_input_tampered_proof_fails (line 309) | def test_encrypt_contest_valid_input_tampered_proof_fails(
    method test_encrypt_contest_overvote_fails (line 373) | def test_encrypt_contest_overvote_fails(
    method test_encrypt_contest_manually_formed_contest_description_valid_succeeds (line 400) | def test_encrypt_contest_manually_formed_contest_description_valid_suc...
    method test_encrypt_contest_duplicate_selection_object_ids_fails (line 445) | def test_encrypt_contest_duplicate_selection_object_ids_fails(self):
    method test_encrypt_ballot_simple_succeeds (line 495) | def test_encrypt_ballot_simple_succeeds(self):
    method test_encrypt_ballot_with_composer_succeeds (line 539) | def test_encrypt_ballot_with_composer_succeeds(self):
    method test_encrypt_simple_ballot_from_file_with_composer_succeeds (line 566) | def test_encrypt_simple_ballot_from_file_with_composer_succeeds(self):
    method test_encrypt_simple_ballot_from_files_succeeds (line 594) | def test_encrypt_simple_ballot_from_files_succeeds(self) -> None:
    method test_encrypt_ballot_with_derivative_nonces_regenerates_valid_proofs (line 634) | def test_encrypt_ballot_with_derivative_nonces_regenerates_valid_proofs(
    method test_encrypt_ballot_with_verify_proofs_false_passed_on (line 727) | def test_encrypt_ballot_with_verify_proofs_false_passed_on(self):

FILE: tests/property/test_encrypt_hypotheses.py
  class TestElections (line 29) | class TestElections(BaseTestCase):
    method test_generators_yield_valid_output (line 38) | def test_generators_yield_valid_output(self, manifest: Manifest):
    method test_accumulation_encryption_decryption (line 57) | def test_accumulation_encryption_decryption(
  function _accumulate_encrypted_ballots (line 156) | def _accumulate_encrypted_ballots(

FILE: tests/property/test_group.py
  class TestEquality (line 45) | class TestEquality(BaseTestCase):
    method test_p_not_equal_to_q (line 49) | def test_p_not_equal_to_q(self, q: ElementModQ, q2: ElementModQ) -> None:
  class TestModularArithmetic (line 77) | class TestModularArithmetic(BaseTestCase):
    method test_add_q (line 81) | def test_add_q(self, q: ElementModQ) -> None:
    method test_a_plus_bc_q (line 87) | def test_a_plus_bc_q(self, q: ElementModQ) -> None:
    method test_a_minus_b_q (line 93) | def test_a_minus_b_q(self, q: ElementModQ) -> None:
    method test_div_q (line 99) | def test_div_q(self, q: ElementModQ) -> None:
    method test_div_p (line 105) | def test_div_p(self, p: ElementModQ) -> None:
    method test_no_mult_inv_of_zero (line 110) | def test_no_mult_inv_of_zero(self) -> None:
    method test_mult_inverses (line 114) | def test_mult_inverses(self, elem: ElementModP) -> None:
    method test_mult_identity (line 119) | def test_mult_identity(self, elem: ElementModP) -> None:
    method test_mult_noargs (line 122) | def test_mult_noargs(self) -> None:
    method test_add_noargs (line 125) | def test_add_noargs(self) -> None:
    method test_properties_for_constants (line 128) | def test_properties_for_constants(self) -> None:
    method test_simple_powers (line 138) | def test_simple_powers(self) -> None:
    method test_in_bounds_q (line 144) | def test_in_bounds_q(self, q: ElementModQ) -> None:
    method test_in_bounds_p (line 158) | def test_in_bounds_p(self, p: ElementModP) -> None:
    method test_in_bounds_q_no_zero (line 172) | def test_in_bounds_q_no_zero(self, q: ElementModQ):
    method test_in_bounds_p_no_zero (line 183) | def test_in_bounds_p_no_zero(self, p: ElementModP) -> None:
    method test_large_values_rejected_by_int_to_q (line 194) | def test_large_values_rejected_by_int_to_q(self, q: ElementModQ) -> None:
  class TestOptionalFunctions (line 199) | class TestOptionalFunctions(BaseTestCase):
    method test_unwrap (line 202) | def test_unwrap(self) -> None:
    method test_match (line 209) | def test_match(self) -> None:
    method test_get_or_else (line 216) | def test_get_or_else(self) -> None:
    method test_flatmap (line 223) | def test_flatmap(self) -> None:

FILE: tests/property/test_hash.py
  class TestHash (line 15) | class TestHash(BaseTestCase):
    method test_same_answer_twice_in_a_row (line 19) | def test_same_answer_twice_in_a_row(self, a: ElementModQ, b: ElementMo...
    method test_basic_hash_properties (line 26) | def test_basic_hash_properties(self, a: ElementModQ, b: ElementModQ):
    method test_hash_of_big_integer_with_leading_zero_bytes (line 35) | def test_hash_of_big_integer_with_leading_zero_bytes(
    method test_hash_of_big_integer_with_single_leading_zero (line 54) | def test_hash_of_big_integer_with_single_leading_zero(
    method test_hash_for_zero_number_is_zero_string (line 71) | def test_hash_for_zero_number_is_zero_string(self):
    method test_hash_for_non_zero_number_string_same_as_explicit_number (line 74) | def test_hash_for_non_zero_number_string_same_as_explicit_number(self):
    method test_different_strings_casing_not_the_same_hash (line 77) | def test_different_strings_casing_not_the_same_hash(self):
    method test_hash_for_none_same_as_null_string (line 83) | def test_hash_for_none_same_as_null_string(self):
    method test_hash_of_save_values_in_list_are_same_hash (line 86) | def test_hash_of_save_values_in_list_are_same_hash(self):
    method test_hash_null_equivalents (line 89) | def test_hash_null_equivalents(self):
    method test_hash_not_null_equivalents (line 97) | def test_hash_not_null_equivalents(self):
    method test_hash_value_from_nested_list_and_result_of_hashed_list_by_taking_the_hex (line 101) | def test_hash_value_from_nested_list_and_result_of_hashed_list_by_taki...

FILE: tests/property/test_nonces.py
  class TestNonces (line 13) | class TestNonces(BaseTestCase):
    method test_nonces_iterable (line 17) | def test_nonces_iterable(self, seed: ElementModQ):
    method test_nonces_deterministic (line 25) | def test_nonces_deterministic(self, seed: ElementModQ, i: int):
    method test_nonces_seed_matters (line 34) | def test_nonces_seed_matters(self, seed1: ElementModQ, seed2: ElementM...
    method test_nonces_with_slices (line 41) | def test_nonces_with_slices(self, seed: ElementModQ):
    method test_nonces_type_errors (line 57) | def test_nonces_type_errors(self):

FILE: tests/property/test_schnorr.py
  class TestSchnorr (line 27) | class TestSchnorr(BaseTestCase):
    method test_schnorr_proofs_simple (line 30) | def test_schnorr_proofs_simple(self) -> None:
    method test_schnorr_proofs_valid (line 38) | def test_schnorr_proofs_valid(
    method test_schnorr_proofs_invalid_u (line 46) | def test_schnorr_proofs_invalid_u(
    method test_schnorr_proofs_invalid_h (line 57) | def test_schnorr_proofs_invalid_h(
    method test_schnorr_proofs_invalid_public_key (line 68) | def test_schnorr_proofs_invalid_public_key(
    method test_schnorr_proofs_bounds_checking (line 79) | def test_schnorr_proofs_bounds_checking(

FILE: tests/property/test_tally.py
  class TestTally (line 29) | class TestTally(BaseTestCase):
    method test_tally_cast_ballots_accumulates_valid_tally (line 40) | def test_tally_cast_ballots_accumulates_valid_tally(
    method test_tally_spoiled_ballots_accumulates_valid_tally (line 89) | def test_tally_spoiled_ballots_accumulates_valid_tally(
    method test_tally_ballot_invalid_input_fails (line 141) | def test_tally_ballot_invalid_input_fails(
    method _decrypt_with_secret (line 228) | def _decrypt_with_secret(
    method _cannot_erroneously_mutate_state (line 242) | def _cannot_erroneously_mutate_state(

FILE: tests/property/test_verify.py
  class TestVerify (line 45) | class TestVerify(BaseTestCase):
    method test_verify_ballot (line 56) | def test_verify_ballot(self, keypair: ElGamalKeyPair):
    method test_verify_decryption (line 77) | def test_verify_decryption(self):
    method test_verify_aggregation (line 131) | def test_verify_aggregation(self, election_details: ElectionsAndBallot...

FILE: tests/unit/electionguard/test_ballot.py
  function get_sample_contest_description (line 15) | def get_sample_contest_description() -> ContestDescriptionWithPlaceholders:
  class TestBallot (line 41) | class TestBallot(BaseTestCase):
    method test_contest_valid (line 44) | def test_contest_valid(self) -> None:
    method test_contest_valid_with_null_vote (line 59) | def test_contest_valid_with_null_vote(self) -> None:
    method test_contest_valid_with_under_vote (line 68) | def test_contest_valid_with_under_vote(self) -> None:
    method test_contest_valid_with_over_vote (line 81) | def test_contest_valid_with_over_vote(self) -> None:

FILE: tests/unit/electionguard/test_ballot_box.py
  class TestBallotBox (line 20) | class TestBallotBox(BaseTestCase):
    method setUp (line 23) | def setUp(self) -> None:
    method test_ballot_box_cast_ballot (line 36) | def test_ballot_box_cast_ballot(self) -> None:
    method test_ballot_box_spoil_ballot (line 69) | def test_ballot_box_spoil_ballot(self) -> None:
    method test_submit_ballot_to_box (line 102) | def test_submit_ballot_to_box(self) -> None:
    method test_cast_ballot (line 154) | def test_cast_ballot(self) -> None:
    method test_spoil_ballot (line 173) | def test_spoil_ballot(self) -> None:
    method test_submit_ballot (line 192) | def test_submit_ballot(self) -> None:

FILE: tests/unit/electionguard/test_ballot_code.py
  class TestBallotCode (line 12) | class TestBallotCode(BaseTestCase):
    method test_rotate_ballot_code (line 15) | def test_rotate_ballot_code(self):

FILE: tests/unit/electionguard/test_ballot_compact.py
  class TestCompactBallot (line 23) | class TestCompactBallot(BaseTestCase):
    method setUp (line 32) | def setUp(self) -> None:
    method test_compact_plaintext_ballot (line 51) | def test_compact_plaintext_ballot(self) -> None:
    method test_compact_submitted_ballot (line 68) | def test_compact_submitted_ballot(self) -> None:

FILE: tests/unit/electionguard/test_constants.py
  class TestConstants (line 22) | class TestConstants(BaseTestCase):
    method test_get_standard_primes (line 26) | def test_get_standard_primes(self):
    method test_get_test_primes (line 40) | def test_get_test_primes(self):

FILE: tests/unit/electionguard/test_decrypt_with_shares.py
  class TestDecryptWithShares (line 45) | class TestDecryptWithShares(BaseTestCase):
    method setUp (line 52) | def setUp(self):
    method tearDown (line 168) | def tearDown(self):
    method test_decrypt_selection_with_all_guardians_present (line 173) | def test_decrypt_selection_with_all_guardians_present(self):
    method test_decrypt_ballot_with_all_guardians_present (line 210) | def test_decrypt_ballot_with_all_guardians_present(self):
    method test_decrypt_ballot_with_missing_guardians (line 246) | def test_decrypt_ballot_with_missing_guardians(self):

FILE: tests/unit/electionguard/test_decryption.py
  class TestDecryption (line 58) | class TestDecryption(BaseTestCase):
    method setUp (line 65) | def setUp(self):
    method tearDown (line 183) | def tearDown(self):
    method test_compute_decryption_share (line 189) | def test_compute_decryption_share(self):
    method test_compute_compensated_decryption_share (line 225) | def test_compute_compensated_decryption_share(self):
    method test_compute_selection (line 247) | def test_compute_selection(self):
    method test_compute_compensated_selection (line 263) | def test_compute_compensated_selection(self):
    method test_compute_compensated_selection_failure (line 429) | def test_compute_compensated_selection_failure(self):
    method test_reconstruct_decryption_share (line 459) | def test_reconstruct_decryption_share(self):
    method test_reconstruct_decryption_shares_for_ballot (line 500) | def test_reconstruct_decryption_shares_for_ballot(self):
    method test_reconstruct_decryption_share_for_ballot (line 547) | def test_reconstruct_decryption_share_for_ballot(self):

FILE: tests/unit/electionguard/test_election_polynomial.py
  class TestElectionPolynomial (line 19) | class TestElectionPolynomial(BaseTestCase):
    method test_generate_polynomial (line 22) | def test_generate_polynomial(self):
    method test_compute_polynomial_coordinate (line 29) | def test_compute_polynomial_coordinate(self):
    method test_verify_polynomial_coordinate (line 47) | def test_verify_polynomial_coordinate(self):

FILE: tests/unit/electionguard/test_elgamal.py
  class TestElgamal (line 13) | class TestElgamal(BaseTestCase):
    method test_hashed_elgamal_with_session_key_that_starts_with_0 (line 16) | def test_hashed_elgamal_with_session_key_that_starts_with_0(self) -> N...
    method test_hashed_elgamal_with_session_key_that_starts_with_1 (line 32) | def test_hashed_elgamal_with_session_key_that_starts_with_1(self) -> N...
    method do_hashed_elgamal (line 46) | def do_hashed_elgamal(

FILE: tests/unit/electionguard/test_encrypt.py
  function get_sample_contest_description (line 27) | def get_sample_contest_description() -> ContestDescriptionWithPlaceholders:
  class TestEncrypt (line 57) | class TestEncrypt(TestCase):
    method test_contest_data_conversion (line 60) | def test_contest_data_conversion(self) -> None:
    method _padding_cycle (line 87) | def _padding_cycle(self, data: ContestData) -> None:
    method test_encrypt_simple_contest_referendum_succeeds (line 103) | def test_encrypt_simple_contest_referendum_succeeds(self) -> None:
    method test_contest_encrypt_with_overvotes (line 131) | def test_contest_encrypt_with_overvotes(self) -> None:
    method test_contest_encrypt_with_write_ins (line 177) | def test_contest_encrypt_with_write_ins(self):
    method test_contest_data_integration (line 226) | def test_contest_data_integration(self) -> None:

FILE: tests/unit/electionguard/test_guardian.py
  class TestGuardian (line 23) | class TestGuardian(BaseTestCase):
    method test_import_from_guardian_private_record (line 26) | def test_import_from_guardian_private_record(self) -> None:
    method test_set_ceremony_details (line 52) | def test_set_ceremony_details(self) -> None:
    method test_share_key (line 69) | def test_share_key(self) -> None:
    method test_save_guardian_key (line 85) | def test_save_guardian_key(self) -> None:
    method test_all_guardian_keys_received (line 101) | def test_all_guardian_keys_received(self) -> None:
    method test_share_backups (line 118) | def test_share_backups(self) -> None:
    method test_save_election_partial_key_backup (line 144) | def test_save_election_partial_key_backup(self) -> None:
    method test_all_election_partial_key_backups_received (line 162) | def test_all_election_partial_key_backups_received(self) -> None:
    method test_verify_election_partial_key_backup (line 183) | def test_verify_election_partial_key_backup(self) -> None:
    method test_verify_election_partial_key_challenge (line 212) | def test_verify_election_partial_key_challenge(self) -> None:
    method test_publish_election_backup_challenge (line 242) | def test_publish_election_backup_challenge(self) -> None:
    method test_save_election_partial_key_verification (line 266) | def test_save_election_partial_key_verification(self) -> None:
    method test_all_election_partial_key_backups_verified (line 292) | def test_all_election_partial_key_backups_verified(self) -> None:
    method test_publish_joint_key (line 319) | def test_publish_joint_key(self) -> None:

FILE: tests/unit/electionguard/test_hmac.py
  class TestHmac (line 6) | class TestHmac(BaseTestCase):
    method test_get_hmac (line 9) | def test_get_hmac(self) -> None:

FILE: tests/unit/electionguard/test_key_ceremony.py
  class TestKeyCeremony (line 35) | class TestKeyCeremony(BaseTestCase):
    method test_generate_election_key_pair (line 38) | def test_generate_election_key_pair(self) -> None:
    method test_generate_election_partial_key_backup (line 54) | def test_generate_election_partial_key_backup(self) -> None:
    method test_encrypt_then_verify_coordinate (line 73) | def test_encrypt_then_verify_coordinate(self) -> None:
    method test_verify_election_partial_key_backup (line 95) | def test_verify_election_partial_key_backup(self) -> None:
    method test_generate_election_partial_key_challenge (line 122) | def test_generate_election_partial_key_challenge(self) -> None:
    method test_verify_election_partial_key_challenge (line 148) | def test_verify_election_partial_key_challenge(self) -> None:
    method test_combine_election_public_keys (line 174) | def test_combine_election_public_keys(self) -> None:

FILE: tests/unit/electionguard/test_key_ceremony_mediator.py
  class TestKeyCeremonyMediator (line 21) | class TestKeyCeremonyMediator(BaseTestCase):
    method setUp (line 28) | def setUp(self) -> None:
    method test_reset (line 38) | def test_reset(self) -> None:
    method test_take_attendance (line 46) | def test_take_attendance(self) -> None:
    method test_exchange_of_backups (line 71) | def test_exchange_of_backups(self) -> None:
    method test_partial_key_backup_verification_success (line 117) | def test_partial_key_backup_verification_success(self) -> None:
    method test_partial_key_backup_verification_failure (line 151) | def test_partial_key_backup_verification_failure(self) -> None:

FILE: tests/unit/electionguard/test_logs.py
  class TestLogs (line 16) | class TestLogs(BaseTestCase):
    method test_log_methods (line 19) | def test_log_methods(self):
    method test_log_handlers (line 32) | def test_log_handlers(self):

FILE: tests/unit/electionguard/test_manifest.py
  class TestManifest (line 26) | class TestManifest(BaseTestCase):
    method _set_selection (line 30) | def _set_selection(
    method _set_candidate (line 47) | def _set_candidate(
    method test_get_selection_names_with_valid_selection (line 58) | def test_get_selection_names_with_valid_selection(self) -> None:
    method test_get_selection_names_with_missing_language (line 71) | def test_get_selection_names_with_missing_language(self) -> None:
    method test_get_selection_names_with_missing_candidate (line 84) | def test_get_selection_names_with_missing_candidate(self) -> None:
    method test_get_selection_names_with_write_in (line 97) | def test_get_selection_names_with_write_in(self) -> None:
    method test_simple_manifest_is_valid (line 110) | def test_simple_manifest_is_valid(self) -> None:
    method test_simple_manifest_can_serialize (line 120) | def test_simple_manifest_can_serialize(self) -> None:
    method test_manifest_has_deterministic_hash (line 132) | def test_manifest_has_deterministic_hash(self) -> None:
    method test_manifest_hash_is_consistent_regardless_of_format (line 141) | def test_manifest_hash_is_consistent_regardless_of_format(self) -> None:
    method test_manifest_from_file_generates_consistent_internal_description_contest_hashes (line 175) | def test_manifest_from_file_generates_consistent_internal_description_...
    method test_contest_description_valid_input_succeeds (line 189) | def test_contest_description_valid_input_succeeds(self) -> None:
    method test_contest_description_invalid_input_fails (line 223) | def test_contest_description_invalid_input_fails(self) -> None:

FILE: tests/unit/electionguard/test_scheduler.py
  function _callable (line 10) | def _callable(data: int):
  function _exception_callable (line 14) | def _exception_callable(something: int):
  class TestScheduler (line 18) | class TestScheduler(BaseTestCase):
    method test_schedule_callable_throws (line 21) | def test_schedule_callable_throws(self):
    method test_safe_map (line 33) | def test_safe_map(self):

FILE: tests/unit/electionguard/test_singleton.py
  class TestSingleton (line 5) | class TestSingleton(BaseTestCase):
    method test_singleton (line 8) | def test_singleton(self):
    method test_singleton_when_not_initialized (line 14) | def test_singleton_when_not_initialized(self):

FILE: tests/unit/electionguard/test_utils.py
  class TestUtils (line 8) | class TestUtils(BaseTestCase):
    method test_conversion_to_ticks_from_utc (line 11) | def test_conversion_to_ticks_from_utc(self):
    method test_conversion_to_ticks_from_local (line 18) | def test_conversion_to_ticks_from_local(self):
    method test_conversion_to_ticks_with_tz (line 25) | def test_conversion_to_ticks_with_tz(self):
    method test_conversion_to_ticks_produces_valid_epoch (line 46) | def test_conversion_to_ticks_produces_valid_epoch(self):

FILE: tests/unit/electionguard_gui/test_decryption_dto.py
  class TestDecryptionDto (line 9) | class TestDecryptionDto(BaseTestCase):
    method test_no_spoiled_ballots (line 12) | def test_no_spoiled_ballots(self) -> None:
    method test_get_status_with_no_guardians (line 22) | def test_get_status_with_no_guardians(self) -> None:
    method test_get_status_with_all_guardians_joined_but_not_completed (line 37) | def test_get_status_with_all_guardians_joined_but_not_completed(self) ...
    method test_get_status_with_all_guardians_joined_and_completed (line 49) | def test_get_status_with_all_guardians_joined_and_completed(self) -> N...
    method test_admins_can_not_join_key_ceremony (line 66) | def test_admins_can_not_join_key_ceremony(self, auth_service: MagicMoc...
    method test_users_can_join_key_ceremony_if_not_already_joined (line 81) | def test_users_can_join_key_ceremony_if_not_already_joined(
    method test_users_cant_join_twice (line 98) | def test_users_cant_join_twice(self, auth_service: MagicMock) -> None:

FILE: tests/unit/electionguard_gui/test_eel_utils.py
  class TestEelUtils (line 6) | class TestEelUtils(BaseTestCase):
    method test_utc_to_str_with_valid_utc_date (line 9) | def test_utc_to_str_with_valid_utc_date(self):
    method test_utc_to_str_with_empty (line 15) | def test_utc_to_str_with_empty(self):

FILE: tests/unit/electionguard_gui/test_election_dto.py
  class TestElectionDto (line 7) | class TestElectionDto(BaseTestCase):
    method test_get_status_with_no_guardians (line 10) | def test_get_status_with_no_guardians(self) -> None:
    method test_sum_two_ballots (line 30) | def test_sum_two_ballots(self) -> None:
    method test_sum_zero_ballots (line 53) | def test_sum_zero_ballots(self) -> None:

FILE: tests/unit/electionguard_gui/test_plaintext_ballot_service.py
  class TestPlaintextBallotService (line 10) | class TestPlaintextBallotService(BaseTestCase):
    method test_get_tally_report_with_no_contests (line 13) | def test_get_tally_report_with_no_contests(self) -> None:
    method test_given_one_contest_with_valid_name_when_get_tally_report_then_name_returned (line 34) | def test_given_one_contest_with_valid_name_when_get_tally_report_then_...
    method test_given_one_contest_with_invalid_name_when_get_tally_report_then_name_is_na (line 59) | def test_given_one_contest_with_invalid_name_when_get_tally_report_the...
    method test_given_two_contests_with_duplicate_names_when_get_tally_report_then_both_names_returned (line 85) | def test_given_two_contests_with_duplicate_names_when_get_tally_report...
    method test_zero_sections (line 119) | def test_zero_sections(self) -> None:
    method test_one_non_write_in (line 137) | def test_one_non_write_in(self, plaintext_tally_selection: MagicMock) ...
    method test_duplicate_section_names (line 169) | def test_duplicate_section_names(
    method test_one_write_in (line 219) | def test_one_write_in(self, plaintext_tally_selection: MagicMock) -> N...
    method test_zero_write_in (line 241) | def test_zero_write_in(self, plaintext_tally_selection: MagicMock) -> ...
Condensed preview — 303 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (1,575K chars).
[
  {
    "path": ".github/ISSUE_TEMPLATE/bug_report.yml",
    "chars": 1639,
    "preview": "name: 🐞 Bug\ndescription: Submit a bug if something isn't working as expected.\ntitle: \"🐞 <title>\"\nlabels: [bug, triage]\nb"
  },
  {
    "path": ".github/ISSUE_TEMPLATE/config.yml",
    "chars": 326,
    "preview": "blank_issues_enabled: false\ncontact_links:\n  - name: Discussions\n    url: https://github.com/microsoft/electionguard/dis"
  },
  {
    "path": ".github/ISSUE_TEMPLATE/enhancement.yml",
    "chars": 1115,
    "preview": "name: ✨ Enhancement\ndescription: Suggest an enhancement or an improvement.\ntitle: \"✨ <title>\"\nlabels: [enhancement, tria"
  },
  {
    "path": ".github/pull_request_template.md",
    "chars": 248,
    "preview": "[//]: # (🚨 Please review the CONTRIBUTING.md in this repository. 💔Thank you!)\n\n### Issue\n*Link your PR to an issue*\n\nFix"
  },
  {
    "path": ".github/workflows/pull_request.yml",
    "chars": 3095,
    "preview": "name: Validate Pull Request\n\non:\n  push:\n    branches: [main, \"integration/**\", \"releases/**\"]\n  pull_request:\n    branc"
  },
  {
    "path": ".github/workflows/release.yml",
    "chars": 4702,
    "preview": "name: Release Build\n\non:\n  milestone:\n    types: [closed]\n\nenv:\n  PYTHON_VERSION: 3.9\n  POETRY_PATH: \"$HOME/.poetry/bin\""
  },
  {
    "path": ".gitignore",
    "chars": 2114,
    "preview": "# Byte-compiled / optimized / DLL files\n__pycache__/\n*.py[cod]\n*$py.class\n\n# C extensions\n*.so\n\ndata/0.95.0/\ndata/1.0/\n\n"
  },
  {
    "path": ".vscode/extensions.json",
    "chars": 678,
    "preview": "{\n  // See https://go.microsoft.com/fwlink/?LinkId=827846 to learn about workspace recommendations.\n  // Extension ident"
  },
  {
    "path": "CODE_OF_CONDUCT.md",
    "chars": 453,
    "preview": "# Microsoft Open Source Code of Conduct\r\n\r\nThis project has adopted the [Microsoft Open Source Code of Conduct](https://"
  },
  {
    "path": "CONTRIBUTING.md",
    "chars": 1937,
    "preview": "## Contributing\n\nThis project welcomes contributions and suggestions. Before you get started, you should read the [readm"
  },
  {
    "path": "LICENSE",
    "chars": 1162,
    "preview": "    MIT License\r\n\r\n    Copyright (c) Microsoft Corporation.\r\n\r\n    Permission is hereby granted, free of charge, to any "
  },
  {
    "path": "Makefile",
    "chars": 7524,
    "preview": ".PHONY: all environment openssl-fix install install-gmp install-gmp-mac install-gmp-linux install-gmp-windows install-mk"
  },
  {
    "path": "README.md",
    "chars": 10267,
    "preview": "![Microsoft Defending Democracy Program: ElectionGuard Python][banner image]\r\n\r\n# 🗳 ElectionGuard Python\r\n\r\n[![ElectionG"
  },
  {
    "path": "SECURITY.md",
    "chars": 2865,
    "preview": "<!-- BEGIN MICROSOFT SECURITY.MD V0.0.3 BLOCK -->\r\n\r\n## Security\r\n\r\nMicrosoft takes the security of our software product"
  },
  {
    "path": "data/ballot_in_simple.json",
    "chars": 580,
    "preview": "{\n  \"object_id\": \"some-external-id-string-123\",\n  \"style_id\": \"jefferson-county-ballot-style\",\n  \"contests\": [\n    {\n   "
  },
  {
    "path": "data/election_manifest_simple.json",
    "chars": 9143,
    "preview": "{\n  \"spec_version\": \"v0.95\",\n  \"geopolitical_units\": [\n    {\n      \"object_id\": \"jefferson-county\",\n      \"name\": \"Jeffe"
  },
  {
    "path": "data/manifest-full.json",
    "chars": 9895,
    "preview": "{\n  \"election_scope_id\": \"jefferson-county-primary\",\n  \"spec_version\": \"1.0\",\n  \"type\": \"primary\",\n  \"start_date\": \"2020"
  },
  {
    "path": "data/manifest-hamilton-general.json",
    "chars": 45807,
    "preview": "{\n  \"election_scope_id\": \"hamilton-county-general-election\",\n  \"spec_version\": \"1.0\",\n  \"type\": \"general\",\n  \"start_date"
  },
  {
    "path": "data/manifest-minimal.json",
    "chars": 2206,
    "preview": "{\n  \"election_scope_id\": \"franklin-minimal-referendum-manifest\",\n  \"spec_version\": \"1.0\",\n  \"type\": \"general\",\n  \"start_"
  },
  {
    "path": "data/manifest-small.json",
    "chars": 5624,
    "preview": "{\n  \"election_scope_id\": \"franklin-county-general-march2020\",\n  \"spec_version\": \"1.0\",\n  \"type\": \"general\",\n  \"start_dat"
  },
  {
    "path": "data/plaintext_ballots_simple.json",
    "chars": 3394,
    "preview": "[\n  {\n    \"object_id\": \"1048ce32-f1b1-4b05-b7fb-8c615ac842ee\",\n    \"style_id\": \"jefferson-county-ballot-style\",\n    \"con"
  },
  {
    "path": "data/plaintext_two_ballots_minimal.json",
    "chars": 694,
    "preview": "[\r\n  {\r\n    \"object_id\": \"external-ballot-id-1234\",\r\n    \"style_id\": \"ballot-style-01\",\r\n    \"contests\": [\r\n      {\r\n   "
  },
  {
    "path": "data/plaintext_two_ballots_small.json",
    "chars": 1472,
    "preview": "[\r\n  {\r\n    \"object_id\": \"external-ballot-id-2345\",\r\n    \"style_id\": \"franklin-county-ozark-schools\",\r\n    \"contests\": ["
  },
  {
    "path": "docs/0_Configure_Election.ipynb",
    "chars": 5740,
    "preview": "{\n \"cells\": [\n  {\n   \"cell_type\": \"markdown\",\n   \"source\": [\n    \"# Election Configuration\\n\",\n    \"\\n\",\n    \"An electio"
  },
  {
    "path": "docs/1_Key_Ceremony.md",
    "chars": 6098,
    "preview": "# Key Ceremony\n\nThe ElectionGuard Key Ceremony is the process used by Election Officials to share encryption keys for an"
  },
  {
    "path": "docs/2_Encrypt_Ballots.md",
    "chars": 2348,
    "preview": "# Encrypt Ballots\n\nThe primary function of ElectionGuard is to encrypt ballots.  Ballots are encrypted on a uniquely ide"
  },
  {
    "path": "docs/3_Cast_and_Spoil.md",
    "chars": 6153,
    "preview": "# Cast and Spoil Ballots\n\nEach ballot that is completed by a voter must be either cast or spoiled.  A cast ballot is a b"
  },
  {
    "path": "docs/4_Decrypt_Tally.md",
    "chars": 7754,
    "preview": "# Decryption\n\nAt the conclusion of voting, all of the cast ballots are published in their encrypted form in the election"
  },
  {
    "path": "docs/5_Publish_and_Verify.md",
    "chars": 1396,
    "preview": "# Publish and Verify\n\n## Publish\n\nPublishing the election artifacts helps ensure third parties can verify the election. "
  },
  {
    "path": "docs/Build_and_Run.md",
    "chars": 2069,
    "preview": "# Build and Run\n\nThese instructions can be used to build and run the project.\n\n## Setup\n\n### 1. Initialize dev environme"
  },
  {
    "path": "docs/Design_and_Architecture.md",
    "chars": 6342,
    "preview": "# Design & Architecture\n\nThis describes the design and architecture of the `electionguard-python` project.\n\n## Design\n\n#"
  },
  {
    "path": "docs/Election_Manifest.md",
    "chars": 15225,
    "preview": "# Overview\n\nThere are many types of elections. We need a base set of data that shows how these different types of electi"
  },
  {
    "path": "docs/Project_Workflow.md",
    "chars": 2081,
    "preview": "# Project Workflow\n\n## ✨ Start an Iteration\nEach iteration on this repository will be tracked by a GitHub **[Milestone]("
  },
  {
    "path": "docs/Tablet Setup.md",
    "chars": 3473,
    "preview": "# Setup Surface Go 3 Tablet\r\n\r\nThis documentation is a reference on how to setup a brand new computer (in this case a Su"
  },
  {
    "path": "docs/index.md",
    "chars": 5973,
    "preview": "![Microsoft Defending Democracy Program: ElectionGuard Python](https://github.com/microsoft/electionguard-python/blob/ma"
  },
  {
    "path": "mkdocs.yml",
    "chars": 982,
    "preview": "site_name: ElectionGuard Python\nsite_url: https://electionguard-python.readthedocs.io/\n# site_description:\nsite_author: "
  },
  {
    "path": "pyproject.toml",
    "chars": 3247,
    "preview": "[project]\nname = \"electionguard\"\nversion = \"1.4.0\"\nrequires-python = \">=3.9.5,<4.0.0\"\ndescription = \"ElectionGuard: Supp"
  },
  {
    "path": "src/electionguard/__init__.py",
    "chars": 18840,
    "preview": "import importlib.metadata\n\n# <AUTOGEN_INIT>\nfrom electionguard import ballot\nfrom electionguard import ballot_box\nfrom e"
  },
  {
    "path": "src/electionguard/ballot.py",
    "chars": 38124,
    "preview": "from dataclasses import dataclass, field, replace\nfrom datetime import datetime, timezone\nfrom enum import Enum\nfrom fun"
  },
  {
    "path": "src/electionguard/ballot_box.py",
    "chars": 4028,
    "preview": "from dataclasses import dataclass, field\nfrom typing import Dict, Optional\n\nfrom .ballot import (\n    BallotBoxState,\n  "
  },
  {
    "path": "src/electionguard/ballot_code.py",
    "chars": 941,
    "preview": "from .hash import hash_elems\nfrom .group import ElementModQ\n\n\ndef get_hash_for_device(\n    device_id: int, session_id: i"
  },
  {
    "path": "src/electionguard/ballot_compact.py",
    "chars": 5601,
    "preview": "from dataclasses import dataclass\nfrom typing import Dict, List\n\n\nfrom .ballot import (\n    CiphertextBallot,\n    Submit"
  },
  {
    "path": "src/electionguard/ballot_validator.py",
    "chars": 4303,
    "preview": "from .ballot import CiphertextBallot, CiphertextBallotContest, CiphertextBallotSelection\nfrom .election import Ciphertex"
  },
  {
    "path": "src/electionguard/big_integer.py",
    "chars": 3401,
    "preview": "from typing import Any, Tuple, Union\nfrom base64 import b16decode\n\n# pylint: disable=no-name-in-module\nfrom gmpy2 import"
  },
  {
    "path": "src/electionguard/byte_padding.py",
    "chars": 1758,
    "preview": "from enum import IntEnum\nfrom typing import Literal\n\n\n_PAD_BYTE = b\"\\x00\"\n_BYTE_ORDER: Literal[\"little\", \"big\"] = \"big\"\n"
  },
  {
    "path": "src/electionguard/chaum_pedersen.py",
    "chars": 17608,
    "preview": "# pylint: disable=too-many-instance-attributes\nfrom dataclasses import dataclass\n\nfrom .elgamal import ElGamalCiphertext"
  },
  {
    "path": "src/electionguard/constants.py",
    "chars": 6098,
    "preview": "\"\"\"Creating and managing mathematic constants for the election.\"\"\"\n\nfrom os import getenv\n\nfrom dataclasses import datac"
  },
  {
    "path": "src/electionguard/data_store.py",
    "chars": 2751,
    "preview": "from collections.abc import Mapping\n\nfrom typing import (\n    Dict,\n    Generic,\n    Iterable,\n    Iterator,\n    List,\n "
  },
  {
    "path": "src/electionguard/decrypt_with_secrets.py",
    "chars": 14153,
    "preview": "from typing import List, Optional\n\nfrom .ballot import (\n    CiphertextBallot,\n    CiphertextBallotContest,\n    Cipherte"
  },
  {
    "path": "src/electionguard/decrypt_with_shares.py",
    "chars": 7687,
    "preview": "from typing import Dict, Optional, Tuple\n\n\nfrom .ballot import SubmittedBallot, CiphertextContest, CiphertextSelection\nf"
  },
  {
    "path": "src/electionguard/decryption.py",
    "chars": 24229,
    "preview": "from typing import Dict, List, Optional, Tuple\nfrom electionguard.chaum_pedersen import ChaumPedersenProof, make_chaum_p"
  },
  {
    "path": "src/electionguard/decryption_mediator.py",
    "chars": 13862,
    "preview": "from typing import Dict, List, Optional\n\n\nfrom .ballot import SubmittedBallot\nfrom .decryption import (\n    compute_lagr"
  },
  {
    "path": "src/electionguard/decryption_share.py",
    "chars": 9017,
    "preview": "from dataclasses import dataclass, field\nfrom typing import Dict, Optional, Tuple, Union\n\nfrom .chaum_pedersen import Ch"
  },
  {
    "path": "src/electionguard/discrete_log.py",
    "chars": 6238,
    "preview": "# pylint: disable=global-statement\n# support for computing discrete logs, with a cache so they're never recomputed\n\nimpo"
  },
  {
    "path": "src/electionguard/election.py",
    "chars": 4893,
    "preview": "\"\"\"Context for election encryption.\"\"\"\n\nfrom dataclasses import dataclass, field\nfrom typing import Dict, Optional\n\nfrom"
  },
  {
    "path": "src/electionguard/election_object_base.py",
    "chars": 1477,
    "preview": "\"\"\"Base objects to derive other election objects.\"\"\"\n\nfrom dataclasses import dataclass\nfrom typing import List, Sequenc"
  },
  {
    "path": "src/electionguard/election_polynomial.py",
    "chars": 5227,
    "preview": "from dataclasses import dataclass\nfrom typing import Dict, List, Optional\n\nfrom .elgamal import ElGamalKeyPair\nfrom .gro"
  },
  {
    "path": "src/electionguard/elgamal.py",
    "chars": 9011,
    "preview": "from dataclasses import dataclass\nfrom typing import Any, Iterable, Optional, Union\n\n\nfrom .big_integer import bytes_to_"
  },
  {
    "path": "src/electionguard/encrypt.py",
    "chars": 20162,
    "preview": "from datetime import datetime, timezone\nfrom dataclasses import dataclass, field\nfrom typing import Dict, List, Optional"
  },
  {
    "path": "src/electionguard/group.py",
    "chars": 7839,
    "preview": "\"\"\"Basic modular math module.\n\nSupport for basic modular math in ElectionGuard. This code's primary purpose is to be \"co"
  },
  {
    "path": "src/electionguard/guardian.py",
    "chars": 20956,
    "preview": "# pylint: disable=too-many-public-methods\n\nfrom dataclasses import dataclass\nfrom typing import Dict, List, Optional, Ty"
  },
  {
    "path": "src/electionguard/hash.py",
    "chars": 3426,
    "preview": "# pylint: disable=isinstance-second-argument-not-valid-type\nfrom abc import abstractmethod\nfrom collections.abc import S"
  },
  {
    "path": "src/electionguard/hmac.py",
    "chars": 1149,
    "preview": "\"\"\"Implementation of Hashing for Message Authentication Codes (HMAC)\"\"\"\n\nfrom hmac import digest\nfrom typing import Opti"
  },
  {
    "path": "src/electionguard/key_ceremony.py",
    "chars": 9594,
    "preview": "from dataclasses import dataclass\nfrom typing import List, Type, TypeVar, Optional\n\nfrom .serialize import padded_decode"
  },
  {
    "path": "src/electionguard/key_ceremony_mediator.py",
    "chars": 10773,
    "preview": "from dataclasses import dataclass, field\nfrom typing import Dict, Iterable, List, Optional\nfrom .key_ceremony import (\n "
  },
  {
    "path": "src/electionguard/logs.py",
    "chars": 5612,
    "preview": "import inspect\nimport logging\nimport os.path\nimport sys\nfrom typing import Any, List, Tuple\nfrom logging.handlers import"
  },
  {
    "path": "src/electionguard/manifest.py",
    "chars": 37960,
    "preview": "from dataclasses import dataclass, field, InitVar\nfrom datetime import datetime\nfrom enum import Enum, unique\nfrom typin"
  },
  {
    "path": "src/electionguard/nonces.py",
    "chars": 2380,
    "preview": "# pylint: disable=too-many-ancestors\nfrom typing import Union, Sequence, List, overload\n\nfrom electionguard.group import"
  },
  {
    "path": "src/electionguard/proof.py",
    "chars": 600,
    "preview": "from enum import Enum\n\nfrom .utils import space_between_capitals\n\n\nclass ProofUsage(Enum):\n    \"\"\"Usage case for proof\"\""
  },
  {
    "path": "src/electionguard/py.typed",
    "chars": 0,
    "preview": ""
  },
  {
    "path": "src/electionguard/scheduler.py",
    "chars": 3858,
    "preview": "# pylint: disable=consider-using-with\nfrom __future__ import annotations\nimport traceback\nfrom typing import Any, Callab"
  },
  {
    "path": "src/electionguard/schnorr.py",
    "chars": 2482,
    "preview": "from dataclasses import dataclass\n\nfrom .elgamal import ElGamalKeyPair, ElGamalPublicKey\nfrom .group import (\n    Elemen"
  },
  {
    "path": "src/electionguard/serialize.py",
    "chars": 3832,
    "preview": "from datetime import datetime\nfrom io import TextIOWrapper\nimport json\nimport os\nfrom pathlib import Path\nfrom typing im"
  },
  {
    "path": "src/electionguard/singleton.py",
    "chars": 457,
    "preview": "from typing import Any\n\n\nclass Singleton:\n    \"\"\"A Singleton Class\"\"\"\n\n    __instance = None\n\n    @staticmethod\n    def "
  },
  {
    "path": "src/electionguard/tally.py",
    "chars": 14880,
    "preview": "# pylint: disable=unnecessary-comprehension\nfrom dataclasses import dataclass, field\nfrom typing import Iterable, Option"
  },
  {
    "path": "src/electionguard/type.py",
    "chars": 100,
    "preview": "BallotId = str\nContestId = str\nGuardianId = str\nMediatorId = str\nVerifierId = str\nSelectionId = str\n"
  },
  {
    "path": "src/electionguard/utils.py",
    "chars": 4683,
    "preview": "from datetime import datetime, timezone\nfrom enum import Enum\nfrom re import sub\nfrom typing import Callable, List, Opti"
  },
  {
    "path": "src/electionguard_cli/__init__.py",
    "chars": 6304,
    "preview": "from electionguard_cli import cli_models\nfrom electionguard_cli import cli_steps\nfrom electionguard_cli import e2e\nfrom "
  },
  {
    "path": "src/electionguard_cli/cli_models/__init__.py",
    "chars": 1198,
    "preview": "from electionguard_cli.cli_models import cli_decrypt_results\nfrom electionguard_cli.cli_models import cli_election_input"
  },
  {
    "path": "src/electionguard_cli/cli_models/cli_decrypt_results.py",
    "chars": 537,
    "preview": "from dataclasses import dataclass\nfrom typing import Dict\nfrom electionguard.tally import CiphertextTally, PlaintextTall"
  },
  {
    "path": "src/electionguard_cli/cli_models/cli_election_inputs_base.py",
    "chars": 339,
    "preview": "from abc import ABC\nfrom typing import List\nfrom electionguard.guardian import Guardian\nfrom electionguard.manifest impo"
  },
  {
    "path": "src/electionguard_cli/cli_models/e2e_build_election_results.py",
    "chars": 368,
    "preview": "from dataclasses import dataclass\n\nfrom electionguard.election import CiphertextElectionContext\nfrom electionguard.manif"
  },
  {
    "path": "src/electionguard_cli/cli_models/encrypt_results.py",
    "chars": 353,
    "preview": "from dataclasses import dataclass\nfrom typing import List\nfrom electionguard.ballot import CiphertextBallot\nfrom electio"
  },
  {
    "path": "src/electionguard_cli/cli_models/mark_results.py",
    "chars": 362,
    "preview": "from typing import List\nfrom electionguard.ballot import PlaintextBallot\n\n\nclass MarkResults:\n    \"\"\"Responsible for hol"
  },
  {
    "path": "src/electionguard_cli/cli_models/submit_results.py",
    "chars": 367,
    "preview": "from typing import List\nfrom electionguard.ballot import SubmittedBallot\n\n\nclass SubmitResults:\n    \"\"\"Responsible for h"
  },
  {
    "path": "src/electionguard_cli/cli_steps/__init__.py",
    "chars": 2092,
    "preview": "from electionguard_cli.cli_steps import cli_step_base\nfrom electionguard_cli.cli_steps import decrypt_step\nfrom election"
  },
  {
    "path": "src/electionguard_cli/cli_steps/cli_step_base.py",
    "chars": 995,
    "preview": "from typing import Any, Optional\nimport click\n\n\nclass CliStepBase:\n    \"\"\"\n    Responsible for providing common function"
  },
  {
    "path": "src/electionguard_cli/cli_steps/decrypt_step.py",
    "chars": 2773,
    "preview": "from typing import List\nimport click\nfrom electionguard.guardian import Guardian\nfrom electionguard.utils import get_opt"
  },
  {
    "path": "src/electionguard_cli/cli_steps/election_builder_step.py",
    "chars": 1544,
    "preview": "from typing import Optional\nimport click\nfrom electionguard.elgamal import ElGamalPublicKey\nfrom electionguard.group imp"
  },
  {
    "path": "src/electionguard_cli/cli_steps/encrypt_votes_step.py",
    "chars": 2597,
    "preview": "from typing import List, Tuple\nimport click\n\nfrom electionguard.encrypt import EncryptionDevice, EncryptionMediator\nfrom"
  },
  {
    "path": "src/electionguard_cli/cli_steps/input_retrieval_step_base.py",
    "chars": 2611,
    "preview": "from typing import List, Type, TypeVar\nfrom os.path import isfile, isdir, join\nfrom os import listdir\nfrom io import Tex"
  },
  {
    "path": "src/electionguard_cli/cli_steps/key_ceremony_step.py",
    "chars": 1040,
    "preview": "from typing import List\nfrom electionguard.guardian import Guardian\nfrom electionguard.key_ceremony import (\n    Electio"
  },
  {
    "path": "src/electionguard_cli/cli_steps/mark_ballots_step.py",
    "chars": 893,
    "preview": "from typing import Optional\nfrom electionguard_tools.factories import BallotFactory\n\nfrom .cli_step_base import CliStepB"
  },
  {
    "path": "src/electionguard_cli/cli_steps/output_step_base.py",
    "chars": 1617,
    "preview": "from typing import List, Any\n\nfrom electionguard import to_file\nfrom electionguard.guardian import Guardian, GuardianRec"
  },
  {
    "path": "src/electionguard_cli/cli_steps/print_results_step.py",
    "chars": 2222,
    "preview": "from typing import Dict\nfrom electionguard.manifest import Manifest\nfrom electionguard.type import BallotId\nfrom electio"
  },
  {
    "path": "src/electionguard_cli/cli_steps/submit_ballots_step.py",
    "chars": 1181,
    "preview": "from typing import List\nimport click\n\nfrom electionguard.data_store import DataStore\nfrom electionguard.ballot_box impor"
  },
  {
    "path": "src/electionguard_cli/cli_steps/tally_step.py",
    "chars": 2251,
    "preview": "from typing import Iterable, List, Tuple\nfrom electionguard.scheduler import Scheduler\nfrom electionguard.data_store imp"
  },
  {
    "path": "src/electionguard_cli/e2e/__init__.py",
    "chars": 1083,
    "preview": "from electionguard_cli.e2e import e2e_command\nfrom electionguard_cli.e2e import e2e_election_builder_step\nfrom electiong"
  },
  {
    "path": "src/electionguard_cli/e2e/e2e_command.py",
    "chars": 3662,
    "preview": "from io import TextIOWrapper\nimport click\n\n\nfrom ..cli_steps import (\n    DecryptStep,\n    PrintResultsStep,\n    TallySt"
  },
  {
    "path": "src/electionguard_cli/e2e/e2e_election_builder_step.py",
    "chars": 650,
    "preview": "from electionguard.key_ceremony import ElectionJointKey\nfrom .e2e_inputs import E2eInputs\nfrom ..cli_models import Build"
  },
  {
    "path": "src/electionguard_cli/e2e/e2e_input_retrieval_step.py",
    "chars": 1505,
    "preview": "from io import TextIOWrapper\nfrom typing import Optional\nfrom electionguard.ballot import PlaintextBallot\n\nfrom election"
  },
  {
    "path": "src/electionguard_cli/e2e/e2e_inputs.py",
    "chars": 1170,
    "preview": "from typing import List, Optional\nfrom electionguard.ballot import PlaintextBallot\nfrom electionguard.guardian import Gu"
  },
  {
    "path": "src/electionguard_cli/e2e/e2e_publish_step.py",
    "chars": 2510,
    "preview": "from shutil import make_archive\nfrom os.path import splitext\nfrom tempfile import TemporaryDirectory\nfrom click import e"
  },
  {
    "path": "src/electionguard_cli/e2e/submit_votes_step.py",
    "chars": 1944,
    "preview": "from typing import List\nimport click\n\nfrom electionguard.data_store import DataStore\nfrom electionguard.ballot_box impor"
  },
  {
    "path": "src/electionguard_cli/encrypt_ballots/__init__.py",
    "chars": 1287,
    "preview": "from electionguard_cli.encrypt_ballots import encrypt_ballot_inputs\nfrom electionguard_cli.encrypt_ballots import encryp"
  },
  {
    "path": "src/electionguard_cli/encrypt_ballots/encrypt_ballot_inputs.py",
    "chars": 948,
    "preview": "from typing import List\nfrom electionguard.ballot import PlaintextBallot\nfrom electionguard.election import CiphertextEl"
  },
  {
    "path": "src/electionguard_cli/encrypt_ballots/encrypt_ballots_election_builder_step.py",
    "chars": 799,
    "preview": "from ..cli_models import BuildElectionResults\nfrom ..cli_steps import ElectionBuilderStep\nfrom .encrypt_ballot_inputs im"
  },
  {
    "path": "src/electionguard_cli/encrypt_ballots/encrypt_ballots_input_retrieval_step.py",
    "chars": 992,
    "preview": "from io import TextIOWrapper\nfrom electionguard.ballot import PlaintextBallot\n\nfrom electionguard.manifest import Manife"
  },
  {
    "path": "src/electionguard_cli/encrypt_ballots/encrypt_ballots_publish_step.py",
    "chars": 841,
    "preview": "from click import echo\n\nfrom electionguard import to_file\n\nfrom ..cli_models import EncryptResults\nfrom ..cli_steps impo"
  },
  {
    "path": "src/electionguard_cli/encrypt_ballots/encrypt_command.py",
    "chars": 1656,
    "preview": "from io import TextIOWrapper\nimport click\n\n\nfrom .encrypt_ballots_election_builder_step import EncryptBallotsElectionBui"
  },
  {
    "path": "src/electionguard_cli/import_ballots/__init__.py",
    "chars": 1276,
    "preview": "from electionguard_cli.import_ballots import import_ballot_inputs\nfrom electionguard_cli.import_ballots import import_ba"
  },
  {
    "path": "src/electionguard_cli/import_ballots/import_ballot_inputs.py",
    "chars": 1281,
    "preview": "from typing import List\nfrom electionguard.ballot import SubmittedBallot\nfrom electionguard.election import CiphertextEl"
  },
  {
    "path": "src/electionguard_cli/import_ballots/import_ballots_command.py",
    "chars": 3069,
    "preview": "from io import TextIOWrapper\nimport click\n\nfrom .import_ballots_publish_step import ImportBallotsPublishStep\nfrom .impor"
  },
  {
    "path": "src/electionguard_cli/import_ballots/import_ballots_election_builder_step.py",
    "chars": 794,
    "preview": "from ..cli_models import BuildElectionResults\nfrom ..cli_steps import ElectionBuilderStep\nfrom .import_ballot_inputs imp"
  },
  {
    "path": "src/electionguard_cli/import_ballots/import_ballots_input_retrieval_step.py",
    "chars": 3231,
    "preview": "from typing import List\nfrom io import TextIOWrapper\nfrom os import listdir\nfrom os.path import join\n\nfrom electionguard"
  },
  {
    "path": "src/electionguard_cli/import_ballots/import_ballots_publish_step.py",
    "chars": 1957,
    "preview": "from typing import List\nfrom shutil import make_archive\nfrom os.path import splitext\nfrom tempfile import TemporaryDirec"
  },
  {
    "path": "src/electionguard_cli/mark_ballots/__init__.py",
    "chars": 1182,
    "preview": "from electionguard_cli.mark_ballots import mark_ballot_inputs\nfrom electionguard_cli.mark_ballots import mark_ballots_el"
  },
  {
    "path": "src/electionguard_cli/mark_ballots/mark_ballot_inputs.py",
    "chars": 602,
    "preview": "from electionguard.election import CiphertextElectionContext\nfrom electionguard.manifest import Manifest\n\nfrom ..cli_mod"
  },
  {
    "path": "src/electionguard_cli/mark_ballots/mark_ballots_election_builder_step.py",
    "chars": 784,
    "preview": "from ..cli_models import BuildElectionResults\nfrom ..cli_steps import ElectionBuilderStep\nfrom .mark_ballot_inputs impor"
  },
  {
    "path": "src/electionguard_cli/mark_ballots/mark_ballots_input_retrieval_step.py",
    "chars": 752,
    "preview": "from io import TextIOWrapper\n\nfrom electionguard.manifest import Manifest\n\nfrom .mark_ballot_inputs import MarkBallotInp"
  },
  {
    "path": "src/electionguard_cli/mark_ballots/mark_ballots_publish_step.py",
    "chars": 682,
    "preview": "from click import echo\n\nfrom electionguard import to_file\n\nfrom ..cli_models import MarkResults\nfrom ..cli_steps import "
  },
  {
    "path": "src/electionguard_cli/mark_ballots/mark_command.py",
    "chars": 1472,
    "preview": "from io import TextIOWrapper\nimport click\n\n\nfrom .mark_ballots_election_builder_step import MarkBallotsElectionBuilderSt"
  },
  {
    "path": "src/electionguard_cli/setup_election/__init__.py",
    "chars": 1132,
    "preview": "from electionguard_cli.setup_election import output_setup_files_step\nfrom electionguard_cli.setup_election import setup_"
  },
  {
    "path": "src/electionguard_cli/setup_election/output_setup_files_step.py",
    "chars": 2796,
    "preview": "from os import path\nfrom os.path import join\nfrom typing import Optional\n\nimport click\nfrom electionguard.election impor"
  },
  {
    "path": "src/electionguard_cli/setup_election/setup_election_builder_step.py",
    "chars": 695,
    "preview": "from electionguard import ElectionJointKey\n\nfrom .setup_inputs import SetupInputs\nfrom ..cli_models import BuildElection"
  },
  {
    "path": "src/electionguard_cli/setup_election/setup_election_command.py",
    "chars": 2374,
    "preview": "from io import TextIOWrapper\nimport click\n\nfrom .setup_election_builder_step import SetupElectionBuilderStep\nfrom .outpu"
  },
  {
    "path": "src/electionguard_cli/setup_election/setup_input_retrieval_step.py",
    "chars": 1040,
    "preview": "from io import TextIOWrapper\nfrom typing import Optional\nfrom electionguard.key_ceremony import CeremonyDetails\nfrom ele"
  },
  {
    "path": "src/electionguard_cli/setup_election/setup_inputs.py",
    "chars": 792,
    "preview": "from typing import List, Optional\n\nfrom electionguard.guardian import Guardian\nfrom electionguard.manifest import Manife"
  },
  {
    "path": "src/electionguard_cli/start.py",
    "chars": 651,
    "preview": "import click\n\nfrom .setup_election.setup_election_command import SetupElectionCommand\nfrom .e2e.e2e_command import E2eCo"
  },
  {
    "path": "src/electionguard_cli/submit_ballots/__init__.py",
    "chars": 1252,
    "preview": "from electionguard_cli.submit_ballots import submit_ballot_inputs\nfrom electionguard_cli.submit_ballots import submit_ba"
  },
  {
    "path": "src/electionguard_cli/submit_ballots/submit_ballot_inputs.py",
    "chars": 858,
    "preview": "from typing import List\n\nfrom electionguard.election import CiphertextElectionContext\nfrom electionguard.manifest import"
  },
  {
    "path": "src/electionguard_cli/submit_ballots/submit_ballots_election_builder_step.py",
    "chars": 794,
    "preview": "from ..cli_models import BuildElectionResults\nfrom ..cli_steps import ElectionBuilderStep\nfrom .submit_ballot_inputs imp"
  },
  {
    "path": "src/electionguard_cli/submit_ballots/submit_ballots_input_retrieval_step.py",
    "chars": 1178,
    "preview": "from io import TextIOWrapper\n\nfrom electionguard.manifest import Manifest\nfrom electionguard.ballot import CiphertextBal"
  },
  {
    "path": "src/electionguard_cli/submit_ballots/submit_ballots_publish_step.py",
    "chars": 696,
    "preview": "from click import echo\n\nfrom electionguard import to_file\n\nfrom ..cli_models import SubmitResults\nfrom ..cli_steps impor"
  },
  {
    "path": "src/electionguard_cli/submit_ballots/submit_command.py",
    "chars": 1776,
    "preview": "from io import TextIOWrapper\nimport click\n\n\nfrom .submit_ballots_election_builder_step import SubmitBallotsElectionBuild"
  },
  {
    "path": "src/electionguard_db/docker-compose.db.yml",
    "chars": 756,
    "preview": "version: \"3.8\"\nservices:\n  mongo:\n    image: mongo:4.4\n    container_name: \"electionguard-db\"\n    restart: always\n    po"
  },
  {
    "path": "src/electionguard_db/mongo-init.js",
    "chars": 661,
    "preview": "db.createCollection(\"guardians\");\ndb.createCollection(\"key_ceremonies\");\ndb.createCollection(\"elections\");\ndb.createColl"
  },
  {
    "path": "src/electionguard_gui/.dockerignore",
    "chars": 31,
    "preview": "docker-compose*.yml\nDockerfile\n"
  },
  {
    "path": "src/electionguard_gui/Dockerfile",
    "chars": 3064,
    "preview": "FROM ubuntu:22.04\n\n##################################################################################\n# Install pyenv (h"
  },
  {
    "path": "src/electionguard_gui/__init__.py",
    "chars": 7558,
    "preview": "from electionguard_gui import components\nfrom electionguard_gui import containers\nfrom electionguard_gui import eel_util"
  },
  {
    "path": "src/electionguard_gui/components/__init__.py",
    "chars": 3507,
    "preview": "from electionguard_gui.components import component_base\nfrom electionguard_gui.components import create_decryption_compo"
  },
  {
    "path": "src/electionguard_gui/components/component_base.py",
    "chars": 971,
    "preview": "from abc import ABC\nimport traceback\nfrom typing import Any\nfrom electionguard_gui.eel_utils import eel_fail\n\nfrom elect"
  },
  {
    "path": "src/electionguard_gui/components/create_decryption_component.py",
    "chars": 2392,
    "preview": "from typing import Any\nimport eel\nfrom electionguard_gui.eel_utils import eel_fail, eel_success\nfrom electionguard_gui.c"
  },
  {
    "path": "src/electionguard_gui/components/create_election_component.py",
    "chars": 5326,
    "preview": "from os import path\nfrom shutil import make_archive, rmtree\nfrom typing import Any\nimport eel\nfrom electionguard.constan"
  },
  {
    "path": "src/electionguard_gui/components/create_key_ceremony_component.py",
    "chars": 2065,
    "preview": "from typing import Any\nimport eel\nfrom electionguard_gui.components.component_base import ComponentBase\n\nfrom electiongu"
  },
  {
    "path": "src/electionguard_gui/components/election_list_component.py",
    "chars": 806,
    "preview": "from typing import Any\nimport eel\nfrom electionguard_gui.components.component_base import ComponentBase\nfrom electiongua"
  },
  {
    "path": "src/electionguard_gui/components/export_election_record_component.py",
    "chars": 3303,
    "preview": "import os\nfrom tempfile import TemporaryDirectory\nfrom os.path import splitext\nfrom typing import Any\nfrom shutil import"
  },
  {
    "path": "src/electionguard_gui/components/export_encryption_package_component.py",
    "chars": 1613,
    "preview": "import os\nfrom typing import Any\nfrom shutil import unpack_archive\nimport eel\nfrom electionguard_gui.eel_utils import ee"
  },
  {
    "path": "src/electionguard_gui/components/guardian_home_component.py",
    "chars": 2908,
    "preview": "from typing import Any\nimport eel  # type: ignore[import-untyped]\nfrom electionguard_gui.eel_utils import eel_success\n\nf"
  },
  {
    "path": "src/electionguard_gui/components/key_ceremony_details_component.py",
    "chars": 5787,
    "preview": "import traceback\nfrom typing import List\nimport eel  # type: ignore[import-untyped]\nfrom pymongo.database import Databas"
  },
  {
    "path": "src/electionguard_gui/components/upload_ballots_component.py",
    "chars": 9116,
    "preview": "import os\nfrom typing import Any\nfrom datetime import datetime, timezone\nimport eel  # type: ignore[import-untyped]\nfrom"
  },
  {
    "path": "src/electionguard_gui/components/view_decryption_component.py",
    "chars": 4576,
    "preview": "import traceback\nfrom typing import Any\nimport eel  # type: ignore[import-untyped]\nfrom pymongo.database import Database"
  },
  {
    "path": "src/electionguard_gui/components/view_election_component.py",
    "chars": 749,
    "preview": "from typing import Any\nimport eel\nfrom electionguard_gui.components.component_base import ComponentBase\nfrom electiongua"
  },
  {
    "path": "src/electionguard_gui/components/view_spoiled_ballot_component.py",
    "chars": 2282,
    "preview": "from typing import Any\nimport eel\nfrom electionguard.tally import PlaintextTally\nfrom electionguard_gui.eel_utils import"
  },
  {
    "path": "src/electionguard_gui/components/view_tally_component.py",
    "chars": 1706,
    "preview": "from typing import Any\nimport eel\nfrom electionguard_gui.eel_utils import eel_success\nfrom electionguard_gui.components."
  },
  {
    "path": "src/electionguard_gui/containers.py",
    "chars": 12621,
    "preview": "from dependency_injector import containers, providers\nfrom dependency_injector.providers import Factory, Singleton\nfrom "
  },
  {
    "path": "src/electionguard_gui/docker-compose.yml",
    "chars": 2538,
    "preview": "version: \"3.8\"\nservices:\n  mongo:\n    image: mongo:4.4\n    container_name: \"electionguard-db\"\n    restart: always\n    po"
  },
  {
    "path": "src/electionguard_gui/eel_utils.py",
    "chars": 666,
    "preview": "from datetime import timezone, datetime\nimport os\nfrom typing import Any, Optional\n\n\ndef eel_fail(message: str) -> dict["
  },
  {
    "path": "src/electionguard_gui/main_app.py",
    "chars": 4113,
    "preview": "import traceback\nfrom typing import List\nimport eel\n\nfrom electionguard_gui.components import (\n    ViewElectionComponen"
  },
  {
    "path": "src/electionguard_gui/models/__init__.py",
    "chars": 777,
    "preview": "from electionguard_gui.models import decryption_dto\nfrom electionguard_gui.models import election_dto\nfrom electionguard"
  },
  {
    "path": "src/electionguard_gui/models/decryption_dto.py",
    "chars": 6971,
    "preview": "from typing import Any, Dict, Optional\nfrom datetime import datetime\nfrom electionguard.decryption_share import Decrypti"
  },
  {
    "path": "src/electionguard_gui/models/election_dto.py",
    "chars": 5340,
    "preview": "from typing import Any, Optional\nfrom datetime import datetime\nfrom electionguard.election import CiphertextElectionCont"
  },
  {
    "path": "src/electionguard_gui/models/key_ceremony_dto.py",
    "chars": 6670,
    "preview": "from typing import Any, List\nfrom datetime import datetime\nfrom electionguard import ElectionPartialKeyVerification\nfrom"
  },
  {
    "path": "src/electionguard_gui/models/key_ceremony_states.py",
    "chars": 322,
    "preview": "from enum import Enum\n\n\nclass KeyCeremonyStates(Enum):\n    \"\"\"A list of states for the key ceremony.\"\"\"\n\n    PendingGuar"
  },
  {
    "path": "src/electionguard_gui/services/__init__.py",
    "chars": 6184,
    "preview": "from electionguard_gui.services import authorization_service\nfrom electionguard_gui.services import ballot_upload_servic"
  },
  {
    "path": "src/electionguard_gui/services/authorization_service.py",
    "chars": 1119,
    "preview": "from typing import Optional\nimport eel\n\nfrom electionguard_gui.services.configuration_service import ConfigurationServic"
  },
  {
    "path": "src/electionguard_gui/services/ballot_upload_service.py",
    "chars": 5957,
    "preview": "from datetime import datetime\nfrom time import sleep\nfrom typing import Callable\nfrom pymongo.database import Database\nf"
  },
  {
    "path": "src/electionguard_gui/services/configuration_service.py",
    "chars": 1533,
    "preview": "from os import environ\nfrom sys import exit\nfrom typing import Optional\n\nDB_PASSWORD_KEY = \"EG_DB_PASSWORD\"\nDB_HOST_KEY "
  },
  {
    "path": "src/electionguard_gui/services/db_serialization_service.py",
    "chars": 1761,
    "preview": "from typing import Any\nfrom electionguard.key_ceremony import (\n    ElectionJointKey,\n    ElectionPartialKeyBackup,\n    "
  },
  {
    "path": "src/electionguard_gui/services/db_service.py",
    "chars": 1281,
    "preview": "from pymongo import MongoClient\nfrom pymongo.database import Database\nfrom electionguard_gui.services.configuration_serv"
  },
  {
    "path": "src/electionguard_gui/services/db_watcher_service.py",
    "chars": 2842,
    "preview": "from typing import Callable, Optional\nfrom threading import Event\nimport eel\nfrom pymongo.database import Database\nfrom "
  },
  {
    "path": "src/electionguard_gui/services/decryption_service.py",
    "chars": 6729,
    "preview": "from datetime import datetime, timezone\nfrom typing import Any, Dict, List, Optional\nfrom bson import ObjectId\nfrom pymo"
  },
  {
    "path": "src/electionguard_gui/services/decryption_stages/__init__.py",
    "chars": 843,
    "preview": "from electionguard_gui.services.decryption_stages import decryption_s1_join_service\nfrom electionguard_gui.services.decr"
  },
  {
    "path": "src/electionguard_gui/services/decryption_stages/decryption_s1_join_service.py",
    "chars": 2573,
    "preview": "from pymongo.database import Database\nimport eel  # type: ignore[import-untyped]\nfrom electionguard.ballot import Ballot"
  },
  {
    "path": "src/electionguard_gui/services/decryption_stages/decryption_s2_announce_service.py",
    "chars": 4329,
    "preview": "from pymongo.database import Database\nimport eel  # type: ignore[import-untyped]\nfrom electionguard import DecryptionMed"
  },
  {
    "path": "src/electionguard_gui/services/decryption_stages/decryption_stage_base.py",
    "chars": 2683,
    "preview": "from abc import ABC\nfrom typing import List\nfrom pymongo.database import Database\nfrom electionguard.ballot import Submi"
  },
  {
    "path": "src/electionguard_gui/services/directory_service.py",
    "chars": 605,
    "preview": "import os\n\n\nDOCKER_MOUNT_DIR = \"/egui_mnt\"\n\n\ndef get_export_dir() -> str:\n    return _get_egui_mnt_subdir(\"export\")\n\n\nde"
  },
  {
    "path": "src/electionguard_gui/services/eel_log_service.py",
    "chars": 1797,
    "preview": "from datetime import datetime\nimport logging\nfrom os import path, makedirs\nfrom typing import Any\nfrom electionguard.log"
  },
  {
    "path": "src/electionguard_gui/services/election_service.py",
    "chars": 5681,
    "preview": "import json\nfrom datetime import datetime, timezone\nfrom bson import ObjectId\nfrom pymongo.database import Database\nfrom"
  },
  {
    "path": "src/electionguard_gui/services/export_service.py",
    "chars": 1410,
    "preview": "import os\nfrom electionguard_gui.services.directory_service import get_data_dir, get_export_dir\n\n\ndef get_export_locatio"
  },
  {
    "path": "src/electionguard_gui/services/guardian_service.py",
    "chars": 4056,
    "preview": "from os import path\nfrom electionguard.serialize import from_file, to_file\nfrom electionguard.guardian import Guardian, "
  },
  {
    "path": "src/electionguard_gui/services/gui_setup_input_retrieval_step.py",
    "chars": 839,
    "preview": "from typing import Optional\nfrom electionguard import Manifest\nfrom electionguard.guardian import Guardian\nfrom election"
  },
  {
    "path": "src/electionguard_gui/services/key_ceremony_service.py",
    "chars": 6510,
    "preview": "from typing import Any, List\nfrom datetime import datetime, timezone\nfrom pymongo.database import Database\nfrom bson imp"
  },
  {
    "path": "src/electionguard_gui/services/key_ceremony_stages/__init__.py",
    "chars": 2151,
    "preview": "from electionguard_gui.services.key_ceremony_stages import key_ceremony_s1_join_service\nfrom electionguard_gui.services."
  },
  {
    "path": "src/electionguard_gui/services/key_ceremony_stages/key_ceremony_s1_join_service.py",
    "chars": 1614,
    "preview": "from pymongo.database import Database\n\nfrom electionguard_gui.models.key_ceremony_dto import KeyCeremonyDto\nfrom electio"
  },
  {
    "path": "src/electionguard_gui/services/key_ceremony_stages/key_ceremony_s2_announce_service.py",
    "chars": 2224,
    "preview": "from typing import Any, List\nfrom pymongo.database import Database\nfrom electionguard.key_ceremony import ElectionPublic"
  },
  {
    "path": "src/electionguard_gui/services/key_ceremony_stages/key_ceremony_s3_make_backup_service.py",
    "chars": 1809,
    "preview": "from pymongo.database import Database\nfrom electionguard_gui.models.key_ceremony_dto import KeyCeremonyDto\nfrom election"
  },
  {
    "path": "src/electionguard_gui/services/key_ceremony_stages/key_ceremony_s4_share_backup_service.py",
    "chars": 2168,
    "preview": "from typing import Any, List\nfrom pymongo.database import Database\nfrom electionguard_gui.models.key_ceremony_dto import"
  },
  {
    "path": "src/electionguard_gui/services/key_ceremony_stages/key_ceremony_s5_verify_backup_service.py",
    "chars": 2347,
    "preview": "from typing import List\nfrom pymongo.database import Database\nfrom electionguard.key_ceremony import ElectionPartialKeyV"
  },
  {
    "path": "src/electionguard_gui/services/key_ceremony_stages/key_ceremony_s6_publish_key_service.py",
    "chars": 1914,
    "preview": "from pymongo.database import Database\nfrom electionguard_gui.models.key_ceremony_dto import KeyCeremonyDto\nfrom election"
  },
  {
    "path": "src/electionguard_gui/services/key_ceremony_stages/key_ceremony_stage_base.py",
    "chars": 1905,
    "preview": "from abc import ABC, abstractmethod\nfrom pymongo.database import Database\n\nfrom electionguard_gui.models.key_ceremony_dt"
  },
  {
    "path": "src/electionguard_gui/services/key_ceremony_state_service.py",
    "chars": 2825,
    "preview": "from electionguard_gui.models.key_ceremony_dto import KeyCeremonyDto\nfrom electionguard_gui.models.key_ceremony_states i"
  },
  {
    "path": "src/electionguard_gui/services/plaintext_ballot_service.py",
    "chars": 4581,
    "preview": "from typing import Any\nfrom electionguard import PlaintextTally\nfrom electionguard.manifest import Manifest, get_i8n_val"
  },
  {
    "path": "src/electionguard_gui/services/service_base.py",
    "chars": 203,
    "preview": "from abc import ABC\n\n\nclass ServiceBase(ABC):\n    \"\"\"Responsible for common functionality among services\"\"\"\n\n    def ini"
  },
  {
    "path": "src/electionguard_gui/services/version_service.py",
    "chars": 840,
    "preview": "from os import path\nfrom subprocess import check_output\nfrom typing import Optional\nimport eel\nfrom electionguard_gui.se"
  },
  {
    "path": "src/electionguard_gui/start.py",
    "chars": 133,
    "preview": "from electionguard_gui.containers import Container\n\n\ndef run() -> None:\n    container = Container()\n    container.main_a"
  },
  {
    "path": "src/electionguard_gui/web/components/admin/admin-home-component.js",
    "chars": 1256,
    "preview": "import KeyCeremonyList from \"../shared/key-ceremony-list-component.js\";\nimport ElectionsList from \"../shared/election-li"
  },
  {
    "path": "src/electionguard_gui/web/components/admin/create-decryption-component.js",
    "chars": 1872,
    "preview": "import RouterService from \"../../services/router-service.js\";\nimport Spinner from \"../shared/spinner-component.js\";\n\nexp"
  },
  {
    "path": "src/electionguard_gui/web/components/admin/create-election-component.js",
    "chars": 3366,
    "preview": "import Spinner from \"../shared/spinner-component.js\";\nimport RouterService from \"../../services/router-service.js\";\n\nexp"
  },
  {
    "path": "src/electionguard_gui/web/components/admin/create-key-ceremony-component.js",
    "chars": 2903,
    "preview": "import Spinner from \"../shared/spinner-component.js\";\nimport RouterService from \"../../services/router-service.js\";\n\nexp"
  }
]

// ... and 103 more files (download for full content)

About this extraction

This page contains the full source code of the microsoft/electionguard-python GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 303 files (1.4 MB), approximately 373.3k tokens, and a symbol index with 1879 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.

Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.

Copied to clipboard!