{"record":{"id":"349ed6222ca245cb","repo":"jackwener/OpenCLI","slug":"openreview-venue-cannot-be-empty","errorCode":null,"errorMessage":"openreview venue cannot be empty","messagePattern":"openreview venue cannot be empty","errorType":"validation","errorClass":"ArgumentError","httpStatus":null,"severity":"error","filePath":"clis/openreview/venue.js","lineNumber":31,"sourceCode":"\ncli({\n    site: 'openreview',\n    name: 'venue',\n    access: 'read',\n    description: 'List papers at an OpenReview venue (e.g. \"ICLR 2024 oral\" or full invitation id)',\n    domain: 'openreview.net',\n    strategy: Strategy.PUBLIC,\n    browser: false,\n    args: [\n        { name: 'venue', positional: true, required: true, help: 'Venue name (\"ICLR 2024 oral\") or invitation (\"ICLR.cc/2025/Conference/-/Submission\")' },\n        { name: 'limit', type: 'int', default: 25, help: 'Max results (max 200)' },\n        { name: 'offset', type: 'int', default: 0, help: 'Pagination offset' },\n    ],\n    columns: ['rank', 'id', 'title', 'authors', 'keywords', 'primary_area', 'pdate', 'pdf', 'url'],\n    func: async (args) => {\n        const value = String(args.venue ?? '').trim();\n        if (!value) {\n            throw new ArgumentError('openreview venue cannot be empty');\n        }\n        const limit = requireBoundedInt(args.limit, 25, 200);\n        const offset = requireNonNegativeInt(args.offset, 0);\n        const isInvitation = value.includes('/-/');\n        const filter = isInvitation\n            ? `invitation=${encodeURIComponent(value)}`\n            : `content.venue=${encodeURIComponent(value)}`;\n        const path = `/notes?${filter}&limit=${limit}&offset=${offset}`;\n        const json = await openreviewFetch(path, `openreview venue ${value}`);\n        const notes = Array.isArray(json?.notes) ? json.notes : [];\n        if (!notes.length) {\n            const hint = isInvitation\n                ? 'Check the invitation id (e.g. \"ICLR.cc/2025/Conference/-/Submission\").'\n                : 'Try a venue text like \"ICLR 2024 oral\" or pass a full invitation id.';\n            throw new EmptyResultError('openreview', `No papers found at venue \"${value}\". ${hint}`);\n        }\n        return notes.slice(0, limit).map((note, i) => {\n            const row = noteToRow(note);","sourceCodeStart":13,"sourceCodeEnd":49,"githubUrl":"https://github.com/jackwener/OpenCLI/blob/49907e53dc3ade5c223ff0c4c2c2785687cec4e6/clis/openreview/venue.js#L13-L49","documentation":"The venue command's func validates args.venue itself (it has no default) and throws ArgumentError when the trimmed value is empty. An empty venue would generate an API query with no filter, which is never intended.","triggerScenarios":"Running the venue command without the venue argument, or with '' / whitespace only.","commonSituations":"User ran the venue command with no argument; shell variable holding the venue name is empty; quoting mistake passed an empty string (e.g. venue \"\").","solutions":["Provide a venue text like 'ICLR 2024 oral' or a full invitation id like 'ICLR.cc/2025/Conference/-/Submission'.","Check quoting so the argument is not swallowed by the shell.","See the command's help for the venue argument."],"exampleFix":"// before\ncli venue \"$VENUE\"\n// after\ncli venue \"${VENUE:?venue text or invitation id required}\"","handlingStrategy":"validation","validationCode":"const venue = String(process.argv[3] ?? '').trim();\nif (!venue) { console.error('usage: cli venue <venue-text-or-invitation-id>'); process.exit(2); }","typeGuard":"const hasVenue = (v) => typeof v === 'string' && v.trim().length > 0;","tryCatchPattern":"try { await venueCmd(args); } catch (e) { if (e instanceof ArgumentError) { console.error(e.message); process.exit(2); } throw e; }","preventionTips":["Quote the venue argument so shells do not drop it.","Require the variable with ${VENUE:?} in scripts.","Provide venue text or a full invitation id, never an empty string."],"tags":["validation","argument-error","missing-argument"],"backgroundTag":"missing-required-argument","analyzedSha":"49907e53dc3ade5c223ff0c4c2c2785687cec4e6","analyzedAt":"2026-08-29T08:14:47.543Z","schemaVersion":2},"datasetVersion":"2026-08-29T12:17:43.993Z"}