<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div>Just to chime in in the middle: There is no known solution to the so-called "DLL hell" problem. Libraries interact badly because of their interactions, not because one or the other is "bad." Even with the best of intentions, a library author cannot predict what changes will break existing clients and what changes won't, because that author doesn't know about all possible interactions. When APIs change, telling clients that they are now incompatible may be a lie, because they may not depend on the specific change. (For example, is the addition of a keyword argument an incompatible change or not? It may, or it may not be...)</div><div><br></div><div>You are basically trying to solve the halting problem for a program where you don't know significant parts of the program. ;)</div><div><br></div><div>There is a field of research about component-oriented programming where this was a hot topic for quite some time, and nothing ever came out of it. The only practical working solution was that of Microsoft COM, where you need to change a GUID when APIs change, and since it's a black box model, that covers a lot of ground. Common Lisp libraries are definitely not black box, so even this solution will probably not work that well. (Changing the name of the library or the system definition, as Vsevolod suggests, would be similar.)</div><div><br></div><div>If you want to give control to developers, you could provide a way that depends-on specifications are list designators, with some form of declarative way of precisely specifying which versions are compatible and which aren't. (Then you could describe situations like, compatible with everything up to and including 0.9.x, and everything above 1.0.0, but excluding 1.0.0 - a situation that actually occurred when Closer to MOP was incompatible with SBCL 1.0.0 for a brief moment in history... ;)</div><div><br></div><div>Pascal<br><br>Sent from my iPad</div><div><br>On 20 Nov 2013, at 14:34, Vsevolod Dyomkin <<a href="mailto:vseloved@gmail.com">vseloved@gmail.com</a>> wrote:<br><br></div><blockquote type="cite"><div><div dir="ltr">I think, you're both right. :)<div><br><div class="gmail_extra">I have a similar experience of migrating a large Java application through changes of versions of Jetty from 6th to 9th, and it was much less painful when the namespaces were changed (between v. 6 and 7 if I'm not mistaken) for the points mentioned by Anton. So I think, it indeed makes sense to create, say, hunchentoot2 if there's going to be again a serious incompatible API change, like the transfer from 0.X to 1.X. (But a transfer from 0.X to 1.X is an exception here, because it is assumed that until v.1 the software is not stable).</div>

<div class="gmail_extra"><br></div><div class="gmail_extra">At the same time, if you make a small "local" API change, it often doesn't justify creating a new package & system, because there will be more total inconvenience for those who aren't affected (the majority) to migrate to the new version than for those who are affected to change their code.</div>

<div class="gmail_extra"><br></div><div class="gmail_extra">So it all just boils down to common senses, some level of discipline and the amount of change some system really needs to go through intrinsically. My guess is that for the vast majority of libraries such dramatic version transitions may happen once in several years, and it totally makes sense for me to do a new namespace/system for that.</div>

<div class="gmail_extra"><br></div><div class="gmail_extra">Best regards,</div><div class="gmail_extra"><br></div><div class="gmail_extra"><div><div dir="ltr">---<br><div>Vsevolod Dyomkin<br></div><div><div>+38-096-111-41-56</div>

<div>skype, twitter: vseloved</div></div></div></div> <br><br><div class="gmail_quote">On Wed, Nov 20, 2013 at 2:50 PM, Anton Vodonosov <span dir="ltr"><<a href="mailto:avodonosov@yandex.ru" target="_blank">avodonosov@yandex.ru</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">19.11.2013, 23:41, "Robert P. Goldman" <<a href="mailto:rpgoldman@sift.info">rpgoldman@sift.info</a>>:<br>


> it's too radical<br>
It's not radical, actually my proposal is very similar to yours<br>
<div class="im"><br>
> It's like having a purely functional programming language<br>
</div>Yes, I see this as an FP analogy too and expect that avoiding<br>
mutations and destructive changes will simplify life<br>
for developers.<br>
<br>
> with no garbage-collection!<br>
Why without garbage-collection? We are not leaking any resources.<br>
<div class="im"><br>
> We'd be left with heaps of unmaintained and unmaintainable<br>
> versions of basic-lib floating around in the worse case.<br>
<br>
</div>The amount of library versions does not change in the approach<br>
I propose. But versions with different APIs are have different names.<br>
<br>
And we deal only with versions we use, and can forget about any<br>
other versions.<br>
<div class="im"><br>
> Also, the two different libraries won't live happily in the same lisp<br>
> image, unless they change package<br>
<br>
</div>Wait, I do propose to change package<br>
<br>
> at every release<br>
<br>
at every API incompatible change (in other words, for every new API).<br>
<div class="im"><br>
> This approach seems like it will be such a monumental pain for the<br>
> library maintainers,<br>
<br>
</div>What pain do you mean? It's a zero cost solution. It requires no<br>
additional efforts from library maintainer, and even no special<br>
support from ASDF and other tools.<br>
<div class="im"><br>
> and anyone who wishes to upgrade his/her client program<br>
> from basic-lib to basic-lib2<br>
<br>
</div>The client job remains the same: if he wants to migrate to<br>
the new API he rewrites parts of his code using new functions.<br>
Nothing above that.<br>
<br>
Moreover, as client can have access to both APIs simultaneously,<br>
he can sometimes migrate partially: leave his old tested code<br>
as is (using basic-lib), but in the places where he needs<br>
new functionality he calls basic-lib2.<br>
So, client can benefit from new features without investing<br>
efforts into rewriting and retesting code.<br>
<div class="im"><br>
> I'd argue that having two versions of the same library *in the same<br>
> image* is too demanding a target.<br>
<br>
</div>It's not a target. The target is to not break clients.<br>
It's rather a tool to achieve this target, or a pleasant side-product<br>
of a cheap decision to name different things differently.<br>
<br>
Please think about this approach a little more.<br>
IMHO this approach is convenient and I would recommend<br>
it as the first thing to consider to anyone who is going<br>
to change API of a public library.<br>
<br>
Am I missing anything?<br>
<br>
Best regards,<br>
- Anton<br>
<br>
</blockquote></div><br></div></div></div>
</div></blockquote></body></html>