diff --git a/tests/risk_labels_heldout.json b/tests/risk_labels_heldout.json new file mode 100644 index 0000000..4086c61 --- /dev/null +++ b/tests/risk_labels_heldout.json @@ -0,0 +1,97 @@ +[ + {"path": "docs/getting-started.md", "floor": "trivial", "reason": "Plain documentation, changes no behaviour."}, + {"path": "README.md", "floor": "trivial", "reason": "Project readme, documentation only."}, + {"path": "docs/authors.md", "floor": "trivial", "reason": "A list of contributors; the name says auth but it is plain text."}, + {"path": "web/src/assets/images/hookah.png", "floor": "trivial", "reason": "Image asset, nothing executes."}, + {"path": "web/src/assets/icons/logo.svg", "floor": "trivial", "reason": "Vector image asset."}, + {"path": "web/src/styles/button.css", "floor": "trivial", "reason": "Styling only."}, + {"path": "app/static/css/theme-dark.scss", "floor": "trivial", "reason": "Dark theme colours, styling only."}, + {"path": "mobile/ios/Assets.xcassets/hero.imageset/hero@2x.png", "floor": "trivial", "reason": "Image asset for the iOS app."}, + {"path": "docs/adr/0007-caching-strategy.md", "floor": "trivial", "reason": "Decision record, documentation only."}, + {"path": "pkg/parser/README.md", "floor": "trivial", "reason": "Documentation about parsing code, not the code itself."}, + {"path": "services/ledger/docs/payments.md", "floor": "trivial", "reason": "Documentation about payments, changes no behaviour."}, + {"path": "examples/env/.env.example", "floor": "trivial", "reason": "Template with placeholder values; not read by production."}, + {"path": "LICENSE", "floor": "trivial", "reason": "Licence text."}, + {"path": "docs/glossary.txt", "floor": "trivial", "reason": "Plain text glossary."}, + + {"path": "web/src/components/locksmith/LocksmithBadge.tsx", "floor": "isolated", "reason": "A UI badge; the name is a word, not an auth feature."}, + {"path": "web/src/pages/recipes/parsley-soup.tsx", "floor": "isolated", "reason": "One recipe page component."}, + {"path": "src/helpers/payload.py", "floor": "isolated", "reason": "Generic helper, behaviour limited to its module."}, + {"path": "app/views/profile_card.html.erb", "floor": "isolated", "reason": "One view template."}, + {"path": "internal/handlers/health.go", "floor": "isolated", "reason": "Health endpoint handler, contained behaviour."}, + {"path": "src/main/java/com/acme/ui/ChartPanel.java", "floor": "isolated", "reason": "Single UI panel class."}, + {"path": "web/tests/components/navbar.test.tsx", "floor": "isolated", "reason": "Test of an ordinary component."}, + {"path": "src/cli/format_table.rs", "floor": "isolated", "reason": "Output formatting for one CLI command."}, + {"path": "lib/strings/truncate.rb", "floor": "isolated", "reason": "Simple string helper."}, + {"path": "Sources/Views/SettingsRow.swift", "floor": "isolated", "reason": "One SwiftUI row view."}, + {"path": "src/widgets/Sidebar.vue", "floor": "isolated", "reason": "One sidebar component."}, + {"path": "tests/fixtures/sample_user.json", "floor": "isolated", "reason": "Test fixture data for an ordinary test."}, + {"path": "src/utils/hookah-timer.ts", "floor": "isolated", "reason": "A countdown timer utility; the name is incidental."}, + {"path": "web/src/components/Authors/AuthorList.tsx", "floor": "isolated", "reason": "Renders a list of authors; no auth logic."}, + {"path": "src/notifications/welcome_email.py", "floor": "isolated", "reason": "Builds one email template, contained behaviour."}, + + {"path": "src/finance/rounding.py", "floor": "logic", "reason": "Money rounding rules; subtle mistakes give wrong amounts."}, + {"path": "pkg/tax/brackets.go", "floor": "logic", "reason": "Tax bracket arithmetic, a numeric rule."}, + {"path": "crates/codec/src/base64.rs", "floor": "logic", "reason": "Encoding logic with a wide input space."}, + {"path": "src/parser/expr_parser.cpp", "floor": "logic", "reason": "Expression parser; grammar edge cases matter."}, + {"path": "src/orders/state_machine.ts", "floor": "logic", "reason": "Order state machine; invalid transitions are subtle bugs."}, + {"path": "services/pricing/discount_engine.ts", "floor": "logic", "reason": "Discount calculation rules, numeric."}, + {"path": "src/main/java/com/acme/scheduling/IntervalMerger.java", "floor": "logic", "reason": "Interval merging algorithm, off-by-one prone."}, + {"path": "app/lib/currency/convert.rb", "floor": "logic", "reason": "Currency conversion arithmetic."}, + {"path": "src/parsing/csv_reader.py", "floor": "logic", "reason": "Parsing untrusted text with many edge cases."}, + {"path": "internal/scheduler/cron_expr.go", "floor": "logic", "reason": "Cron expression parser and next-time algorithm."}, + {"path": "crates/protocol/src/frame_decoder.rs", "floor": "logic", "reason": "Binary frame decoding, wide input space."}, + {"path": "src/Money.swift", "floor": "logic", "reason": "Money type arithmetic and formatting."}, + {"path": "tests/test_auth_token_parser.py", "floor": "logic", "reason": "Test of critical token parsing, so the test carries the logic floor."}, + {"path": "tests/test_migration_backfill.py", "floor": "logic", "reason": "Test of data migration code, carries the logic floor."}, + + {"path": "api/openapi.yaml", "floor": "integration", "reason": "Public API definition that clients depend on."}, + {"path": "proto/payments/v2/payments.proto", "floor": "integration", "reason": "Public service interface definition."}, + {"path": "package-lock.json", "floor": "integration", "reason": "Lockfile; third-party code changes come in here."}, + {"path": "Cargo.lock", "floor": "integration", "reason": "Lockfile pinning third-party crates."}, + {"path": "go.mod", "floor": "integration", "reason": "Dependency manifest."}, + {"path": ".github/workflows/ci.yml", "floor": "integration", "reason": "CI configuration, runs on every change."}, + {"path": "Dockerfile", "floor": "integration", "reason": "Container build configuration."}, + {"path": "vendor/github.com/google/uuid/uuid.go", "floor": "integration", "reason": "Vendored third-party code, not written here."}, + {"path": "web/tsconfig.json", "floor": "integration", "reason": "Build configuration for the front end."}, + {"path": "gradle/libs.versions.toml", "floor": "integration", "reason": "Dependency version catalogue."}, + {"path": "Makefile", "floor": "integration", "reason": "Build configuration."}, + {"path": "pyproject.toml", "floor": "integration", "reason": "Build and dependency configuration."}, + {"path": "Gemfile.lock", "floor": "integration", "reason": "Lockfile for third-party gems."}, + {"path": "api/graphql/schema.graphql", "floor": "integration", "reason": "Public GraphQL interface definition."}, + + {"path": "db/migrations/20260101_add_invoice_status.sql", "floor": "data", "reason": "Schema migration changing stored invoice shape."}, + {"path": "migrations/0042_drop_legacy_sessions.py", "floor": "data", "reason": "Migration that drops a table of stored data."}, + {"path": "db/schema.sql", "floor": "data", "reason": "Database schema definition."}, + {"path": "src/persistence/user_repository.ts", "floor": "data", "reason": "Persistence layer for user records."}, + {"path": "internal/storage/bolt_store.go", "floor": "data", "reason": "Storage layer writing to disk."}, + {"path": "app/models/order.rb", "floor": "data", "reason": "ORM model defining the stored shape of orders."}, + {"path": "src/main/java/com/acme/dao/AccountDao.java", "floor": "data", "reason": "Data access object for accounts."}, + {"path": "infra/sql/views/customer_summary.sql", "floor": "data", "reason": "Database view over stored customer data."}, + {"path": "Sources/Storage/CoreDataStack.swift", "floor": "data", "reason": "Local persistent store setup."}, + {"path": "src/db/session_store.py", "floor": "data", "reason": "Persists session records to the database."}, + {"path": "prisma/schema.prisma", "floor": "data", "reason": "Database schema source."}, + {"path": "db/seeds/reference_countries.sql", "floor": "data", "reason": "Seed rows written into stored reference data."}, + {"path": "migrations/V7__add_index_orders.sql", "floor": "data", "reason": "Migration adding an index to stored orders."}, + + {"path": "src/auth/session_token.ts", "floor": "critical", "reason": "Issues and validates session tokens."}, + {"path": "internal/authz/policy.go", "floor": "critical", "reason": "Authorisation policy decisions."}, + {"path": "crates/crypto/src/aes_gcm.rs", "floor": "critical", "reason": "Cryptographic primitive usage."}, + {"path": "src/payments/charge.py", "floor": "critical", "reason": "Moves money on a payment card."}, + {"path": "billing/stripe_webhook.rb", "floor": "critical", "reason": "Handles billing events and signature checks."}, + {"path": "src/secrets/vault_client.go", "floor": "critical", "reason": "Reads and writes secrets."}, + {"path": "scripts/install.sh", "floor": "critical", "reason": "Installer that changes the user's machine."}, + {"path": "src/concurrency/lock_free_queue.c", "floor": "critical", "reason": "Concurrency primitive, races are silent."}, + {"path": "config/shell/profile.d/10-path.sh", "floor": "critical", "reason": "Runs automatically on every login shell."}, + {"path": "web/src/lib/crypto/hash.ts", "floor": "critical", "reason": "Password hashing."}, + {"path": "src/main/java/com/acme/security/RoleChecker.java", "floor": "critical", "reason": "Role-based access check."}, + {"path": "Sources/Keychain/KeychainStore.swift", "floor": "critical", "reason": "Stores credentials in the system keychain."}, + {"path": "services/auth/passwordless/magic_link.py", "floor": "critical", "reason": "Login link generation, an authentication flow."}, + + {"path": "VERSION", "floor": "release", "reason": "Version marker file."}, + {"path": "scripts/release.sh", "floor": "release", "reason": "Release machinery."}, + {"path": ".release-please-manifest.json", "floor": "release", "reason": "Release tooling state."}, + {"path": "src/version.py", "floor": "release", "reason": "Version constant read by the package."}, + {"path": ".goreleaser.yaml", "floor": "release", "reason": "Release build and publish configuration."}, + {"path": "pkg/version/version.go", "floor": "release", "reason": "Version marker compiled into the binary."} +]