Tariff: A Python package that imposes tariffs on Python imports

221 points by khaledh 2 months ago | 29 comments
  • cosmicgadget 2 months ago
    I am going to be so much more productive now that I'm incentivized to code everything from scratch.
    • graemep 2 months ago
      I was hoping this would be a way of penalising developers who add ridiculous numbers of dependencies.
      • snvzz 2 months ago
        Or automatically funding projects depended on.
      • Lvl999Noob 2 months ago
        Feature request! Could this automatically figure out which country the package is from, then impose the at-that-time current tariff? And maybe work out whether the dev is in USA or outside.

        A best effort is fine! (Actually, mid effort is probably better; more true to the source)

        • elashri 2 months ago
          There should be a method to impose base tarrifs of 10% by default on all packages. Even if you are not importing non-existent packages from the penguin Islands.
          • jogu 2 months ago
            The tariff definition is just a dict so it's pretty straightforward to pass a dict that has a default value instead.
          • 3eb7988a1663 2 months ago
            The issue tracker + pull requests are also worth browsing: https://github.com/hxu296/tariff/issues
            • adamquek 2 months ago
              Oh! Thanks for sharing. #4 is a winner!
              • skylurk 2 months ago
                > C++, what a disrespectful language! Nobody can be faster than Python, NOBODY! We should raise the tariff charged to C++ to 145x.
            • JodieBenitez 2 months ago
              I don't have a horse in the white house race. I'm not even american, so my voice don't count here. But I wish developers would refrain from using the languages tooling to voice political opinions. At least this package I can ignore... but the last time I used npm my terminal looked like both a blend of a protest march and a craigslist page, completely drowning the relevant informations.
              • 4ndrewl 2 months ago
                OTOH you're fortunate enough not to have to worry about US/world politics _and_ all these people have written a bunch of code for you for free. So there's that...
                • JodieBenitez 2 months ago
                  Yeah, sure. OTOH if this forum never had any criticism of free stuff we could probably host it on a raspberry pi.
                • bccdee 2 months ago
                  The point of a protest march is that it takes place in infrastructure that people need to use for other stuff & that it's hard to ignore. It's not just the expression of a political opinion, it's a form of activism—a way to push for change by making it uncomfortable for things to remain as they are. It's meant to be annoying.
                  • edent 2 months ago
                    I'm pretty glad Alan Turing expressed his political opinions in code.
                    • sabslikesobs 2 months ago
                      Yeah. I feel there's a kind of eternal serenity to be found in truly apolitical works. For everyone to put their connection to Today aside and share in something timeless---that really feels like genuine connection to others.
                      • exe34 2 months ago
                        I feel it's dehumanising to expect people to provide free work and hide their lived struggles. There are trans people contributing top notch code to the community - I don't want them to feel like they have to hide their existence and the ongoing persecution of their kind and produce apolitical code just because it makes some people uncomfortable to see somebody else suffer.
                        • Peritract 2 months ago
                          > For everyone to put their connection to Today aside and share in something timeless

                          This is a political position.

                          • philipov 2 months ago
                            Yes, the purest form of privilege is the option to not engage with politics.
                        • 12_throw_away 2 months ago
                          wow, sounds awful, you should probably ask for your money back
                          • paulddraper 2 months ago
                            You can disable that stuff. I do.
                          • decremental 2 months ago
                            [dead]
                          • Imustaskforhelp 2 months ago
                            oh boy I was thinking of doing something like this for the lolz but I genuinely didn't knew what it meant to put tariff in programming.

                            The author however has it figured out.

                            What an amazing job to create something so mematic I think. A perfect blend of politics and programming.

                            • hughdbrown 2 months ago
                              Because those packages are cheating us.
                              • norskeld 2 months ago
                                roll-safe.jpg

                                  tariff.set({
                                    "numpy": -100
                                  })
                                • akkartik 2 months ago
                                  What is #mipa?
                                • moktonar 2 months ago
                                  Well.. this might not be as silly as it seems..
                                  • touristtam 2 months ago
                                    I feel I need this for node....