TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Ask HN: Why do you hate (or love!?) your language's package manager?

2 pointsby nathandalyover 2 years ago
We&#x27;re getting ready to design a package manager for Rel, the declarative relational language we&#x27;re building at RelationalAI (https:&#x2F;&#x2F;relational.ai&#x2F;). I know that building a package manager is a fraught task, and that people have very strong feelings about their package managers.<p>Why do you hate yours? What mistakes should we take care to avoid?<p>Or if you&#x27;re one of the lucky few blessed with happy package management, what is it you love about yours?

4 comments

thetwentyoneover 2 years ago
Pkg.jl has been such a breath of fresh air vs my prior experience with Python,R, VBA. Built into language, environment management, dependency pinning, SemVer enforcement at the registry level, easy to update as a package developer.
评论 #33386740 未加载
fiedziaover 2 years ago
Cargo is best there is in this domain so far. Poetry is good. I rarely use anything else.<p>Important things:<p>1. Consider what developer need and what devops need. Those are different needs. 2. Packages should be immutable. 3. Take care about what text you print. This should be to the point, no spamming. 4. Having reliable package repository is the best way to go. Getting dependencies from random git repos is a recipe for production issues, as those come and go.<p>(I do not now Rel, so maybe this is irrelevant).
iamed2over 2 years ago
It&#x27;s important to resolve changes to the package environment as a whole. Pip doesn&#x27;t really do this, and as of a few years ago didn&#x27;t even resolve multiple CLI-specified packages together, and this causes major compatibility and consistency issues.<p>Doing this correctly can be difficult to get fast, but performance does matter. Resolving Conda environments adds way too much time to CI jobs. The Pkg.jl resolver is pretty great and we never have to wait for resolution. It&#x27;s my understanding that this was a non-trivial technical problem that went through a few implementation iterations.<p>Explainability on failure to resolve is a really useful tool that becomes more difficult the more features you add. Pkg.jl has struggled with this in some cases where it hides certain version restrictions (e.g. &quot;by explicit requirement&quot; is rough when your project hasn&#x27;t set that particular requirement). Lots of people have spent lots of time trying to identify incompatibilities over the years, and we&#x27;ve had to rely on people developing arcane knowledge to interpret resolution failures.<p>Immutable, cached packages is important for avoiding spending a lot of time downloading. It&#x27;s very important to completely distinguish different versions&#x2F;configurations though, i.e. you don&#x27;t want a configuration setting that affects which code gets put at `~&#x2F;mypkg&#x2F;packages&#x2F;&lt;pkg-version-id&gt;`.<p>The package source should be reliable&#x2F;redundant. People will install packages in the course of normal work (automated updates, testing, etc.) and will need an always-on package manager. GitHub has proven not to be reliable enough.<p>At the same time, an offline mode should be available.<p>Getting installation configuration options right can be a big value add. I love cargo&#x27;s feature flag implementation, and even Python now has &quot;extras&quot;.<p>Every package manager eventually regrets not adding a &quot;yank&quot; feature.<p>Enterprise users will always eventually want to see multiple sources (private and public).<p>I appreciate when package managers consider the audience for their output and don&#x27;t output line-by-line progress meters when running in a non-interactive environment.<p>Querying the package dependency tree is really useful! Both dependants and dependencies, flat and recursive. Even better if there&#x27;s a library to do this that you can script and experiment with.
borodiover 2 years ago
SemVer is very important for me. If the language has binary dependencies the package manager should also handle them. Depending on the system for them leads to hard to debug issues. An easy way to reproduce environments is also important via a toml file or something similar.