Releases: offerrall/FuncToWeb
Releases · offerrall/FuncToWeb
0.9.5
[0.9.5] - 2025-12-09
Added
- New Generic
FileType: Added support for a genericFiletype hint.- Use
from func_to_web.types import Fileto accept uploaded files of any extension.
- Use
- Expanded File Extensions: Significantly broadened the list of supported formats for specific file types.
0.9.4
[0.9.4] - 2025-12-08
Added
- Python Enum Support: Full support for Python
Enumtypes as dropdown menus.- Use standard Python enums as type hints:
def func(theme: Theme) - Supports
str,int, andfloatenum values - Your function receives the actual Enum member (e.g.,
Theme.LIGHT), not just the string value - Access both
.nameand.valueproperties in your function - Compatible with all enum features (methods, properties, iteration)
- Add tests covering enum handling, conversion, and edge cases
- Use standard Python enums as type hints:
0.9.3
[0.9.3] - 2025-11-30
Fixed
- Async Function Support: Fixed an issue where passing an
async deffunction displayed a<coroutine object>instead of the result.- The library now automatically detects
asyncfunctions andawaitsthem properly. - Enables seamless integration with async libraries (e.g.,
httpx,tortoise-orm,motor).
- The library now automatically detects
0.9.2
[0.9.2] - 2025-11-25
Added
- Built-in Authentication: Robust, stateless authentication system.
- Enable simply by passing a dictionary
auth={"username": "password"}to therun()function. - Architecture based on Signed Cookies (no database required).
- Includes protection against Timing Attacks (
secrets.compare_digest) and CSRF (SameSite='Lax').
- Enable simply by passing a dictionary
- Session Management: New
secret_keyargument inrun()to control session persistence across server restarts. - Login UI:
- Dedicated, modern login page that automatically inherits the application's theme (Light/Dark).
- Responsive design matching the core library aesthetics.
- Logout Functionality: New logout button in the header navigation (automatically appears when auth is enabled).
Changed
- Dependencies: Added
itsdangerousto required packages (essential for session signing). - Templates: Updated
basetemplates to handle conditional rendering based on authentication state (has_authflag).