Posted on :: 916 Words :: Tags: , , , , , ,

Executive Summary

Although macOS is my daily driver for data science and development, real-world consulting sometimes demands using unfamiliar ground, in this case, Windows 11. Why? In this case my client required a Windows-only DLL. Integrating it with Python without fighting cross-platform headaches meant going native.

This post documents how I set up a robust, reproducible Windows 11 environment using Chocolatey for package management, uv for fast Python workflows, and VS Code for a seamless coding experience, all with the minimum fuss, maximum efficiency, and a few lessons learned along the way.

Why Shift to Windows?

As someone who values comfort and reproducibility, macOS is my usual choice. It’s fast, intuitive, and fits my personal workflow. But sometimes, the technology we build for is dictated by client needs, not personal preference. Integrating a calculation engine distributed as a native Windows DLL (C/C++) meant no shortcuts: I needed Windows, not WSL, not a VM, and certainly not cross-compilation hacks. The experience drove home how efficient a modern Windows data science setup can be (with the right tools) - although I think of this as a short vacation not a permanent move!

Getting Started

My target was a minimal, scriptable Windows setup for Python development and DLL integration. The hardware I chose was modest: Lenovo IdeaPad Slim 3i (Gen 8), Intel Core i5-12450H, 8GB RAM, 512GB SSD. Enough to run notebooks, scripts, sample DuckDB queries, and do serious benchmarking. No unnecessary bells and whistles. The stack:

  • Windows 11 Home (24H2), freshly updated.
  • Chocolatey for package management (think Windows Homebrew).
  • uv for Python (speedy environments, dependency resolution, no more pip pain).
  • VS Code, synced extensions for familiarity.
  • Git for version control.

Everything operates natively; WSL skipped, as all needs are satisfied in Windows proper.

Windows Setup Notes

  • First boot: Windows 11 updates took ~30 minutes; subsequent ones 5-10 minutes. Expect and plan for downtime.
  • Checks: Just a single admin account, verified with Belarc Advisor.
  • Snappy installs: Chocolatey and uv let me run the setup quickly and painlessly, just like Homebrew on macOS.

Chocolatey: The Power User’s Installer

Chocolatey outperforms Winget for developer workflows thanks to its huge repository and simple PowerShell commands. Installation is one-liner-and-done; verify with choco --version. Essentials installed right away:

  • choco install git -y
  • choco install notepadplusplus -y
  • choco install vscode -y

Tip: Windows Terminal (tabs, copy-paste) makes shell interactions much smoother than vanilla PowerShell.

Python Environments with uv

uv was a revelation: Rust-fast installs, automatic Python version management, and seamless dependency resolution. No need for manual Python install or wrestling with virtualenv, proxies, or PATH weirdness. Disable the Microsoft store Python suggestion for full control. For reproducible scripts and heavy libraries (pandas, DuckDB), uv is fast, isolated, and reliable. Typical workflow:

  • choco install uv -y
  • uv python install 3.12
  • mkdir testproject && cd testproject; uv init --python 3.12; uv venv; . .\.venv\Scripts\activate

VS Code and Git Integration

VS Code remains my IDE of choice, syncing extensions/settings from Mac (Python, Jupyter, GitLens) was seamless. A quick sign-in, and my familiar dev environment was ready to go. For GitHub auth: just use browser-based login and mobile app for 2FA. No fuss. Git’s integration is as easy and everything is portable.

Notes and Sharing: Cross-Platform Transfers

Setup notes and PowerShell scripts were shared via iCloud in the browser. Next time, Gists or a synced cloud folder might be even better.

Wrapping Up: The Mac-Like Windows Experience

Despite my ongoing preference for macOS, this Windows setup proved clean, fast, and reliable, ready for intensive data science with DLL support. The IdeaPad Slim 3i handled some test DuckDB workloads smoothly, and everything felt familiar thanks to cross-platform tooling. For benchmarking and client deliverables, it’s a solid second-place ;)


Bottom line: When macOS doesn't support your use case / constraints, a native Windows setup with Chocolatey, uv, and VS Code makes working with tricky client DLLs smooth, scriptable, and as close to pain-free as it gets.


Appendix: Step-by-Step Setup

Skip to here for full setup steps. All commands work in Windows Terminal as Administrator.

1. Update Windows and Check System

  • Settings > Windows Update > Check for updates (~1 hr first boot, 10–20 min later).
  • I use Belarc Advisor to confirm the machine specs and admin setup.

2. Install Chocolatey

Set-ExecutionPolicy Bypass -Scope Process -Force
[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072
$webClient = New-Object System.Net.WebClient
$script = $webClient.DownloadString('https://community.chocolatey.org/install.ps1')
iex $script
  • Verify: choco --version

3. Install uv

  • PowerShell: choco install uv -y (Or: powershell -c "irm https://astral.sh/uv/install.ps1 | iex")
  • Verify: uv --version
  • Create Python environment, for example: uv python install 3.12 mkdir testproject && cd testproject; uv init --python 3.12; uv venv; . .\.venv\Scripts\activate
  • Or just uv sync if you already have pyproject.toml

4. Install Git

  • Install: choco install git -y
  • Verify: git --version
  • Configure Git identity.

5. Notepad++

  • Install: choco install notepadplusplus -y
  • Useful for quick file edits on Windows.

6. VS Code

  • Install: choco install vscode -y
  • Launch, sign in, sync extensions/settings (in my case those from VS Code on my MacBook)
  • Adjust the extensions as needed

7. GitHub Authentication

  • Authenticate via browser + mobile app.

8. Extra: Automation (just)

just simplifies repetitive command execution by letting you script and automate tasks, like builds, installs, or data pulls, in a single, cross-platform recipe file. I never leave home without it. See Streamlining Processes: Tools for Efficiency.

  • Install: choco install just -y
  • Verify: just --version
  • Example minimal cross-platform justfile:
set windows_shell := ["powershell.exe", "-c"]
set posix_shell := ["bash", "-c"]
set shell := if OS == "windows" { windows_shell } else { posix_shell }

default:
  @just --list