{"record":{"id":"23f77ed6a2c3b07e","repo":"pcottle/learnGitBranching","slug":"generalargs-0-is-not-a-remote-in-your-rep","errorCode":null,"errorMessage":"' + generalArgs[0] + ' is not a remote in your repository! try adding origin to that argument","messagePattern":"' \\+ generalArgs\\[0\\] \\+ ' is not a remote in your repository! try adding origin to that argument","errorType":"exception","errorClass":"GitError","httpStatus":null,"severity":"error","filePath":"src/js/git/commands.js","lineNumber":92,"sourceCode":"  assertIsRef(engine, ref);\n  var obj = engine.resolveID(ref);\n\n  if (obj.get('type') !== 'branch' ||\n      !obj.getIsRemote()) {\n    throw new GitError({\n      msg: intl.todo(\n        ref + ' is not a remote branch'\n      )\n    });\n  }\n};\n\nvar assertOriginSpecified = function(generalArgs) {\n  if (!generalArgs.length) {\n    return;\n  }\n  if (generalArgs[0] !== 'origin') {\n    throw new GitError({\n      msg: intl.todo(\n        generalArgs[0] + ' is not a remote in your repository! try adding origin to that argument'\n      )\n    });\n  }\n};\n\nvar assertBranchIsRemoteTracking = function(engine, branchName) {\n  branchName = crappyUnescape(branchName);\n  if (!engine.resolveID(branchName)) {\n    throw new GitError({\n      msg: intl.todo(branchName + ' is not a branch!')\n    });\n  }\n  var branch = engine.resolveID(branchName);\n  if (branch.get('type') !== 'branch') {\n    throw new GitError({\n      msg: intl.todo(branchName + ' is not a branch!')","sourceCodeStart":74,"sourceCodeEnd":110,"githubUrl":"https://github.com/pcottle/learnGitBranching/blob/5b09d0ff9678cad164f5a7488a279a44f90d7256/src/js/git/commands.js#L74-L110","documentation":"assertOriginSpecified throws when an optional first argument is present but is not the literal 'origin'. The simulation only models a single remote named origin, so any other remote name is rejected.","triggerScenarios":"Commands like fetch/pull/push/fakeTeamwork with a first general arg such as 'upstream' or 'github' instead of 'origin' (or omitted entirely is fine).","commonSituations":"Translating real-world muscle memory (git pull upstream main) into the simulator; typos like 'orgin'.","solutions":["Use 'origin' or omit the remote argument","Re-check your input: only origin is supported in this app"],"exampleFix":"// before\ngit fetch upstream\n// after\ngit fetch origin","handlingStrategy":"validation","validationCode":"if (args.length && args[0] !== 'origin') { args[0] = 'origin'; /* or reject */ }","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Normalize the remote token to 'origin' before dispatch","Remember only origin exists in this simulation"],"tags":["git","remote","simulation-limit"],"backgroundTag":"unknown-remote-name","analyzedSha":"5b09d0ff9678cad164f5a7488a279a44f90d7256","analyzedAt":"2026-08-27T13:53:49.057Z","schemaVersion":2},"datasetVersion":"2026-08-27T19:17:21.184Z"}