Skip to content

[v4 GUI] TypeError: Cannot read properties of undefined (reading 'toLowerCase') crashes app immediately after loading almost any folder or session #1

Description

@wonnami

This report concerns the v4 GUI application ("Docs par Archifiltre"), not the new v5 CLI tool in this repository.

Environment

OS Architecture App Version Result
macOS (M1 Max) arm64 v4.2.1 Crash
macOS (M1 Max) x64 (Rosetta) v4.2.1 Crash
macOS (M1 Max) arm64 v4.1.2 Crash
macOS (M1 Max) x64 (Rosetta) v4.1.2 Crash
macOS (M2) v4.2.1 Crash
Windows 11 v4.2.1 Crash

Description

The app crashes to a generic "Something went wrong." error screen almost immediately after a folder scan or session load completes (sometimes after the audit report generation succeeds, sometimes with no user interaction at all). Reproduced across multiple machines, app versions, and CPU architectures.

Error message
TypeError: Cannot read properties of undefined (reading 'toLowerCase')

Likely source location

Based on reviewing the v4.2.1 source, this matches getFileTypeFromFileName in src/renderer/utils/file-types.ts:

const extName = path.extname(fileName.toLowerCase()); // fileName appears to be undefined here

Called automatically after loading from:

  • src/renderer/exporters/audit/audit-report-values-computer.ts
  • src/renderer/utils/duplicates.ts
  • src/renderer/utils/color.ts

Steps to reproduce

  1. Scan any folder (tested with genuine source data and minimal single-file test folders — folder content does not appear to matter)
  2. Wait for loading / audit report generation to complete
  3. App crashes, either automatically or after clicking the "Audit report is ready" notification

What we ruled out

  • App version (v4.1.2, v4.2.1)
  • CPU architecture (arm64, x64/Rosetta)
  • OS (macOS, Windows 11)
  • Folder content (single genuine file, empty test folder)
  • Full Disk Access / permissions on macOS
  • Clean reinstall (removing Application Support, Preferences, Caches)

Attached
Session JSON captured just before a crash, showing a well-formed filesAndFolders structure with no missing name fields.

crash-session-example.json

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions