Logging is a logging library for Roblox that takes after Python's logging library. It has no dependencies and is lightweight.
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local Logging = require(ReplicatedStorage:WaitForChild("Logging"))
-- Do this just once at startup:
-- Now log events when they happen:
-- Using a Logger object for your module/game:
local logger = Logging:getLogger("MyGame")
logger:debug("Created %d zombies", 5)
logger:info("Starting round with %d players", 2)
logger:warning("Watch out, the %s might %s", "balloon", "pop")
logger:error("DataStores might be down")
logger:critical("A real showstopper, closing server")
-- Filter logs lower than a certain level:
-- Use child loggers for subsystems:
logger:getChild("DataStores"):info("Loaded player data")
Dive right into the Getting Started guide for more.
- Visual Studio Code
- Markdown (.md) linted using markdownlint
- Luau code (.lua) linted using selene
- Built using Rojo 7:
- default.project.json builds the library as a model, can be included in other Rojo projects which depend on this library.
- test.project.json builds a place which runs unit tests
(open in Roblox Studio and click Run).
- Tests can be found in tests/Tests.lua
- Makefile included with several useful targets (
serve) which operate on the Rojo project files above.
- wally.toml: package manifest for wally
- moonwave.toml Configuration for building documentation using Moonwave