Repository Analysis

TencentCloud/CubeSandbox

Instant, Concurrent, Secure & Lightweight Sandbox for AI Agents.

5.3 Low AI signal View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of TencentCloud/CubeSandbox, a Rust project with 10,120 GitHub stars. SynthScan v2.0 examined 597,496 lines of code across 2282 source files, recording 1815 pattern matches distributed across 23 syntactic categories. The overall adjusted score of 5.3 places this repository in the Low AI signal band.

The scanner applied 160+ deterministic lexical heuristics, multi-line block detectors, abstract syntax tree depth profilers, and a cross-file Jaccard similarity matrix to construct a statistically normalised synthetic code estimate. All matches are individually weighted by severity coefficient and contextual multiplier before summation, and the resulting headline score is temporally discounted to account for the repository's development history relative to the commercial emergence of large language model coding tooling (November 2022 onward).

5.3
Adjusted Score
5.3
Raw Score
100%
Time Factor
2026-07-14
Last Push
10.1K
Stars
Rust
Language
597.5K
Lines of Code
2.3K
Files
1.8K
Pattern Hits
2026-07-14
Scan Date
0.01
HC Hit Rate

What These Metrics Mean

Adjusted Score
Primary synthetic code indicator. Raw score normalised per 1,000 lines of code and multiplied by the temporal discount factor. This is the definitive comparative metric — use it to rank repositories by AI authorship density.
Raw Score
The unmodified sum of all severity-weighted, context-multiplied pattern match scores before temporal discounting. Reflects the absolute signal strength independent of when the repository was last active.
Time Factor
The temporal discount multiplier (0–100%) applied to the raw score. Repositories last updated before ChatGPT's launch (Nov 2022) receive a 5% factor. Full signal is only assigned to repositories active in the post-adoption era (Jan 2024+).
Pattern Hits
Total count of individual pattern matches across all files and categories. A high hit count with a low score may indicate a very large codebase with isolated AI snippets; a low count with a high score indicates dense, concentrated AI signatures.
HC Hit Rate
High+Critical pattern hits per file, averaged across the repository. This orthogonal signal catches repositories where a few files are densely packed with high-severity AI tells — a strong indicator even when the normalised score appears moderate due to codebase size.
Lines of Code / Files
Total lines and files analysed. The scanner examines 94 file extensions. These denominators are used to normalise the score, enabling fair comparison between repositories of vastly different sizes.

Score History

This chart maps the temporal evolution of the adjusted synthetic code score across successive scan runs. An upward trajectory indicates ongoing incorporation of AI-generated code or expanding LLM-assisted scaffolding; a stable or declining trajectory may reflect active human refactoring, code removal, or the adoption of stricter authorship policies. The dashed secondary line (right axis) independently tracks total raw pattern hit count, which can diverge from the normalised score when codebase size changes significantly between scans.

Severity Breakdown

Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.

CRITICAL 0HIGH 27MEDIUM 642LOW 1146

Directory Score Breakdown

This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.

Pattern Findings

The scanner identified 1815 distinct pattern matches across 23 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.

Reading the findings table: The Severity column indicates the diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.

Decorative Section Separators618 hits · 1728 pts
SeverityFileLineSnippetContext
MEDIUMcubecow/Cargo.toml58# -----------------------------------------------------------------------------COMMENT
MEDIUMcubecow/Cargo.toml60# -----------------------------------------------------------------------------COMMENT
MEDIUMweb/src/hooks/useGlobalHotkeys.ts31 // ── ⌘K / Ctrl+K → Command Palette ──────────────────────────────COMMENT
MEDIUMweb/src/hooks/useGlobalHotkeys.ts38 // ── Escape → Close Palette ──────────────────────────────────────COMMENT
MEDIUMweb/src/hooks/useGlobalHotkeys.ts44 // ── Skip remaining shortcuts when focus is in an input ──────────COMMENT
MEDIUMweb/src/hooks/useGlobalHotkeys.ts47 // ── R → Refetch all active queries ──────────────────────────────COMMENT
MEDIUMweb/src/hooks/useGlobalHotkeys.ts55 // ── ? → Settings / Shortcuts ────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Settings.tsx21// ── Sidebar nav ───────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Settings.tsx57// ── Section: Appearance ───────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Settings.tsx128// ── Section: Cluster ──────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Settings.tsx214// ── Section: Account ──────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Settings.tsx327// ── Section: Shortcuts ────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Settings.tsx375// ── Section: About ────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Settings.tsx421// ── Shared primitives ─────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Settings.tsx449// ── Page ──────────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Templates.tsx18// ── create template modal ────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Templates.tsx504// ── delete confirm modal ────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Templates.tsx565// ── main page ────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/NodeDetail.tsx13// ── Resource bar ──────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/NodeDetail.tsx30// ── KPI card ──────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/NodeDetail.tsx66// ── Section wrapper ───────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/NodeDetail.tsx80// ── Stat row ──────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/NodeDetail.tsx91// ── Condition row ─────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/NodeDetail.tsx115// ── Main page ─────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Versions.tsx25// ── Types ───────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Versions.tsx101// ── Page ────────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Versions.tsx259// ── KPI card ────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Versions.tsx293// ── Components section ──────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Versions.tsx491// ── Node × Component matrix ─────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Versions.tsx690// ── Shared primitives ───────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/SandboxDetail.tsx19// ── Log level colors ────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/SandboxDetail.tsx33// ── Main page ───────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/SandboxDetail.tsx40 // ── Sandbox detail ──────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/SandboxDetail.tsx48 // ── Logs ────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/SandboxDetail.tsx68 // ── Lifecycle mutations ─────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/SandboxDetail.tsx255// ── Helpers ─────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Observability.tsx19// ── Shared primitives ─────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Observability.tsx46// ── Section 1: Sandbox Health ─────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Observability.tsx150// ── Section 2: Node Health ────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Observability.tsx245// ── Section 3: API Monitor ────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Observability.tsx317// ── Section 4: Template Build Status ─────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/Observability.tsx402// ── Page ──────────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/SandboxNew.tsx17// ── Types ────────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/SandboxNew.tsx32// ── Template selector card ───────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/SandboxNew.tsx107// ── KV metadata editor ───────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/SandboxNew.tsx161// ── Section wrapper ──────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/SandboxNew.tsx174// ── Main page ────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateStore.tsx20// ── helpers ───────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateStore.tsx47// ── InstallModal ──────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateStore.tsx259// ── InstalledDropdown ─────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateStore.tsx372// ── StoreCard ─────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateStore.tsx470// ── main page ─────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateDetail.tsx18// ── status helpers ────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateDetail.tsx79// ── copy button ───────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateDetail.tsx99// ── field ─────────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateDetail.tsx119// ── copy tooltip wrapper ─────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateDetail.tsx143// ── section (borderless) ──────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateDetail.tsx159// ── monoblock ─────────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateDetail.tsx185// ── progress bar ──────────────────────────────────────────────────────────────COMMENT
MEDIUMweb/src/pages/TemplateDetail.tsx198// ── log viewer ────────────────────────────────────────────────────────────────COMMENT
558 more matches not shown…
Over-Commented Block641 hits · 620 pts
SeverityFileLineSnippetContext
LOWdocker/cube-entrypoint.sh1#!/bin/shCOMMENT
LOWCubeEgress/start.sh81COMMENT
LOWCubeEgress/scripts/cube-proxy-iptables-init.sh1#!/usr/bin/env bashCOMMENT
LOWcubecow/Cargo.toml41COMMENT
LOWcubecow/Cargo.toml61# We intentionally avoid `criterion` to keep the dependency tree slim; theCOMMENT
LOWcubecow/include/cubecow.h41/* Opaque handle types */COMMENT
LOWcubecow/examples/go-test/main.go1// Copyright (c) 2026 Tencent Inc.COMMENT
LOWcubecow/examples/go-test/main.go21// backwards compatibility withCOMMENT
LOWcubecow/examples/go-test/main.go41 "os"COMMENT
LOWcubecow/examples/go-test/main.go81 defaultSnapshotName = "go-test-snap"COMMENT
LOWcubecow/examples/go-test/cubecow/cubecow.h41COMMENT
LOWcubecow/benches/reflink_ops.rs1// Copyright (c) 2026 Tencent Inc.COMMENT
LOWcubecow/benches/reflink_ops.rs21// 3. **Multi-worker concurrent fanout** — M workers create M·NCOMMENT
LOWcubecow/benches/reflink_ops.rs41// Hand-rolled p50/p90/p99 (no criterion) keeps the dependency treeCOMMENT
LOWcubecow/benches/reflink_ops.rs61// in scenario 4 (default 1 MiB).COMMENT
LOWcubecow/benches/reflink_ops.rs161}COMMENT
LOWcubecow/benches/reflink_ops.rs181 /// only inside `Drop` once the engine has been moved out.COMMENT
LOWcubecow/benches/reflink_ops.rs421 // Numerical Recipes constants. Bottom bits are well-mixed for ourCOMMENT
LOWcubecow/benches/reflink_ops.rs481COMMENT
LOWcubecow/benches/reflink_ops.rs541/// p50/p99 over all `threads * per_worker` samples *and* aCOMMENT
LOWcubecow/benches/reflink_ops.rs681COMMENT
LOWcubecow/src/lib.rs1// Copyright (c) 2026 Tencent Inc.COMMENT
LOWcubecow/src/lib.rs41pub struct Volume {COMMENT
LOWcubecow/src/lib.rs61 /// This is the **canonical identifier** for a snapshot across theCOMMENT
LOWcubecow/src/ffi.rs1// Copyright (c) 2026 Tencent Inc.COMMENT
LOWcubecow/src/ffi.rs321/// After this call, the engine pointer is invalid and must not be used.COMMENT
LOWcubecow/src/ffi.rs381/// Free a string allocated by cubecow FFI functions.COMMENT
LOWcubecow/src/ffi.rs521///COMMENT
LOWcubecow/src/ffi.rs581COMMENT
LOWcubecow/src/ffi.rs621 Ok(Err(code)) => code,COMMENT
LOWcubecow/src/ffi.rs721/// node. `out_device_path` receives the path of the resulting node.COMMENT
LOWcubecow/src/ffi.rs741/// - `cubecow_list_snapshots` to enumerate (the entry will appear withCOMMENT
LOWcubecow/src/ffi.rs801/// Idempotent.COMMENT
LOWcubecow/src/ffi.rs841 }COMMENT
LOWcubecow/src/config/mod.rs1// Copyright (c) 2026 Tencent Inc.COMMENT
LOWcubecow/src/config/mod.rs21 /// shipping backend at the moment, but the [`BackendConfig`] blockCOMMENT
LOWcubecow/src/config/mod.rs41}COMMENT
LOWcubecow/src/config/mod.rs81 #[default]COMMENT
LOWcubecow/src/engine/reflink.rs1// Copyright (c) 2026 Tencent Inc.COMMENT
LOWcubecow/src/engine/reflink.rs21// owns the `volumes/` subtree:COMMENT
LOWcubecow/src/engine/reflink.rs81///COMMENT
LOWcubecow/src/engine/reflink.rs101enum NameKind {COMMENT
LOWcubecow/src/engine/reflink.rs121 /// `initialize`; mutated under a single writer lock thereafter.COMMENT
LOWcubecow/src/engine/reflink.rs441COMMENT
LOWcubecow/src/engine/reflink.rs541 // Match dm-thin's contract: `get_volume_info` is the one-shotCOMMENT
LOWcubecow/src/engine/reflink.rs1101}COMMENT
LOWcubecow/src/engine/mod.rs1// Copyright (c) 2026 Tencent Inc.COMMENT
LOWcubecow/src/engine/mod.rs21use crate::{Snapshot, Volume, VolumeBlockInfo};COMMENT
LOWcubecow/src/pkg/mod.rs1// Copyright (c) 2026 Tencent Inc.COMMENT
LOWcubecow/src/pkg/metrics/mod.rs1// Copyright (c) 2026 Tencent Inc.COMMENT
LOWcubecow/src/pkg/metrics/mod.rs21/// Total number of active snapshotsCOMMENT
LOWcubecow/src/pkg/logger/mod.rs1// Copyright (c) 2026 Tencent Inc.COMMENT
LOWcubecow/src/pkg/errors/mod.rs1// Copyright (c) 2026 Tencent Inc.COMMENT
LOWnetwork-agent/internal/cubeegress/client.go81 }COMMENT
LOWnetwork-agent/internal/cubeegress/wire.go1// Copyright (c) 2026 Tencent Inc.COMMENT
LOWnetwork-agent/internal/cubeegress/wire.go21// snake_case. The renderer is the single point that bridges the twoCOMMENT
LOWnetwork-agent/internal/cubeegress/wire.go81// CubeEgress's PUT /admin/v1/policies/<sandbox_ip> expects.COMMENT
LOWnetwork-agent/internal/service/local_service.go381COMMENT
LOWnetwork-agent/internal/service/local_service.go461 }COMMENT
LOWnetwork-agent/internal/service/tap_lifecycle.go261// full rationale.COMMENT
581 more matches not shown…
Structural Annotation Overuse90 hits · 172 pts
SeverityFileLineSnippetContext
LOWcubecow/examples/go-test/main.go374 // Step 1: Create volumeCOMMENT
LOWcubecow/examples/go-test/main.go377 // Step 2: Get volume infoCOMMENT
LOWcubecow/examples/go-test/main.go380 // Step 3: Get volume block infoCOMMENT
LOWcubecow/examples/go-test/main.go383 // Step 4: Resize volumeCOMMENT
LOWcubecow/examples/go-test/main.go386 // Step 5: Create snapshotCOMMENT
LOWcubecow/examples/go-test/main.go389 // Step 6: List snapshotsCOMMENT
LOWcubecow/examples/go-test/main.go392 // Step 7: List volumesCOMMENT
LOWcubecow/examples/go-test/main.go395 // Step 8: Get metricsCOMMENT
LOWcubecow/examples/go-test/main.go398 // Step 9: Cleanup - delete snapshot then volume (unless -no-cleanup)COMMENT
LOWdeploy/one-click/terraform/tencentcloud/create.sh2783# Step 1: terraform initCOMMENT
LOWdeploy/one-click/terraform/tencentcloud/create.sh2816# Step 2: terraform apply (with retry logic)COMMENT
LOWdeploy/one-click/terraform/tencentcloud/create.sh3300# Step 6: Replace with the CubeSandbox kernelCOMMENT
LOWdeploy/one-click/terraform/tencentcloud/create.sh3514# Step 7: Reboot the CVM and verify the new kernelCOMMENT
LOWdeploy/one-click/terraform/tencentcloud/create.sh3669# Step 8: Initialize all compute nodes (purchased sequentially in step 3)COMMENT
LOW…services/cubebox/snapshot_base_memory_fallback_test.go210 // Step 1: Create-restore from tpl-T sets BOTH bindings.COMMENT
LOW…services/cubebox/snapshot_base_memory_fallback_test.go216 // Step 2: Commit A advances the runtime-snapshot binding only.COMMENT
LOW…services/cubebox/snapshot_base_memory_fallback_test.go222 // Step 3: Commit B — same invariant.COMMENT
LOW…services/cubebox/snapshot_base_memory_fallback_test.go227 // Step 4: Rollback to A: rollback restarts the VM, so it bumps BOTH.COMMENT
LOW…services/cubebox/snapshot_base_memory_fallback_test.go233 // Step 5: Commit C after rollback — runtime-snapshot advances; theCOMMENT
LOWdocs/guide/dev-environment.md45### Step 1: Prepare the image (one-off)COMMENT
LOWdocs/guide/dev-environment.md57### Step 2: Boot the VMCOMMENT
LOWdocs/guide/dev-environment.md68### Step 3: Log in (in a new terminal)COMMENT
LOWdocs/guide/bare-metal-deploy.md29## Step 1: InstallCOMMENT
LOWdocs/guide/bare-metal-deploy.md73## Step 2: Create a TemplateCOMMENT
LOWdocs/guide/bare-metal-deploy.md102## Step 3: Run Your First Agent CodeCOMMENT
LOWdocs/guide/quickstart.md47## Step 1: Provision a Cloud Server & Install the PVM KernelCOMMENT
LOWdocs/guide/quickstart.md170## Step 2: InstallCOMMENT
LOWdocs/guide/quickstart.md198## Step 3: Create a TemplateCOMMENT
LOWdocs/guide/quickstart.md231## Step 4: Run Your First Agent CodeCOMMENT
LOWdocs/guide/multi-node-deploy.md46## Step 1: Prepare the Release BundleCOMMENT
LOWdocs/guide/multi-node-deploy.md55## Step 2: Configure Environment VariablesCOMMENT
LOWdocs/guide/multi-node-deploy.md83## Step 3: InstallCOMMENT
LOWdocs/guide/pvm-deploy.md43## Step 0: Provision a Cloud ServerCOMMENT
LOWdocs/guide/pvm-deploy.md55## Step 1: Install the PVM Host KernelCOMMENT
LOWdocs/guide/pvm-deploy.md154## Step 2: Install Cube Sandbox with PVM EnabledCOMMENT
LOWdocs/guide/pvm-deploy.md216## Step 3: Verify the PVM EnvironmentCOMMENT
LOWdocs/guide/pvm-deploy.md230## Step 4: Create a Template and Get StartedCOMMENT
LOWdocs/guide/self-build-deploy.md53## Step 1: Build the Release BundleCOMMENT
LOWdocs/guide/self-build-deploy.md103## Step 2: Deploy to the Target MachineCOMMENT
LOW…s/blog/posts/2026-06-03-cubesandbox-v0.3.0-snapshot.md137# Step 1: take a base snapshot in the v0 stateCOMMENT
LOW…s/blog/posts/2026-06-03-cubesandbox-v0.3.0-snapshot.md144# Step 2: spin up a new sandbox from the base snapshotCOMMENT
LOW…s/blog/posts/2026-06-03-cubesandbox-v0.3.0-snapshot.md148# Step 3: write v1 and drop a checkpointCOMMENT
LOW…s/blog/posts/2026-06-03-cubesandbox-v0.3.0-snapshot.md154# Step 4: write v2 and confirm it landedCOMMENT
LOW…s/blog/posts/2026-06-03-cubesandbox-v0.3.0-snapshot.md161# Step 5: roll back to the v1 checkpointCOMMENT
LOW…s/blog/posts/2026-06-03-cubesandbox-v0.3.0-snapshot.md165# Step 6: verify state is restored to v1 (sandbox_id unchanged)COMMENT
LOWdocs/blog/posts/2026-07-08-cubesandbox-arm-support.md94### Step 1: Download and installCOMMENT
LOWdocs/blog/posts/2026-07-08-cubesandbox-arm-support.md117### Step 2: Deployment verification & environment variablesCOMMENT
LOWdocs/blog/posts/2026-07-08-cubesandbox-arm-support.md130### Step 3: Spin up your first sandboxCOMMENT
LOW…h/blog/posts/2026-06-03-cubesandbox-v0.3.0-snapshot.md137# Step 1: 在 v0 状态创建一个基础快照COMMENT
LOW…h/blog/posts/2026-06-03-cubesandbox-v0.3.0-snapshot.md144# Step 2: 从基础快照拉起一个新沙箱COMMENT
LOW…h/blog/posts/2026-06-03-cubesandbox-v0.3.0-snapshot.md148# Step 3: 写入 v1,打一个 checkpointCOMMENT
LOW…h/blog/posts/2026-06-03-cubesandbox-v0.3.0-snapshot.md154# Step 4: 写入 v2,确认已生效COMMENT
LOW…h/blog/posts/2026-06-03-cubesandbox-v0.3.0-snapshot.md161# Step 5: 回滚到 v1 这个 checkpointCOMMENT
LOW…h/blog/posts/2026-06-03-cubesandbox-v0.3.0-snapshot.md165# Step 6: 验证状态已恢复为 v1(sandbox_id 保持不变)COMMENT
LOWCubeAPI/src/handlers/agenthub.rs2597 // Step 1: a plain restart is enough for transient failures.COMMENT
LOWCubeAPI/src/handlers/agenthub.rs2613 // Step 2: restart failed — roll back to the latest known-healthy snapshot.COMMENT
LOWCubeMaster/pkg/templatecenter/image/native.go146 // Step 1: Concurrently prefetch layers to disk to maximize network throughput.COMMENT
LOWCubeMaster/pkg/templatecenter/image/native.go245 // Step 2: Sequentially apply and immediately delete layers as they finish downloading.COMMENT
LOW…eMaster/pkg/base/dao/migrate/migrate_alignment_test.go96 // Step 1: table set — catches missing tables like runtime_active quickly.COMMENT
LOWexamples/mini-rl-training/README.md18### Step 1: Install DependenciesCOMMENT
30 more matches not shown…
Hyper-Verbose Identifiers159 hits · 112 pts
SeverityFileLineSnippetContext
LOWweb/src/lib/templateConfig.ts55export function extractTemplateRuntimeConfig(cr: unknown): TemplateRuntimeConfig | null {CODE
LOWweb/src/lib/templateConfig.ts73export function extractTemplateNetworkPolicy(cr: unknown): TemplateNetworkPolicy {CODE
LOWweb/src/pages/Versions.tsx63function stripPlatformVersionSuffix(version: string): string {CODE
LOWCubelet/scripts/cubebox_appsnapshot.py61def get_cubebox_snapshot_spec(cubebox_id):CODE
LOWCubelet/scripts/cubebox_appsnapshot.py109def gen_cubebox_appsnapshot_cmd(cubebox_id, spec, snapshot_path, cube_runtime_path=None):CODE
LOWsdk/python/cubesandbox/_policy.py332def _validate_allow_out_domains_require_deny_all(CODE
LOWsdk/python/cubesandbox/_policy.py347def _is_domain_allow_out_target(target: object) -> bool:CODE
LOWsdk/python/cubesandbox/_policy.py371def _is_dotted_decimal_like_target(target: str) -> bool:CODE
LOWsdk/python/cubesandbox/_policy.py376def _is_valid_dns_domain_name(domain: str) -> bool:CODE
LOWsdk/python/cubesandbox/_commands.py119 def _run_with_connect_fallback(CODE
LOWsdk/python/cubesandbox/_commands.py169def _envd_rpc_base_url_and_headers(sandbox: "Sandbox") -> tuple[str, dict[str, str]]:CODE
LOWsdk/python/cubesandbox/_commands.py211def _parse_process_start_stream(chunks) -> CommandResult:CODE
LOWsdk/python/cubesandbox/_commands.py269def _raise_connect_end_stream(raw: bytes) -> None:CODE
LOWsdk/python/cubesandbox/_commands.py324def _exit_code_from_end_event(end) -> int | None:CODE
LOWsdk/python/tests/test_template_e2e.py57def test_template_list_and_get_existing_template(pytestconfig: pytest.Config) -> None:CODE
LOWsdk/python/tests/test_template_e2e.py75def test_template_create_from_image_and_cleanup(pytestconfig: pytest.Config) -> None:CODE
LOWsdk/python/tests/test_sandbox.py95 def test_create_missing_template_raises(self):CODE
LOWsdk/python/tests/test_sandbox.py100 def test_create_sends_template_and_timeout(self):CODE
LOWsdk/python/tests/test_sandbox.py107 def test_create_omits_timeout_when_absent(self):CODE
LOWsdk/python/tests/test_sandbox.py115 def test_create_sends_explicit_zero_timeout(self):CODE
LOWsdk/python/tests/test_sandbox.py122 def test_create_sends_never_timeout(self):CODE
LOWsdk/python/tests/test_sandbox.py131 def test_create_sends_env_vars(self):CODE
LOWsdk/python/tests/test_sandbox.py137 def test_create_sends_metadata(self):CODE
LOWsdk/python/tests/test_sandbox.py144 def test_create_template_not_found(self):CODE
LOWsdk/python/tests/test_sandbox.py156 def test_create_allow_internet_access_false(self):CODE
LOWsdk/python/tests/test_sandbox.py162 def test_create_allow_internet_access_true_not_in_payload(self):CODE
LOWsdk/python/tests/test_sandbox.py168 def test_create_network_allow_out(self):CODE
LOWsdk/python/tests/test_sandbox.py174 def test_create_network_deny_out(self):CODE
LOWsdk/python/tests/test_sandbox.py180 def test_create_network_empty_not_in_payload(self):CODE
LOWsdk/python/tests/test_sandbox.py186 def test_create_default_lifecycle_omitted(self):CODE
LOWsdk/python/tests/test_sandbox.py281 def test_create_network_allow_out_accepts_wildcard_domain_target(self, domain):CODE
LOWsdk/python/tests/test_sandbox.py288 def test_create_network_allow_out_preserves_mixed_domain_and_cidr_targets(self):CODE
LOWsdk/python/tests/test_sandbox.py293 def test_create_network_allow_out_preserves_order_and_duplicates(self):CODE
LOWsdk/python/tests/test_sandbox.py298 def test_create_network_domain_filtering_preserves_literal_domain_values(self):CODE
LOWsdk/python/tests/test_sandbox.py303 def test_create_network_domain_filtering_with_deny_all_mode(self):CODE
LOWsdk/python/tests/test_sandbox.py313 def test_create_network_domain_filtering_rejects_without_deny_all(self):CODE
LOWsdk/python/tests/test_sandbox.py321 def test_create_network_domain_filtering_accepts_deny_all_among_other_deny_out(self):CODE
LOWsdk/python/tests/test_sandbox.py352 def test_create_network_empty_allow_out_is_still_sent(self):CODE
LOWsdk/python/tests/test_sandbox.py360 def test_create_network_rules_dataclass(self):CODE
LOWsdk/python/tests/test_sandbox.py453 def test_match_to_wire_omits_none_fields(self):CODE
LOWsdk/python/tests/test_sandbox.py459 def test_action_to_wire_omits_none_inject_and_audit(self):CODE
LOWsdk/python/tests/test_sandbox.py582 def test_rejects_non_dict_transform(self):CODE
LOWsdk/python/tests/test_sandbox.py589 def test_rejects_missing_headers(self):CODE
LOWsdk/python/tests/test_sandbox.py596 def test_rejects_unsupported_transform_keys(self):CODE
LOWsdk/python/tests/test_sandbox.py608 def test_rejects_non_string_header_value(self):CODE
LOWsdk/python/tests/test_sandbox.py617 def test_rejects_unsupported_entry_keys(self):CODE
LOWsdk/python/tests/test_sandbox.py626 def test_rejects_non_list_entries(self):CODE
LOWsdk/python/tests/test_sandbox.py751 def test_context_manager_kills_on_exit(self):CODE
LOWsdk/python/tests/test_sandbox.py759 def test_context_manager_suppresses_kill_error(self):CODE
LOWsdk/python/tests/test_sandbox.py814 def test_resume_omits_timeout_by_default(self):CODE
LOWsdk/python/tests/test_sandbox.py824 def test_resume_explicit_zero_is_sent(self):CODE
LOWsdk/python/tests/test_sandbox.py833 def test_resume_sends_never_timeout(self):CODE
LOWsdk/python/tests/test_sandbox.py862 def test_set_timeout_sends_explicit_zero(self):CODE
LOWsdk/python/tests/test_sandbox.py868 def test_set_timeout_sends_never_timeout(self):CODE
LOWsdk/python/tests/test_sandbox.py875 def test_set_timeout_not_found(self):CODE
LOWsdk/python/tests/test_sandbox.py890 def test_get_host_custom_port(self):CODE
LOWsdk/python/tests/test_sandbox.py894 def test_domain_fallback_to_config(self):CODE
LOWsdk/python/tests/test_sandbox.py910 def test_text_returns_main_result(self):CODE
LOWsdk/python/tests/test_sandbox.py917 def test_text_none_when_no_results(self):CODE
LOWsdk/python/tests/test_sandbox.py920 def test_text_none_when_no_main(self):CODE
99 more matches not shown…
Excessive Try-Catch Wrapping89 hits · 100 pts
SeverityFileLineSnippetContext
LOWCubelet/scripts/cubebox_appsnapshot.py43 except Exception:CODE
LOWCubelet/scripts/cubebox_appsnapshot.py90 except Exception as e:CODE
LOWCubelet/scripts/cubebox_appsnapshot.py176 except Exception as e:CODE
LOWCubeAPI/examples/benchmark.py550 except Exception as exc:CODE
LOWCubeAPI/examples/benchmark.py566 except Exception as exc:CODE
LOWCubeAPI/examples/benchmark.py633 except Exception as exc:CODE
LOWCubeAPI/examples/test.py52 except Exception:CODE
LOWCubeAPI/examples/test.py59 except Exception:CODE
LOWCubeAPI/examples/test.py65 except Exception:CODE
LOWCubeAPI/examples/test.py76 except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs2721 except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs2730 except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs2734 except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs2744 except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs2790except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs2984except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs3059except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs3514 except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs3523 except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs3527 except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs3537 except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs3580except Exception:CODE
LOWCubeAPI/src/handlers/agenthub.rs3636except Exception:CODE
LOWsdk/python/cubesandbox/_filesystem.py294 except Exception: # noqa: BLE001CODE
MEDIUMsdk/python/cubesandbox/_filesystem.py263def _read_frame(self) -> WatchEvent | None | object:CODE
LOWsdk/python/cubesandbox/_pty.py121 except Exception:CODE
LOWsdk/python/cubesandbox/_pty.py154 except Exception:CODE
LOWsdk/python/cubesandbox/_pty.py449 except Exception:CODE
LOWsdk/python/cubesandbox/_pty.py513 except Exception:CODE
LOWsdk/python/cubesandbox/_pty.py547 except Exception:CODE
MEDIUMsdk/python/cubesandbox/_pty.py105def _handle_events(self) -> Generator[PtyOutput, None, None]:CODE
LOWsdk/python/cubesandbox/_template.py21 except Exception:CODE
LOWsdk/python/cubesandbox/sandbox.py37 except Exception:CODE
LOWsdk/python/cubesandbox/sandbox.py518 except Exception:CODE
LOWsdk/python/cubesandbox/sandbox.py663 except Exception: # noqa: BLE001 — best-effortCODE
LOWsdk/python/cubesandbox/sandbox.py672 except Exception: # noqa: BLE001CODE
LOWsdk/python/cubesandbox/sandbox.py759 except Exception: # noqa: BLE001 — best-effort cleanupCODE
LOWsdk/python/cubesandbox/sandbox.py771 except Exception: # noqa: BLE001 — best-effort cleanupCODE
MEDIUMsdk/python/cubesandbox/sandbox.py515def __del__(self) -> None:CODE
LOWsdk/python/cubesandbox/_commands.py292 except Exception:CODE
LOWsdk/python/tests/integration_test_sdk.py249 except Exception:CODE
LOWsdk/python/tests/integration_test_sdk.py267 except Exception:CODE
MEDIUMsdk/python/tests/integration_test_sdk.py245def collect():CODE
LOWexamples/pi-agent-integration/resume_pi_agent.py213 except Exception as exc: # noqa: BLE001 - cleanup must not mask real errorsCODE
LOWexamples/pi-agent-integration/network_policy.py237 except Exception as exc: # noqa: BLE001 - cleanup must not mask real errorsCODE
LOW…raining/mini-swe-agent-patch/environments/extra/e2b.py232 except Exception as e:CODE
LOW…raining/mini-swe-agent-patch/environments/extra/e2b.py400 except Exception as e:CODE
LOW…raining/mini-swe-agent-patch/environments/extra/e2b.py449 except Exception as e:CODE
LOW…aining/mini-swe-agent-patch/run/benchmarks/swebench.py176 except Exception as e:CODE
LOW…aining/mini-swe-agent-patch/run/benchmarks/swebench.py276 except Exception as e:CODE
LOWexamples/mini-rl-training/scripts/run-concurrent.py490 except Exception:CODE
LOWexamples/mini-rl-training/scripts/run-concurrent.py176 except Exception:CODE
LOWexamples/mini-rl-training/scripts/run-concurrent.py476 except Exception as e:CODE
LOWexamples/mini-rl-training/scripts/run-concurrent.py648 except Exception as e:CODE
LOWexamples/mini-rl-training/scripts/run-concurrent.py703 except Exception as e:CODE
LOWexamples/openai-agents-example/simple_demo.py269 except Exception as e:CODE
LOWexamples/openai-agents-example/main.py119 except Exception as e:CODE
LOWexamples/openai-agents-example/main.py149 except Exception as e:CODE
LOWexamples/openai-agents-example/main.py302 except Exception as e:CODE
LOWexamples/openai-agents-example/main.py376 except Exception as e:CODE
29 more matches not shown…
Verbosity Indicators45 hits · 91 pts
SeverityFileLineSnippetContext
LOWcubecow/examples/go-test/main.go374 // Step 1: Create volumeCOMMENT
LOWcubecow/examples/go-test/main.go377 // Step 2: Get volume infoCOMMENT
LOWcubecow/examples/go-test/main.go380 // Step 3: Get volume block infoCOMMENT
LOWcubecow/examples/go-test/main.go383 // Step 4: Resize volumeCOMMENT
LOWcubecow/examples/go-test/main.go386 // Step 5: Create snapshotCOMMENT
LOWcubecow/examples/go-test/main.go389 // Step 6: List snapshotsCOMMENT
LOWcubecow/examples/go-test/main.go392 // Step 7: List volumesCOMMENT
LOWcubecow/examples/go-test/main.go395 // Step 8: Get metricsCOMMENT
LOWcubecow/examples/go-test/main.go398 // Step 9: Cleanup - delete snapshot then volume (unless -no-cleanup)COMMENT
LOWdeploy/one-click/terraform/tencentcloud/create.sh2783# Step 1: terraform initCOMMENT
LOWdeploy/one-click/terraform/tencentcloud/create.sh2816# Step 2: terraform apply (with retry logic)COMMENT
LOWdeploy/one-click/terraform/tencentcloud/create.sh3300# Step 6: Replace with the CubeSandbox kernelCOMMENT
LOWdeploy/one-click/terraform/tencentcloud/create.sh3514# Step 7: Reboot the CVM and verify the new kernelCOMMENT
LOWdeploy/one-click/terraform/tencentcloud/create.sh3669# Step 8: Initialize all compute nodes (purchased sequentially in step 3)COMMENT
LOW…services/cubebox/snapshot_base_memory_fallback_test.go210 // Step 1: Create-restore from tpl-T sets BOTH bindings.COMMENT
LOW…services/cubebox/snapshot_base_memory_fallback_test.go216 // Step 2: Commit A advances the runtime-snapshot binding only.COMMENT
LOW…services/cubebox/snapshot_base_memory_fallback_test.go222 // Step 3: Commit B — same invariant.COMMENT
LOW…services/cubebox/snapshot_base_memory_fallback_test.go227 // Step 4: Rollback to A: rollback restarts the VM, so it bumps BOTH.COMMENT
LOW…services/cubebox/snapshot_base_memory_fallback_test.go233 // Step 5: Commit C after rollback — runtime-snapshot advances; theCOMMENT
LOWCubeAPI/src/handlers/agenthub.rs2597 // Step 1: a plain restart is enough for transient failures.COMMENT
LOWCubeAPI/src/handlers/agenthub.rs2613 // Step 2: restart failed — roll back to the latest known-healthy snapshot.COMMENT
LOWCubeMaster/pkg/templatecenter/image/native.go146 // Step 1: Concurrently prefetch layers to disk to maximize network throughput.COMMENT
LOWCubeMaster/pkg/templatecenter/image/native.go245 // Step 2: Sequentially apply and immediately delete layers as they finish downloading.COMMENT
LOW…eMaster/pkg/base/dao/migrate/migrate_alignment_test.go96 // Step 1: table set — catches missing tables like runtime_active quickly.COMMENT
LOWexamples/openai-agents-example/simple_demo.py216 # Step 1: Create sandbox and write a marker fileCOMMENT
LOWexamples/openai-agents-example/simple_demo.py236 # Step 3: Pause (stop + shutdown with pause_on_exit=True)COMMENT
LOWexamples/openai-agents-example/simple_demo.py244 # Step 4: ResumeCOMMENT
LOWexamples/openai-agents-example/simple_demo.py251 # Step 5: Verify marker file persistsCOMMENT
LOWexamples/snapshot-rollback-clone/rollback_demo.py18# Step 1: create a base snapshotCOMMENT
LOWexamples/snapshot-rollback-clone/rollback_demo.py25# Step 2: spin up a sandbox from the base snapshotCOMMENT
LOWexamples/snapshot-rollback-clone/rollback_demo.py29 # Step 3: write v1 to both disk and tmpfs, take a checkpointCOMMENT
LOWexamples/snapshot-rollback-clone/rollback_demo.py35 # Step 4: write v2, verify it stuck on bothCOMMENT
LOWexamples/snapshot-rollback-clone/rollback_demo.py42 # Step 5: rollback to the v1 checkpointCOMMENT
LOWexamples/snapshot-rollback-clone/rollback_demo.py46 # Step 6: verify both disk and tmpfs restored to v1COMMENT
LOWexamples/snapshot-rollback-clone/09_rollback.py17# Step 1: create a base snapshot at v0COMMENT
LOWexamples/snapshot-rollback-clone/09_rollback.py24# Step 2: spin up a sandbox from the base snapshotCOMMENT
LOWexamples/snapshot-rollback-clone/09_rollback.py28# Step 3: write v1, take a checkpointCOMMENT
LOWexamples/snapshot-rollback-clone/09_rollback.py34# Step 4: write v2, confirm it stuckCOMMENT
LOWexamples/snapshot-rollback-clone/09_rollback.py41# Step 5: rollback to the v1 checkpointCOMMENT
LOWexamples/snapshot-rollback-clone/09_rollback.py45# Step 6: verify state is v1COMMENT
LOWhypervisor/scripts/run_integration_tests_x86_64.sh242 # Step 1: Priority 1 - Boot & Lifecycle (parallel)COMMENT
LOWhypervisor/scripts/run_integration_tests_x86_64.sh249 # Step 2: Priority 2 - Core I/O Devices (parallel)COMMENT
LOWhypervisor/scripts/run_integration_tests_x86_64.sh258 # Step 3: Priority 3 - Hotplug (parallel)COMMENT
LOWhypervisor/scripts/run_integration_tests_x86_64.sh267 # Step 4: Priority 4 - Snapshot & Live Migration (parallel + sequential)COMMENT
LOWhypervisor/scripts/run_integration_tests_x86_64.sh279 # Step 5: Priority 5 - VMM Instance API (lib mode, sequential)COMMENT
Cross-File Repetition14 hits · 70 pts
SeverityFileLineSnippetContext
HIGHexamples/host-mount/env_utils.py0best-effort load of a nearby .env file without overriding real env vars.STRING
HIGHexamples/route-aware-egress/env_utils.py0best-effort load of a nearby .env file without overriding real env vars.STRING
HIGHexamples/pi-agent-integration/env_utils.py0best-effort load of a nearby .env file without overriding real env vars.STRING
HIGHexamples/network-policy/env_utils.py0best-effort load of a nearby .env file without overriding real env vars.STRING
HIGHexamples/code-sandbox-quickstart/env_utils.py0best-effort load of a nearby .env file without overriding real env vars.STRING
HIGHexamples/code-sandbox-quickstart/auto-kill.py0\ import hashlib data = "cube sandbox pause/resume demo" hash_val = hashlib.sha256(data.encode()).hexdigest()[:16] pi_apSTRING
HIGHexamples/code-sandbox-quickstart/auto-resume.py0\ import hashlib data = "cube sandbox pause/resume demo" hash_val = hashlib.sha256(data.encode()).hexdigest()[:16] pi_apSTRING
HIGHexamples/code-sandbox-quickstart/pause.py0\ import hashlib data = "cube sandbox pause/resume demo" hash_val = hashlib.sha256(data.encode()).hexdigest()[:16] pi_apSTRING
HIGHexamples/code-sandbox-quickstart/auto-kill.py0on_stdout may deliver multi-line blobs; normalize to individual lines.STRING
HIGHexamples/code-sandbox-quickstart/auto-resume.py0on_stdout may deliver multi-line blobs; normalize to individual lines.STRING
HIGHexamples/code-sandbox-quickstart/pause.py0on_stdout may deliver multi-line blobs; normalize to individual lines.STRING
HIGHexamples/code-sandbox-quickstart/auto-kill.py0extract value from 'key = value' formatted output line.STRING
HIGHexamples/code-sandbox-quickstart/auto-resume.py0extract value from 'key = value' formatted output line.STRING
HIGHexamples/code-sandbox-quickstart/pause.py0extract value from 'key = value' formatted output line.STRING
Unused Imports67 hits · 60 pts
SeverityFileLineSnippetContext
LOWCubeAPI/examples/benchmark.py26CODE
LOWCubeAPI/examples/list.py4CODE
LOWsdk/python/cubesandbox/_filesystem.py4CODE
LOWsdk/python/cubesandbox/_filesystem.py19CODE
LOWsdk/python/cubesandbox/__init__.py4CODE
LOWsdk/python/cubesandbox/__init__.py4CODE
LOWsdk/python/cubesandbox/__init__.py5CODE
LOWsdk/python/cubesandbox/__init__.py6CODE
LOWsdk/python/cubesandbox/__init__.py6CODE
LOWsdk/python/cubesandbox/__init__.py6CODE
LOWsdk/python/cubesandbox/__init__.py6CODE
LOWsdk/python/cubesandbox/__init__.py6CODE
LOWsdk/python/cubesandbox/__init__.py6CODE
LOWsdk/python/cubesandbox/__init__.py7CODE
LOWsdk/python/cubesandbox/__init__.py7CODE
LOWsdk/python/cubesandbox/__init__.py7CODE
LOWsdk/python/cubesandbox/__init__.py7CODE
LOWsdk/python/cubesandbox/__init__.py7CODE
LOWsdk/python/cubesandbox/__init__.py7CODE
LOWsdk/python/cubesandbox/__init__.py8CODE
LOWsdk/python/cubesandbox/__init__.py9CODE
LOWsdk/python/cubesandbox/__init__.py9CODE
LOWsdk/python/cubesandbox/__init__.py9CODE
LOWsdk/python/cubesandbox/__init__.py9CODE
LOWsdk/python/cubesandbox/__init__.py10CODE
LOWsdk/python/cubesandbox/__init__.py10CODE
LOWsdk/python/cubesandbox/__init__.py10CODE
LOWsdk/python/cubesandbox/__init__.py11CODE
LOWsdk/python/cubesandbox/__init__.py11CODE
LOWsdk/python/cubesandbox/__init__.py11CODE
LOWsdk/python/cubesandbox/__init__.py11CODE
LOWsdk/python/cubesandbox/_transport.py4CODE
LOWsdk/python/cubesandbox/_pty.py14CODE
LOWsdk/python/cubesandbox/_pty.py39CODE
LOWsdk/python/cubesandbox/_stream.py4CODE
LOWsdk/python/cubesandbox/_template.py4CODE
LOWsdk/python/cubesandbox/sandbox.py4CODE
LOWsdk/python/cubesandbox/sandbox.py11CODE
LOWsdk/python/cubesandbox/sandbox.py16CODE
LOWsdk/python/cubesandbox/_policy.py13CODE
LOWsdk/python/cubesandbox/_models.py4CODE
LOWsdk/python/cubesandbox/_config.py4CODE
LOWsdk/python/cubesandbox/_commands.py4CODE
LOWsdk/python/cubesandbox/_commands.py14CODE
LOWsdk/python/cubesandbox/_exceptions.py4CODE
LOWsdk/python/tests/conftest.py4CODE
LOWsdk/python/tests/integration_test_sdk.py14CODE
LOWsdk/python/tests/integration_test_sdk.py16CODE
LOWsdk/python/tests/test_template_e2e.py9CODE
LOWsdk/python/tests/test_sandbox.py10CODE
LOWsdk/python/tests/test_sandbox.py26CODE
LOWsdk/python/tests/test_sandbox.py26CODE
LOWexamples/pi-agent-integration/_pi_common.py12CODE
LOWexamples/pi-agent-integration/resume_pi_agent.py17CODE
LOWexamples/pi-agent-integration/env_utils.py4CODE
LOWexamples/pi-agent-integration/run_pi_agent.py5CODE
LOWexamples/pi-agent-integration/network_policy.py21CODE
LOWexamples/mini-rl-training/scripts/run-concurrent.py25CODE
LOWexamples/mini-rl-training/scripts/run-concurrent.py38CODE
LOWexamples/mini-rl-training/scripts/run-concurrent.py939CODE
7 more matches not shown…
Docstring Block Structure9 hits · 45 pts
SeverityFileLineSnippetContext
HIGHsdk/python/cubesandbox/_template.py150GET /templates — List all templates. Args: config: SDK config. Uses default (env-based) config if STRING
HIGHsdk/python/cubesandbox/_template.py181GET /templates/:templateID — Get a template and its build history. Args: template_id: Template idenSTRING
HIGHsdk/python/cubesandbox/_template.py238POST /templates - Build (create) a new template from an image. Submits CubeAPI's create-from-image request and STRING
HIGHsdk/python/cubesandbox/sandbox.py158POST /sandboxes - Create a new sandbox. Args: template: Template ID. Falls back to ``CUBE_TEMPLATE_STRING
HIGHsdk/python/cubesandbox/sandbox.py255POST /sandboxes/:sandboxID/connect - Connect to an existing sandbox. Resumes the sandbox if it is currently pauSTRING
HIGHsdk/python/cubesandbox/sandbox.py345POST /execute - Execute code inside the sandbox. Streams the ndjson response from the sandbox's envd process viSTRING
HIGHsdk/python/cubesandbox/sandbox.py526POST /sandboxes/:sandboxID/snapshots — Create a snapshot (1.1). The sandbox is temporarily paused during snapshSTRING
HIGHsdk/python/cubesandbox/sandbox.py615POST /sandboxes/:sandboxID/rollback — Roll back a sandbox to a snapshot (1.5). Reverts the sandbox's filesystemSTRING
HIGHsdk/python/cubesandbox/sandbox.py677Clone this sandbox *n* times (1.6). Internally this executes three steps: 1. :meth:`create_snapshot` —STRING
AI Slop Vocabulary9 hits · 26 pts
SeverityFileLineSnippetContext
MEDIUMcubecow/benches/reflink_ops.rs236 // we name it explicitly so the recipe is robust to defaultCOMMENT
MEDIUMdeploy/pvm/pvm_setup.sh80# is more robust and is a no-op on RPM distributions.COMMENT
MEDIUMdeploy/one-click/terraform/tencentcloud/validate.sh103 # keep this robust across checkout layouts. Gate on errors so genuine bugsCOMMENT
MEDIUMdeploy/one-click/terraform/tencentcloud/create.sh359 # fall through to auto-detect / prompt so re-runs stay robust.COMMENT
MEDIUMdocs/package-lock.json3401 "resolved": "https://registry.npmjs.org/robust-predicates/-/robust-predicates-3.0.3.tgz",CODE
MEDIUMdev-env/internal/setup_selinux.sh53# most robust fix is to flip SELinux to permissive mode. We do it bothCOMMENT
MEDIUMCubeMaster/pkg/templatecenter/image/disk.go147 // set explicitly to be robust); --numeric-owner avoids name lookupsCOMMENT
MEDIUMCubeMaster/pkg/templatecenter/image/native.go147 // Temp directory is created in destDir's workspace to utilize the same fast disk.COMMENT
LOWexamples/openai-agents-example/main.py18 python main.py --sandbox-only # just create & destroy sandboxSTRING
Example Usage Blocks14 hits · 21 pts
SeverityFileLineSnippetContext
LOWCubeEgress/scripts/cube-proxy-iptables-init.sh17# Usage:COMMENT
LOWdeploy/one-click/scripts/cube-diag/collect-logs.sh21# Usage:COMMENT
LOWdeploy/one-click/scripts/cube-diag/cube-check.sh18# Usage:COMMENT
LOWdeploy/one-click/scripts/cube-diag/check-procs.sh18# Usage:COMMENT
LOWdev-env/run_vm.sh18# Usage:COMMENT
LOWdev-env/prepare_image.sh19# Usage:COMMENT
LOWdev-env/cube-autostart.sh18# Usage:COMMENT
LOWdev-env/login.sh11# Usage:COMMENT
LOWdev-env/copy_logs.sh12# Usage:COMMENT
LOWCubeAPI/scripts/test-cube-api.sh4# Usage:COMMENT
LOWCubeMaster/scripts/redis_key_migrate.sh4# Usage:COMMENT
LOWscripts/bump-image.sh14# Usage:COMMENT
LOWscripts/new-migration.sh12# Usage:COMMENT
LOWscripts/gh.sh7# Usage:COMMENT
Self-Referential Comments7 hits · 20 pts
SeverityFileLineSnippetContext
MEDIUMdeploy/pvm/common.sh3# This file is sourced by build-pvm-host-kernel-pkg.sh andCOMMENT
MEDIUMdeploy/one-click/terraform/tencentcloud/main.tf519# Create the database (via the jumpserver)COMMENT
MEDIUMdeploy/one-click/terraform/tencentcloud/lib-phases.sh21# This file is sourced by create.sh (and by the test). It must not run anythingCOMMENT
MEDIUMdeploy/one-click/terraform/tencentcloud/create.sh5270 # Create the MySQL instance (+ cube account/privilege + the applicationCOMMENT
MEDIUMdeploy/one-click/scripts/common/validation.sh5# This file is sourced by callers that already define die().COMMENT
MEDIUMdeploy/one-click/lib/common.sh3# This file is a sourced library. Do not set shell options here: entrypointCOMMENT
MEDIUMscripts/new-migration.sh5# Create a new CubeMaster MySQL migration with a UTC timestamp version prefix.COMMENT
Deep Nesting16 hits · 14 pts
SeverityFileLineSnippetContext
LOWCubeAPI/examples/benchmark.py611CODE
LOWsdk/python/cubesandbox/_pty.py464CODE
LOWsdk/python/cubesandbox/_stream.py15CODE
LOWsdk/python/cubesandbox/sandbox.py676CODE
LOWsdk/python/cubesandbox/_commands.py185CODE
LOWsdk/python/cubesandbox/_commands.py211CODE
LOWexamples/pi-agent-integration/_pi_common.py38CODE
LOW…raining/mini-swe-agent-patch/environments/extra/e2b.py195CODE
LOW…aining/mini-swe-agent-patch/run/benchmarks/swebench.py227CODE
LOWexamples/mini-rl-training/scripts/run-concurrent.py669CODE
LOWexamples/mini-rl-training/scripts/run-concurrent.py730CODE
LOWexamples/openai-agents-example/main.py399CODE
LOWexamples/openai-agents-example/main.py444CODE
LOWexamples/e2b-dev-sidecar/dev_sidecar.py180CODE
LOWexamples/e2b-dev-sidecar/dev_sidecar.py198CODE
LOW…ai-agents-code-interpreter/code_interpreter_demo_ci.py519CODE
Magic Placeholder Names2 hits · 10 pts
SeverityFileLineSnippetContext
HIGHexamples/mini-rl-training/README.md48E2B_API_KEY="<your-api-key>"CODE
HIGHexamples/mini-rl-training/README_zh.md46E2B_API_KEY="<your-api-key>"CODE
Redundant / Tautological Comments7 hits · 10 pts
SeverityFileLineSnippetContext
LOWdeploy/one-click/install.sh601 # Check if the user has explicitly opted to skip this check.COMMENT
LOWdeploy/one-click/online-install.sh191 # Check if the closest existing parent directory is writable by root (detects read-only mounts)COMMENT
LOWdeploy/one-click/terraform/tencentcloud/create.sh2699 # Set TENCENTCLOUD_COMPUTE_INSTANCE_TYPE to choose explicitly.COMMENT
LOWagent/bootstrap.sh3# Check if the user is running this script as rootCOMMENT
LOW…visor/scripts/run_integration_tests_windows_aarch64.sh33# Check if the images are presentCOMMENT
LOW…rvisor/scripts/run_integration_tests_windows_x86_64.sh33# Check if the images are presentCOMMENT
LOWhypervisor/scripts/run_integration_tests_aarch64.sh220# Check if there is any error in the execution of `update_workloads`.COMMENT
Modern AI Meta-Vocabulary4 hits · 8 pts
SeverityFileLineSnippetContext
MEDIUMdocs/guide/self-build-deploy.md358│ ├── bin/network-agent # Network orchestration serviceCODE
MEDIUMdocs/guide/usecases/trpc-agent-go.md17[trpc-agent-go](https://github.com/trpc-group/trpc-agent-go) is Tencent's open-source Go framework for building productiCODE
MEDIUMdocs/changelog/v0.4.0.md56- **Artifact management** (#506): A new job runner orchestrates the full pipeline (image export → rootfs artifact build CODE
MEDIUMdocs/changelog/v0.3.0.md54- **Docker Compose container lifecycle** (#386): Container lifecycle management migrated to Docker Compose, simplifying CODE
Cross-Language Confusion1 hit · 8 pts
SeverityFileLineSnippetContext
HIGHexamples/openai-agents-example/main.py381 result = await session.exec("uname -a && cat /etc/os-release | head -3")CODE
AI Response Leakage1 hit · 8 pts
SeverityFileLineSnippetContext
HIGHhypervisor/virtio-devices/src/vsock/csm/connection.rs57// receiving peer's behavior is undefined. In this implementation, we forcefully terminateCOMMENT
Fake / Example Data6 hits · 6 pts
SeverityFileLineSnippetContext
LOWweb/src/locales/zh/command.json3 "placeholder": "搜索或输入命令…",CODE
LOWweb/src/locales/en/command.json3 "placeholder": "Search or type a command…",CODE
LOWweb/src/components/CommandPalette.tsx45 placeholder={t('placeholder')}CODE
LOWweb/src/i18n/index.ts20 ns: ['common', 'nav', 'topbar', 'command', 'overview', 'sandboxes', 'sandboxDetail', 'sandboxNew', 'templates', 'temCODE
LOWweb/src/pages/Placeholder.tsx10type PlaceholderKey = ParseKeys<'placeholder'>;CODE
LOWweb/src/pages/Placeholder.tsx21 const { t } = useTranslation('placeholder');CODE
Slop Phrases4 hits · 6 pts
SeverityFileLineSnippetContext
LOWhypervisor/vmm/src/vm.rs1303 // Don't forget to set the terminal in canonical modeCOMMENT
LOWhypervisor/virtiofsd/src/passthrough/mod.rs1370 // a new option here, don't forget to add it there, too, and handle it both inCOMMENT
LOWhypervisor/src/lib.rs354 // Don't forget to set the terminal in canonical modeCOMMENT
LOWhypervisor/src/main.rs770 // Don't forget to set the terminal in canonical modeCOMMENT
Modern Structural Boilerplate5 hits · 6 pts
SeverityFileLineSnippetContext
LOWsdk/python/cubesandbox/_filesystem.py11logger = logging.getLogger(__name__)CODE
LOWsdk/python/cubesandbox/__init__.py13__all__ = [CODE
LOWsdk/python/cubesandbox/_stream.py12logger = logging.getLogger(__name__)CODE
LOWsdk/python/cubesandbox/sandbox.py457 def set_timeout(self, timeout: int) -> None:CODE
LOWexamples/mini-rl-training/scripts/run-concurrent.py499def _update_preds(path: Path, instance_id: str, model_name: str, patch: str) -> None:CODE
AI Structural Patterns5 hits · 5 pts
SeverityFileLineSnippetContext
LOWCubelet/scripts/cubebox_appsnapshot.py106CODE
LOWsdk/python/cubesandbox/_template.py209CODE
LOWsdk/python/cubesandbox/sandbox.py145CODE
LOWsdk/python/cubesandbox/_models.py61CODE
LOW…aining/mini-swe-agent-patch/run/benchmarks/swebench.py227CODE
Overly Generic Function Names2 hits · 2 pts
SeverityFileLineSnippetContext
LOWweb/public/mockServiceWorker.js124async function handleRequest(event, requestId, requestInterceptedAt) {CODE
LOWsdk/python/cubesandbox/_transport.py25 def handle_request(self, request: httpx.Request) -> httpx.Response:CODE