Changelog¶
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
[Unreleased]¶
Added¶
Added the
UnsupportedBrowserBannercomponent to theduck.html.components.unsupported_browsermodule.Added the
glaciervariant to theSnackbarcomponent, providing a modern frosted-glass appearance.
Changed¶
Updated the
SnackbarandProgresscomponents to support dynamic color updates after initialization.Updated
lively.jsandlively.min.jsto support the new page progress bar and snackbar behavior.Simplified the
Pagecomponent implementation.Refined Lively’s WebSocket connection notifications to display only meaningful status changes, removing the initial “Connected” toast.
Updated
Pagemethods such asset_author,set_canonical,set_pagination, andset_json_ldto allow multiple invocations without raisingComponentAttributeProtectionerror, making them safe to update or override throughout the page lifecycle.
Fixed¶
Fixed several issues related to snackbar state synchronization and dynamic updates.
[2.1.0] - June 20, 2026¶
Added¶
Added
is_valid_hostto theduck.utils.netmodule.Added two built-in template tags and one filter:
smart_truncateexpand_exceptionto_spaced_camel_casesmart_truncateandto_spaced_camel_caseare powered by utilities from theduck.utils.stringmodule.
Improved default blueprint scaffolding:
New blueprints now include a
ui/directory by default.views.pyis generated automatically.Static assets are automatically discovered from
ui/static/.Templates are automatically discovered from
ui/templates/.
Added a built-in Dashboard blueprint for monitoring and managing Duck applications, including:
Request and response metrics
Latency tracking
Error reporting
Route inspection
Log monitoring
Real-time server state monitoring
Added support for log handlers in the
duck.logging.handlermodule, enabling custom integrations and actions to be executed whenever log messages are emitted.Added a built-in Dashboard accessible via the
/dashboardroute, providing visibility into:Requests and responses
Errors and exceptions
Logs and routes
Performance metrics
Server diagnostics
Added support for the
ENABLE_DASHBOARDsetting, allowing the Dashboard to be enabled or disabled without manual blueprint registration.Added
DASHBOARD_USERNAMEandDASHBOARD_PWDsettings for securing Dashboard access during development and debugging.Added
get_user_idtoduck.contrib.authfor efficiently retrieving the authenticated user’s ID from supported authentication backends such asjwtandsession, avoiding the overhead of loading the full user object when only the identifier is required.Added the
duck.securitypackage for security-related utilities.Added a
user_idargument toduck.contrib.auth.loginandduck.contrib.auth.async_login, enabling fast authentication when the user ID is already known.Added a
force_reparentargument toInnerHtmlComponent.add_childandInnerHtmlComponent.add_childrenthat automatically detaches a component from any existing parent and component tree before reattaching it. This is useful when reusing components that were temporarily attached elsewhere during construction.Added
remove_ansi_escape_codes_strto theduck.utils.ansimodule.Added the
duck.security.passwordsmodule for password strength validation and security checks.
Changed¶
Renamed
duck.etc.appstoduck.etc.blueprintsto better reflect its purpose.Renamed the built-in blueprint:
duck.etc.apps.defaultsite.blueprint.Ducksiteto:
duck.etc.blueprints.welcome.blueprint.WelcomeRemoved
simple_responsefromduck.contrib.responses.Renamed
template_responsetomake_responsefor improved clarity and consistency.Added
async_make_responseas the asynchronous equivalent ofmake_response.Refined middleware implementations and improved middleware debugging messages.
Modernized Duck’s default pages and error pages with a cleaner, more polished user experience.
Simplified and reduced complexity within
duck.contrib.responses.errors.Dashboard functionality is now only enabled when securely configured.
Moved the
duck.ansimodule toduck.utils.ansi.Added
https://fonts.googleapis.comandhttps://fonts.gstatic.comto the default Content Security Policy (CSP) rules.duck.utils.fileio.FileIOStreamnow caches read and write operations to improve performance during repeated access.
Fixed¶
Fixed various issues related to blueprint generation and resource discovery.
Fixed inconsistencies in default blueprint structure and automatic asset resolution.
Fixed middleware
process_responsehooks not executing for error responses.process_responseis now always executed whenever a request object is available.Fixed
InnerHtmlComponent.add_childrento iterate over a copy of the provided children collection, preventing issues caused by mutations during iteration.Fixed several subtle bugs in
duck.utils.xsocket.Fixed an issue with the
duck collectstaticcommand.
[2.0.0] - June 8, 2026¶
Added¶
Added
static_filepathandmedia_filepathhelpers to theduck.shortcutsmodule.Added an
absoluteargument to themediaandstaticshortcut functions.Added a
log_resultsargument to theexec_timeandasync_exec_timedecorators induck.utils.performance.Added support for
selectedandvaluekeyword arguments to theOptionHTML/Lively component and improved theSelectcomponent.Added
update_now()toLivelyWebsocketView, allowing immediate synchronization of component state with the client during event execution.Added automatic session persistence for Lively events when session data is modified.
Added the
set_meta()method to thePagecomponent.Added the
csrf_exemptdecorator toduck.views.Introduced a cleaner application architecture where all applications inherit from
duck.app.base.BaseApp.Added a
server_urlargument toBaseAppfor improved reverse-proxy and deployment support.Added support for application events through the
eventsargument on core applications fromduck.apps.Added first-class JWT support, modeled after Duck’s session system. JWT payloads can now be accessed and modified directly using syntax such as:
request.JWT["key"] = valueAdded authentication utilities to
duck.contrib.auth:authenticateloginlogoutget_user_from_sessionget_user_from_jwt
Added
JWTMiddlewareto Duck’s default middleware stack.Added encrypted cache support through
duck.utils.caching.encrypted.
Changed¶
Refactored the
staticandmediahelpers to support external URLs in addition to internal assets.Refined AI guidelines in the
ai/directory.Made
duck.http.middlewares.contrib.WWWRedirectMiddlewareoptional and removed it from the default middleware configuration.Renamed
SessionStore.create()toassign_new_session_key()for improved clarity.Made request sessions lazily loaded on first access or modification.
Renamed
_extract_and_process_request_data()to_set_request_fields().Renamed
duck.utils.port_recordertoduck.utils.port_registryand fully refactored its internals.Improved and refined the
ssl-gencommand.Improved
SessionStorageConnectorshutdown performance by executing storage cleanup operations in background threads.Improved and refined the
duck.app.microappmodule.Renamed the
FORCE_HTTPSsetting toHTTPS_REDIRECT.Improved the
AppAPI and internal application lifecycle.Removed default self-signed certificate generation settings; certificate generation is now entirely optional.
Reduced the default
DJANGO_SERVER_WAIT_TIMEto 1 second.Improved how Lively synchronizes SESSION, JWT, and other server-side state after mutations. Synchronization now uses a secure server-issued flow that updates credentials through a protected
fetch()request while preserving support forHttpOnlycookies.Improved session storage security.
Fixed¶
Fixed a Lively navigation issue when navigating from URLs containing fragments (e.g.
https://duckframework.com#section) to internal routes.
[1.0.2] - March 6, 2026¶
Added¶
Added minor features and quality-of-life improvements.
Changed¶
Refactored various parts of the codebase to improve maintainability.
Fixed¶
Fixed several minor bugs and stability issues.