Skip to content

Cross-platform desktop app to automate UCL Portico admissions processing using Playwright browser automation

Notifications You must be signed in to change notification settings

TechAngelX/Dossier

Repository files navigation

Dossier

Main Interface

Automate UCL Portico admissions processing with Playwright browser automation

Main Interface Processing View
Portico Automation Results

.NET Avalonia Playwright Platform


About the Project

Dossier is a cross-platform desktop application that automates repetitive admissions workflows in university student record systems. Instead of manually clicking through hundreds of student records, staff can load a spreadsheet and let the automation handle batch decision processing and document generation — reducing hours of manual work to minutes.

The app utilises Playwright, an open-source browser automation tool developed by Microsoft, to automate web browsers for testing, automation, and interaction with web applications—such as clicking buttons, filling forms, capturing screenshots, and navigating pages.

The Problem

During admissions season, staff must process hundreds of student applications by:

  1. Searching for each student by number
  2. Clicking into their application (selecting the correct programme if multiple exist)
  3. Navigating to the Actions tab
  4. Clicking "Recommend Offer or Reject"
  5. Selecting the appropriate decision
  6. Clicking Process
  7. Repeating for every student...

Additionally, academic reviewers who need to assess applicants must manually open each student record, navigate to their documents, and click through individual PDFs one by one. For large cohorts, this means hours of repetitive clicking just to review application materials.

The Solution

Dossier reads student data from an Excel or CSV file and automates the entire workflow using Microsoft Edge browser automation. It supports two core functions:

  • Batch Decision Processing — Automatically processes Accept/Reject recommendations for hundreds of students, intelligently matching each to their correct programme application.
  • Merge Overview — Automatically generates and downloads a merged overview PDF for each student, combining all their application documents (personal statement, CV, transcripts, references, etc.) into a single file. The resulting batch folder can be handed directly to reviewers, eliminating the need to navigate the system record by record.

Features

Feature Description
Drag and Drop Excel/CSV Load student data from .xlsx, .xls, or .csv files
Smart Programme Matching Automatically maps short codes (ML, CS, FT) to Portico codes (TMSCOMSMCL01, etc.)
Batch Decision Processing Process multiple Accept/Reject recommendations in one run
Merge Overview Generate and download merged overview PDFs for entire cohorts in a single batch
Persistent Login SSO session saved between runs — no repeated MFA
Real-time Status Live progress log with step-by-step visibility
Live Progress Counter Real-time "Processed X of Y — Z remaining" with elapsed timer
Sleep Prevention Automatically prevents OS sleep during batch runs — safe for overnight processing
Failure Recovery Automatically recovers and continues to the next student if a record fails
Cross-Platform Works on Windows, macOS, and Linux
Configurable Adjust delays, headless mode, and more

UI Design

The interface features a modern glassmorphic design inspired by contemporary web frameworks:

  • Acrylic blur effects — Frosted glass transparency on panels
  • Soft shadows — Subtle depth with drop shadows
  • Rounded corners — Modern card-based layouts
  • Color-coded status indicators — Green (done), blue (processing), gray (pending)
  • Smooth animations — Fade-in effects and progress transitions
  • Cross-platform consistency — Identical look on Windows and macOS

Enterprise Robustness

Dossier is engineered for unattended, large-scale batch processing — designed to run reliably outside of business hours with zero manual intervention.

  • OS Sleep Prevention — The app automatically inhibits system sleep for the duration of a batch run (caffeinate on macOS, SetThreadExecutionState on Windows, systemd-inhibit on Linux). No need to adjust power settings manually; the machine stays awake until the job completes, then normal sleep behaviour resumes.
  • Live Progress Tracking — A persistent footer displays the running count (Processed 47 of 131 — 84 remaining), a continuously ticking elapsed timer, and a percentage progress bar. When the batch finishes, the footer shows total elapsed time and a success/failure breakdown.
  • Automatic Failure Recovery — If an individual record fails (timeout, missing data, unexpected page state), the app logs the error, navigates the browser back to a known-good state, and continues to the next student. One bad record does not halt the entire batch.
  • Persistent SSO Sessions — Browser context is persisted between runs, so MFA/SSO login only needs to happen once. Subsequent runs reuse the saved session for up to 60 days.

These features allow staff to confidently run batches of 100+ records overnight without supervision.


Architecture Dossier follows the MVVM (Model-View-ViewModel) architectural pattern, providing clear separation of concerns for maintainability and testability.

Key Components:

Views — Avalonia XAML windows and controls (MainWindow, ProcessingWindow, SettingsWindow) ViewModels — Handle UI state and expose observable properties for data binding Models — Data structures for students, decisions, and programme mappings Services — Business logic for Excel parsing, programme matching, and Playwright automation

Architecture

Dossier follows the MVVM (Model-View-ViewModel) architectural pattern, providing clear separation of concerns for maintainability and testability.

┌─────────────────────────────────────────────────────────────┐
│                          VIEW                               │
│         (Avalonia XAML - MainWindow, ProcessingWindow)      │
│                                                             │
│   ┌─────────────────┐    ┌─────────────────────────────┐   │
│   │  MainWindow     │    │  ProcessingWindow           │   │
│   │  - File panels  │    │  - Progress bar             │   │
│   │  - Settings     │    │  - Student list             │   │
│   │  - Start button │    │  - Status log               │   │
│   └─────────────────┘    └─────────────────────────────┘   │
└──────────────────────────────┬──────────────────────────────┘
                               │ Data Binding
┌──────────────────────────────▼──────────────────────────────┐
│                       VIEWMODEL                             │
│              (Event handling, state management)             │
│                                                             │
│   - ProcessingStudentViewModel                              │
│   - Observable collections for real-time UI updates         │
│   - Command bindings for user interactions                  │
└──────────────────────────────┬──────────────────────────────┘
                               │
┌──────────────────────────────▼──────────────────────────────┐
│                         MODEL                               │
│                (Business logic, data, services)             │
│                                                             │
│   ┌────────────────┐  ┌────────────────┐  ┌──────────────┐ │
│   │  Models/       │  │  Services/     │  │  Playwright  │ │
│   │  - Student     │  │  - Excel       │  │  - Browser   │ │
│   │  - Decision    │  │  - Automation  │  │  - Portico   │ │
│   │  - Programme   │  │  - Mapping     │  │  - Actions   │ │
│   └────────────────┘  └────────────────┘  └──────────────┘ │
└─────────────────────────────────────────────────────────────┘

Programme Code Mapping

The app automatically converts spreadsheet short codes to Portico programme codes:

Excel Code Portico Code Programme
ML TMSCOMSMCL01 MSc Machine Learning
CS TMSCOMSING01 MSc Computer Science
DSML TMSDATSMLE01 MSc Data Science and Machine Learning
FT TMSFINSTEC01 MSc Financial Technology
CGVI TMSCOMSCGV01 MSc Computer Graphics and Vision
RAI TMSROBAARI01 MSc Robotics and AI
AISD TMSARTSINT02 MSc AI for Sustainable Development
... ... and more

Tech Stack

Technology Purpose
C# Code Language
.NET 10 Runtime framework
Avalonia UI 11 Cross-platform UI framework
Playwright Browser automation engine
EPPlus Excel and CSV file parsing
Microsoft Edge Automated browser (with SSO support)

Project Structure

dossier/
├── App.axaml                 # Application XAML
├── App.axaml.cs
├── MainWindow.axaml          # Main UI layout
├── MainWindow.axaml.cs       # UI logic and event handlers
├── SettingsWindow.axaml      # Settings dialog
├── SettingsWindow.axaml.cs
├── Program.cs                # Entry point
├── Models/
│   ├── StudentRecord.cs      # Student data model
│   ├── AppConfig.cs          # Configuration model
│   └── ProcessingStudentViewModel.cs  # ViewModel for processing UI
├── Services/
│   ├── ExcelService.cs       # Excel parsing logic
│   ├── PorticoAutomationService.cs  # Playwright automation
│   ├── SleepInhibitor.cs     # Cross-platform OS sleep prevention
│   └── Interfaces/
├── Dossier.Tests/
│   ├── Models/
│   │   ├── StudentRecordTests.cs
│   │   ├── AppConfigTests.cs
│   │   └── ProcessingStudentViewModelTests.cs
│   ├── Services/
│   │   ├── ExcelServiceCsvTests.cs
│   │   └── ExcelServiceExcelTests.cs
│   └── Dossier.Tests.csproj
├── public/
│   └── images/               # Screenshots and logo
├── Dossier.csproj
└── Dossier.sln

Testing

The project includes a comprehensive test suite built with xUnit, covering models and services.

dotnet test Dossier.Tests/
Test File Tests What's Covered
StudentRecordTests 8 Default values, Name computed property, enum values
AppConfigTests 6 Default configuration values, property setters
ProcessingStudentViewModelTests 5 Default state, INotifyPropertyChanged events, property updates
ExcelServiceCsvTests 19 CSV parsing, tab/comma delimiter detection, fuzzy column matching, quoted fields (RFC 4180), edge cases
ExcelServiceExcelTests 8 .xlsx parsing, sheet fallback, fuzzy headers, GetSheetNames()

66 tests total — all passing.


Getting Started

Building Standalone Executables

Windows (.exe)

dotnet publish -c Release -r win-x64 --self-contained true -p:PublishSingleFile=true -p:IncludeNativeLibrariesForSelfExtract=true

Output: bin/Release/net10.0/win-x64/publish/Dossier.exe

macOS (.app)

# Intel Mac
dotnet publish -c Release -r osx-x64 --self-contained true -p:PublishSingleFile=true

# Apple Silicon (M1/M2/M3)
dotnet publish -c Release -r osx-arm64 --self-contained true -p:PublishSingleFile=true

Output: bin/Release/net10.0/osx-x64/publish/Dossier (or osx-arm64)

Notes on File Size

Self-contained builds include the .NET runtime (~100-150 MB). For smaller builds that require .NET to be installed on the target machine:

dotnet publish -c Release -r win-x64 --self-contained false -p:PublishSingleFile=true

This produces a ~1 MB executable but requires .NET 10 Desktop Runtime on the target PC.


Prerequisites

  • .NET 10 SDK
  • Microsoft Edge browser installed
  • Playwright browsers installed

Installation

# Clone the repository
git clone https://github.com/YOUR_USERNAME/dossier.git
cd dossier

# Restore dependencies
dotnet restore

# Install Playwright browsers (first time only)
dotnet tool install -g Microsoft.Playwright.CLI
playwright install msedge

# Build and run
dotnet build
dotnet run

# Run tests
dotnet test Dossier.Tests/

Usage

Accept/Reject Processing

  1. Load spreadsheet — Drag and drop or browse to select your Excel or CSV file
  2. Select worksheet — Choose the sheet containing student decisions (auto-selects "Dept In-tray"; skipped for CSV)
  3. Select mode — Choose "Process Accepts" or "Process Rejects"
  4. Click Start — The browser will launch and begin automation
  5. Complete MFA — On first run, complete SSO/MFA login (session saves for 60 days)
  6. Monitor progress — Watch the status log for real-time updates

Merge Overview

  1. Load spreadsheet — Drag and drop an Excel or CSV file containing student numbers and programme codes
  2. Select "Merge Overview" mode
  3. Click Start — For each student, the app will:
    • Navigate to their record and select the correct programme
    • Open the Documents & Uploads tab
    • Click "Create Overview.pdf" (or "Amend Overview.pdf" if one already exists)
    • Wait for server processing to complete
    • Click "Merge Documents" and confirm
    • Download the merged PDF to Desktop/LATEST_BATCH/
    • Return to the search screen and repeat for the next student
  4. Collect results — All merged PDFs are saved to a single folder, ready for offline review

Expected Input Format

For Accept/Reject processing — requires StudentNo, Programme, and Decision columns:

StudentNo Programme Decision (other columns)
26034803 ML Accept ...
26045424 CS Reject ...
23014690 ML Accept ...

For Merge Overview — only StudentNo and Programme are required:

StudentNo Programme
26034803 ML
26045424 CS
23014690 DSML

Configuration

Click the ⚙️ Settings button to configure:

Setting Description Default
Headless Mode Run browser invisibly Off
Action Delay Milliseconds between actions 100ms
Portico URL Login page URL evision.ucl.ac.uk

How It Works

┌──────────────────┐     ┌─────────────────┐     ┌─────────────────┐
│  Excel / CSV     │────▶│  Dossier   │────▶│  Portico        │
│  (Student Data)  │     │  (Automation)   │     │  (Browser)      │
└──────────────────┘     └─────────────────┘     └─────────────────┘
                               │
                 ┌─────────────┴─────────────┐
                 ▼                           ▼
    ┌────────────────────┐      ┌────────────────────────┐
    │  Accept/Reject     │      │  Merge Overview        │
    │  1. Search by ID   │      │  1. Search by ID       │
    │  2. Match programme│      │  2. Match programme    │
    │  3. Click Actions  │      │  3. Documents tab      │
    │  4. Process decision│     │  4. Create/Amend PDF   │
    └────────────────────┘      │  5. Merge Documents    │
                                │  6. Download PDF       │
                                │  7. Exit & repeat      │
                                └────────────────────────┘

Troubleshooting

Issue Solution
Playwright not found Run playwright install msedge
Wrong row clicked Ensure Programme column matches short codes (ML, CS, etc.)
Login timeout Complete MFA within 4 minutes
Browser closes unexpectedly Check Status Log for error details

Contributing

Contributions are welcome. Feel free to open an issue or submit a pull request.


Licence

Distributed under the MIT Licence. See LICENCE for more information.


Disclaimer

This tool is for authorised UCL staff use only. Ensure you have appropriate permissions before automating Portico interactions. The authors are not responsible for any misuse or unintended consequences.



Tech Angel X Logo

Built by Ricki Angel • Tech Angel X

About

Cross-platform desktop app to automate UCL Portico admissions processing using Playwright browser automation

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published