Home / Companies / Mergify / Blog / March 2026

March 2026 Summaries

7 posts from Mergify

Filter
Month: Year:
Post Summaries Back to Blog
GitHub webhooks can sometimes deliver payloads with stale data, leading to issues such as the unexpected ejection of pull requests from merge queues, as experienced by a team that traced the problem to out-of-order webhook delivery. The incident involved a structurally valid webhook payload with an empty labels array, despite the pull request having all necessary labels, illustrating how out-of-order delivery and incomplete payloads can corrupt database states when webhooks are treated as the authoritative source. The team identified that the webhook's action field should be used to determine which fields to trust, rather than assuming every field in every event is both authoritative and current. To address this, they implemented an action-aware update mechanism, ensuring that labels are only overwritten when the webhook action pertains to label changes, thus preserving existing labels in the database. This targeted fix, which was integrated into the model layer for broader applicability, underscores the importance of recognizing patterns of incomplete payloads and designing resilience into webhook processing systems.
Mar 27, 2026 1,367 words in the original blog post.
Mehdi Abaakouk's article discusses the pitfalls of using floating versions like ":latest," "^," and "~" in software development, highlighting how these seemingly convenient choices lead to broken builds, hidden regressions, and security risks. These floating versions result in non-reproducible builds by relying on mutable upstream code, which can change unexpectedly, causing failures in CI pipelines and production environments. The author emphasizes the security vulnerabilities posed by unpinned dependencies, illustrated by incidents such as the SolarWinds breach and a phishing attack in September 2025 that compromised popular npm packages to inject malware. To mitigate these risks, the article advises pinning dependencies to exact versions using GitHub Actions, Docker images, and lockfiles, and utilizing tools like Dependabot and Renovate to automate safe updates. By controlling updates and avoiding floating versions, developers can ensure reliable, secure, and reproducible software builds, reducing the risks associated with trusting mutable code from external sources.
Mar 25, 2026 1,072 words in the original blog post.
Python's asynchronous programming model is often misunderstood, especially by engineers familiar with JavaScript or C#, due to its unique handling of coroutines and tasks. Unlike these languages where awaiting an async function automatically yields control to the event loop, in Python, awaiting a coroutine does not necessarily introduce concurrency. Instead, concurrency is created only when tasks are explicitly defined using `asyncio.create_task()`. This distinction is crucial for understanding when locking is necessary, as locking should only be considered at actual suspension points where tasks might interleave, not merely at the presence of async functions. Python's design, which evolved from generator-based control flow rather than promises or green threads, provides explicit boundaries between structured control and concurrency. This leads to a more fine-grained control over when and where concurrency occurs, but also to confusion among developers accustomed to other paradigms. Understanding this difference allows for more accurate code reviews and efficient asynchronous code by focusing on true suspension points rather than assuming all async functions are automatic tasks.
Mar 25, 2026 1,302 words in the original blog post.
Fabien Martinet's article explores the intricacies of PostgreSQL's cost-based optimizer and its decision-making process, particularly why it sometimes opts for sequential scans over index scans in large tables. At Mergify, where tables often contain millions of rows, the organization experienced cases where PostgreSQL ignored indexes, resulting in increased API latencies. By understanding how the planner evaluates execution plans and the influence of factors like stale statistics, weak correlation, and cost model mismatches, they were able to optimize queries effectively. They found that using SQLAlchemy and techniques such as ORDER BY clauses, adjusting cost constants, and ensuring frequent statistics refreshes could significantly enhance query performance. The article emphasizes the importance of treating PostgreSQL's planner as a partner in query optimization, advocating for a strategy of conversational optimization that involves analyzing and responding to the planner's cost outputs to achieve consistent high performance.
Mar 25, 2026 1,360 words in the original blog post.
AI can significantly enhance code reviews by providing the missing context that human reviewers often overlook, thus making both human and AI reviews more effective. The author describes an experiment where AI-generated comments by Claude added necessary intent explanations to code, which GitHub Copilot then used to make smarter review suggestions. This interaction between AI tools demonstrates that reviews often fail due to a lack of documented intent rather than problems with the code itself. The author argues that AI should be used to document code intent, as this practice can improve the quality of both human and AI feedback, creating a more informative and effective review process. While concerns about AI-generated comments potentially leading to inaccuracies exist, the benefits of having some context—albeit imperfect—outweigh the drawbacks, as it prompts deeper investigation and clarification. Ultimately, the author advocates for AI-driven documentation to become as standard as automated testing, ensuring that every code review is well-informed and comprehensive.
Mar 25, 2026 793 words in the original blog post.
In the blog post, Alexandre Gaubert discusses the importance of using the "import type" feature in TypeScript to optimize and clarify JavaScript build processes. Although TypeScript is crucial for modern JavaScript applications, it doesn't execute code, leading to potential confusion during the build process when bundlers mistakenly incorporate type information as if it were executable code. The introduction of the "verbatimModuleSyntax" compiler option in TypeScript 5.0 requires developers to explicitly distinguish between type-only imports and runtime code, eliminating unnecessary "ghost imports" and creating cleaner, more efficient, and accurate builds. This change aligns the mental model of code with its actual execution, ensuring that imports reflect true runtime dependencies, reducing build times, and preventing integration errors. Gaubert emphasizes the importance of adopting this practice, as it represents a shift towards more explicit and reliable coding standards in the TypeScript ecosystem and is encouraged by frameworks like Next.js and Vite.
Mar 25, 2026 1,455 words in the original blog post.
Software engineering is undergoing a transformation due to advancements in AI, which have democratized access to what was once an exclusive, skill-intensive domain. The integration of AI tools in coding processes has resulted in mixed outcomes, such as increased speed and efficiency in code production, but also a rise in errors, vulnerabilities, and false perceptions of productivity. AI's ability to write code without human cognitive constraints raises questions about the future design of software, where behavior specifications might replace source code. This shift is challenging the traditional apprenticeship model and entry-level opportunities in tech, potentially reducing the development of future senior engineers. The skills now required in software engineering are increasingly about judgment, strategic understanding, and knowing when to distrust AI-generated solutions, rather than mere syntactic expertise. This evolution points to a future where human involvement focuses on deciding what is important to build, emphasizing quality and understanding user needs beyond mere technical implementation.
Mar 06, 2026 1,375 words in the original blog post.