473,473 Members | 2,236 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Reinvent no more forever

Howdy all,

On dirtSimple.org[0], PJE wrote:

"Why is Python "blessed" with so much reinvention? Because it's
often cheaper to rewrite than to reuse. Python code is easy to
write, but hard to depend on. You pretty much have to:

1. limit yourself to platforms with a suitable packaging
system,
2. bundle all your dependencies into your distribution, or
3. make your users do all the work themselves

Ouch. No wonder rewriting looks easier."

He then goes on to talk about his own solution: PyPI, setuptools,
EasyInstall, and so on for better dependency control. He concludes:

"But for right now, I plan to start by putting my dependencies
where my mouth is. I will bundle no more forever, for I am tired
of keeping them up-to-date with their upstream maintainers. I
shall rend my monolithic packages into smaller projects, so that
people can make use of cool parts of PEAK without having to
install anything but the part they want. I will find out if this
stuff really works. From where the setuptools now stand, I will
bundle no more forever."

Fine sentiments. What does this mean for PyPI though? How should those
of us who also want to "reinvent no more forever" proceed? How do we
deal with the rampant proliferation of a zillion implementations of
some standard idiom in PyPI?

The case that led me to this quandary is simple: I'm developing an
application that could become simple, and I'm on the lookout for
pieces that might be valuable outside this application. The first one
to catch my eye is an Enum implementation.

I now have a setuptools package of my Enum implementation. Should I
submit it to PyPI?

Advantages:

- I can declare a dependency on that package for all my other
packages that need such functionality, instead of bundling it
every time.

- Others can benefit from my code, instead of yet again including an
Enum implementation (home-grown, or picked from a cookbook) by a
simple dependency declaration.

- The code hopefully gets improved and generalised and all the other
benefits that accrue to software with many users.

Disadvantages:

- Proliferation. What's the protocol when[1] someone else puts an
(incompatible, differently-specified) Enum implementation into
PyPI?

- Naming. How many ways can a package providing an Enum be named?
I'd prefer mine to be named "Enum" or "enum", but why should mine
be the one that claims that name?

- It's just a pretty simple type, with unit tests. Does this really
justify a PyPI package?

This is common to any repository of code. But the "automatic
dependency" problem means that all those packages, and many more
outside that repository, need to know how those problems are resolved.

Operating system distributors have policies (to greater or lesser
degrees of strictness) to ensure this kind of quality control. My
understanding of PyPI is that there's no such policy.

I'd love to follow the mantra PJE espouses, but if it's good for one
person it's probably good for countless others. How do we deal with
that? What actions can we take in advance to prevent problems in
future?
[0] <URL:http://dirtsimple.org/2005/07/reinvent-no-more-forever.html>

[1] Of course, someone already has. I prefer mine to theirs, hence the
question.

--
\ "I planted some bird seed. A bird came up. Now I don't know |
`\ what to feed it." -- Steven Wright |
_o__) |
Ben Finney
Nov 22 '05 #1
0 975

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Robert Stearns | last post by:
While attempting to alleviate a persistent but not consistent problem with my database operation (DB2) I coded the do...while loop around my odbc_connect. When $dbConn is false the first time, the...
1
by: Yannick Turgeon | last post by:
Hello all, I'm using SS 2000 and NT4 (and Access97 as front-end on another server) Well, probably by lack of knowledge about table locks, I don't really know where to start to present this...
0
by: Cable | last post by:
Greetings, We have a production website, and within that website we have an 'Admin' section of the website. Two separate ASP.NET/C# web applications. Recently when trying to log into the admin...
28
by: Stefano Masini | last post by:
On 8 Sep 2005 08:24:50 -0700, Fuzzyman <fuzzyman@gmail.com> wrote: > What is pythonutils ? > ===================== > ConfigObj - simple config file handling > validate - validation and type...
1
by: Amil Hanish | last post by:
I'm having an issue on IIS 6 on Windows 2003 Server. The following simple file hangs the client forever (I quite waiting after about five minutes). No error in IIS error file or IIS log file. The...
16
by: Ben Finney | last post by:
Howdy all, On dirtSimple.org, PJE wrote: "Why is Python "blessed" with so much reinvention? Because it's often cheaper to rewrite than to reuse. Python code is easy to write, but hard to...
6
by: alessandro | last post by:
Hi all, This is my framework for create TCP server listening forever on a port and supporting threads: import SocketServer port = 2222 ip = "192.168.0.4"
8
by: damod.php | last post by:
Iam a php/mysql developer. I wanna know whether staying in php and mysql forever would affect my future. Most s/w people are in either java or dotnet. Iam novice in both of them. I love php and i...
4
by: Ronald S. Cook | last post by:
We're looking to not reinvent the wheel in designing the UI for our enterprise Windows app. It's a pretty common scenarion... user clicks to view a list of customers. User clicks on a customer...
3
by: Inny | last post by:
I want To offer a login Option, two Checkboxs, 1 labeled 'normal' the other labeled 'Forever'. I want to assign the check boxes to switch between the cookie script below (normal) and An altered...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.