$npx skillfedfor your agent

javalang

Pure Python Java parser and tools

With conditionsPyPI LibrariesReleased Mar 2020369.8K downloads / mopermissive licensePure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — javalang-0.13.0-py2-none-any.whl · javalang-0.13.0-py3-none-any.whl
v0.13.0 · released 2020-03-28 · 1 runtime deps: six

Yes, if you need to parse Java 8 code and can tolerate dormant maintenance. The library is stable, has no known vulnerabilities, installs with minimal friction, and carries a permissive license. It is well-suited for one-off analysis or tooling. Avoid it if you need active maintenance, support for newer language features, or ongoing bug fixes.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Installation is straightforward with low friction; the package depends only on six and has wheels for both Python 2 and 3.
  • However, maintenance is dormant—the last release was in 2020 and no commits have landed since 2023-09-17, so bug fixes or compatibility updates are unlikely.

License · maintenance · safety

permissive license (permissive) — Licensed under MIT (permissive), so you can use, modify, and distribute javalang freely in both open and closed projects with minimal restrictions.

last release 2020-03-28 (2330 days) · last repo commit 2023-09-17 · 795 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 369,845 downloads/mo, #7,183 on PyPI

Verify before relying

import javalang

tree = javalang.parse.parse("package example; class Test {}")
print(tree.package.name)
print(tree.types[0].name)
  • Whether the Java 8 parser handles syntax features beyond Java 8 or only Java 8 constructs.
  • Performance characteristics when parsing large or complex Java source files.
  • Compatibility with current Python versions beyond what classifiers declare.
Same gist for agents: .md · .json

What it is and what it does

javalang is a pure Python library that parses Java source code into an abstract syntax tree (AST) you can inspect and traverse. It includes a lexer (tokenizer) and parser targeting Java 8, built from the official Java language specification. You pass a complete Java source file as a string to javalang.parse.parse() and get back a CompilationUnit object—the root of a tree where each node represents a syntactic element (package, class, method, etc.). You can iterate over the tree, filter by node type, and extract metadata like class names, package declarations, and method signatures.

The library exposes its components individually: you can tokenize code directly with javalang.tokenizer.tokenize() to get a stream of JavaToken objects with position and value info, or use javalang.parser.Parser directly on a token stream to parse snippets (expressions, type declarations, etc.) rather than full compilation units. It depends only on six for Python 2/3 compatibility, making installation lightweight. However, the project is dormant—last updated in 2020—so it will not track language evolution or receive bug fixes.

Use it for

  • Extract class and method names from Java source files for documentation or code analysis tools.
  • Build a Java code search or indexing tool that needs to understand package and type structure.
  • Analyze Java code for metrics (method count, inheritance depth, etc.) without running a compiler.
  • Implement a Java code refactoring or transformation tool that needs to parse and manipulate the AST.
  • Validate or lint Java code snippets in a Python application without invoking javac.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

With conditions

Yes, if you need to parse Java 8 code and can tolerate dormant maintenance.

The library is stable, has no known vulnerabilities, installs with minimal friction, and carries a permissive license. It is well-suited for one-off analysis or tooling. Avoid it if you need active maintenance, support for newer language features, or ongoing bug fixes.

Install

javalang on PyPI

Before you install

Installation is straightforward with low friction; the package depends only on six and has wheels for both Python 2 and 3. However, maintenance is dormant—the last release was in 2020 and no commits have landed since 2023-09-17, so bug fixes or compatibility updates are unlikely.

License in practice

Licensed under MIT (permissive), so you can use, modify, and distribute javalang freely in both open and closed projects with minimal restrictions.

Quickstart

import javalang

tree = javalang.parse.parse("package example; class Test {}")
print(tree.package.name)
print(tree.types[0].name)

Verify before relying

  • Whether the Java 8 parser handles syntax features beyond Java 8 or only Java 8 constructs.
  • Performance characteristics when parsing large or complex Java source files.
  • Compatibility with current Python versions beyond what classifiers declare.

Package facts

Licensepermissive license permissive
Python supportNot specified
Install frictionLow. Pure-Python wheel
Runtime dependencies
1 package
six
MaintenanceDormant 2,330 days since the last release
Last repo commit
First released
Downloads369,845 / month, #7,183 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Development Status :: 4 - BetaIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: PythonTopic :: Software Development :: Libraries

Evidence: javalang-0.13.0-py2-none-any.whl; javalang-0.13.0-py3-none-any.whl

Tags

Capabilities
java parser pythonjava source code analysisjava ast treejava lexer tokenizerparse java files python
Topics
java-parsingast-analysiscode-inspection

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “java source code analysis”

  • javalangjavalang is a pure Python lexer and parser for Java 8 source code…
  • tree-sitter-javaProvides a Java language grammar for tree-sitter, enabling…
  • mobsfscanmobsfscan is a static analysis tool that detects insecure code…

Give your agent the search over MCP, or paste the wish link into any chat.

More Libraries packages

urllib3 Worth it
PyPI · Libraries · released May 2026

urllib3 is an HTTP client library that provides thread-safe connection pooling, SSL/TLS verification, multipart file uploads, request retries, compression support, and proxy handling for Python applications.

MITpure Python · 3.10+
1.8Bdownloads / mo
requests Worth it
PyPI · Libraries · released May 2026

Requests is a Python HTTP library that simplifies sending HTTP/1.1 requests with automatic handling of headers, authentication, cookies, and response parsing.

Apache-2.0pure Python · 3.10+
1.8Bdownloads / mo
pluggy Worth it
PyPI · Libraries · released May 2025

Pluggy provides a plugin system that lets you define hook specifications and register implementations to be called in sequence, enabling extensible Python applications without tight coupling.

Install it if you're building an extensible application or framework.

MITpure Python · 3.9+aging
1.3Bdownloads / mo
python-dateutil Worth it
PyPI · Libraries · released Mar 2024

Provides parsing, arithmetic, and recurrence rule computation for dates and times, with timezone support and iCalendar RFC compliance.

Install it if you need to parse flexible date strings, compute relative dates, handle timezones, or work with recurrence rules—it's the de facto choice for these tasks.

Apache-2.0pure Python
1.2Bdownloads / mo
six With conditions
PyPI · Libraries · released Dec 2024

Six provides utility functions to write Python code that runs on both Python 2.7 and Python 3.3+, smoothing over language differences between the two versions.

MITpure Python
1.2Bdownloads / mo
pytest Worth it
PyPI · Libraries · released Jun 2026

pytest is a testing framework that lets you write test functions using plain assert statements and automatically discovers and runs them, with detailed failure reporting.

MITpure Python · 3.10+
1.1Bdownloads / mo

See also pytokens · tree-sitter-java · funcparserlib · ply · pygmars · sly · proto-schema-parser · py-partiql-parser · esprima · luaparser