stubs(ROOT): add SetMaxTheta, nrOfDP, IsEqual, mnstat#1256
Conversation
Three real PyROOT/ROOT methods used in-tree but missing from the hand-curated stubs: * Pythia8Generator.SetMaxTheta and .nrOfDP — actually defined on the C++ base SHiP::Generator (SetMaxTheta in shipgen/Generator.h:51) and DPPythia8Generator (nrOfDP in shipgen/DPPythia8Generator.h:88). Hoisting both to the Pythia8Generator stub means HNLPythia8Generator and DPPythia8Generator inherit them transparently, matching the PyROOT-exposed behaviour. * TH1.IsEqual — bin-content comparison used by python/experimental/compare_histograms.py. * TMinuit.mnstat — fit-status accessor used by python/shipVertex.py for migrad-convergence reporting. Drops 3 pyrefly missing-attribute errors (128 → 125).
|
Warning Review limit reached
More reviews will be available in 58 minutes and 22 seconds. Learn how PR review limits work. Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file). ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based credits. 🚦 How do rate limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan refill rate. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, the refill rate gradually slows as usage increases. The highest same-day bursts are limited more strictly. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Per-site narrowing for the residual NoneType / uninitialized findings: * configGenieGenerator.py — assert top.FindNode result not None * SBTDetector.py — guard self.MCdet.push_back with is not None * compare_histograms.py — bind TClass.GetClass and skip when None * convertEvtCalc.py — parse_file now returns None on error; caller bails * eventDisplay.py — DrawVetoDigi.Targetz class attr, fRun asserts, one pyrefly:ignore for tkinter Checkbutton.var dynamic attach * pythia8darkphoton_conf.py — initialise hname before the parser loop * shipStrawTracking.py — rebuild hits dict comprehension-style, guard None pos after extrapolateToPlane, lambda for dict-max key Pyrefly errors drop from 128 to 109 (19 fewer; 1 suppression). The remaining mypy attr-defined complaint on TH1.IsEqual is fixed by the companion stubs PR (#1256); mypy hook locally skipped while that lands.
CI Plots |
|
@coderabbitai rate limit |
|
Your plan includes PR reviews subject to rate limits. More reviews will be available in 27 minutes and 17 seconds. |
|
@coderabbitai review |
✅ Action performedReview finished.
|











































































































































Summary
Three real PyROOT/ROOT methods used in-tree but missing from the hand-curated stubs:
Pythia8Generator.SetMaxThetamacro/run_simScript.py:618SHiP::Generator(shipgen/Generator.h:51); hoist toPythia8Generatorstub soHNLPythia8Generator/DPPythia8GeneratorinheritPythia8Generator.nrOfDPmacro/run_simScript.py:986DPPythia8Generator(shipgen/DPPythia8Generator.h:88); base stub keeps subclass call sites typedTH1.IsEqualpython/experimental/compare_histograms.py:17TMinuit.mnstatpython/shipVertex.py:286Test plan
pyrefly check --output-format=full-text python macrodrops from 128 → 125 errorsSetMaxThetasite is aNoneTypenarrowing (will be resolved by PR-D2)Surface-minimal per the stubs file's own guidance.