-
Notifications
You must be signed in to change notification settings - Fork 167
Description
Summary
Comprehensive testing of the func delete command identified 9+ issues across flag validation and argument parsing, with the primary concerns being missing validation for the --all flag where undocumented values like TRUE, False, yes, 1, 0, and empty strings are silently accepted and interpreted as boolean values without any error messages, creating a dangerous situation where users might think they're deleting all resources when the flag is actually set to false, or vice versa; hyphen-prefixed name parsing bug where function names starting with hyphens are misinterpreted as flags, showing confusing error messages without guidance on DNS-1035 naming rules, which is the same issue that existed in func create and was already fixed there; and late validation where invalid flag values are accepted and the command proceeds to connect to the Kubernetes cluster before failing, wasting time and resources instead of catching errors early. Key findings include the critical bug where the --all flag accepts any string value and silently converts it to true/false using Go's default boolean parsing, meaning values like yes, 1, TRUE all work but aren't documented, while invalid values like invalid are silently treated as false without warning the user; the argument parsing issue where names like -myfunction trigger flag parsing errors instead of helpful messages about naming rules; and the lack of early validation that causes the command to attempt cluster connections even when flag values are clearly invalid.
Full Detailed Report: Link to Google Docs - https://docs.google.com/document/d/1yeMw5ZrdaOC9qqGI2lRFRASlJQ-XN6b92CQkymXZNNM/edit?usp=sharing
Resolved Issues
The following issues have been marked as resolved in the detailed report:
(No issues marked as resolved yet)