{"record":{"id":"0ede3968fcd3030f","repo":"larksuite/cli","slug":"invalid-timestamp-q-w","errorCode":null,"errorMessage":"invalid timestamp %q: %w","messagePattern":"invalid timestamp %q: %w","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"shortcuts/vc/vc_meeting_events.go","lineNumber":44,"sourceCode":"\tdefaultVCMeetingEventsSize = 20\n\tminVCMeetingEventsPageSize = 20\n\tmaxVCMeetingEventsPageSize = 100\n\tmaxVCMeetingEventsPages    = 200\n\tleaveReasonUserLeft        = 1\n\tleaveReasonMeetingEnded    = 2\n\tleaveReasonKicked          = 3\n)\n\nvar meetingDisplayLocation = time.FixedZone(\"UTC+8\", 8*60*60)\n\n// toUnixSeconds converts a supported CLI time input into a Unix seconds string.\nfunc toUnixSeconds(input string, hint ...string) (string, error) {\n\tts, err := common.ParseTime(input, hint...)\n\tif err != nil {\n\t\treturn \"\", err\n\t}\n\tif _, err := strconv.ParseInt(ts, 10, 64); err != nil {\n\t\treturn \"\", fmt.Errorf(\"invalid timestamp %q: %w\", ts, err) //nolint:forbidigo // intermediate parse error; callers wrap it into a typed ValidationError\n\t}\n\treturn ts, nil\n}\n\n// VCMeetingEvents lists meeting events for a meeting.\nvar VCMeetingEvents = common.Shortcut{\n\tService:     \"vc\",\n\tCommand:     \"+meeting-events\",\n\tDescription: \"List meeting events by meeting ID\",\n\tRisk:        \"read\",\n\t// UAT exposes user-granted scopes, so the framework can preflight the user\n\t// recommendation. TAT has no scope metadata; keep the bot recommendation\n\t// conditional so it is available to diagnostics without a local preflight.\n\tUserScopes:           []string{meetingQueryUserScope},\n\tConditionalBotScopes: []string{meetingQueryBotScope},\n\tAuthTypes:            []string{\"user\", \"bot\"},\n\tHasFormat:            true,\n\tFlags: []common.Flag{","sourceCodeStart":26,"sourceCodeEnd":62,"githubUrl":"https://github.com/larksuite/cli/blob/7fd6ef3c07182257ce776cdc5a614e122d5bd4b3/shortcuts/vc/vc_meeting_events.go#L26-L62","documentation":"toUnixSeconds first converts user time input via common.ParseTime, then validates the result is a parseable 64-bit integer Unix timestamp. If ParseInt fails, it wraps the cause as 'invalid timestamp %q: %w'. This is an intermediate parse error; callers (parseMeetingEventsTimeRange) wrap it into a typed ValidationError.","triggerScenarios":"Calling VC meeting events with --start/--end values that ParseTime accepts but that do not yield an integer string — practically, when ParseTime is configured/extended to return non-numeric output or the input bypasses normal parsing, since ParseTime's own failure is returned unwrapped first.","commonSituations":"Passing exotic date formats that a customized parser produced non-numeric output for, or feeding a pre-formatted value through a path where ParseTime passes it through unvalidated.","solutions":["Use a standard, unambiguous time format (RFC3339 like '2026-09-04T10:00:00+08:00' or 'YYYY-MM-DD HH:MM').","Check the wrapped cause after 'invalid timestamp' to see why the integer conversion failed.","If providing raw Unix seconds, supply a plain integer like '1780000000'.","Check --help/schema for accepted --start/--end formats for the meeting events command."],"exampleFix":"// before\n--start \"04/09/2026 10am\"\n// after\n--start \"2026-09-04T10:00:00+08:00\"","handlingStrategy":"validation","validationCode":"ts, err := common.ParseTime(input)\nif err != nil { return err }\nif _, err := strconv.ParseInt(ts, 10, 64); err != nil {\n\treturn fmt.Errorf(\"--start/--end must resolve to Unix seconds, got %q\", ts)\n}","typeGuard":"func isUnixSecondsString(s string) bool {\n\t_, err := strconv.ParseInt(strings.TrimSpace(s), 10, 64)\n\treturn err == nil\n}","tryCatchPattern":"if err != nil {\n\tvar ve *errs.ValidationError\n\tif errors.As(err, &ve) { return hintUsage(ve, \"use RFC3339 or Unix seconds for --start/--end\") }\n\treturn err\n}","preventionTips":["Pass RFC3339 or plain Unix-seconds strings to --start/--end.","Avoid locale-specific date formats in scripts."],"tags":["validation","vc","timestamp","cli"],"backgroundTag":"invalid-timestamp-format","analyzedSha":"7fd6ef3c07182257ce776cdc5a614e122d5bd4b3","analyzedAt":"2026-09-04T21:17:44.649Z","contentChangedAt":"2026-09-04T21:17:44.649Z","schemaVersion":2},"datasetVersion":"2026-09-12T02:17:10.037Z"}