qishibo/AnotherRedisDesktopManager · error

${vue.$t('message.key_no_permission')}\n[${e.message}]

Error message

${vue.$t('message.key_no_permission')}\n[${e.message}]

What it means

getFileContent (src/redisClient.js) wraps fs.readFileSync in try/catch and converts any read failure - EACCES, ENOENT, sandbox denial - into a forced alert with the localized 'no permission' text, then emits closeConnection. On the Mac App Store build the file must also be reachable through a security-scoped bookmark (startAccessingSecurityScopedResource); without a valid bookmark the sandbox denies the read and lands here.

Source

Thrown at src/redisClient.js:374

  getFileContent(file, bookmark = '') {
    if (!file) {
      return undefined;
    }

    try {
      // mac app store version, read through bookmark
      if (bookmark) {
        const bookmarkClose = remote.app.startAccessingSecurityScopedResource(bookmark);
      }

      const content = fs.readFileSync(file);
      (typeof bookmarkClose === 'function') && bookmarkClose();

      return content;
    } catch (e) {
      // force alert
      alert(`${vue.$t('message.key_no_permission')}\n[${e.message}]`);
      vue.$bus.$emit('closeConnection');

      return undefined;
    }
  },
};

View on GitHub (pinned to c149855106)

Solutions

  1. Re-select the file through the app's file dialog so a fresh security-scoped bookmark is stored, then retry.
  2. Verify the file still exists and is readable ('ls -l path', fix with chmod if needed).
  3. Use the non-MAS build (direct download or built from source), which is not sandboxed and reads paths directly.
Defensive patterns

Strategy: validation

Validate before calling

const fs = require('fs');

function canRead(file) {
  try {
    fs.accessSync(file, fs.constants.R_OK);
    return true;
  } catch {
    return false;
  }
}
if (!file || !canRead(file)) skipAndWarn(); // avoids the forced alert

Try / catch

try {
  const content = getFileContent(file, bookmark);
} catch (e) {
  // alert already forced by getFileContent; here just clean up state without re-alerting
}

Prevention

When it happens

Trigger: Mac App Store (sandboxed) build reading a file whose security-scoped bookmark is missing or stale; file deleted or moved between selection and read; OS-level permission (macOS TCC, directory ACL) denying the app; path loaded from an old config that no longer resolves.

Common situations: MAS version of the app after a file was moved/renamed; user picked a file in a protected location (Desktop/Documents under TCC); file permissions changed after the connection was created.

Related errors


AI-assisted analysis of qishibo/AnotherRedisDesktopManager@c149855106 (2026-08-22). Data as JSON: /api/errors/b0b54280608934a5. Report an issue: GitHub.