← Back to Pull requests

chore: use a global func instead of the core-tools devDependency #521

Closed
unknown closed this pull request without merging on Nov 25, 2026 09:14 UTC
View on GitHub
unknown unknown commented on Nov 25, 2026 07:38 UTC
Author

Why

azure-functions-core-tools was a devDependency of packages/functions. Its postinstall downloads about 1.5 GB of Functions host binaries into node_modules/azure-functions-core-tools/bin, which is about half of every checkout and every agent worktree (3.2 GB of node_modules each). None of it ships: CI installs with --ignore-scripts, and the deploy package installs with --omit=dev.

What changed

  • packages/functions/package.json: removed the devDependency. start (func start) and pack (func pack) now use the func on PATH.

  • scripts/dev-preflight.mjs: new --func check, used by npm run dev and npm run dev:functions. It fails with install steps when func is missing or older than 4.16 (the minimum the old devDependency required).

  • Docs: the root README prerequisites, the functions README and the CLAUDE.md dev notes now say to install func globally (brew tap azure/functions && brew install azure-functions-core-tools@4, or npm i -g azure-functions-core-tools@4 on other platforms). The deploy.yml comments no longer mention the removed package.

  • package-lock.json: core-tools and its 29 transitive packages are gone. The lockfile also picks up the exact eslint-config-next: 16.4.3 spec that apps/web/package.json already pins.
  • Verification

  • A clean npm ci gives 1.6 GB of node_modules, down from 3.2 GB.

  • Preflight with --func: fails with no func on PATH, fails with 4.12.0 ("too old"), passes with 4.17.0. Without the flag the result is unchanged.

  • The pre-push hook passed: unit tests in every workspace, the web production build and the functions build.

  • Started the host with a Homebrew func 4.17.0 (func start --port 7099 from packages/functions). All 93 HTTP routes registered, and GET /api/config/flags returned 200.
  • After merge

    Each developer needs a global func of version 4.16 or later. Existing checkouts lose the 1.5 GB folder on the next npm ci / npm run setup.

    🤖 Generated with Claude Code

    <!-- This is an auto-generated comment: release notes by coderabbit.ai -->
    <!-- coderabbit-ai-generated:v1 -->

    Summary by CodeRabbit

    Documentation
    Updated setup instructions to require Azure Functions Core Tools v4.16 or later, with installation guidance for macOS and other platforms.
    Clarified that Core Tools must be installed separately from npm dependencies.

    Bug Fixes
    * Development commands now check that Core Tools is installed and meets the minimum version requirement, and provide installation guidance if it is missing or outdated.
    <!-- end of auto-generated comment: release notes by coderabbit.ai -->

    Diff: 338 lines (+253 / -85) across 4 files Reviewer: mattmck Review duration: 95m
    All Vouch review confidence checks passed
    Residual risk 0.19 = Change Risk (0.47) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.47 · 338 lines diff across 4 files
    0.47
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.349
    Shallow Review Depth shallow_review_depth
    0.289
    Ai Authored ai_authored
    0.050
    Real PR Conversation Timeline
    1 comments
    "Review active on #521"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 47.2% (MEDIUM) · Higher = larger blast radius
    47.2%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 18.7% · Safe to merge
    18.7%