2

I am working on a port of a codebase (Java) to another language (Python), with some modifications. The Java codebase is licensed under CC BY-NC-SA. Understandably, the Python codebase will also be CC BY-NC-SA, but what's not clear to me is whether I can write a book that goes into the implementation details and theory, and sell that for commercial purposes, assuming the Python codebase is published on Github or something like that.

1
  • Did you write the Java codebase? – user1937198 Jul 19 at 14:19
6

If your book does not contain any actual code snippets or transliterations of the code into English (i.e. code translated to sufficiently descriptive pseudo-code), but it only describes the ideas contained in the code, then your book is not a derived work in the sense of copyrights and you are not constrained in how you publish and license the book.

If the book does contain snippets of code, then it becomes a question if your use of the code in the book falls under a copyright exemption, like fair use, or not. In many countries, copyright law contains exemptions of copyright protection, allowing small portions of a copyrighted work to be copied to, for example, provide context in a critique about the work. If your code snippets fall within the criteria of such an exemption can only be definitively be determined in a court of law.

3
  • 3
    To be clear, if the book contains snippets of the translated code (which OP holds the copyright to) and not the original code, then what matters is whether OP's use of snippets the translated code would violate the copyright of the original code. The OP's book would be a transformative use of the original code, which greatly strengthens the case for a fair use defense in most jurisdictions, but it's probably still best to consult a copyright lawyer for advice. – kaya3 Jul 19 at 11:22
  • @kaya3 But as I understand the concept of the book, it would be quite likely to show some "before"/"after". The "after" would likely fall into "transformative use" and be fine. But the "before" would have to rely on "fair use" and is the really tricky (lawyer...) part. – manassehkatz-Moving 2 Codidact Jul 19 at 16:14
  • @kaya3, the OP does not have an exclusive copyright claim on the translated code. As it is a translation, the copyrights are at least shared with the authors of the original Java code. – Bart van Ingen Schenau Jul 19 at 17:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.