Assuming I understand the code correctly, it appears that the copy_to_container method creates a tar file containing the entire project, and copies it to the container. If the project contains any large files (in my case, I had a cdk.out directory that was ~2.5G), the container.put_archive call fails with a mysterious ('Connection aborted.', OSError(22, 'Invalid argument')) error. Best I've been able to determine, this is due to the filesize exceeding some limit imposed by the OS (MacOS Sonoma 14.6.1, in my case).
It would be helpful if this plugin supported something similar to .dockerignore or an exclude property in the pyproject.toml file. It looks like TarFile.add supports a filter argument, which looks like a good starting point.
Attached is the stacktrace that was output when the OSError occurred.
stacktrace.txt
Assuming I understand the code correctly, it appears that the
copy_to_containermethod creates a tar file containing the entire project, and copies it to the container. If the project contains any large files (in my case, I had acdk.outdirectory that was ~2.5G), thecontainer.put_archivecall fails with a mysterious('Connection aborted.', OSError(22, 'Invalid argument'))error. Best I've been able to determine, this is due to the filesize exceeding some limit imposed by the OS (MacOS Sonoma 14.6.1, in my case).It would be helpful if this plugin supported something similar to
.dockerignoreor anexcludeproperty in thepyproject.tomlfile. It looks likeTarFile.addsupports afilterargument, which looks like a good starting point.Attached is the stacktrace that was output when the OSError occurred.
stacktrace.txt