Skip to content

fix: replace LICENSE files with exact official Apache 2.0 text#356

Merged
ajitpratap0 merged 1 commit intomainfrom
fix/license-apache-2.0
Mar 8, 2026
Merged

fix: replace LICENSE files with exact official Apache 2.0 text#356
ajitpratap0 merged 1 commit intomainfrom
fix/license-apache-2.0

Conversation

@ajitpratap0
Copy link
Copy Markdown
Owner

Problem

pkg.go.dev shows License: UNKNOWN because the LICENSE file had minor deviations from the official Apache 2.0 template text. The license detector does exact matching and couldn't recognize it.

Differences found

  • the Licensor vs Licensor (2 occurrences)
  • excluding any notices vs excluding those notices
  • Modified appendix section (shortened boilerplate text)
  • Indentation differences in the copyright notice template

Fix

Both LICENSE and vscode-extension/LICENSE replaced with the verbatim text from https://www.apache.org/licenses/LICENSE-2.0.txt

After this merges and pkg.go.dev re-indexes, the license should show as Apache-2.0

pkg.go.dev license detection requires an exact match against the
official Apache 2.0 template. The previous LICENSE files had minor
textual deviations (e.g. 'the Licensor' vs 'Licensor', modified
appendix section) that prevented detection.

Both root LICENSE and vscode-extension/LICENSE now use the verbatim
text from https://www.apache.org/licenses/LICENSE-2.0.txt
@claude
Copy link
Copy Markdown

claude bot commented Mar 8, 2026

Claude finished @ajitpratap0's task —— View job


PR Review: License Apache 2.0 Fix ✅

Todo List:

  • Read and analyze both LICENSE files
  • Verify Apache 2.0 compliance and formatting
  • Check for security and legal concerns
  • Review consistency between files
  • Provide comprehensive feedback

Review Summary

This PR successfully addresses the license detection issue by replacing both LICENSE files with the exact official Apache 2.0 text. The changes are correct and appropriate.

Code Quality & Best Practices

  • Excellent: Both LICENSE files (LICENSE:1-203 and vscode-extension/LICENSE:1-203) now contain the verbatim Apache 2.0 text from the official source
  • Consistent: Both files are identical, ensuring uniform licensing across the project
  • Complete: All sections are present including the full terms, conditions, and appendix

Correctness Verification

The changes correctly address the license detection issues:

  1. Fixed text inconsistencies:

    • "the Licensor""Licensor" (LICENSE:49, LICENSE:61)
    • "excluding any notices""excluding those notices" (LICENSE:104)
  2. Restored official appendix (LICENSE:179-202):

    • Removed custom boilerplate text about NOTICE files
    • Added back the official Apache 2.0 appendix template
    • Fixed indentation in copyright template
  3. Added missing blank line (LICENSE:1):

    • Proper formatting as per official template

Legal & Security Assessment

  • No security concerns: License text changes only affect legal metadata, not code functionality
  • Legal compliance: Using exact Apache 2.0 text ensures proper license recognition by automated tools
  • Proper attribution: NOTICE file exists and is properly maintained

Performance Considerations

  • No performance impact: LICENSE files are not loaded during runtime
  • Tool compatibility: pkg.go.dev and other license scanners will now properly detect Apache 2.0

⚠️ Test Coverage Note

No tests required for license files, as they are legal documents rather than functional code.

Recommendations

  1. Monitor pkg.go.dev: After merge and re-indexing, verify the license shows as "Apache-2.0" ✅
  2. Consider automation: Future license updates could use the official text source to avoid drift

Impact Assessment

  • Positive: Resolves pkg.go.dev license detection
  • No breaking changes: License terms remain Apache 2.0
  • Improved: Better tool compatibility and legal clarity

This is a well-executed fix that maintains legal consistency while solving the license detection problem.


@ajitpratap0 ajitpratap0 merged commit 8dd346a into main Mar 8, 2026
22 checks passed
@ajitpratap0 ajitpratap0 deleted the fix/license-apache-2.0 branch March 8, 2026 09:13
ajitpratap0 pushed a commit that referenced this pull request Mar 8, 2026
…ion fix

v1.9.2 was cached by the Go module proxy before PR #356 (LICENSE fix)
landed, so pkg.go.dev still shows License: UNKNOWN. Bumping to v1.9.3
ensures the proxy fetches a fresh zip with the corrected LICENSE.
ajitpratap0 added a commit that referenced this pull request Mar 8, 2026
…ion fix (#357)

v1.9.2 was cached by the Go module proxy before PR #356 (LICENSE fix)
landed, so pkg.go.dev still shows License: UNKNOWN. Bumping to v1.9.3
ensures the proxy fetches a fresh zip with the corrected LICENSE.

Co-authored-by: Ajit Pratap Singh <ajitpratapsingh@Ajits-Mac-mini-2655.local>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant