This error "Path cannot have space after a slash" would occur during the Debian metadata indexing if there is any space in the matrix params (deb.distribution, deb.component, deb.architecture) for a Debian package.
In below example, component name is defined with a space in value which will cause the errors with metadata calculation.:
For reference, below is the corresponding complete error in Artifactory log:
Couldn't save resource debian-local:dists/ trusty/_temp-1627411940677_/ trusty/ main/binary-all/Packages, reason:
java.nio.file.InvalidPathException: Path cannot have a space after a slash: debian-local/dists/ trusty/_temp-1627411940677_/
In order to resolve these errors, make sure it doesn't include any spaces in their matrix params(deb.distribution, deb.component, deb.architecture) during debian package deployment.