“Sharing GPL Code” sounds like such a loaded title because the topic is forever hot. But hang with me because the purpose of this post has nothing to do with actually arguing for or against the GPL or code around it.

I know the simple answer is that all GPL code, by very nature of its license, it’s available for sharing, but there’s another aspect that plays into this I want to discuss.

Sharing GPL Code

Sharing GPL Code can be more about collaborating on code, right?

 

And that’s this:

What is the ethics of sharing the code for a project that you’ve built for someone else even if it maintains the GPL?

For the most part, I think it’s fine. But when you’re running a business and you’re building solutions for clients, there’s a little more to it.

At least, that’s my experience.

Sharing GPL Code

Again, this is not a post to argue for or against the GPL. Obviously, I don’t have a problem with it because I continue to work in an industry that has built itself upon it.

Secondly, I don’t get into many of the debates about it because:

  • I’ve never run into a problem with it regarding the law.
  • I agree with the four freedoms.
  • I try to share as much code as I can through various blogs, articles, and projects.
  • I want to respect my clients as much as I want to educate those who want to get into development.

With that said, I thought I’d share some of my thoughts as it relates to working with clients, educating others, and sharing GPL code.

Sharing Code

I don’t mind sharing code on my website that may be part of another project because, after all, it’s under the GPL, right?

But that doesn’t necessarily give me the license to undermine my client’s wishes, does it? That is, if s/he would rather me not share the code publicly, does that mean I shouldn’t?

I find this to be an ethical issue, and ultimately, I think this depends on where yours lie.

I try not to share the code that I’ve written for my clients exactly as I’ve written it. Instead, I will try to take the take the code, generalize class names, function names, variable names, and so on, and then share it from there.

The core algorithm will be the same, but the overall picture won’t be as complete.

Client Respect

This respects, what I believe, to be both the license of the software in question and the requests of the client. In all of my years of blogging and working on projects like this, I’ve never had a problem with this approach.

Not once.

If you’re on the fence as to whether or not you should share code that you’ve written for a client, don’t merely justify your sharing it because it’s GPL and don’t neglect talking to your client about what you’d like to share.

After all, the gist of what you want to share is going to be something you’ve learned or that you want to help others learn, right?

Anyway, at least grant your client the respect of asking if they care. If they do, explain to them the nature of open source and the license under which the software falls, and then offer them an alternative (such as generalizing aspects of the code but not the core algorithm).

The Business Cost

Most of the people who choose WordPress understand the nature of open source. That is, at least to a degree, because they selected WordPress as their solution because of its price tag.

If they still aren’t a fan of it, then it’s really up to you. I err on the side of respecting the client as I’d value my relationship with them over the relationship with a license.

This doesn’t mean I’m trying to keep code private or anything. It’s that I’m attempting to be a respectable person with whom to work

There’s More

When it comes to the issue of licensing, ethics, and the like, there is plenty to discuss. I don’t know if this is going to generate a lot of comments or not, but I don’t want to turn this into a discussion about the legalities of the GPL.

The point of this post is balancing the freedoms granted by the GPL, the respect we should grant those with whom we work, and the ethics and fall between the two points.

Category:
Articles
Tags:
,

Join the conversation! 19 Comments

  1. I couldn’t agree more with you Tom. In have also written some of my posts upon some code use in a project. Of course, under different names and even purposes but the algorithm is the same.

    All that was done so people can learn more, see how something can be done or even just to have something to look into if they are stuck on something similar. If I had to spend few hours to figure something out, I want others to know it so they can focus on other stuff. Maybe they make something after that from which I can learn.

    But also I could understand if a client doesn’t want me to share it because of their fear of losing jobs or money. So if the sharing does not make others feel afraid, miserable or something else I encourage everyone to share their code and knowledge.

    • I couldn’t agree more with you Tom. In have also written some of my posts upon some code use in a project. Of course, under different names and even purposes but the algorithm is the same.

      Yeah — that’s where libraries definitely come in handy. In those cases, I’m not sure how other licenses come into play (as it was never a problem in the closed-source software I used to write) but having that freedom is nice under open source.

      All that was done so people can learn more, see how something can be done or even just to have something to look into if they are stuck on something similar. If I had to spend few hours to figure something out, I want others to know it so they can focus on other stuff. Maybe they make something after that from which I can learn.

      For sure! One of the nicest things about open source is not just the collaborative nature of it, but how other people can learn from the work of others (and built on top of it or borrow ideas from it).

      But also I could understand if a client doesn’t want me to share it because of their fear of losing jobs or money. So if the sharing does not make others feel afraid, miserable or something else I encourage everyone to share their code and knowledge.

      Yeah, I definitely understand it. I gotta say that I err on the side with darrinb’s comment where he says:

      The irony of the benefits they’ve received from the open source community over the years while also preventing me from giving back is totally lost on them!

      I don’t think it could be summed up better than that.

  2. I actually have a client for whom I’ve done a lot of work over the years and have built some really cool projects for. At times, they’ve stretched the limits of my WordPress knowledge which resulted in learning new and creative ways of building things. Unfortunately I was also required to sign and NDA with this client which carried over to all written scripts.

    I’ve tried for years to convince them to allow me to release the code I’ve written for them–stripping identifying information first–to no avail. And while I have a really great relationship with the project manager I work with, but he’s part of a larger agency, so his hands are tied. They’ve even prevented me from listing them, or their client projects, on my portfolio site.

    The irony of the benefits they’ve received from the open source community over the years while also preventing me from giving back is totally lost on them!

    • At times, they’ve stretched the limits of my WordPress knowledge which resulted in learning new and creative ways of building things

      Don’t you love those projects? No sarcasm here, either. I love it when we get challenged with stuff like that. That’s the stuff that just levels you up as a programmer.

      And while I have a really great relationship with the project manager I work with, but he’s part of a larger agency, so his hands are tied. They’ve even prevented me from listing them, or their client projects, on my portfolio site.

      Totally understand that kind of relationship. Currently, I don’t have any of them (thankfully), but at least the project manager understands it. It just sucks his hands are tied.

      As far as the agency is concerned, are they more afraid of having some type of IP “stolen” or something like that? I ask just out of genuine curiosity. I generally try not to assume anything. I’m sure they have their reasons (though it is odd given the platform they’ve chosen :).

      The irony of the benefits they’ve received from the open source community over the years while also preventing me from giving back is totally lost on them!

      I love this.

  3. Great article touching on a pertinent topic, which to me is: What is the inheritance component of GPL work?

    I think the time has come for wordpress to offer 2 different licenses, a GPL for open, non-profit work and personal use, and a commercial license with tiers of support for “for-profit” implementations. That way, if someone wants to sign a NDA etc., they pay for the “silence”…

    My humble 2 cents..

    • Great article touching on a pertinent topic, which to me is: What is the inheritance component of GPL work?

      This has been discussed a lot within the WordPress economy. I try not to get into the debates so I’ll offer this with the disclaimer that I’m not looking to get into a back and forth about it, though.

      The general consensus is that anything built on top of WordPress is a derivative work of WordPress because it has to communicate or “pass thru” WordPress (or perhaps be “processed” by WordPress), therefore all work should be GPL.

      I think the time has come for wordpress to offer 2 different licenses, a GPL for open, non-profit work and personal use, and a commercial license with tiers of support for “for-profit” implementations. That way, if someone wants to sign a NDA etc., they pay for the “silence”…

      I wouldn’t hold your breath waiting for this to happen. My guess is WordPress is going to be GPL and purely that forever.

      My humble 2 cents..

      And it’s much appreciated :).

      • Thanks for the reply Tom.

        This dilemma is prevalent in most commercial implementations from GPL roots. How can you claim ‘proprietary’ from ‘common base’, unless you have done everything ground up. Which of course would null and void most of the NDAs. A real Catch 22 here eh? Especially the way i see it.

        Okay Okay, i shall shut up now :)

        • Thanks for the reply Tom.

          And thanks for the comment! I’m enjoying talking about all of this :).

          This dilemma is prevalent in most commercial implementations from GPL roots. How can you claim ‘proprietary’ from ‘common base’, unless you have done everything ground up. Which of course would null and void most of the NDAs. A real Catch 22 here eh? Especially the way i see it.

          It’s absolutely a catch-22 when you’re dealing with a project in this way. It’s more fun to think about and talk about than to actually deal with ;).

          As far as NDAs are concerned, I think (or I guess, is probably a better phrase!) it would depend on the nature of the NDA. Could the contract just prevent disclosure up until the point of release? Sure. Could it prevent disclosure after release? Sure (though that seems odd to me).

          I guess it just depends on how “far” the agreement would attempt to reach. But I’ve not had to deal with many of these in my line of work. A few. But not many.

          The rest of this could almost be a secondary post, but here’s how I see it: What if you have a base that’s closed source but you release a utility built on top of said base licensed under the GPL?

          In that case, the utility would be fine to release — easy, even. We see these types of programs more and more now (probably now more so than ever).

          But if the inverse is the case, that is, you have a base that’s GPL, must you release the utility under GPL?

          From my understanding, that’s the generally accepted practice; however, I’m sure there’s plenty of room for legal interpretation here and a lawyer I am not :).

          On top of that, I only work in a sliver of the open source community.

          So, personally speaking, when it comes to these type of situations, I stick with the GPL and make sure that clients are aware of what license the work will fall under.

          This doesn’t mean I’ll release it “just because I can” because I see that as an integrity issue (which I hope the posts highlights enough), but it means that it’s not something that can be considered proprietary (though some people try to make their work both open source and proprietary at the same time).

          For the most part, I think we’re on the same page, but tossing the ideas back and forth is fun. I know discussions regarding licensing like this can also go on for a long time (as I’ve witnessed it on other blogs :) with no clear end and that’s okay with me.

          I’m interested more in seeing other people’s perspectives and gaining food for thought than anything else.

  4. What would you say if I said its a bit like being an arms dealer. You know what they are going to do with the weapons, but you close your eyes to it. Past history and pointed discussion have clearly identified what they are up to, and of that there is no doubt. In other words, they are going to steal from the open source community by ignoring the GPL and you are going to help them by supplying the weapons. Who do you think is more guilty of breaking the license terms and conditions; you or them?

    • What would you say if I said its a bit like being an arms dealer. You know what they are going to do with the weapons, but you close your eyes to it. Past history and pointed discussion have clearly identified what they are up to, and of that there is no doubt.

      I’m probably misunderstanding your comment, but this analogy seems to be a bit excessive.

      That is, I don’t think people are looking to release code for the sake of others to do unethical things. People release that code to contribute back to the economy and to educate others.

      What a person does with that code is another issue, though. Some will learn from it, some will copy it. Such is the nature of open source.

      In other words, they are going to steal from the open source community by ignoring the GPL and you are going to help them by supplying the weapons.

      They aren’t stealing something that’s made available for free, though. And the freedom brings about a lot of positive.

      That’s why I think drawing an analogy to weapons is a bit extreme.

      Who do you think is more guilty of breaking the license terms and conditions; you or them?

      I know I sound dense, but I don’t know if I get this question. The terms and conditions of the license explicitly state what we are allowed to do under the GPL so can you be marked as guilty when you’re acting on the freedoms granted to you?

      If the GPL offers a number of freedoms, which it does, and you attempt to work in opposition to it, then that would be more incriminating behavior.

      • I agree, it was a tad excessive as an an analogy, but most analogies are there simply to get your attention, and the point remains.

        The tobacco industry says it’s not the cigarettes or second hand smoke that kills you, its thoughtless people smoking in crowded rooms. And the gun lobby says its not the guns that kill you, its the crazy people who point them at you.

        My point was simply that, its not always somebody else’s fault, and while you know they are breaking the terms of the GPL then you might need to ask yourself if you are entirely blameless in this scenario.

        I think you need to read the terms of the GPL a little more carefully. As well the GPL providing you with the basic freedoms, it also acknowledges copyright and places the onus on future users to honor their responsibilities under the license. One of which is to provide those enhancements to the community.

        Obviously, your clients are taking advantage of previous developers and clients who took their responsibilities a little more seriously, but shirking theirs.

  5. Nice post. I’ve heard of people having a clause in their standard contract that allows them to retain copyright and release as GPL. That is nice if you are able to do it.

    There is no requirement that GPL code be distributed, but if it is then you have to include the source. So, an NDA is legal, even if we would prefer otherwise.

    http://www.gnu.org/licenses/old-licenses/gpl-2.0-faq.en.html#GPLRequireSourcePostedPublic

    • Nice post. I’ve heard of people having a clause in their standard contract that allows them to retain copyright and release as GPL. That is nice if you are able to do it.

      Agreed! I tend to take it on a project-by-project basis. It’s not really a hill I’m willing to die on. At least I haven’t come up on a case for that yet, but I do err on the side of having the freedom to do it without damaging the relationship with the client, if that makes sense.

      There is no requirement that GPL code be distributed, but if it is then you have to include the source. So, an NDA is legal, even if we would prefer otherwise.

      At the end of the day, I want to say that I’d choose people over a license, you know? If a person doesn’t want source code distributed then I’ll say that “I won’t publicly distribute it but I’m not going to obfuscate it or anything like that.”

      • Tom, what about the situation where you aggregate custom code that you developed over the years, and release a plugin or theme for $$ and there are similarities with a client solution.

        Im talking about how you think as a developer, and logically there could be some overlap. This may be a what-if scenario, but i’m still wondering…

        • Im talking about how you think as a developer, and logically there could be some overlap. This may be a what-if scenario, but i’m still wondering…

          This is a bit of a late reply (so sorry for that!) but to make sure I understand your statement right, you’re asking about the situation where I may release a plugin that’s an aggregation of code that I’ve released for previous clients?

          Generally speaking, I don’t think there’s a problem with it.

          Personally speaking, I haven’t done this as the problems I’m solving for clients are usually very specific to their niche. If I do opt to release something that’s inspired by a solution for a client, it’s more generalized.

          Furthermore, I always talk with clients about the potential for doing this with projects. 99% of the time, they have no problem with it.

  6. Is taking a gpl plugin, renaming it something else, but otherwise not changing any of the code legal?

    I saw that these guys http://www.gplkit.com are doing just that. Calling it their own, but hey have just renamed the plugin slightly.

    • Is taking a gpl plugin, renaming it something else, but otherwise not changing any of the code legal?

      As far as my limited understanding is concerned, yes, it’s legal. Ethical? That’s a whole other issue.

      I saw that these guys http://www.gplkit.com are doing just that. Calling it their own, but hey have just renamed the plugin slightly.

      Yeah. Things like this do more harm to a community and economy than help, but that’s content for another post or for lawyers :).

      • My understanding is that if you fork a GPL project you cannot infringe any trademarks (i.e. the renaming part) and you need to retain the copyright notice of the original author.

        There is no question that it is legal and ethical to fork a GPL project. Forking is one of the freedoms of the GPL.

        What feels scummy is to take a freely distributed plugin, fork it, and then start charging for updates etc … or forking a premium plugin after the original author built up a business. Both of those can be legal, but are not community builders.

        • I agree with you 100% but you can’t have one without the other David.

          What’s open for responsible community minded developers is also open for scumbags too.

          Fortunately there are ways other than the GPL the WordPress ecosystem uses to deal with that kind of behaviour.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.