simple-ftp-deploy icon indicating copy to clipboard operation
simple-ftp-deploy copied to clipboard

ignoredFolders matches substrings of the whole absolute path; files silently never uploaded

Open dpc00 opened this issue 2 months ago • 1 comments

ignoredFolders is matched as a substring of the whole absolute path (minus extension), so files are silently never deployed.

ignored() does for folder in config.get('ignoredFolders', []): if folder in filename, where filename is os.path.splitext(fullAbsolutePath)[0] (main.py:54-56). That is neither a folder-name match nor project-relative.

Reproduced live in Sublime Text 4 with Simple FTP Deploy 1.8.1 installed via Package Control, saving real files in a real project window. To avoid needing a server, ftplib.FTP was replaced by a recording stub (the failing logic is all before/around the network calls).

Config "ignoredFolders": ["test"], project at .../ftpx/site:

  • site/css/latest.css -> silently not uploaded (no message; "test" is in the file name).
  • site/attestation/x.css -> silently not uploaded.
  • site/css/ok.css -> uploaded normally.
  • When I first ran this the project lived in a directory named .../ftptest/site: every file in the project was silently ignored, because the substring is matched against the absolute path including parent directories outside the project.

So ["build"] ignores rebuild.js and everything under C:\Users\me\builds\; [".git"] ignores .github/; ["tmp"] ignores attmpt.txt. This is probably behind the "nothing happens" reports (#2, #13).

Fix: compute the path relative to the project folder, split it into components and compare each directory component for equality (or use fnmatch on the relative path).

dpc00 avatar Sep 24 '26 16:09 dpc00

Claude reports: closing this after 30 days with no response. Reopen it if it is still relevant.

dpc00 avatar Oct 27 '26 19:10 dpc00