Releases: Kampfkarren/selene
Releases · Kampfkarren/selene
[0.21.1] - 2022-09-19
Fixed
- Fixed not being able to use projects without selene.toml.
[0.21.0] - 2022-09-17
Added
undefined_variable
now properly catchesglobal
as undefined infunction global.name()
.- Added the "luau" builtin library.
unused_variable
andincorrect_standard_library_use
will now suggest configuring a standard library if one is detected.- Added
constant_table_comparison
check to catchx == {}
, which will always fail. - Added
high_cyclomatic_complexity
check to catch overly complex functions that are hard to test, and harder to reason about. This lint is disabled by default. - Added
Font.new
to the Roblox standard library. roblox_incorrect_roact_usage
now lints for invalid events.
Changed
- Match
.luau
filename extension by default. - Allow
--pattern
to be passed multiple times. roblox_incorrect_roact_usage
now uses the generated standard library to know what classes and properties exist, meaning a selene update is no longer necessary to update.- Roblox standard libraries are now guaranteed to regenerate when the previously generated standard library is on a different version.
Fixed
- Fixed
unused_variable
incorrectly taggingfunction global.name()
whenglobal
is defined in the standard library. - Fixed
unscoped_variables
incorrectly taggingfunction global.name()
as creating an unscoped variable forglobal
. - Fixed
roblox_incorrect_roact_usage
always showing the class name as "Instance". (#297) roblox_incorrect_roact_usage
will now find instances of createElement that do not specify properties.- Fixed issues where
roblox_incorrect_color3_new_bounds
would sometimes fail to run.
New Contributors
- @Yumacide made their first contribution in #399
- @LastTalon made their first contribution in #401
- @PysephWasntAvailable made their first contribution in #414
[0.20.0] - 2022-07-21
Added
- Added
utf8
globals to the builtinlua53
standard library. - Added Roblox datatype constructors
CatalogSearchParams.new
,FloatCurveKey.new
, andRotationCurveKey.new
.
Changed
- Errors for generating Roblox API dumps are now more detailed.
Fixed
- Fixed newer versions of the Roblox API dump failing to create standard libraries for.
- Fixed reporting an error when generating standard libraries panicking.
[0.19.1] - 2022-06-22
Fixed
- Fixed releases coming with Tracy.
[0.19.0] - 2022-06-22
Added
table.insert(x)
no longer counts as a read tox
, which allows selene to alert you that you are only assigning to it.- This is done through a new standard library field for arguments called
observes
. This takes 3 values: "read-write" (the default), signifying a potential read and write, "read", signifying only a read, and "write", signifying only a write. Only "write" has meaning at this time.
- This is done through a new standard library field for arguments called
- Added new
must_use
lint, which will warn you when you are not using the return value of a function that performs no other behavior.- This is done through a new standard library field for functions called
must_use
. Set it totrue
to gain this functionality.
- This is done through a new standard library field for functions called
Fixed
- Fixed a bunch of performance failures, lowering some benchmarks from 3 seconds to 200ms.
[0.18.2] - 2022-06-10
Fixed
- Fixed
Enum.NAME.Value
failing in newly generated standard libraries.
[0.18.1] - 2022-06-07
Changed
- Updated internal parser, bringing bug fixes to type information with generic packs.
[0.18.0] - 2022-06-07
Added
- Added new YAML based standard library format. The old TOML format is now deprecated and will not have any new functionality added to it, but will be preserved for the forseeable future.
- You can upgrade old TOML standard libraries by running
selene upgrade-std library.toml
, which will create a new .yml file of the same name in the new format. - This only affects standard library files.
selene.toml
has not changed. - Added new
deprecated
lint, which can be configured by standard libraries. - Added
debug.resetmemorycategory
to the Roblox standard library. - Added
debug.setmemorycategory
to the Roblox standard library. - Added
--no-summary
option to suppress summary information.
Changed
- Roblox standard library files are now no longer generated in the project directory, and will be updated automatically every 6 hours. You can update it manually with
selene update-roblox-std
. - As per the deprecation of TOML standard libraries, you should delete your
roblox.toml
if you have one. - It is possible to pin a standard library in the same way
roblox.toml
was if you are in an environment where you do not want automatic updates, such as one where you want to limit selene's internet usage. Learn more on the Roblox Guide documentation page.
Removed
- With the introduction of the new
deprecated
lint, the--deprecated
field has been removed fromgenerate-roblox-std
, and is now implied.
[0.17.0] - 2022-04-10
Added
- Added
start_line
,start_column
,end_line
, andend_column
to JSON diagnostic output. - Added
Color3.fromHex
to the Roblox standard library. - Added
table.clone
to the Roblox standard library. - Added
coroutine.close
to the Roblox standard library. - Added
task.cancel
to the Roblox standard library.
[0.16.0] - 2022-01-30
Added
- Added support for parsing generic type packs, variadic type packs, and explicit type packs in generic arguments for a type under the
roblox
feature flag (type X<S...> = Y<(string, number), ...string, S...>
) - Added support for string and boolean singleton types under the
roblox
feature flag (type Element = { ["$$typeof"]: number, errorCaught: true, which: "Query" | "Mutation" | "Subscription" }
- Added support for default types in a generic type declaration under the
roblox
feature flag (type Foo<X = string> = X
) - Added
table.freeze
,table.isfrozen
,bit32.countlz
,bit32.countrz
to the Roblox standard library. - Added
Vector2.zero
,Vector2.one
,Vector2.xAxis
,Vector2.yAxis
to the Roblox standard library. - Added
Vector3.zero
,Vector3.one
,Vector3.xAxis
,Vector3.yAxis
,Vector3.zAxis
to the Roblox standard library. - Added
CFrame.identity
to the Roblox standard library. - Added
gcinfo
to the Roblox standard library.
Fixed
- Fixed a bug where empty else blocks were not properly closing their scope, meaning that they could confuse the shadowing lint. (#116)