Pants Has Got Your Python Monorepo Covered


November 23rd, 2020

51 mins 38 secs

Your Hosts

About this Episode


In a software project writing code is just one step of the overall lifecycle. There are many repetitive steps such as linting, running tests, and packaging that need to be run for each project that you maintain. In order to reduce the overhead of these repeat tasks, and to simplify the process of integrating code across multiple systems the use of monorepos has been growing in popularity. The Pants build tool is purpose built for addressing all of the drudgery and for working with monorepos of all sizes. In this episode core maintainers Eric Arellano and Stu Hood explain how the Pants project works, the benefits of automatic dependency inference, and how you can start using it in your own projects today. They also share useful tips for how to organize your projects, and how the plugin oriented architecture adds flexibility for you to customize Pants to your specific needs.


  • Hello and welcome to Podcast.__init__, the podcast about Python and the people who make it great.
  • When you’re ready to launch your next app or want to try a project you hear about on the show, you’ll need somewhere to deploy it, so take a look at our friends over at Linode. With the launch of their managed Kubernetes platform it’s easy to get started with the next generation of deployment and scaling, powered by the battle tested Linode platform, including simple pricing, node balancers, 40Gbit networking, dedicated CPU and GPU instances, and worldwide data centers. Go to and get a $100 credit to try out a Kubernetes cluster of your own. And don’t forget to thank them for their continued support of this show!
  • Python has become the default language for working with data, whether as a data scientist, data engineer, data analyst, or machine learning engineer. Springboard has launched their School of Data to help you get a career in the field through a comprehensive set of programs that are 100% online and tailored to fit your busy schedule. With a network of expert mentors who are available to coach you during weekly 1:1 video calls, a tuition-back guarantee that means you don’t pay until you get a job, resume preparation, and interview assistance there’s no reason to wait. Springboard is offering up to 20 scholarships of $500 towards the tuition cost, exclusively to listeners of this show. Go to today to learn more and give your career a boost to the next level.
  • Feature flagging is a simple concept that enables you to ship faster, test in production, and do easy rollbacks without redeploying code. Teams using feature flags release new software with less risk, and release more often. ConfigCat is a feature flag service that lets you easily add flags to your Python code, and 9 other platforms. By adopting ConfigCat you and your manager can track and toggle your feature flags from their visual dashboard without redeploying any code or configuration, including granular targeting rules. You can roll out new features to a subset or your users for beta testing or canary deployments. With their simple API, clear documentation, and pricing that is independent of your team size you can get your first feature flags added in minutes without breaking the bank. Go to today to get 35% off any paid plan with code PYTHONPODCAST or try out their free forever plan.
  • Your host as usual is Tobias Macey and today I’m interviewing Eric Arellano and Stu Hood about Pants, a flexible build system that works well with monorepos.


  • Introductions
  • How did you get introduced to Python?
  • Can you start by describing what Pants is and how it got started?
    • What’s the story behind the name?
  • What is a monorepo and why might I want one?
    • What are the challenges caused by working with a monorepo?
    • Why are monorepos so uncommon in Python projects?
  • What is the workflow for a developer or team who is managing a project with Pants?
  • How does Pants integrate with the broader ecosystem of Python tools for dependency management and packaging (e.g. Poetry, Pip, pip-tools, Flit, Twine, Pex, Shiv, etc.)?
  • What is involved in setting up Pants for working with a new Python project?
    • What complications might developers encounter when trying to implement Pants in an existing project?
  • How is Pants itself implemented?
    • How have the design, goals, or architecture evolved since Pants was first created?
    • What are the major changes in the v2 release?
      • What was the motivation for the major overhaul of the project?
  • How do you recommend developers lay out their projects to work well with Python?
  • How can I handle code shared between different modules or packages, and reducing the third party dependencies that are built into the respective packages?
  • What are some of the most interesting, unexpected, or innovative ways that you have seen Pants used?
  • What have you found to be the most interesting, unexpected, or challenging aspects of working on Pants?
  • What are the cases where Pants is the wrong choice?
  • What do you have planned for the future of the pants project?

Keep In Touch



The intro and outro music is from Requiem for a Fish The Freak Fandango Orchestra / CC BY-SA