-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
Open
Labels
docsThis change adds or pertains to documentationThis change adds or pertains to documentationfilesystemUnderlying file system and functions that use itUnderlying file system and functions that use it
Description
The maximum filename length is 255, isfile should return false rather than raising an error when the file name is too long.
julia> isfile(randstring(256))
ERROR: IOError: stat("yDdEhZcxL943psM9mDEXZJhZwXH0cnrNCR8Ps1MrdDB8I8EDaN1WDyL40PQlcEra20zt1CyDOEv4cR7BlsIyJr0hBhoFl1kP2kQBJvTcdsTjVUx65g2kgCfER3adn3xQkIVA80mYfXvQBNBxNg9rLfsOh6TjGXApOLVRBBRBWsGc6dYwFRWZgDyRhkjNBecthZ7Pgg0EQFnLPRrlXpMdBaPoV0fDF8iNfhguOdfGpwjAD7U8ABJSW2fFUeHmUoMr"): name too long (ENAMETOOLONG)
Stacktrace:
[1] uv_error
@ ./libuv.jl:97 [inlined]
[2] stat(path::String)
@ Base.Filesystem ./stat.jl:69
[3] isfile(path::String)
@ Base.Filesystem ./stat.jl:311
[4] top-level scope
@ REPL[20]:1The same applies for isdir
relevant code:
Line 311 in a163d3e
| @eval ($f)(path...) = ($f)(stat(path...)) |
Julia version: 1.6.0-rc1
nstiurca
Metadata
Metadata
Assignees
Labels
docsThis change adds or pertains to documentationThis change adds or pertains to documentationfilesystemUnderlying file system and functions that use itUnderlying file system and functions that use it