Cannot zip directory on Mac due to 'no such file' error

Hello, I encountered a problem yesterday, I tried to zip a directory in order to send it to my friend through email, however, whenever I try to zip the directory, it tells me :

The file “TP réseau 1TSCIEL.docx” couldn’t be opened because there is no such file.

But when I did it on my other laptop, which is on Ubuntu, I didn't get this message and it worked just fine.

When I tried to look up 'TP réseau 1TSCIEL.docx' in my files, I couldn't find anything

here's the video showing my issue

MacBook Air, macOS 26.5

Posted on Jun 18, 2026 1:16 PM

Reply
21 replies

Jun 20, 2026 2:04 PM in response to detectivemayo

That docx should already be zipped. That’s how docx works.


The following (benign) command will show some info on the file:

file TP\ réseau\ 1TSCIEL.docx


FAT also does its own platform-specific thing with filenames, so (for the purposes of not debugging more) I’d rename the file into ASCII characters. And no spaces temporarily either, as that avoids needing escapes and quoting.

Jun 19, 2026 5:48 AM in response to detectivemayo

detectivemayo wrote:
1 - there are many files in this directory, it’s mainly all of what I do in class, but I went through each of them one by one and still couldn’t find the file they’re talking about it

Check for hidden files. You've probably got a leftover ".TP réseau 1TSCIEL.docx" file in that directory. That's a metadata file. When it can't find the data file, it gives up.


2- I don’t know what you mean by "maybe the computer had other files" but what I meant is, the "SALL" directory on my usb key successfully zipped on another OS

You literally are talking about multiple computers and multiple different directories. They're simply going to be different.


3- there may be a problem w accents and spotlights search, but that doesn’t explain how I’m unable to zip it through the terminal either?

That precisely explains it. The Finder's "Archive" feature is not the same as the command line zip tool. And the Mac command line zip tool is not the same as the Linux tool. And most importantly, the Linux file system is not the same as the Mac filesystem.


If you regularly exchange files between Linux and Mac, then you need to be very careful to avoid any kind of non-English characters. Oubliez toutes les lettres diacritiques et semblables.


Years ago, this was a problem because Apple's old HFS system encoded diacritics is technically correct, but unusual way. Then, when Apple switch to APFS, they didn't actually specify how to handle them. It's like they forgot or something. So if you do a test, like Matti Haveri did, solely on a Mac, it will work fine. But if you copy files directly to a drive, or use a network, then it's just up to random luck whether or not it works.


In this specific case, it sounds like it actually isn't the Unicode. It sounds like there's a leftover hidden sidecar file. Did I mention that there's no standard zip file format. Every version, Finder, Linux, Mac command line, etc. does it differently.

Jun 21, 2026 5:01 AM in response to detectivemayo

detectivemayo wrote:
I find it very weird I'm unable to find the file in Finder yet I'm able to find it in the terminal

That's what I meant in my first reply. There are multiple ways to handle "é". It can be just "é", or it can be "e" combined with "´". It is encoded on disk in one of those formats and Terminal can understand that format. But Finder cannot understand that format. But other tools in Terminal will interpret your typing the way Finder is expecting that string to be encoded, so it won't find any result.


For (a lot) more detail, see https://www.unicode.org/reports/tr15/

Jun 21, 2026 2:18 AM in response to HWTech

1- My other laptop runs Ubuntu! not macOS, so I'm mainly switching between Linux, MacOS and Windows occasionally


2- I absolutely didn't think of the file name, but now that many people mentioned it, the problem might be the file name because I don't see another issue beside this one, thought I find it very weird I'm unable to find the file in Finder yet I'm able to find it in the terminal

Jun 20, 2026 1:10 PM in response to detectivemayo

It looks like all of this is taking place on an MS-DOS file system. So you can obviously ignore anything I said about Apple's APFS. I don't think MS-DOS file systems support non-ASCII files. And if they do, there's a strong chance it isn't in any kind of standard, compatible way. That would certainly explain why Finder can't see it and can't zip it.


Just because the Archive utility and the command-line zip tool aren't the same doesn't mean there isn't one or more other complications that would break one or more other tools.


If you want to use file names with any kind of non-ASCII characters, and share the files across Windows, Linux, and macOS, then you have one (1) option. That's using an SMB file share.

Jun 20, 2026 9:36 PM in response to detectivemayo

detectivemayo wrote:
I decided to go on my other laptop and found the "non-existent" file finder can't find :

What is the exact version of macOS was this other laptop using? I'm assuming the first Mac is running macOS 26.5 Tahoe as noted in the system reference of your initial post. I know that 26.5.1 has been out for a little bit (I haven't had any issues other than the memory/storage management has reverted back to some bad behavior by running the storage out of space again to critical levels & pausing apps more often again due to "Application out of memory" errors).


What else may be different between the two computers in terms of software & configuration?


Or perhaps you have some third party software installed on the first Mac that is interfering with the system which is not installed on this other laptop which can see the problem file.


I, again, went to check on my Mac in this specific directory for hidden file or anything but nothing appears, I then decided to check through the terminal and this is what I got :
Official Apple Support Community

I wonder if the file name itself is part of the problem here. It has a space followed by a hyphen. Plus it has parentheses. I know not too long ago macOS was having issues with file names that had a space followed by a dot/period.


For some years now I have occasionally had issues zipping files on macOS (both in the Finder with "compress" option and the command line) & even on Linux. I usually go to the command line and make .tgz files instead as they tend to just work.


Jun 18, 2026 3:23 PM in response to detectivemayo

detectivemayo wrote:
Hello, I encountered a problem yesterday, I tried to zip a directory in order to send it to my friend through email, however, whenever I try to zip the directory, it tells me :
The file “TP réseau 1TSCIEL.docx” couldn’t be opened because there is no such file.

What files are in that directory?


But when I did it on my other laptop, which is on Ubuntu, I didn't get this message and it worked just fine.

Perhaps the other computer has different files.

When I tried to look up 'TP réseau 1TSCIEL.docx' in my files, I couldn't find anything
here's the video showing my issue

You were using Spotlight search. Don't even waste your time with that. Plus, you were typing in a non-ASCII file name. Apple is a California company. Americans don't understand accents.

Jun 18, 2026 8:08 PM in response to etresoft

1 - there are many files in this directory, it’s mainly all of what I do in class, but I went through each of them one by one and still couldn’t find the file they’re talking about it


2- I don’t know what you mean by "maybe the computer had other files" but what I meant is, the "SALL" directory on my usb key successfully zipped on another OS


3- there may be a problem w accents and spotlights search, but that doesn’t explain how I’m unable to zip it through the terminal either?

Jun 20, 2026 11:36 AM in response to etresoft

Okay so I read your whole comment and here're stuff I noticed :

I actually went through everyyy of my directories to search for a hidden file (through finder) and couldn't find one (after doing <cmd><shift>.)

I decided to go on my other laptop and found the "non-existent" file finder can't find :


I, again, went to check on my Mac in this specific directory for hidden file or anything but nothing appears, I then decided to check through the terminal and this is what I got :



As for this file, I did it on window, like 97% of the files in this directory, but this may be an accent problem as you're saying because a big part of my other files don't have accent in it, but the directories do (idk if this is relevant in any way)


if the Finder's archive feature and the command line zip tool aren't the same, then why can't I zip the directory through the terminal? I'm pretty sure the command line for zipping a file is 'zip -r' isn't it?



[Edited by Moderator]

Cannot zip directory on Mac due to 'no such file' error

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.