Comments (31)
LLVM is changing their license to a ""Apache 2.0 with LLVM Exception", where the exception is a block at the end of the license to work around issues like these.
http://llvm.org/foundation/relicensing/
http://llvm.org/foundation/relicensing/LICENSE.txt (scroll to the bottom to see the exception)
from tslib.
Hey all, after some internal discussion, we're leaning towards relicensing tslib under the Zero-Clause BSD license. 0BSD is derived from the ISC license, but specifically differs in that it does not place any requirement on the copyright notice appearing in copies of the licensed work.
- Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies.
+ Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
In the near future, we'll be putting up a PR to replace the license. We'll give the PR about 10 business days, and if there are no strong objections, we'll pull the change in and publish a new version of tslib with the less-restrictive license.
from tslib.
tslib 1.11.2 should contain the relicense.
Thanks to everyone for helping out here and being patient! 🙂
from tslib.
Hey all, just wanted to thank everyone for your patience and to give an update here.
We've managed to get the conversation rolling further and I'm generally pretty happy with the direction we're moving towards. We're looking into adding a license exception, but the specifics are in the works. When we figure that out, we'll post it here to get a gauge on whether the language feels reasonable.
from tslib.
Another update on this: as best we can tell at this point, this is not going to be fixed by the TS team -- we've attempted to reach out many times across two years and through multiple channels and still don't have a response.
Our best idea at this point is to attempt a clean room reimplementation of tslib, though we haven't seriously investigated it at this point. If you were considering doing the same, please comment on this bug to share what you end up with.
from tslib.
+1
from tslib.
+1
from tslib.
Another ping -- @DanielRosenwasser's comment is exactly what we want, but we need it in some place that lawyers will believe, because I believe GitHub comments are non-binding. ;)
from tslib.
As an update, I've reached out to our appropriate legal reps. They're not in the office at the moment so we'll need to wait on that.
from tslib.
Sorry to re-ping, just wanted to make sure you didn't forget this.
from tslib.
Please do not use "public domain", it's not a license and it makes it impossible to use such code in corporate context. Essentially, only government or very long time makes code public domain.
from tslib.
The exceptions in C++ compilers (LLVM/gcc) are actually written about that case specifically, where the compiler emits some code into the resulting binary, like TS without importHelpers
. Currently TS is silent about the legal status of the code in inserts inline, which is what the above LLVM exception is more concerned with.
The tslib issue makes this problem more apparent because it tslib does have an explicit license on it.
from tslib.
I spoke to @DanielRosenwasser in person about this at tsconf, and I now understand I had two separate issues confused.
- Code that TS inserts into the output bundle is of unclear copyright. This is the thing the LLVM exception is all about, but that is not what this particular issue is about.
- This library (tslib) that TS may add as dependency of output, and how that requires the resulting artifacts to carry the MS copyright. For this one, the best solution is to relicense this library as something that doesn't require the MS copyright on compilation output.
For #2, you can use a license like:
https://opensource.org/licenses/0BSD
For your lawyers, I know it's not the normal license you'd like to use, but this is all for a very special case and it's also not very much code.
from tslib.
@phinguyen202 as long as you specifically call out which parts are MIT vs. Apache 2.0 you should be fine, but I'd check with an attorney regarding what you're trying to achieve.
Keep in mind, if you're writing a library, you shouldn't need to bundle tslib - let your consumers do that.
from tslib.
Hmm, this definitely was not the intent; these helpers get auto-injected anyway. Babel has also done this with their helpers under an MIT license which has similar implications. Let me try to figure things out on our end.
from tslib.
Just wanted to ask if there was any progress on this.
from tslib.
Ping again!
from tslib.
Heya @DanielRosenwasser !
I would also like to include this in the dist builds of ethers, but the Apache license is incompatible.
Could we possibly get these licensed under multiple, permissive licenses (e.g. MIT, BSD, et cetera)?
Or better yet, just released into the public domain.
Or provide a way in TypeScript to override the library included with importHelpers
, so we can override "tslib" with our own implementations.
Thanks! :)
from tslib.
@ricmoo if you're bundling, couldn't you use path aliasing? But I could see that.
Also, looping back with our legal team.
from tslib.
Maybe legal team is now back from vacation and ready to take a fresh look? (Sorry again for all the annoying comments!)
from tslib.
So here's what I can state given the conversations I've had thus far.
Occasionally, the TypeScript compiler injects JavaScript code that users don’t actually write. These are helper functions to make it easier for us to make JavaScript work equivalently with respect to the input TypeScript code. We do not expect users to provide any reference to the Apache 2.0 license governing the TypeScript compiler for the JavaScript code occasionally injected into the output of the compiler. Likewise, we have no expectation that the license text in tslib needs to be retained upon redistribution.
from tslib.
Can that “expectation” be put in writing? :)
Maybe a /*! Public domain: Microsoft 2018 */
injected into the code along side it?
from tslib.
@mmotorny There are "public-domain" licenses such as the CC0 or the Unlicense which should not be problematic in corporate environments (the problems are when there is no license, because this means that the author retains the copyrights). IMHO any of these should be a good fit for the TSLib code.
from tslib.
@avonwyss I'm aware of CC0 and Unlicense, but that's not what @ricmoo was suggesting.
from tslib.
Really all I was implying is that the license be inlined, and formalized. Not simply suggested in a GitHub issue that it "should be alright to include"...
from tslib.
Any movement here? It seems like everyone agrees on the solution. Any chance of making it happen?
from tslib.
We're looking into adding a license exception,
So, the kind that, like the LLVM exception mentioned above, gets listed at https://spdx.org/licenses/exceptions-index.html, or the kind where your legal people say "yeah, you can use a more liberal license for that part of the code"?
Also, the part about the non---importHelpers
case not adding any Apache license headers got me thinking:
Why isn't tslib
just getting the helper code from the compiler, perhaps using a special flag to ask tsc
to just spit out all helpers (for a given target).
That might not really help with the legal situation, but wouldn't it simplify updates to tslib?
from tslib.
+1 - I cannot use Typescript in some open source until this is changed
from tslib.
Hi guys,
I know less about licences. I'm writing a react library using typescript and tslib. And yeah, I know I have include Ms copyright+license in the resulting product as evmar said. I'm planning to set it under MIT licence. Is that any illegal?
from tslib.
See #96 for the PR.
from tslib.
Despite the move to zero clause BSD, bundlers still retain the license because it starts with /*!
This is for legal reasons. By default comments with
@license
,@preserve
or starting with/*!
are preserved
I have opened #160 to remove the /*!
.
from tslib.
Related Issues (20)
- Use standard `exports` in `package.json` HOT 3
- __importDefault method may return an object with undefined default property HOT 2
- __assign is not a function
- Type 'boolean' is not assignable to parameter of type '(false | Observable<false>) & (true | Observable<true>) HOT 1
- CI: set minimal permissions for GitHub Workflows HOT 1
- TypeError: (0 , tslib__WEBPACK_IMPORTED_MODULE_0__.__rest) is not a function HOT 1
- Should tslib be in peerDependencies or just dependencies when building a library? HOT 3
- [2.5.1][Regression] imported helper named '__decorate' does not exist in 'tslib' HOT 6
- ERROR in bundle from UglifyJs Unexpected token: punc (,) HOT 8
- Regression in [email protected] when using private fields i.c.m. with ESM HOT 3
- Cannot find module '...node_modules/tslib/modules/index.js' imported from chunks/app/server.mjs HOT 2
- Generate SLSA Build L3 provenance HOT 4
- tslib >=2.5.1 regression - increases bundle size caused by noop `Object.create;` statements
- calls to tslib __setFunctionName fail on Cobalt 9 HOT 5
- Suggest an dependabot to keep GitHub Actions updated HOT 1
- Regression failure upgrading from 2.5.0 to 2.5.1+, webpack fails to transpile new export statement for ES5. HOT 1
- Performance improvement HOT 2
- The spread (...) syntax allows an string,but __spreadArray does not support string. HOT 2
- Why do I get compilation results of tslib imports containing native absolute path? HOT 2
- this appears to be a dev-dependency, but the instructions point it to be a dependency HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tslib.