You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@fory.apache.org by "pjfanning (via GitHub)" <gi...@apache.org> on 2026/10/06 10:45:48 UTC

[I] [License] LICENSE is missing Fluent Python (MIT) and a Spark-derived file; remove stale LICENSE-v8.txt [fory]

pjfanning opened a new issue, #4126:
URL: https://github.com/apache/fory/issues/4126

   ### Description
   
   While verifying the 1.7.7-rc1 source release, I found two pieces of third-party code that LICENSE doesn't list, and one leftover licence file. None of these is new in 1.7.7: both pieces of code have been in every release since 2023.
   
   #### 1. `python/pyfory/type_util.py` – `record_class_factory` comes from Fluent Python (MIT)
   
   The function has the comment `# modified from 'fluent python'`. It is derived from `record_factory` in the Fluent Python example code, which is MIT licensed:
   
   - https://github.com/fluentpython/example-code-2e/blob/master/24-class-metaprog/factories_ducktyped.py
   - (the first-edition repo `fluentpython/example-code` is also MIT)
   
   The doctest docstring is almost word for word the same (the `Dog`/`Rex`/`Bob` example), and `__init__`, `__iter__` and `__repr__` are nearly identical. Fory added `__eq__`, `__hash__`, `__reduce__` and `as_dict`.
   
   MIT requires the copyright and permission notice to be included with substantial portions. The file has neither, and LICENSE has no entry. The code was added in 445abdf61 (#458, 2023-06-08).
   
   Suggested fix:
   - Add a `fluentpython/example-code-2e` entry under "MIT licenses" in LICENSE that lists `python/pyfory/type_util.py (record_class_factory function)`.
   - Add `licenses/LICENSE-fluentpython.txt` containing the upstream MIT text and copyright line.
   - Change the source comment to name the upstream project and link to it.
   
   #### 2. `java/fory-core/src/main/java/org/apache/fory/util/ClassLoaderUtils.java` – Spark-derived classes not listed
   
   `ParentClassLoader` and `ChildFirstURLClassLoader` are marked "Derived from" Apache Spark's classes of the same names (`core/src/main/java/org/apache/spark/util/ParentClassLoader.java` and `ChildFirstURLClassLoader.java`). Spark is already under "Apache-2.0 licenses" in LICENSE, but this file isn't in its file list. The code was added in b44a97193 (#58, 2023-05-05).
   
   Suggested fix: add `java/fory-core/src/main/java/org/apache/fory/util/ClassLoaderUtils.java` to the spark entry.
   
   #### 3. `licenses/LICENSE-v8.txt` is no longer referenced
   
   This file was added for the vendored `javascript/packages/hps/src/v8-fast-api-calls.h`. That header and its LICENSE entry were removed in 980f0ede9 (#2137), but the licence text was not. Nothing in LICENSE refers to it now.
   
   Suggested fix: delete `licenses/LICENSE-v8.txt`.
   
   #### Minor: protobuf keyword list
   
   `compiler/fory_compiler/generators/cpp.py` says `CPP_KEYWORDS` is "Taken from kKeywordList defined in helpers.cc in protobuf". It's a list of C++ language keywords, which are facts rather than creative work, so I don't think it needs a LICENSE entry. Rewording the comment (for example, "C++ reserved keywords") would remove the ambiguity.
   
   ### How this was checked
   
   I scanned the unpacked `apache-fory-1.7.7-src.tar.gz` for:
   - copyright lines from anyone other than the ASF;
   - non-ASF licence text;
   - comments saying code was derived, ported, adapted, copied or taken from somewhere.
   
   I then compared the results with the files LICENSE lists. Everything else matched. This method only finds third-party code that is marked in some way.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@fory.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@fory.apache.org
For additional commands, e-mail: commits-help@fory.apache.org


Re: [I] [License] LICENSE is missing Fluent Python (MIT) and a Spark-derived file; remove stale LICENSE-v8.txt [fory]

Posted by "chaokunyang (via GitHub)" <gi...@apache.org>.
chaokunyang closed issue #4126: [License] LICENSE is missing Fluent Python (MIT) and a Spark-derived file; remove stale LICENSE-v8.txt
URL: https://github.com/apache/fory/issues/4126


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@fory.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@fory.apache.org
For additional commands, e-mail: commits-help@fory.apache.org