Skip to content

WA-VERIFY-101: Audit deprecated File.exists?/Dir.exists? usage (Ruby 3.x) #1104

@kitcommerce

Description

@kitcommerce

Summary

Audit for deprecated File.exists? / Dir.exists? usage (Ruby 3.x compatibility). These are deprecated in favor of exist?.

Approach

Run detection:

cd /Users/Shared/openclaw/projects/workarea-modernization/repos/workarea
rg -n "\\b(File|Dir)\\.exists\\?\\b" core admin storefront | head -n 200

Objective

  • Confirm Workarea does not call deprecated *.exists? methods.
  • If present, replace with exist?.

Client Impact

None expected (behavior should remain equivalent).

Acceptance Criteria

  • All File.exists? / Dir.exists? call sites audited
  • Deprecated calls replaced with exist?
  • Add/adjust tests if any edge-case behavior is affected

Verification Plan

  • Run targeted tests.
  • Re-run detection and confirm no remaining matches.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions