Recently, someone did the unthinkable: they published their own version of Dive Into Python and got it listed on Amazon.com. This apparently caused a small firestorm within Apress, the exact details of which I am not privy to, but which (I am told) became a somewhat larger firestorm after the Apress executives realized they had no legal recourse, and asked my opinion on the matter. You see, the book is published under the GNU Free Documentation License, which explicitly gives anyone and everyone the right to publish it themselves. (I was about to write "gives third parties the right," until I realized that there are no third parties because there are no second parties. That's kind of the point.)
This didn't use to matter, because publishing on paper used to require a serious up-front investment in, well, paper. "Freedom of the press" was reserved for those with an actual press, and distribution costs were decidedly non-trivial. Publishing a book commercially just wasn't practical for anyone but, well, a book publisher. That's no longer the case. Copies can be purchased online, printed on demand, and drop-shipped to the customer -- up-front investment be damned. And that's for printed books; e-books are even easier.
Software had this problem first, by virtue of its non-corporeality. How many people are selling Free Software on eBay? We deride these sellers as "scammers," but in truth the only time they run afoul of the law is when they attempt to rebrand your software without acknowledgement, or when they fail to abide by some other intentionally inside-out clause of the license that you chose in the first place (e.g. selling GPL'd binaries without offering source code).
Still, there's a qualitative difference between letting people download your own work from your own site, and watching other people try to profit from it. But it is precisely this difference that strikes at the heart of the Free Software/Free Culture ethos. Part of choosing a Free license for your own work is accepting that people may use it in ways you disapprove of. There are no "field of use" restrictions, and there are no "commercial use" restrictions either. In fact, those are two of the fundamental tenets of the "Free" in Free Software. If "others profiting from my work" is something you seek to avoid, then Free Software is not for you. Opt for a Creative Commons "Non-Commercial" license, or a "personal use only" freeware license, or a traditional End User License Agreement. Free Software doesn't have "end users." That's kind of the point.
The aforementioned Apress executive told me that he did not understand why I would be willing to work with a publisher but then be happy about their competition. This is what I told him:
I enjoy working with publishers because it makes me a better writer. But I don't write for money; I write for love (or passion, or whatever you want to call it). I choose open content licenses because this is the way I want the world to work, and the only way to change the world is to change yourself first.
I don't know where that leaves you as a business. But you've made a good amount of money on the original "Dive Into Python," despite the fact that it's been available for free online for 8 years. A German translation of Dive Into Python 3 is being published this quarter by Springer/Germany [a division of Apress' parent company] almost simultaneously with the English edition -- much sooner-to-market than it would have been under a closed development process. (And an Italian translation was just released yesterday. You should snap that one up too before someone else does!) So maybe the problems you perceive are really opportunities in disguise.
So I am grateful for this anonymous soul who woke up one day and said to herself, "You know what I should do today? I should try to sell copies of that Free book that Pilgrim wrote." Grateful, because it afforded me the opportunity to remind myself why I chose a Free license in the first place. My Zen teacher once told me that, when people try to do you harm, you should thank them for giving you the opportunity to forgive them. In this case it's even simpler, because there's nothing to forgive, just explain. She's redistributing the work that I explicitly made redistributable. She's kind of the point.