<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Oresztesz Margaritisz</title>
    <description>The latest articles on DEV Community by Oresztesz Margaritisz (@gitaroktato).</description>
    <link>https://dev.to/gitaroktato</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F594907%2Fcb9b8f0b-7737-48e7-b250-dc9bfa4b7334.jpeg</url>
      <title>DEV Community: Oresztesz Margaritisz</title>
      <link>https://dev.to/gitaroktato</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/gitaroktato"/>
    <language>en</language>
    <item>
      <title>Creating Your Own AWS Architect with OpenCode and AWS MCP Servers</title>
      <dc:creator>Oresztesz Margaritisz</dc:creator>
      <pubDate>Fri, 06 Feb 2026 12:54:17 +0000</pubDate>
      <link>https://dev.to/gitaroktato/using-your-own-architecture-agent-with-opencode-and-aws-mcp-servers-2j26</link>
      <guid>https://dev.to/gitaroktato/using-your-own-architecture-agent-with-opencode-and-aws-mcp-servers-2j26</guid>
      <description>&lt;h2&gt;
  
  
  Why OpenCode?
&lt;/h2&gt;

&lt;p&gt;OpenCode is an AI-powered coding agent that gives you unprecedented flexibility in choosing your AI provider. Unlike tools locked to a single vendor, OpenCode supports &lt;a href="https://opencode.ai/docs/providers/" rel="noopener noreferrer"&gt;75+ LLM providers&lt;/a&gt; from major platforms like Anthropic, OpenAI, and AWS Bedrock to local models via Ollama or llama.cpp. Whether you're optimizing for cost, privacy, or specific model capabilities, OpenCode's unified provider system lets you connect any compatible service through a simple &lt;code&gt;/connect&lt;/code&gt; command.&lt;/p&gt;

&lt;p&gt;This flexibility becomes particularly powerful when building specialized agents. In this article, we'll leverage public AWS MCP (Model Context Protocol) servers to create a powerful architect buddy.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmgq5pflxrt7gahzpood9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmgq5pflxrt7gahzpood9.png" alt=" " width="800" height="610"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  AWS MCP Servers: Extending agents with AWS Context
&lt;/h2&gt;

&lt;p&gt;AWS provides official MCP servers that extend AI assistants with deep AWS knowledge and tooling capabilities. The Model Context Protocol, developed by Anthropic, offers a standardized way to connect AI models to external data sources and tools through a client-server architecture.&lt;/p&gt;

&lt;p&gt;The &lt;a href="https://awslabs.github.io/mcp/servers/aws-documentation-mcp-server" rel="noopener noreferrer"&gt;&lt;strong&gt;AWS Documentation MCP Server&lt;/strong&gt;&lt;/a&gt; is particularly valuable for architecture work. It provides three core capabilities: fetching and converting AWS documentation pages to markdown format, searching the official AWS documentation using the AWS Search API, and retrieving content recommendations for related AWS services. This means your AI assistant can reference authoritative AWS documentation, verify best practices in real-time, and suggest relevant services based on your architecture requirements.&lt;/p&gt;

&lt;p&gt;AWS also offers the &lt;a href="https://awslabs.github.io/mcp/servers/aws-diagram-mcp-server" rel="noopener noreferrer"&gt;&lt;strong&gt;AWS Diagram MCP Server&lt;/strong&gt;&lt;/a&gt;, which generates professional architecture diagrams using the Python diagrams package with the complete AWS icon set. Combined with documentation lookup, this enables AI assistants to create accurate, best-practice-compliant architecture diagrams through simple natural language prompts—transforming hours of manual diagramming work into minutes of conversation.&lt;/p&gt;

&lt;p&gt;We're going to use the ones above with the combination of a powerful agent specification to create our AWS architect buddy.&lt;/p&gt;

&lt;h2&gt;
  
  
  Combining the best of both worlds
&lt;/h2&gt;

&lt;p&gt;With the combination of OpenCode and AWS MCPs, you have the flexibility of using any of your LLM provider's license while also having access to the most up-to-date AWS documentation and diagramming capabilities. Unlocking the limits of your vendor's toolkit or pricing model.&lt;/p&gt;

&lt;h2&gt;
  
  
  Defining MCPs in OpenCode
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Prerequisites
&lt;/h3&gt;

&lt;p&gt;To make the MCP servers work, you need &lt;code&gt;uv&lt;/code&gt; and &lt;code&gt;graphviz&lt;/code&gt; installed and available on your machine.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://docs.astral.sh/uv/getting-started/installation/" rel="noopener noreferrer"&gt;&lt;code&gt;uv&lt;/code&gt; installation guide&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://wiki.archlinux.org/title/Graphviz#Installation" rel="noopener noreferrer"&gt;&lt;code&gt;graphviz&lt;/code&gt; on Arch for example&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Configuration
&lt;/h3&gt;

&lt;p&gt;I have a ready-made sample for OpenCode with &lt;a href="https://github.com/gitaroktato/opencode-agents/blob/main/opencode.jsonc" rel="noopener noreferrer"&gt;AWS local MCP servers&lt;/a&gt;. To define the AWS MCPs, you have to add them to your &lt;code&gt;opencode.jsonc&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json-doc"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"awslabs.aws-diagram-mcp-server"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"local"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"command"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="s2"&gt;"uvx"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="s2"&gt;"awslabs.aws-diagram-mcp-server"&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"environment"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="nl"&gt;"FASTMCP_LOG_LEVEL"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"ERROR"&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"enabled"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"awslabs.aws-documentation-mcp-server"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"type"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"local"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"command"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="s2"&gt;"uvx"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="s2"&gt;"awslabs.aws-documentation-mcp-server@latest"&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"environment"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="nl"&gt;"FASTMCP_LOG_LEVEL"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"ERROR"&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"enabled"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="err"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Permissions
&lt;/h3&gt;

&lt;p&gt;Make sure that for all other agents the MCP servers above are disabled, by adding the following line to your &lt;code&gt;opencode.jsonc&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json-doc"&gt;&lt;code&gt;&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="nl"&gt;"tools"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"awslabs*"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="err"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;We're going to enable them only for the AWS architect agent that we define later.&lt;/p&gt;

&lt;h3&gt;
  
  
  Testing MCP configuration
&lt;/h3&gt;

&lt;p&gt;Check if the specified MCP servers are working correctly with the following OpenCode CLI command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;opencode mcp list
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Alternatively you can just type &lt;code&gt;/mcps&lt;/code&gt; in &lt;code&gt;OpenCode&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fkgh29irjd9s8m2jwm5on.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fkgh29irjd9s8m2jwm5on.png" alt=" " width="609" height="285"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  OpenCode - Agent Specification
&lt;/h2&gt;

&lt;p&gt;Fortunately, there are ready-made samples for Claude Code &lt;a href="https://github.com/VoltAgent/awesome-claude-code-subagents/blob/main/categories/03-infrastructure/cloud-architect.md" rel="noopener noreferrer"&gt;in this repo&lt;/a&gt;, so we're not going to start from scratch. I tailored the sample above and added some AWS specifics. You can grab the OpenCode version &lt;a href="https://github.com/gitaroktato/opencode-agents/blob/main/.opencode/agents/aws-architect.md" rel="noopener noreferrer"&gt;from here&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Installing the Agent
&lt;/h3&gt;

&lt;p&gt;You can install the agent in various ways. The agent configuration can be found &lt;a href="https://github.com/gitaroktato/opencode-agents/blob/main/.opencode/agents/aws-architect.md" rel="noopener noreferrer"&gt;over here&lt;/a&gt;. Make sure to save this file in the &lt;a href="https://opencode.ai/docs/agents/#markdown" rel="noopener noreferrer"&gt;appropriate location&lt;/a&gt;. Either in &lt;code&gt;~/.config/opencode/agents&lt;/code&gt; (global config) or in &lt;code&gt;.opencode/agents&lt;/code&gt; for your project specific configuration.&lt;/p&gt;

&lt;h3&gt;
  
  
  Agent Permissions
&lt;/h3&gt;

&lt;p&gt;If you open the markdown file you'll notice that many of the tools are disabled. All &lt;code&gt;awslabs&lt;/code&gt; prefixed tools are turned on to make sure only this agent has access to the MCP servers. More about agent permissions are in the &lt;a href="https://opencode.ai/docs/agents/#markdown" rel="noopener noreferrer"&gt;OpenCode documentation&lt;/a&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;permissions:
  bash: deny
tools:
  write: false
  read: true
  grep: true
  glob: true
  awslabs&lt;span class="err"&gt;*&lt;/span&gt;: true
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  The AWS Architect Buddy in Action
&lt;/h2&gt;

&lt;p&gt;Time for truth, time for giving tasks for our new architect. Start &lt;code&gt;opencode&lt;/code&gt; and use the &lt;code&gt;&amp;lt;TAB&amp;gt;&lt;/code&gt; key to switch to the &lt;code&gt;Aws-Architect&lt;/code&gt; agent. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmgq5pflxrt7gahzpood9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmgq5pflxrt7gahzpood9.png" alt=" " width="800" height="610"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;We're going to use an &lt;a href="https://www.architecturalkatas.com/" rel="noopener noreferrer"&gt;architecture kata&lt;/a&gt; for this exercise. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fb7m0yfz57s1cf2mv9h82.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fb7m0yfz57s1cf2mv9h82.png" alt=" " width="800" height="216"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;⚠️&lt;strong&gt;Note:&lt;/strong&gt; All the content below was generated by the agent. I pasted them without any modifications.&lt;/p&gt;

&lt;h3&gt;
  
  
  Working with NFRs
&lt;/h3&gt;

&lt;p&gt;Summary of Key Quantifiable NFRs&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Pillar&lt;/th&gt;
&lt;th&gt;Critical Metrics&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Operational Excellence&lt;/td&gt;
&lt;td&gt;Deploy frequency (weekly), MTTR &amp;lt; 30 min, automated recovery 95%+&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Security&lt;/td&gt;
&lt;td&gt;Zero data breaches, &amp;lt; 1% false positive cheat detection, PCI-DSS compliant&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Reliability&lt;/td&gt;
&lt;td&gt;99.9% uptime, RPO &amp;lt; 1 hour, RTO &amp;lt; 2 hours, match completion rate &amp;gt; 98%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Performance&lt;/td&gt;
&lt;td&gt;&amp;lt; 50ms latency, 60+ FPS, &amp;lt; 30s matchmaking, &amp;lt; 3s map load&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Cost Optimization&lt;/td&gt;
&lt;td&gt;&amp;lt; $0.05 per player-hour, 30%+ cost reduction YoY, 70%+ infrastructure utilization&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Sustainability&lt;/td&gt;
&lt;td&gt;50%+ renewable energy regions, ARM instances where possible, &amp;lt; 2GB RAM usage&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  Technology Choices
&lt;/h3&gt;

&lt;p&gt;Some of the proposed AWS technology stack by the agent (I skipped some of the boring parts for clarity):&lt;/p&gt;

&lt;h4&gt;
  
  
  Game-Specific Services
&lt;/h4&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Technology&lt;/th&gt;
&lt;th&gt;Use Case&lt;/th&gt;
&lt;th&gt;NFR Mapping&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Amazon GameLift FlexMatch&lt;/td&gt;
&lt;td&gt;Skill-based matchmaking with custom rulesets&lt;/td&gt;
&lt;td&gt;&amp;lt; 30 second matchmaking, fair matches&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Amazon IVS (Interactive Video Service)&lt;/td&gt;
&lt;td&gt;Live streaming for tournament observation (ghost mode)&lt;/td&gt;
&lt;td&gt;Low-latency streaming for spectators&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Amazon Chime SDK&lt;/td&gt;
&lt;td&gt;Voice chat for proximity-based communication&lt;/td&gt;
&lt;td&gt;Real-time voice with spatial audio&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h4&gt;
  
  
  Compute Performance
&lt;/h4&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Technology&lt;/th&gt;
&lt;th&gt;Use Case&lt;/th&gt;
&lt;th&gt;NFR Mapping&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;EC2 C6g/C7g Instances (Graviton3)&lt;/td&gt;
&lt;td&gt;ARM-based game servers for better price/performance&lt;/td&gt;
&lt;td&gt;40% better performance per dollar&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;EC2 C6i/C7i Instances&lt;/td&gt;
&lt;td&gt;Intel-based game servers for single-threaded performance&lt;/td&gt;
&lt;td&gt;High clock speed for game physics&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;EC2 G5 Instances&lt;/td&gt;
&lt;td&gt;GPU-based instances for server-side rendering, AI opponents&lt;/td&gt;
&lt;td&gt;GPU acceleration for complex physics&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Lambda Provisioned Concurrency&lt;/td&gt;
&lt;td&gt;Eliminate cold starts for critical paths (matchmaking, authentication)&lt;/td&gt;
&lt;td&gt;&amp;lt; 10ms response time&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Lambda SnapStart (Java)&lt;/td&gt;
&lt;td&gt;Faster cold starts for Java-based services&lt;/td&gt;
&lt;td&gt;10x faster Lambda startup&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h4&gt;
  
  
  Data Resilience
&lt;/h4&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Technology&lt;/th&gt;
&lt;th&gt;Use Case&lt;/th&gt;
&lt;th&gt;NFR Mapping&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Amazon DynamoDB Global Tables&lt;/td&gt;
&lt;td&gt;Multi-region, active-active database for player profiles, inventories&lt;/td&gt;
&lt;td&gt;&amp;lt; 100ms read/write latency globally, 99.999% availability&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;DynamoDB Point-in-Time Recovery&lt;/td&gt;
&lt;td&gt;Continuous backups for 35 days&lt;/td&gt;
&lt;td&gt;RPO of seconds, recover from accidental deletes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Amazon Aurora Global Database&lt;/td&gt;
&lt;td&gt;Multi-region relational database for transactional data (payments)&lt;/td&gt;
&lt;td&gt;Cross-region replication &amp;lt; 1 second lag&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Amazon ElastiCache (Redis)&lt;/td&gt;
&lt;td&gt;Session state, leaderboards, matchmaking queue&lt;/td&gt;
&lt;td&gt;Sub-millisecond latency, 99.99% availability&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Amazon S3&lt;/td&gt;
&lt;td&gt;User-generated content (maps, weapons), game assets&lt;/td&gt;
&lt;td&gt;99.999999999% durability, 99.99% availability&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;S3 Cross-Region Replication&lt;/td&gt;
&lt;td&gt;Replicate UGC and assets to multiple regions&lt;/td&gt;
&lt;td&gt;Disaster recovery, local access&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;AWS Backup&lt;/td&gt;
&lt;td&gt;Centralized backup management for all AWS resources&lt;/td&gt;
&lt;td&gt;Automated backup scheduling, compliance reporting&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  Cost Estimates
&lt;/h3&gt;

&lt;p&gt;The agent even included a cost estimate for the stack of choice.&lt;/p&gt;

&lt;h4&gt;
  
  
  Monthly Cost Breakdown
&lt;/h4&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Service Category&lt;/th&gt;
&lt;th&gt;Estimated Monthly Cost&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Compute (GameLift, Lambda, ECS)&lt;/td&gt;
&lt;td&gt;$80,000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Database (DynamoDB, Aurora, ElastiCache)&lt;/td&gt;
&lt;td&gt;$30,000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Storage (S3, EBS)&lt;/td&gt;
&lt;td&gt;$10,000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Data Transfer (CloudFront, outbound)&lt;/td&gt;
&lt;td&gt;$25,000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;API Gateway (WebSocket, REST)&lt;/td&gt;
&lt;td&gt;$15,000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Monitoring (CloudWatch, X-Ray, Grafana)&lt;/td&gt;
&lt;td&gt;$5,000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Security (WAF, Shield Advanced, GuardDuty)&lt;/td&gt;
&lt;td&gt;$5,000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Other (Cognito, SNS, SQS, etc.)&lt;/td&gt;
&lt;td&gt;$5,000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;TOTAL&lt;/td&gt;
&lt;td&gt;~$175,000/month&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Cost per player-hour: ~$0.04 (within target of &amp;lt; $0.05)&lt;br&gt;
Optimization opportunities:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Use Spot instances for game servers: 40% savings on compute&lt;/li&gt;
&lt;li&gt;Reserved Instances for baseline capacity: 30% additional savings&lt;/li&gt;
&lt;li&gt;Optimize data transfer with better CDN caching: 20% savings&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Putting all to a diagram
&lt;/h3&gt;

&lt;p&gt;Now, diagramming capabilities are quite limited, but they're still valuable if we want to evaluate multiple choices or get an early draft visualized. Let's do this!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fy1vi8qs2rcktkd8lgcne.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fy1vi8qs2rcktkd8lgcne.png" alt=" " width="800" height="1288"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7pxorvr6kxo9npmod8ey.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7pxorvr6kxo9npmod8ey.png" alt=" " width="800" height="924"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Further improvements
&lt;/h3&gt;

&lt;p&gt;We can even extend this agent with various &lt;a href="https://opencode.ai/docs/skills/#use-an-example" rel="noopener noreferrer"&gt;skills&lt;/a&gt;. This can include a Markdown-formatted &lt;a href="https://github.com/joelparkerhenderson/architecture-decision-record/blob/main/locales/en/templates/decision-record-template-by-michael-nygard/index.md" rel="noopener noreferrer"&gt;ADR template&lt;/a&gt;, so you can formulate all the wisdom collected by an agent into a set of decision records. I'll do this later in another article with the introduction of additional skills.&lt;/p&gt;

&lt;h2&gt;
  
  
  References
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://opencode.ai/docs/providers/" rel="noopener noreferrer"&gt;OpenCode Providers Documentation&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://aws.amazon.com/blogs/machine-learning/build-aws-architecture-diagrams-using-amazon-q-cli-and-mcp/" rel="noopener noreferrer"&gt;Build AWS architecture diagrams using Amazon Q CLI and MCP&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://awslabs.github.io/mcp/servers/aws-documentation-mcp-server" rel="noopener noreferrer"&gt;AWS Documentation MCP Server&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="//github.com/gitaroktato/opencode-agents"&gt;My OpenCode settings in GitHub&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>ai</category>
      <category>architecture</category>
      <category>aws</category>
      <category>opensource</category>
    </item>
    <item>
      <title>Steps to Take for an Awesome AWS Deployment Diagram</title>
      <dc:creator>Oresztesz Margaritisz</dc:creator>
      <pubDate>Tue, 02 Dec 2025 15:29:14 +0000</pubDate>
      <link>https://dev.to/gitaroktato/steps-to-take-for-an-awesome-aws-deployment-diagram-222m</link>
      <guid>https://dev.to/gitaroktato/steps-to-take-for-an-awesome-aws-deployment-diagram-222m</guid>
      <description>&lt;p&gt;Have you often envied the rich and crisp AWS diagrams you see online, but aren't sure how to recreate them with confidence? The tips I've collected may help you improve your deployment diagrams. Get ready to deliver cloud solutions architectures that are robust, scalable, and cost-effective!&lt;/p&gt;

&lt;h1&gt;
  
  
  Prerequisites
&lt;/h1&gt;

&lt;p&gt;Before jumping into drawing your AWS architecture diagrams, make sure you have the following prerequisites in place:&lt;/p&gt;

&lt;h2&gt;
  
  
  Declare Your Quality Attributes and NFRs
&lt;/h2&gt;

&lt;p&gt;Ensure you cover all quality attributes and metrics in priority order. You can use a ready-made template to make your work efficient. Some are available publicly:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You can look at the Arc42 quality model &lt;a href="https://quality.arc42.org/" rel="noopener noreferrer"&gt;here&lt;/a&gt;; several examples are available &lt;a href="https://docs.arc42.org/section-10/" rel="noopener noreferrer"&gt;in the template&lt;/a&gt; as well.&lt;/li&gt;
&lt;li&gt;Well-Architected pillars, for instance &lt;a href="https://learn.microsoft.com/en-us/azure/well-architected/pillars" rel="noopener noreferrer"&gt;Azure&lt;/a&gt; or &lt;a href="https://docs.aws.amazon.com/wellarchitected/latest/framework/the-pillars-of-the-framework.html" rel="noopener noreferrer"&gt;AWS&lt;/a&gt;, come with several examples.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F75868unkrja4qlxg9ycc.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F75868unkrja4qlxg9ycc.png" alt="Arc42 quality graph showing scalability in the middle" width="800" height="444"&gt;&lt;/a&gt;&lt;/p&gt;
Arc42 quality graph showing scalability in the middle



&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fe492kn44kt45hf6tcj56.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fe492kn44kt45hf6tcj56.png" alt="AWS Well-Architected Framework pillars" width="800" height="377"&gt;&lt;/a&gt;&lt;/p&gt;
AWS Well-Architected Framework pillars



&lt;h2&gt;
  
  
  Understand Higher-Level Technology Strategy and Context
&lt;/h2&gt;

&lt;p&gt;If the organization's architecture is heading in a well-defined direction, your solution should follow the same approach.&lt;br&gt;
Before working on the details of your own diagram, collect all documents that capture relevant technology strategy for your case.&lt;/p&gt;

&lt;p&gt;The contextual view from the &lt;a href="https://c4model.com/diagrams/system-context" rel="noopener noreferrer"&gt;C4 model&lt;/a&gt; helps you concentrate on your surroundings and minimize effort on details. It is strongly recommended to initiate the first steps of your architecture work with this piece. The main focus should be:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Actors using your system&lt;/li&gt;
&lt;li&gt;External systems as integration points&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fev0hztelleodnff228g2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fev0hztelleodnff228g2.png" alt="Example system context from Arc42" width="517" height="369"&gt;&lt;/a&gt;&lt;/p&gt;
Example system context from Arc42



&lt;h2&gt;
  
  
  Narrow Down Your Architecture Styles and Patterns
&lt;/h2&gt;

&lt;p&gt;Don't forget that this must be aligned with the higher-level technology strategy.&lt;br&gt;
A comprehensive list of architecture styles and patterns can be found at:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://learn.microsoft.com/en-us/azure/architecture/guide/architecture-styles/" rel="noopener noreferrer"&gt;Azure architecture guide&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://en.wikipedia.org/wiki/List_of_software_architecture_styles_and_patterns" rel="noopener noreferrer"&gt;Wikipedia&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;A comprehensive infographic on &lt;a href="https://bytebytego.com/guides/top-5-software-architectural-patterns/" rel="noopener noreferrer"&gt;software architecture styles&lt;/a&gt; from ByteBtyeGo&lt;/li&gt;
&lt;/ul&gt;

&lt;h1&gt;
  
  
  Research
&lt;/h1&gt;

&lt;h2&gt;
  
  
  Collecting Use Cases
&lt;/h2&gt;

&lt;p&gt;The following pages and guides hold valuable blueprints for typical use cases.&lt;/p&gt;

&lt;p&gt;Finding comprehensive AWS use-case blueprints can be challenging, as they are often scattered across different AWS resources. Collecting these links in one place makes it easier to find proven architectures and patterns. This helps you quickly apply AWS best practices to your own projects.&lt;/p&gt;

&lt;p&gt;As the first step, go through this list of resources to gather relevant use cases for your architecture:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://aws.amazon.com/prescriptive-guidance/" rel="noopener noreferrer"&gt;AWS Prescriptive Guidance&lt;/a&gt; – make sure you scroll all the way down and check "Guides," "Patterns," and "Strategies."&lt;/li&gt;
&lt;li&gt;&lt;a href="https://aws.amazon.com/architecture/reference-architecture-diagrams/" rel="noopener noreferrer"&gt;AWS Reference Architecture Diagrams&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://aws.amazon.com/solutions/case-studies/" rel="noopener noreferrer"&gt;AWS Case Studies&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://aws.amazon.com/solutions/" rel="noopener noreferrer"&gt;AWS Solutions Library&lt;/a&gt; – make sure you scroll all the way down and check both "Find solutions by category" and "Browse all solutions."&lt;/li&gt;
&lt;li&gt;&lt;a href="https://aws.amazon.com/architecture/" rel="noopener noreferrer"&gt;AWS Architecture Center&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://aws.amazon.com/architecture/well-architected/" rel="noopener noreferrer"&gt;AWS Well-Architected Lenses&lt;/a&gt; – make sure you check these special well-architected lenses in the "AWS Well-Architected Lenses" section.&lt;/li&gt;
&lt;li&gt;&lt;a href="https://aws.amazon.com/whitepapers" rel="noopener noreferrer"&gt;AWS Whitepapers &amp;amp; Guides&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  General Advice Before Starting to Draw
&lt;/h2&gt;

&lt;p&gt;Pay attention to the style and iconography used in the diagrams you find. Notice how groupings are used to distinguish different parts of the architecture, how to display multi-AZ, multi-region setups, and how to represent security boundaries.&lt;/p&gt;

&lt;h1&gt;
  
  
  Tools for Drawing
&lt;/h1&gt;

&lt;p&gt;After finishing your research, it's time to start drawing your architecture diagrams. Here are some useful resources to help you recreate the AWS style and iconography.&lt;/p&gt;

&lt;h2&gt;
  
  
  Iconography
&lt;/h2&gt;

&lt;p&gt;Here's a website that provides a full list of AWS icons:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://awsicons.dev/" rel="noopener noreferrer"&gt;AWS Icons&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Diagramming Tools
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://www.drawio.com/" rel="noopener noreferrer"&gt;DrawIO&lt;/a&gt; – my favorite tool, able to draw a whole set of different AWS architectures, including all icons. Limited support for 3D AWS deployment views as well.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://aws.amazon.com/infrastructure-composer/" rel="noopener noreferrer"&gt;AWS Composer&lt;/a&gt; – able to generate ready-to-deploy IaC, and integrate with IDEs for generative AI-powered suggestions.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://cloudcraft.co/" rel="noopener noreferrer"&gt;CloudCraft&lt;/a&gt; – specialized in 3D AWS architecture diagrams with support for cost estimation.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fz6rgz8t0w6ew7bvxu16v.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fz6rgz8t0w6ew7bvxu16v.png" alt=" " width="800" height="467"&gt;&lt;/a&gt;&lt;/p&gt;
An example 3D deployment view



&lt;h1&gt;
  
  
  Refine Your Deployment View
&lt;/h1&gt;

&lt;p&gt;After finishing your first draft, it's time to review your work. The tools below help you ensure that your architecture follows AWS best practices and matches your requirements. Gradually refine and polish your diagram based on the materials below.&lt;/p&gt;

&lt;h2&gt;
  
  
  AWS Well-Architected Pillars
&lt;/h2&gt;

&lt;p&gt;Make sure you deep dive into each pillar and collect those gudelines which are relevant for your deployment. Use these as a checklist to verify that your architecture meets AWS best practices. Each pillar has its own dedicated whitepaper. I'm going to list them all in here for your convenience:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://docs.aws.amazon.com/wellarchitected/latest/framework/the-pillars-of-the-framework.html" rel="noopener noreferrer"&gt;Overview of the Pillars&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://docs.aws.amazon.com/wellarchitected/latest/operational-excellence-pillar/welcome.html?ref=wellarchitected-wp" rel="noopener noreferrer"&gt;Operational Excelence&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://docs.aws.amazon.com/wellarchitected/latest/security-pillar/welcome.html?ref=wellarchitected-wp" rel="noopener noreferrer"&gt;Security&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://docs.aws.amazon.com/wellarchitected/latest/reliability-pillar/welcome.html?ref=wellarchitected-wp" rel="noopener noreferrer"&gt;Reliability&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://docs.aws.amazon.com/wellarchitected/latest/performance-efficiency-pillar/welcome.html?ref=wellarchitected-wp" rel="noopener noreferrer"&gt;Performance&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://docs.aws.amazon.com/wellarchitected/latest/cost-optimization-pillar/welcome.html?ref=wellarchitected-wp" rel="noopener noreferrer"&gt;Cost Optimization&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://docs.aws.amazon.com/wellarchitected/latest/sustainability-pillar/sustainability-pillar.html?ref=wellarchitected-wp" rel="noopener noreferrer"&gt;Sustainability&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Evaluating Technologies
&lt;/h2&gt;

&lt;p&gt;Open source projects to find libraries, tools, and resources for your services help narrow down technology choices.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://awstools.dev/" rel="noopener noreferrer"&gt;AWS Tools&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Serverless Patterns
&lt;/h2&gt;

&lt;p&gt;A full set of serverless patterns with example code and one-click deployment. You can use it to polish a specific area of your architecture if you're considering a serverless architectural style.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://serverlessland.com/" rel="noopener noreferrer"&gt;Serverlessland&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F590lgbfntnmhz9oo9o6t.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F590lgbfntnmhz9oo9o6t.png" alt=" " width="800" height="425"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Justify and Explain Your Deployment View
&lt;/h1&gt;

&lt;p&gt;There are some ready-made materials to help make your architecture more understandable. The C4 model is an excellent framework for architecture analysis, so I use most of their provided resources to cross-check my diagrams.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://c4model.com/diagrams/checklist" rel="noopener noreferrer"&gt;Diagram review checklist&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://static.codingthearchitecture.com/techtribesje-software-architecture-diagrams.pdf" rel="noopener noreferrer"&gt;techtribes.je&lt;/a&gt; – sample high-level architecture diagram from Simon Brown, showcasing some of the best practices from the diagram review checklist.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://docs.arc42.org/section-7/" rel="noopener noreferrer"&gt;Arc42 template – deployment view&lt;/a&gt; – The arc42 template offers high-quality, polished guidelines. This section provides specific advice on how to represent deployments.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you want a quick checklist for AWS deployment views, here's a quick one:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Security:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Are boundaries clear between different AWS accounts, regions, and availability zones?&lt;/li&gt;
&lt;li&gt;Are security components (like WAF, AWS Shield, Security Groups, NACLs) included where necessary?&lt;/li&gt;
&lt;li&gt;Is public and private subnetting represented? Is it clear which components are in which subnet?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Scalability:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Is autoscaling represented for services that require it?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Availability:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Are boundaries clear between different AWS accounts, regions, and availability zones?&lt;/li&gt;
&lt;li&gt;Are edge services (like CloudFront, Route 53, API Gateway) clearly represented?&lt;/li&gt;
&lt;li&gt;Is networking between AWS and a physical data center represented (if applicable)?&lt;/li&gt;
&lt;li&gt;If this is a multi-region deployment, are the regions and their interactions clearly represented?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Observability (supports all categories):&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Is observability clearly represented (CloudWatch, CloudTrail, X-Ray, CloudWatch Logs, etc.)?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fm10feseeczdu0g1auu7f.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fm10feseeczdu0g1auu7f.png" alt="techtribes.je - components view" width="477" height="632"&gt;&lt;/a&gt;techtribes.je - components view&lt;/p&gt;

&lt;h2&gt;
  
  
  Provide an Explanation for Your Deployment View
&lt;/h2&gt;

&lt;p&gt;Make sure you back up your technology choices represented in the deployment view with explanations. For instance, you can use the &lt;a href="https://docs.arc42.org/section-9/" rel="noopener noreferrer"&gt;"Architecture Decisions"&lt;/a&gt; section from the Arc42 template.&lt;/p&gt;

&lt;h2&gt;
  
  
  Don't Forget About Cost and Capacity Estimates
&lt;/h2&gt;

&lt;p&gt;Crafting a good deployment plan is an iterative process. Make sure you revisit your architecture diagram and refine it based on cost and capacity estimates. For your cost estimates, you can use the &lt;a href="https://calculator.aws/#/" rel="noopener noreferrer"&gt;AWS Pricing Calculator&lt;/a&gt;. &lt;/p&gt;

&lt;p&gt;To get realistic price calculations, you need basically two things:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Technology choices, to know which services you are going to use.&lt;/li&gt;
&lt;li&gt;Capacity estimates, to be able to fill in the planned workload.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Making good capacity estimates is an art in itself. I recommend a book that provides guidance on how to do it properly: &lt;a href="https://www.oreilly.com/library/view/the-art-of/9781491939192/" rel="noopener noreferrer"&gt;The Art of Capacity Planning&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you need a quick introduction, a short case study is available in a ByteByteGo article &lt;a href="https://blog.bytebytego.com/p/capacity-planning" rel="noopener noreferrer"&gt;here&lt;/a&gt;. It uses synthetic sensor traffic and social media feeds as examples to demonstrate how to derive throughput, clustering, and bandwidth. The article also includes a diagram with a high-level overview of different scenarios.&lt;/p&gt;

&lt;p&gt;Luckily, a handful of database engines offer guidelines and formulas for estimating capacity.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://docs.datastax.com/en/planning/oss/capacity-planning.html" rel="noopener noreferrer"&gt;Cassandra capacity planning guide&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://docs.aws.amazon.com/opensearch-service/latest/developerguide/bp-storage.html" rel="noopener noreferrer"&gt;OpenSearch storage requirements&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmgu023e5xfcj142yfbyx.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmgu023e5xfcj142yfbyx.webp" alt=" " width="800" height="788"&gt;&lt;/a&gt;different capacity planning scenarios&lt;/p&gt;

&lt;p&gt;If it turns out that one specific piece of your architecture is too expensive, you don't necessarily have to proceed with it. Instead, explore alternative services or deployment models to reduce costs.&lt;/p&gt;

&lt;h1&gt;
  
  
  Power of GenAI
&lt;/h1&gt;

&lt;p&gt;If you want to speed up your work, you can use Amazon Q with AWS-provided MCP services as a CLI tool. The generated diagrams are often not enough to meet quality standards, but I think the generated output can be used for exploring different options. Also, with the help of MCP, Amazon Q is able to search inside AWS documentation and help you clarify differences between specific AWS services and deployment models.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://aws.amazon.com/blogs/machine-learning/build-aws-architecture-diagrams-using-amazon-q-cli-and-mcp/" rel="noopener noreferrer"&gt;Build AWS architecture diagrams using Amazon Q CLI and MCP&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzk4rwwvln9e81qv0n3wb.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzk4rwwvln9e81qv0n3wb.png" alt=" " width="569" height="365"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>aws</category>
      <category>architecture</category>
    </item>
    <item>
      <title>Configuring LazyVim and Python on Windows with WSL</title>
      <dc:creator>Oresztesz Margaritisz</dc:creator>
      <pubDate>Tue, 25 Mar 2025 07:42:59 +0000</pubDate>
      <link>https://dev.to/gitaroktato/configuring-lazyvim-and-python-on-windows-with-wsl-2fpd</link>
      <guid>https://dev.to/gitaroktato/configuring-lazyvim-and-python-on-windows-with-wsl-2fpd</guid>
      <description>&lt;h1&gt;
  
  
  Prerequisites
&lt;/h1&gt;

&lt;h2&gt;
  
  
  [OPTIONAL] Install a package manager - &lt;code&gt;scoop&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;You can use &lt;a href="https://scoop.sh" rel="noopener noreferrer"&gt;Scoop&lt;/a&gt; package manager to install various packages. If you want to skip this step, you can install WezTerm manually. Open a PowerShell terminal and type&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;Set-ExecutionPolicy&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-ExecutionPolicy&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;RemoteSigned&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-Scope&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;CurrentUser&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;Invoke-RestMethod&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-Uri&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;https://get.scoop.sh&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;Invoke-Expression&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Install a terminal - &lt;code&gt;wezterm&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;This step is necessary for displaying LazyVim and special icons appropriately. You have to use a terminal that supports LazyVim - &lt;a href="https://github.com/wez/wezterm" rel="noopener noreferrer"&gt;wezterm&lt;/a&gt;. If you haven't installed &lt;code&gt;scoop&lt;/code&gt;, you can just manually download and install WezTerm from &lt;a href="https://wezterm.org/install/windows.html" rel="noopener noreferrer"&gt;here&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;scoop&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;bucket&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;add&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;extras&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;scoop&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;install&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;extras/wezterm&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  First steps - configuring WSL
&lt;/h2&gt;

&lt;p&gt;You can try to run LazyVim from Windows directly, but my experience is that it comes with plenty of tradeoffs and many features are currently broken. I'll try to give an explanation at the end of this article.&lt;br&gt;
Make sure you have WSL2 with latest stable Ubuntu LTS installed.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;wsl&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;--list&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;--online&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;wsl&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;--install&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-d&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;Ubuntu-24.04&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Start &lt;code&gt;wsl&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;wsl&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-d&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;Ubuntu-24.04&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Reference: &lt;a href="https://learn.microsoft.com/en-us/windows/wsl/install" rel="noopener noreferrer"&gt;https://learn.microsoft.com/en-us/windows/wsl/install&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Install command line prerequisites
&lt;/h2&gt;

&lt;p&gt;Install NeoVim latest stable&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;snap &lt;span class="nb"&gt;install &lt;/span&gt;nvim &lt;span class="nt"&gt;--classic&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Reference: &lt;a href="https://github.com/neovim/neovim/blob/master/INSTALL.md#snap" rel="noopener noreferrer"&gt;https://github.com/neovim/neovim/blob/master/INSTALL.md#snap&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Install LazyGit&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;LAZYGIT_VERSION&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="si"&gt;$(&lt;/span&gt;curl &lt;span class="nt"&gt;-s&lt;/span&gt; &lt;span class="s2"&gt;"https://api.github.com/repos/jesseduffield/lazygit/releases/latest"&lt;/span&gt; | &lt;span class="se"&gt;\g&lt;/span&gt;rep &lt;span class="nt"&gt;-Po&lt;/span&gt; &lt;span class="s1"&gt;'"tag_name": *"v\K[^"]*'&lt;/span&gt;&lt;span class="si"&gt;)&lt;/span&gt;
curl &lt;span class="nt"&gt;-Lo&lt;/span&gt; lazygit.tar.gz &lt;span class="s2"&gt;"https://github.com/jesseduffield/lazygit/releases/download/v&lt;/span&gt;&lt;span class="k"&gt;${&lt;/span&gt;&lt;span class="nv"&gt;LAZYGIT_VERSION&lt;/span&gt;&lt;span class="k"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;/lazygit_&lt;/span&gt;&lt;span class="k"&gt;${&lt;/span&gt;&lt;span class="nv"&gt;LAZYGIT_VERSION&lt;/span&gt;&lt;span class="k"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;_Linux_x86_64.tar.gz"&lt;/span&gt;
&lt;span class="nb"&gt;tar &lt;/span&gt;xf lazygit.tar.gz lazygit
&lt;span class="nb"&gt;sudo install &lt;/span&gt;lazygit &lt;span class="nt"&gt;-D&lt;/span&gt; &lt;span class="nt"&gt;-t&lt;/span&gt; /usr/local/bin/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Reference: &lt;a href="https://github.com/jesseduffield/lazygit?tab=readme-ov-file#ubuntu" rel="noopener noreferrer"&gt;https://github.com/jesseduffield/lazygit?tab=readme-ov-file#ubuntu&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Install &lt;code&gt;gcc&lt;/code&gt;, &lt;code&gt;make&lt;/code&gt; and other tools (required for &lt;code&gt;nvim-treesitter&lt;/code&gt; and for installing &lt;code&gt;python&lt;/code&gt; versions)&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt &lt;span class="nb"&gt;install &lt;/span&gt;build-essential &lt;span class="se"&gt;\&lt;/span&gt;
  dpkg-dev &lt;span class="se"&gt;\&lt;/span&gt;
  gcc &lt;span class="se"&gt;\&lt;/span&gt;
  gnupg &lt;span class="se"&gt;\&lt;/span&gt;
  libbluetooth-dev &lt;span class="se"&gt;\&lt;/span&gt;
  libbz2-dev &lt;span class="se"&gt;\&lt;/span&gt;
  libc6-dev &lt;span class="se"&gt;\&lt;/span&gt;
  libdb-dev &lt;span class="se"&gt;\&lt;/span&gt;
  libffi-dev &lt;span class="se"&gt;\&lt;/span&gt;
  libgdbm-dev &lt;span class="se"&gt;\&lt;/span&gt;
  liblzma-dev &lt;span class="se"&gt;\&lt;/span&gt;
  libncursesw5-dev &lt;span class="se"&gt;\&lt;/span&gt;
  libreadline-dev &lt;span class="se"&gt;\&lt;/span&gt;
  libsqlite3-dev &lt;span class="se"&gt;\&lt;/span&gt;
  libssl-dev &lt;span class="se"&gt;\&lt;/span&gt;
  make &lt;span class="se"&gt;\&lt;/span&gt;
  pkg-config &lt;span class="se"&gt;\&lt;/span&gt;
  tk-dev &lt;span class="se"&gt;\&lt;/span&gt;
  uuid-dev &lt;span class="se"&gt;\&lt;/span&gt;
  wget &lt;span class="se"&gt;\&lt;/span&gt;
  xz-utils &lt;span class="se"&gt;\&lt;/span&gt;
  zlib1g-dev
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Reference: &lt;a href="https://github.com/docker-library/python/blob/0330f0baedb296c8806a869d04fe76838f721647/3.13/slim-bullseye/Dockerfile#L30" rel="noopener noreferrer"&gt;https://github.com/docker-library/python/blob/0330f0baedb296c8806a869d04fe76838f721647/3.13/slim-bullseye/Dockerfile#L30&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Install all other tools to work with &lt;code&gt;fzf-lua&lt;/code&gt;. Required for LazyVim to effectively navigate in your project files.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt &lt;span class="nb"&gt;install &lt;/span&gt;fzf ripgrep fdclone
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Install NodeJS with a version manager - &lt;code&gt;nvm&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Mainly required for the builtin LazyVim package manager, called &lt;code&gt;mason&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-o-&lt;/span&gt; https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.2/install.sh | bash
nvm &lt;span class="nb"&gt;install&lt;/span&gt; &lt;span class="nt"&gt;--lts&lt;/span&gt;
nvm use &lt;span class="nt"&gt;--lts&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Check if it's working&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm &lt;span class="nt"&gt;--version&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Reference: &lt;a href="https://github.com/nvm-sh/nvm?tab=readme-ov-file#installing-and-updating" rel="noopener noreferrer"&gt;https://github.com/nvm-sh/nvm?tab=readme-ov-file#installing-and-updating&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Install &lt;code&gt;pyenv&lt;/code&gt; to manage Python environments.
&lt;/h2&gt;

&lt;p&gt;Note, that &lt;code&gt;uv&lt;/code&gt; is not supported currently as a Python provider. Also, &lt;code&gt;uv&lt;/code&gt; does not allow you to use a specify Python version in your &lt;code&gt;PATH&lt;/code&gt;. Follow &lt;a href="https://github.com/astral-sh/uv/issues/6265" rel="noopener noreferrer"&gt;this open GitHub issue&lt;/a&gt; for more information.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl https://pyenv.run | bash
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Change &lt;code&gt;.bashrc&lt;/code&gt; to include &lt;code&gt;pyenv&lt;/code&gt; features&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cat&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&amp;gt;&lt;/span&gt; ~/.bashrc
&lt;span class="nb"&gt;export &lt;/span&gt;&lt;span class="nv"&gt;PYENV_ROOT&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="nv"&gt;$HOME&lt;/span&gt;&lt;span class="s2"&gt;/.pyenv"&lt;/span&gt;
&lt;span class="o"&gt;[[&lt;/span&gt; &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="nv"&gt;$PYENV_ROOT&lt;/span&gt;/bin &lt;span class="o"&gt;]]&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nb"&gt;export &lt;/span&gt;&lt;span class="nv"&gt;PATH&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="nv"&gt;$PYENV_ROOT&lt;/span&gt;&lt;span class="s2"&gt;/bin:&lt;/span&gt;&lt;span class="nv"&gt;$PATH&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;span class="nb"&gt;eval&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="si"&gt;$(&lt;/span&gt;pyenv init - bash&lt;span class="si"&gt;)&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Install latest Python version and make it global&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;pyenv &lt;span class="nb"&gt;install &lt;/span&gt;3.13
pyenv global 3.13
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Reference: &lt;a href="https://github.com/pyenv/pyenv-installer?tab=readme-ov-file#install" rel="noopener noreferrer"&gt;https://github.com/pyenv/pyenv-installer?tab=readme-ov-file#install&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Ready to Roll! 🚀
&lt;/h1&gt;

&lt;p&gt;At this point, you're ready to install LazyVim and take the first look. For the reference this command is taken from &lt;a href="https://www.lazyvim.org/installation" rel="noopener noreferrer"&gt;here&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Make a backup of your current Neovim files:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# required&lt;/span&gt;
&lt;span class="nb"&gt;mv&lt;/span&gt; ~/.config/nvim&lt;span class="o"&gt;{&lt;/span&gt;,.bak&lt;span class="o"&gt;}&lt;/span&gt;

&lt;span class="c"&gt;# optional but recommended&lt;/span&gt;
&lt;span class="nb"&gt;mv&lt;/span&gt; ~/.local/share/nvim&lt;span class="o"&gt;{&lt;/span&gt;,.bak&lt;span class="o"&gt;}&lt;/span&gt;
&lt;span class="nb"&gt;mv&lt;/span&gt; ~/.local/state/nvim&lt;span class="o"&gt;{&lt;/span&gt;,.bak&lt;span class="o"&gt;}&lt;/span&gt;
&lt;span class="nb"&gt;mv&lt;/span&gt; ~/.cache/nvim&lt;span class="o"&gt;{&lt;/span&gt;,.bak&lt;span class="o"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Clone the starter&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git clone https://github.com/LazyVim/starter ~/.config/nvim
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Remove the &lt;code&gt;.git&lt;/code&gt; folder, so you can add it to your own repo later&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;rm&lt;/span&gt; &lt;span class="nt"&gt;-rf&lt;/span&gt; ~/.config/nvim/.git
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Start Neovim for the first time!&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;nvim
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You should see the package manager installing packages, wait until it finishes.&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3z3zmxl51s2fk3o7rdtn.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3z3zmxl51s2fk3o7rdtn.png" alt=" " width="800" height="413"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  Checking installation
&lt;/h2&gt;

&lt;p&gt;Type &lt;code&gt;:LazyHealth&lt;/code&gt; to open up the window showing package statuses. &lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyvaavonbvi1dqm1czq51.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyvaavonbvi1dqm1czq51.png" alt=" " width="800" height="429"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  Using &lt;code&gt;LazyVim Extras&lt;/code&gt; to install Python IDE
&lt;/h2&gt;

&lt;p&gt;Next type &lt;code&gt;:LazyExtras&lt;/code&gt; to go to the &lt;code&gt;LazyVim Extras&lt;/code&gt;. Type &lt;code&gt;/&lt;/code&gt; &lt;code&gt;python&lt;/code&gt; to search for Python related packages.&lt;/p&gt;

&lt;p&gt;Press &lt;code&gt;x&lt;/code&gt; to install related packages (at the cursor, called &lt;code&gt;lang.python&lt;/code&gt;). Do the same for &lt;code&gt;dap.core&lt;/code&gt;, &lt;code&gt;test.core&lt;/code&gt; &lt;code&gt;editor.refactoring&lt;/code&gt;, &lt;code&gt;lang.json&lt;/code&gt;, &lt;code&gt;lang.markdown&lt;/code&gt;, and &lt;code&gt;lang.toml&lt;/code&gt;. Optionally you can install &lt;code&gt;ui.mini-animate&lt;/code&gt; for an animated cursor and &lt;code&gt;coding.yanky&lt;/code&gt; for and advanced clipboard experience.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmmiri1af29a81f2zawm9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmmiri1af29a81f2zawm9.png" alt=" " width="800" height="388"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Press &lt;code&gt;q&lt;/code&gt; to quit &lt;code&gt;LazyExtras&lt;/code&gt;.&lt;/p&gt;
&lt;h1&gt;
  
  
  Configuring plugins
&lt;/h1&gt;

&lt;p&gt;Your next step will be to configure some of the Python plugins to ensure, that they're working as you expect. Start LazyVim with the following command to edit your configuration:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;nvim ~/.config/nvim
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;First thing to do is to configure the Python extra by setting your LSP server + Ruff command. Edit your &lt;code&gt;lua/config/options.lua&lt;/code&gt; file and these lines:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight lua"&gt;&lt;code&gt;&lt;span class="c1"&gt;-- LSP Server to use for Python.&lt;/span&gt;
&lt;span class="c1"&gt;-- Set to "basedpyright" to use basedpyright instead of pyright.&lt;/span&gt;
&lt;span class="n"&gt;vim&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;g&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;lazyvim_python_lsp&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"pyright"&lt;/span&gt;
&lt;span class="c1"&gt;-- Set to "ruff_lsp" to use the old LSP implementation version.&lt;/span&gt;
&lt;span class="n"&gt;vim&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;g&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;lazyvim_python_ruff&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"ruff"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Reference: &lt;a href="https://www.lazyvim.org/extras/lang/python#options" rel="noopener noreferrer"&gt;https://www.lazyvim.org/extras/lang/python#options&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Create a &lt;code&gt;test.lua&lt;/code&gt; under &lt;code&gt;nvim/lua/plugins&lt;/code&gt; folder and configure it like the example below:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight lua"&gt;&lt;code&gt;&lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="s2"&gt;"nvim-neotest/neotest"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;opts&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="n"&gt;adapters&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"neotest-python"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="n"&gt;dap&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;justMyCode&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
        &lt;span class="n"&gt;args&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="s2"&gt;"--capture=no"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
        &lt;span class="n"&gt;pytest_discover_instances&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="p"&gt;},&lt;/span&gt;
  &lt;span class="p"&gt;},&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This will ensure, that &lt;code&gt;neotest&lt;/code&gt; and &lt;code&gt;neotest-python&lt;/code&gt; allows you to:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;flush output buffer during testing, so &lt;code&gt;stdout&lt;/code&gt; and &lt;code&gt;stderr&lt;/code&gt; messages are appearing, while tests are running&lt;/li&gt;
&lt;li&gt;set breakpoints and debug inside library code&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Next you should create a &lt;code&gt;debug.lua&lt;/code&gt; under &lt;code&gt;nvim/lua/plugins&lt;/code&gt; folder and configure it like the example below:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight lua"&gt;&lt;code&gt;&lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="s2"&gt;"mfussenegger/nvim-dap-python"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;opts&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="n"&gt;justMyCode&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;},&lt;/span&gt;
  &lt;span class="p"&gt;},&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This will ensure, that &lt;code&gt;nvim-dap&lt;/code&gt; and &lt;code&gt;nvim-dap-python&lt;/code&gt; allows you to set breakpoints and debug inside library code. The end result should look something like this:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ftk5y3in6z49chm5mfmzi.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ftk5y3in6z49chm5mfmzi.png" alt=" " width="800" height="238"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Creating your first python project
&lt;/h1&gt;

&lt;p&gt;We'll use &lt;code&gt;pyenv&lt;/code&gt; to create a Python project and a virtual environment. Also add &lt;code&gt;pytest&lt;/code&gt; package to verify if testing and debugging works well.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;mkdir &lt;/span&gt;python-sandbox &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nb"&gt;cd &lt;/span&gt;python-sandbox
pyenv global 3.13
python &lt;span class="nt"&gt;-m&lt;/span&gt; venv .venv
&lt;span class="nb"&gt;.&lt;/span&gt; .venv/bin/activate
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Install &lt;code&gt;pytest&lt;/code&gt; executables for testing under your local project&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;pip&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;install&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;pytest&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Make sure you have your local project in the &lt;code&gt;PYTHONPATH&lt;/code&gt; on &lt;code&gt;bash&lt;/code&gt;. You can start LazyVim now within your project.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;PYTHONPATH&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sb"&gt;`&lt;/span&gt;&lt;span class="nb"&gt;pwd&lt;/span&gt;&lt;span class="sb"&gt;`&lt;/span&gt;:&lt;span class="nv"&gt;$PYTHONPATH&lt;/span&gt; nvim &lt;span class="nb"&gt;.&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h1&gt;
  
  
  Checking if key features are working
&lt;/h1&gt;

&lt;h2&gt;
  
  
  LSP
&lt;/h2&gt;

&lt;p&gt;After creating a Python project you can use &lt;code&gt;&amp;lt;leader&amp;gt;cl&lt;/code&gt; to view the LSP config. You should be able to see &lt;code&gt;pyright&lt;/code&gt; and &lt;code&gt;ruff&lt;/code&gt; at the top of the list with its settings.&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcklj058ht6j16r01zr3l.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcklj058ht6j16r01zr3l.png" alt=" " width="800" height="383"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Testing
&lt;/h2&gt;

&lt;p&gt;You need to verify if your &lt;code&gt;Neotest&lt;/code&gt; is interacting properly with &lt;code&gt;neotest-python&lt;/code&gt;. &lt;/p&gt;

&lt;p&gt;Create a simple &lt;code&gt;pytest&lt;/code&gt; test-case and use &lt;code&gt;&amp;lt;leader&amp;gt;ts&lt;/code&gt; for showing up all your test functions implemented under the project. Use &lt;code&gt;r&lt;/code&gt; to run one of your tests to ensure, that things are wired together properly.&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fimvfywh5ixwvvbf7b5z6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fimvfywh5ixwvvbf7b5z6.png" alt=" " width="800" height="480"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Debugging
&lt;/h2&gt;

&lt;p&gt;Final thing to verify if &lt;code&gt;nvim-dap&lt;/code&gt; is interacting with &lt;code&gt;nvim-dap-python&lt;/code&gt; correctly. Put a breakpoint in your code, by using &lt;code&gt;&amp;lt;leader&amp;gt;db&lt;/code&gt; on a line. Next, start a test after showing up all the test functions with pressing &lt;code&gt;d&lt;/code&gt; on the test case's name.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fffq839du4w7cm0gg5v3w.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fffq839du4w7cm0gg5v3w.png" alt=" " width="800" height="390"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Refactoring
&lt;/h2&gt;

&lt;p&gt;Stop on a function and try hitting &lt;code&gt;&amp;lt;leader&amp;gt;rs&lt;/code&gt; for showing the refactoring menu. You should be able to do simple things, like extracting a new function under selection by pressing &lt;code&gt;f&lt;/code&gt;. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9vobqras54fkdavge4gf.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9vobqras54fkdavge4gf.png" alt=" " width="800" height="424"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fn9fpzktj7bjfltps3ve9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fn9fpzktj7bjfltps3ve9.png" alt=" " width="800" height="404"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Final thoughts
&lt;/h1&gt;

&lt;h2&gt;
  
  
  Limited functionality under Windows
&lt;/h2&gt;

&lt;p&gt;I found out, that testing and debugging has several broken features if you run them from Windows natively. I haven't looked at the root cause, but one of the possible issues are inside &lt;code&gt;nvim-dap-python&lt;/code&gt; and &lt;code&gt;neotest-python&lt;/code&gt; libraries providing debugging and testing functionality. These extension libraries have to make distinction between Windows and Linux runtimes as binaries and virtual environments follow a different convention (e.g. &lt;code&gt;venv/bin/python&lt;/code&gt; VS &lt;code&gt;venv/Scripts/pythonw&lt;/code&gt;). These "conditions" and special cases are often getting broken and patched afterwards.&lt;/p&gt;

&lt;h2&gt;
  
  
  Using &lt;code&gt;uv&lt;/code&gt; as a Python version manager
&lt;/h2&gt;

&lt;p&gt;Currently it seems like &lt;code&gt;uv&lt;/code&gt; is not supporting global python versions &lt;a href="https://github.com/astral-sh/uv/issues/6265" rel="noopener noreferrer"&gt;you can see from this GitHub ticket&lt;/a&gt;. If you really like the speed and performance of &lt;code&gt;uv&lt;/code&gt; you can try to combine the best of both worlds: Using &lt;code&gt;pyenv&lt;/code&gt; for managing global Python versions and using &lt;code&gt;uv&lt;/code&gt; for managing your project-specific dependencies.&lt;/p&gt;

</description>
      <category>programming</category>
      <category>neovim</category>
      <category>tutorial</category>
      <category>python</category>
    </item>
    <item>
      <title>Configuring LazyVim and Python on Windows</title>
      <dc:creator>Oresztesz Margaritisz</dc:creator>
      <pubDate>Tue, 18 Mar 2025 06:49:25 +0000</pubDate>
      <link>https://dev.to/gitaroktato/configuring-lazyvim-and-python-on-windows-nke</link>
      <guid>https://dev.to/gitaroktato/configuring-lazyvim-and-python-on-windows-nke</guid>
      <description>&lt;h1&gt;
  
  
  Prerequisites
&lt;/h1&gt;

&lt;h2&gt;
  
  
  Install a package manager - &lt;code&gt;scoop&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;This step is required to simplify subsequent installation steps. Use the &lt;a href="https://scoop.sh" rel="noopener noreferrer"&gt;Scoop&lt;/a&gt; package manager to install various packages. Open a PowerShell terminal and type&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;Set-ExecutionPolicy&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-ExecutionPolicy&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;RemoteSigned&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-Scope&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;CurrentUser&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;Invoke-RestMethod&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-Uri&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;https://get.scoop.sh&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;|&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="n"&gt;Invoke-Expression&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Install a terminal - &lt;code&gt;wezterm&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;This step is necessary for displaying LazyVim and special icons appropriately. Use a terminal that supports LazyVim - &lt;a href="https://github.com/wez/wezterm" rel="noopener noreferrer"&gt;wezterm&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;scoop&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;bucket&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;add&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;extras&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;scoop&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;install&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;extras/wezterm&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Install command line prerequisites
&lt;/h2&gt;

&lt;p&gt;These shell commands are used with LazyVim, a comprehensive list can be found at the &lt;a href="https://www.lazyvim.org/#%EF%B8%8F-requirements" rel="noopener noreferrer"&gt;official documentation&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;scoop&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;bucket&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;add&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;main&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;scoop&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;install&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;main/git&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;main/neovim&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;main/curl&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;main/gcc&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;main/fzf&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;main/fd&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;main/ripgrep&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;main/unzip&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;extras/lazygit&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Install NodeJS with a version manager - &lt;code&gt;nvm&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Required for &lt;code&gt;mason&lt;/code&gt; - a package manager used by LazyVim to install various packages&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;scoop&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;install&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;main/nvm&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;nvm&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;install&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;lts&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;nvm&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;use&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;lts&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Check if it's working&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;npm&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;--version&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Install version manager for your programming language - &lt;code&gt;pyenv&lt;/code&gt;
&lt;/h2&gt;

&lt;p&gt;Note, that &lt;code&gt;uv&lt;/code&gt; is not supported currently as a Python provider. Also, &lt;code&gt;uv&lt;/code&gt; does not allow you to use a specify Python version in your &lt;code&gt;PATH&lt;/code&gt;. Follow &lt;a href="https://github.com/astral-sh/uv/issues/6265" rel="noopener noreferrer"&gt;this open GitHub issue&lt;/a&gt; for more information.&lt;/p&gt;

&lt;p&gt;Make sure you're using &lt;code&gt;scoop&lt;/code&gt; as an &lt;strong&gt;administrator&lt;/strong&gt; to install &lt;code&gt;pyenv&lt;/code&gt; correctly.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;scoop&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;install&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;main/pyenv&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;pyenv&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;install&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;3.11.0b4&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;pyenv&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;global&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;3.11.0b4&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Reference: &lt;a href="https://github.com/pyenv-win/pyenv-win/issues/449" rel="noopener noreferrer"&gt;https://github.com/pyenv-win/pyenv-win/issues/449&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Check if it's working&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;python&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;--version&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h1&gt;
  
  
  Ready to Roll! 🚀
&lt;/h1&gt;

&lt;p&gt;At this point, you're ready to install LazyVim and take the first look. For the reference this command is taken from &lt;a href="https://www.lazyvim.org/installation" rel="noopener noreferrer"&gt;here&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Make a backup of your current Neovim files:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="c"&gt;# required&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;Move-Item&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$&lt;/span&gt;&lt;span class="nn"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="nv"&gt;LOCALAPPDATA&lt;/span&gt;&lt;span class="nx"&gt;\nvim&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$&lt;/span&gt;&lt;span class="nn"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="nv"&gt;LOCALAPPDATA&lt;/span&gt;&lt;span class="nx"&gt;\nvim.bak&lt;/span&gt;&lt;span class="w"&gt;

&lt;/span&gt;&lt;span class="c"&gt;# optional but recommended&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;Move-Item&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$&lt;/span&gt;&lt;span class="nn"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="nv"&gt;LOCALAPPDATA&lt;/span&gt;&lt;span class="nx"&gt;\nvim-data&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$&lt;/span&gt;&lt;span class="nn"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="nv"&gt;LOCALAPPDATA&lt;/span&gt;&lt;span class="nx"&gt;\nvim-data.bak&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Clone the starter&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;git&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;clone&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;https://github.com/LazyVim/starter&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$&lt;/span&gt;&lt;span class="nn"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="nv"&gt;LOCALAPPDATA&lt;/span&gt;&lt;span class="nx"&gt;\nvim&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Remove the .git folder, so you can add it to your own repo later&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;Remove-Item&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$&lt;/span&gt;&lt;span class="nn"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="nv"&gt;LOCALAPPDATA&lt;/span&gt;&lt;span class="nx"&gt;\nvim\.git&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-Recurse&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-Force&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Start Neovim!&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;nvim
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You should see the package manager installing packages, wait until it finishes.&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3z3zmxl51s2fk3o7rdtn.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3z3zmxl51s2fk3o7rdtn.png" alt=" " width="800" height="413"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  Checking installation
&lt;/h2&gt;

&lt;p&gt;Type &lt;code&gt;:LazyHealth&lt;/code&gt; to open up the window showing package statuses. &lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyvaavonbvi1dqm1czq51.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyvaavonbvi1dqm1czq51.png" alt=" " width="800" height="429"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  Using &lt;code&gt;LazyVim Extras&lt;/code&gt; to install Python IDE
&lt;/h2&gt;

&lt;p&gt;Next type &lt;code&gt;:LazyExtras&lt;/code&gt; to go to the &lt;code&gt;LazyVim Extras&lt;/code&gt;. Type &lt;code&gt;/&lt;/code&gt; &lt;code&gt;python&lt;/code&gt; to search for Python related packages.&lt;/p&gt;

&lt;p&gt;Press &lt;code&gt;x&lt;/code&gt; to install related packages (at the cursor, called &lt;code&gt;lang.python&lt;/code&gt;). Do the same for &lt;code&gt;dap.core&lt;/code&gt;, &lt;code&gt;test.core&lt;/code&gt; &lt;code&gt;editor.refactoring&lt;/code&gt;, &lt;code&gt;lang.json&lt;/code&gt;, &lt;code&gt;lang.markdown&lt;/code&gt;, and &lt;code&gt;lang.toml&lt;/code&gt;. Optionally you can install &lt;code&gt;ui.mini-animate&lt;/code&gt; for an animated cursor and &lt;code&gt;coding.yanky&lt;/code&gt; for and advanced clipboard experience.&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7ugk1nvwj6t1j3uip7t3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7ugk1nvwj6t1j3uip7t3.png" alt=" " width="800" height="401"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Press &lt;code&gt;q&lt;/code&gt; to quit &lt;code&gt;LazyExtras&lt;/code&gt;.&lt;/p&gt;
&lt;h1&gt;
  
  
  Configuring plugins
&lt;/h1&gt;

&lt;p&gt;Your next step will be to configure some of the Python plugins to ensure, that they're working as you expect. Start LazyVim with the following command to edit your configuration:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;nvim&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$&lt;/span&gt;&lt;span class="nn"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="nv"&gt;LOCALAPPDATA&lt;/span&gt;&lt;span class="nx"&gt;\nvim&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;First thing to do is to configure the Python extra by setting your LSP server + Ruff command. Edit your &lt;code&gt;lua/config/options.lua&lt;/code&gt; file and these lines:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight lua"&gt;&lt;code&gt;&lt;span class="c1"&gt;-- LSP Server to use for Python.&lt;/span&gt;
&lt;span class="c1"&gt;-- Set to "basedpyright" to use basedpyright instead of pyright.&lt;/span&gt;
&lt;span class="n"&gt;vim&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;g&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;lazyvim_python_lsp&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"pyright"&lt;/span&gt;
&lt;span class="c1"&gt;-- Set to "ruff_lsp" to use the old LSP implementation version.&lt;/span&gt;
&lt;span class="n"&gt;vim&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;g&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;lazyvim_python_ruff&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"ruff"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;em&gt;Reference: &lt;a href="https://www.lazyvim.org/extras/lang/python#options" rel="noopener noreferrer"&gt;https://www.lazyvim.org/extras/lang/python#options&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Create a &lt;code&gt;test.lua&lt;/code&gt; under &lt;code&gt;nvim/lua/plugins&lt;/code&gt; folder and configure it like the example below:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight lua"&gt;&lt;code&gt;&lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="s2"&gt;"nvim-neotest/neotest"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;opts&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="n"&gt;adapters&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"neotest-python"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="n"&gt;dap&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="n"&gt;justMyCode&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
        &lt;span class="n"&gt;args&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="s2"&gt;"--capture=no"&lt;/span&gt; &lt;span class="p"&gt;},&lt;/span&gt;
        &lt;span class="n"&gt;pytest_discover_instances&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="p"&gt;},&lt;/span&gt;
    &lt;span class="p"&gt;},&lt;/span&gt;
  &lt;span class="p"&gt;},&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This will ensure, that &lt;code&gt;neotest&lt;/code&gt; and &lt;code&gt;neotest-python&lt;/code&gt; allows you to:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;flush output buffer during testing, so &lt;code&gt;stdout&lt;/code&gt; and &lt;code&gt;stderr&lt;/code&gt; messages are appearing, while tests are running&lt;/li&gt;
&lt;li&gt;set breakpoints and debug inside library code&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Next you should create a &lt;code&gt;debug.lua&lt;/code&gt; under &lt;code&gt;nvim/lua/plugins&lt;/code&gt; folder and configure it like the example below:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight lua"&gt;&lt;code&gt;&lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="s2"&gt;"mfussenegger/nvim-dap-python"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;opts&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="n"&gt;justMyCode&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="kc"&gt;false&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="p"&gt;},&lt;/span&gt;
  &lt;span class="p"&gt;},&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This will ensure, that &lt;code&gt;nvim-dap&lt;/code&gt; and &lt;code&gt;nvim-dap-python&lt;/code&gt; allows you to set breakpoints and debug inside library code. The end result should look something like this:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0fsn3ydbwkqabrvrryr8.webp" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0fsn3ydbwkqabrvrryr8.webp" alt=" " width="800" height="238"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Fixing possible &lt;code&gt;debugpy&lt;/code&gt; issues
&lt;/h2&gt;

&lt;p&gt;Ensure, that you're disabling alias for &lt;code&gt;python&lt;/code&gt; and &lt;code&gt;python3&lt;/code&gt; under your Windows settings!&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhyuezfqtyna70uuvb5nb.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhyuezfqtyna70uuvb5nb.png" alt=" " width="800" height="320"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;You might require to install &lt;code&gt;debugpy&lt;/code&gt; with Mason again. You can do this with the &lt;code&gt;:MasonInstall debugpy@1.8.12&lt;/code&gt; command&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8l57qntybeyv6fq1kgth.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8l57qntybeyv6fq1kgth.png" alt=" " width="722" height="150"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  Creating your first python project
&lt;/h2&gt;

&lt;p&gt;We'll use &lt;code&gt;uv&lt;/code&gt; to generate a Python project and create a virtual environment. Also add &lt;code&gt;pytest&lt;/code&gt; package to verify if testing and debugging works well.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;mkdir&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;python-sandbox&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;cd&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;python-sandbox&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;python&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-m&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;venv&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;venv&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;venv&lt;/span&gt;&lt;span class="nx"&gt;\Scripts\activate&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Install &lt;code&gt;pytest&lt;/code&gt; executables for testing under your local project&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;pip&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;install&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;pytest&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Make sure you have your local project in the &lt;code&gt;PYTHONPATH&lt;/code&gt; on PowerShell. You can start LazyVim now within your project.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$&lt;/span&gt;&lt;span class="nn"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="nv"&gt;PYTHONPATH&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$pwd&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;nvim&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h1&gt;
  
  
  Checking if key features are working
&lt;/h1&gt;

&lt;h3&gt;
  
  
  Testing
&lt;/h3&gt;

&lt;p&gt;You need to verify if your &lt;code&gt;Neotest&lt;/code&gt; is interacting properly with &lt;code&gt;neotest-python&lt;/code&gt;. &lt;/p&gt;

&lt;p&gt;Create a simple &lt;code&gt;pytest&lt;/code&gt; test-case and use &lt;code&gt;&amp;lt;leader&amp;gt;ts&lt;/code&gt; for showing up all your test functions implemented under the project. Use &lt;code&gt;r&lt;/code&gt; to run one of your tests to ensure, that things are wired together properly.&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fimvfywh5ixwvvbf7b5z6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fimvfywh5ixwvvbf7b5z6.png" alt=" " width="800" height="480"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Debugging
&lt;/h3&gt;

&lt;p&gt;Final thing to verify if &lt;code&gt;nvim-dap&lt;/code&gt; is interacting with &lt;code&gt;nvim-dap-python&lt;/code&gt; correctly. Put a breakpoint in your code, by using &lt;code&gt;&amp;lt;leader&amp;gt;db&lt;/code&gt; on a line. Next, start a test after showing up all the test functions with pressing &lt;code&gt;d&lt;/code&gt; on the test case's name.&lt;/p&gt;

&lt;h3&gt;
  
  
  Refactoring
&lt;/h3&gt;

&lt;p&gt;Stop on a function and try hitting &lt;code&gt;&amp;lt;leader&amp;gt;rs&lt;/code&gt; for showing the refactoring menu. You should be able to do simple things, like extracting a new function under selection by pressing &lt;code&gt;f&lt;/code&gt;. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9vobqras54fkdavge4gf.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9vobqras54fkdavge4gf.png" alt=" " width="800" height="424"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fn9fpzktj7bjfltps3ve9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fn9fpzktj7bjfltps3ve9.png" alt=" " width="800" height="404"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Final thoughts
&lt;/h1&gt;

&lt;h2&gt;
  
  
  Limited functionality under Windows
&lt;/h2&gt;

&lt;p&gt;I found out, that testing and debugging has several broken features if you run them from Windows natively. I haven't looked at the root cause, but one of the possible issues are inside &lt;code&gt;nvim-dap-python&lt;/code&gt; and &lt;code&gt;neotest-python&lt;/code&gt; libraries providing debugging and testing functionality. These extension libraries have to make distinction between Windows and Linux runtimes as binaries and virtual environments follow a different convention (e.g. &lt;code&gt;venv/bin/python&lt;/code&gt; VS &lt;code&gt;venv/Scripts/pythonw&lt;/code&gt;). These "conditions" and special cases are often getting broken and patched afterwards. I suggest to install WSL first and then &lt;code&gt;neovim&lt;/code&gt; on the top of that. I covered this approach in &lt;a href="https://dev.to/gitaroktato/configuring-lazyvim-and-python-on-windows-with-wsl-2fpd"&gt;another tutorial&lt;/a&gt; previously.&lt;/p&gt;

&lt;h2&gt;
  
  
  Using &lt;code&gt;uv&lt;/code&gt; as a Python version manager
&lt;/h2&gt;

&lt;p&gt;Currently it seems like &lt;code&gt;uv&lt;/code&gt; is not supporting global python versions &lt;a href="https://github.com/astral-sh/uv/issues/6265" rel="noopener noreferrer"&gt;you can see from this GitHub ticket&lt;/a&gt;. If you really like the speed and performance of &lt;code&gt;uv&lt;/code&gt; you can try to combine the best of both worlds: Using &lt;code&gt;pyenv&lt;/code&gt; for managing global Python versions and using &lt;code&gt;uv&lt;/code&gt; for managing your project-specific dependencies.&lt;/p&gt;

</description>
      <category>programming</category>
      <category>vim</category>
      <category>neovim</category>
      <category>tutorial</category>
    </item>
  </channel>
</rss>
