starlark
An implementation of the Starlark language in Rust.
0.14.2
4.5M downloads/mo
#4727 most downloaded on crates.io
facebook/starlark-rust
What this package is like to depend on
Last release 2 months ago
05 Jun 2026
Release timing varies
gaps range from 1 weeks to 1.4 years
Most releases are documented
notes for 13 of 20 stable releases
1 version withdrawn
withdrawn after publishing
8 years old
21 releases · first in 2018
3 releases in the last 12 months
see the full history below
Release timeline
21 releases · Sep 2018 to Jun 2026Releases
latest 21-
0.14.205 Jun 2026Nothing published for this version
-
0.14.102 Jun 2026 withdrawnNothing published for this version
-
0.14.022 May 2026Nothing published for this version
-
0.13.013 Dec 2024Release notes
Open source →0.13 (Dec 13, 2024)
- Some API changes (but alas, too many for us to enumerate).
- Move to more Python-like type annotations, e.g.
dict[str, int]now. - Support for the
setdata type. - Improve documentation, both the docs and the doc generator.
- Performance improvements.
- More trait implementation (
Trace,Allocative,AllocValueetc). - Bump dependencies.
-
0.12.009 Feb 2024Release notes
Open source →0.12.0 (Feb 9, 2024)
- Implemented
reverse()forSmallMap. - Added a few more traits and functions to
OrderedSet. - Fixed "go to label" in bzl LSP.
- Added
OwnedFrozenRef. - Added
call_stack_frame()function. - Categorized lexer errors.
- Used correct error printing in
assert. - Cleaned up some code around imports, code consistency, and formatting.
- Fixed multi-line doc generation.
- Updated
dashmapfrom 5.4.0 to 5.5.3. - Removed autocompletion on reserved words and some trigger chars for Starlark
LSP. - Updated
hashbrownfrom 0.13.2 to 0.14.3. - Updated
allocativefrom 0.3.1 to 0.3.2.
- Implemented
-
0.11.019 Jan 2024Release notes
Open source →0.11.0 (Jan 19, 2024)
UnpackValueis no longer implemented forVec. Instead,UnpackList,UnpackTupleorUnpackListOrTuplecan be used.- Added
call_stack()function. - Removed
experimental_regex()function. - Switched from
anyhow::ErrorandDiagnostictostarlark::Errorin many APIs. - Fix
repr()for enums. - Various improvements to DAP support.
- Add a few more traits and functions to
SortedMap. - Disable the legacy type representation, types as strings such as
"bool"are no longer supported. See the revised typing documentation.
-
0.10.017 Oct 2023Release notes
Open source →0.10.0 (Oct 16, 2023)
There were over eight hundred commits since the last release, with the main areas of change including:
- Make it work on 32 bit architectures, including WASM.
- Introduce
starlark_syntax,starlark_lsp,starlark_bincrates. - Expose the AST through
starlark_syntax. - No longer require nightly Rust compiler.
- Change how types are represented, e.g.
{str.type, ""}becomesdict[str, typing.Any]. - Add static type checking options.
- Support f-strings extension.
Release notes
Open source →There were over eight hundred commits since the last release, with the main areas of change including:
- Make it work on 32 bit architectures, including WASM.
- Introduce
starlark_syntax,starlark_lsp,starlark_bincrates. - Expose the AST through
starlark_syntax. - No longer require nightly Rust compiler.
- Change how types are represented, e.g.
{str.type, ""}becomesdict[str, typing.Any]. - Add static type checking options.
- Support f-strings extension.
-
0.9.005 Jun 2023Release notes
Open source →0.9.0 (June 5, 2023)
There were over one thousand commits since the last release, with the main areas of change including:
- Add
Module.namesto get the symbols in a module. - Change iterators on
Valueto support reduced stack space and enable future garbage collection, removingiterate_collectandwith_iterator. - Improve DAP (debugger) support.
- Improve the performance and fix a few bugs in
%string formatting. - Introduce
StarlarkTypeRepras a trait for things that have a type representation. - Optimise and increase standards conformance of the Starlark standard library.
- Rework how
List/Dictare specified, making their internals private and introducingListRef/DictReffor pointers to them. - Add
AllocStruct,AllocListandAllocDictas helpers to allocate the various types more efficiently. - Remove the
dedupeStarlark function. - Integrate with the
allocativecrate to support theAllocativetrait. - Add more
Traceimplementations. - Support type annotations on assignments.
- Make
Module.loadsalso return theFileSpan. - Add
FrozenModule.get_option. - Add support for integers greater than 32 bits.
- Move to a separate
starlark_mapcrate forSmallMapand optimise it. - Require the
starlark_type!macro. - Change
Module.extra_vto beValue<'v>. - Expose
FrozenHeapfromFreezerandGlobalsBuilder. - Remove
Value::new_int. - In
starlark_modulefunctions must be more explicit - returnanyhow::Result, have an explicit'vparameter, explicitheap/evalarguments. - Add
StringValueLiketo cover string types that are values. - Change the
jsonextension method to bejson.encodeandjson.decode. - Support stable Rust.
- Inline all the relevant pieces of the
gazebolibrary. - Change all
starlark_moduleannotations to be#[starlark(...)],#[starlark(require = named)]for name-only parameters. - Many performance optimisations.
- Change the API for profiling and add new profiling features.
- Make the
starlarkbinary spawn the REPL by default. - Many improvements and API changes to the documentation generation code.
- Many improvements to the LSP code.
- Add a
Dialectoption to enable types.
Release notes
Open source →There were over one thousand commits since the last release, with the main areas of change including:
- Add
Module.namesto get the symbols in a module. - Change iterators on
Valueto support reduced stack space and enable future garbage collection, removingiterate_collectandwith_iterator. - Improve DAP (debugger) support.
- Improve the performance and fix a few bugs in
%string formatting. - Introduce
StarlarkTypeRepras a trait for things that have a type representation. - Optimise and increase standards conformance of the Starlark standard library.
- Rework how
List/Dictare specified, making their internals private and introducingListRef/DictReffor pointers to them. - Add
AllocStruct,AllocListandAllocDictas helpers to allocate the various types more efficiently. - Remove the
dedupeStarlark function. - Integrate with the
allocativecrate to support theAllocativetrait. - Add more
Traceimplementations. - Support type annotations on assignments.
- Make
Module.loadsalso return theFileSpan. - Add
FrozenModule.get_option. - Add support for integers greater than 32 bits.
- Move to a separate
starlark_mapcrate forSmallMapand optimise it. - Require the
starlark_type!macro. - Change
Module.extra_vto beValue<'v>. - Expose
FrozenHeapfromFreezerandGlobalsBuilder. - Remove
Value::new_int. - In
starlark_modulefunctions must be more explicit - returnanyhow::Result, have an explicit'vparameter, explicitheap/evalarguments. - Add
StringValueLiketo cover string types that are values. - Change the
jsonextension method to bejson.encodeandjson.decode. - Support stable Rust.
- Inline all the relevant pieces of the
gazebolibrary. - Change all
starlark_moduleannotations to be#[starlark(...)],#[starlark(require = named)]for name-only parameters. - Many performance optimisations.
- Change the API for profiling and add new profiling features.
- Make the
starlarkbinary spawn the REPL by default. - Many improvements and API changes to the documentation generation code.
- Many improvements to the LSP code.
- Add a
Dialectoption to enable types.
- Add
-
0.8.009 May 2022Release notes
Open source →0.8.0 (May 9, 2022)
- Redo
StringValueandFrozenStringValueas aliases forValueTyped<StarlarkStr>andFrozenValueTyped<StarlarkStr>respectively. - Add more trait implementations for
ValueTyped. - Format call stack reports more like Python.
- Implement
FromStrforProfileMode. - Impelement
EqforBorrowHashed. - Minor optimisations throughout.
- Better error messages, e.g for
1 << -2. - Add
StarlarkValue::bit_notfor the bit-negation operator. - In the REPL print non-
Nonevalues. - Add
get_indextoSmallSet. - Add a
Regextype - note this is likely to change API in the next release and is not considered stable. - Upgrade dependencies.
Release notes
Open source →- Redo
StringValueandFrozenStringValueas aliases forValueTyped<StarlarkStr>andFrozenValueTyped<StarlarkStr>respectively. - Add more trait implementations for
ValueTyped. - Format call stack reports more like Python.
- Implement
FromStrforProfileMode. - Impelement
EqforBorrowHashed. - Minor optimisations throughout.
- Better error messages, e.g for
1 << -2. - Add
StarlarkValue::bit_notfor the bit-negation operator. - In the REPL print non-
Nonevalues. - Add
get_indextoSmallSet. - Add a
Regextype - note this is likely to change API in the next release and is not considered stable. - Upgrade dependencies.
- Redo
-
0.7.113 Apr 2022 -
0.7.022 Mar 2022Release notes
Open source →There have been many changes since the last release, focused on performance and features. These changes caused a number of API changes and behavioural changes, the most significant of which are listed below.
- Requires all Starlark types support
Serialize, and providederive(NoSerialize)to easily add a failingSerialize. - Remove
collection_json. - Support the latest
gazebodependency. SmallSetnow returns anExactSizeIterator.- Many optimisations, particularly around strings.
- Many optimisations to the bytecode compiler.
- Rename functions for working with constant strings.
- Add
StringValuetype, forValues which are known to be strings. - Remove
SimpleValue. - Remove the
Spantype. - Rename
SmallHashResulttoSmallHashValue. - Improve error messages on the wrong number of positional arguments.
- Remove some float-related functions from the API.
- Adjust the profiling API to make it more modular.
- Add support for validators when freezing.
Release notes
Open source →There have been many changes since the last release, focused on performance and features. These changes caused a number of API changes and behavioural changes, the most significant of which are listed below.
- Requires all Starlark types support
Serialize, and providederive(NoSerialize)to easily add a failingSerialize. - Remove
collection_json. - Support the latest
gazebodependency. SmallSetnow returns anExactSizeIterator.- Many optimisations, particularly around strings.
- Many optimisations to the bytecode compiler.
- Rename functions for working with constant strings.
- Add
StringValuetype, forValues which are known to be strings. - Remove
SimpleValue. - Remove the
Spantype. - Rename
SmallHashResulttoSmallHashValue. - Improve error messages on the wrong number of positional arguments.
- Remove some float-related functions from the API.
- Adjust the profiling API to make it more modular.
- Add support for validators when freezing.
- Requires all Starlark types support
-
0.6.022 Nov 2021Release notes
Open source →There have been many changes since the last release, focused on performance, documentation, type safety and profiling. These changes caused a number of API changes and behavioural changes, the most significant of which are listed below.
- Support for newer versions of
anyhow. - Some error messages contain "did you mean" suggestions.
- Addition of a bytecode interpreter, with associated performance gains.
- Constant propagation and speculative execution during compilation.
- Removed mutability around the file loader and
set_loader. - Several new forms of profiling, making use of the new
extra_memoryfunction. - Improved errors from derivations.
- Changes around function invocation, in particular
Argumentsis now opaque. - Changes around
ConstFrozenString, which is nowStarlarkStrN. - Add
OwnedFrozenValue::owner. - Add
derivesupport forFreeze. - Add more Starlark typed wrappers, such as
StringValueandValueTyped. - Make tuples and lists opaque types, with new functions for allocating them (e.g.
alloc_tuple). - Make all Starlark types implement
Displayin preference tocollect_repr. - Support for documentation annotations on all types.
Release notes
Open source →There have been many changes since the last release, focused on performance, documentation, type safety and profiling. These changes caused a number of API changes and behavioural changes, the most significant of which are listed below.
- Support for newer versions of
anyhow. - Some error messages contain "did you mean" suggestions.
- Addition of a bytecode interpreter, with associated performance gains.
- Constant propagation and speculative execution during compilation.
- Removed mutability around the file loader and
set_loader. - Several new forms of profiling, making use of the new
extra_memoryfunction. - Improved errors from derivations.
- Changes around function invocation, in particular
Argumentsis now opaque. - Changes around
ConstFrozenString, which is nowStarlarkStrN. - Add
OwnedFrozenValue::owner. - Add
derivesupport forFreeze. - Add more Starlark typed wrappers, such as
StringValueandValueTyped. - Make tuples and lists opaque types, with new functions for allocating them
(e.g.
alloc_tuple). - Make all Starlark types implement
Displayin preference tocollect_repr. - Support for documentation annotations on all types.
- Support for newer versions of
-
0.5.027 Aug 2021Release notes
Open source →There have been many changes since the last release, primarily focused on performance (up to 100x in some benchmarks). These changes caused a number of API changes, the most significant of which are listed below.
- Rename the
starlark_modulecrate tostarlark_derive. - Rename the
walkmethods totraceto align to standard GC literature. - Add
deriveforTrace. - Add
StarlarkAttrsderivation and scheme. - Initial start of documentation generation (still unstable).
- More complete
SmallMapAPI. - Three profiling modes, heap, flame and statement.
- Changes to
invoketo take anArgumentsstructure. - Changed to iteration APIs.
- Many semantic improvements to non-ASCII strings.
- Refinements to types and how they work.
- Mark a few additional APIs as
unsafe. - Use the
gazeboCoercetrait extensively, in particular required for some of thestarlark_valuemacros. - Delete
dict.copyandlist.copy, since they aren't in the Starlark spec. UnpackValueno longer takes aheapargument.
- Rename the
-
0.4.006 Apr 2021Release notes
Open source →- Change maintainer to Facebook.
- Move repo to https://github.com/facebookexperimental/starlark-rust.
- Switch to a garbage collector.
- Add
#[starlark_module]proc-macro. - Significant rewrite of most code, changing most APIs.
-
0.3.230 Sep 2021Release notes
Open source →- Commits and tag exist in https://github.com/indygreg/starlark-rust.
- Changed dependency versions from
X.Y.ZtoX.Yto allow adopting newer point releases. - lalrpop crate upgraded from 0.16 to 0.19 and code ported to enable building on Rust 1.56+.
- Fixed compiler warnings on Rust 1.56+ related to semicolons in macro expansions.
-
0.3.107 Oct 2020 -
0.3.029 Jan 2020Nothing published for this version
-
0.2.028 Dec 2018Nothing published for this version
-
0.1.228 Sep 2018Nothing published for this version
-
0.1.128 Sep 2018Nothing published for this version
-
0.1.027 Sep 2018Nothing published for this version