{"record":{"id":"5b5775e06ff518bb","repo":"dotnet/runtime","slug":"no-jit-changes-found-starting-with-baseline-hash-5b5775","errorCode":null,"errorMessage":"No JIT changes found starting with baseline hash","messagePattern":"No JIT changes found starting with baseline hash","errorType":"exception","errorClass":"RuntimeError","httpStatus":null,"severity":"error","filePath":"src/coreclr/scripts/superpmi.py","lineNumber":4913,"sourceCode":"            logging.info(\"Baseline hash: %s\", baseline_hash)\n        else:\n            baseline_hash = coreclr_args.base_git_hash\n\n        if coreclr_args.base_git_hash is None:\n            # Enumerate the last 20 changes, starting with the baseline, that included JIT and JIT-EE GUID changes.\n            command = [ \"git\", \"log\", \"--pretty=format:%H\", baseline_hash, \"-20\", \"--\", \"src/coreclr/jit/*\", \"src/coreclr/inc/jiteeversionguid.h\" ]\n            logging.debug(\"Invoking: %s\", \" \".join(command))\n            proc = subprocess.Popen(command, stdout=subprocess.PIPE)\n            stdout_change_list, _ = proc.communicate()\n            return_code = proc.returncode\n            change_list_hashes = []\n            if return_code == 0:\n                change_list_hashes = stdout_change_list.decode('utf-8').strip().splitlines()\n            else:\n                raise RuntimeError(\"Couldn't determine list of JIT changes starting with baseline hash\")\n\n            if len(change_list_hashes) == 0:\n                raise RuntimeError(\"No JIT changes found starting with baseline hash\")\n        else:\n            # If `-base_git_hash` is specified, then we use exactly that hash and no other for the baseline.\n            change_list_hashes = [ coreclr_args.base_git_hash ]\n\n        # For each hash, (1) see if we have the JIT already, and if not (2) try to download the corresponding JIT from the rolling build.\n\n        hashnum = 1\n        for git_hash in change_list_hashes:\n            logging.debug(\"%s: %s\", hashnum, git_hash)\n\n            jit_name = get_jit_name(coreclr_args)\n            basejit_dir = os.path.join(default_basejit_root_dir, \"{}.{}.{}.{}\".format(git_hash, coreclr_args.host_os, coreclr_args.arch, coreclr_args.build_type))\n            basejit_path = os.path.join(basejit_dir, jit_name)\n            if os.path.isfile(basejit_path):\n                # We found this baseline JIT in our cache; use it!\n                coreclr_args.base_jit_path = basejit_path\n                logging.info(\"Using baseline %s\", coreclr_args.base_jit_path)\n                return","sourceCodeStart":4895,"sourceCodeEnd":4931,"githubUrl":"https://github.com/dotnet/runtime/blob/290d5ab72cc1102813fbc0406fb186ceadabc340/src/coreclr/scripts/superpmi.py#L4895-L4931","documentation":"Raised by get_baseline_jit when `git log` for JIT changes succeeds but returns zero commits. With no JIT-EE GUID change in the last 20 commits back from the baseline, there is no candidate hash to download a baseline JIT for.","triggerScenarios":"The current branch is at or near the merge-base with origin/main and the last 20 commits in src/coreclr/jit/* or jiteeversionguid.h all predate the baseline window, or the pathspec matches nothing.","commonSituations":"Running diffs on a branch with no JIT changes since the last main sync; freshly merged main so baseline==HEAD; running in a worktree where the JIT pathspec was renamed.","solutions":["If you expect a change, verify `git log --oneline -20 -- src/coreclr/jit/` actually lists commits.","Supply `--base_git_hash <commit>` to force a specific baseline.","Make at least one JIT-EE GUID-affecting commit, or confirm you intentionally have nothing to diff (no-op case).","Ensure the working branch is ahead of the merge-base with real JIT edits."],"exampleFix":"// before\n# branch has no JIT changes since main -> raises [184]\n// after\npython superpmi.py --base_git_hash <older-commit-with-jit-changes> ...","handlingStrategy":"validation","validationCode":"import subprocess\nout = subprocess.run(['git','log','--pretty=format:%H',baseline_hash,'-20','--','src/coreclr/jit/*','src/coreclr/inc/jiteeversionguid.h'], cwd=runtime_repo_location, capture_output=True, text=True)\nif out.returncode == 0 and not out.stdout.strip():\n    raise SystemExit('no JIT changes since baseline; nothing to diff — pass --base_git_hash for an older baseline')","typeGuard":"def has_jit_changes_since(baseline: str, cwd: str) -> bool:\n    import subprocess\n    out = subprocess.run(['git','log','--pretty=format:%H',baseline,'-20','--','src/coreclr/jit/*'], cwd=cwd, capture_output=True, text=True)\n    return out.returncode == 0 and bool(out.stdout.strip())","tryCatchPattern":"try:\n    main(...)\nexcept RuntimeError as e:\n    if 'No JIT changes found' in str(e):\n        # pick an older known-JIT baseline explicitly\n        main_with(base_git_hash=older_jit_commit)","preventionTips":["Only diff branches actually ahead of main on JIT code","Pass --base_git_hash for reproducible baselines","Pre-check `git log -- src/coreclr/jit/`"],"tags":["git","superpmi","configuration"],"analyzedSha":"290d5ab72cc1102813fbc0406fb186ceadabc340","analyzedAt":"2026-08-06T19:57:01.276Z","schemaVersion":2},"datasetVersion":"2026-08-06T23:17:07.152Z"}