-
-
Notifications
You must be signed in to change notification settings - Fork 743
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
packaging: Explicit add data files to the manifest #7876
Conversation
We've started seeing some failures to build in Debian and Ubuntu that can be traced to those files missing from the manifest when we're calling setup.py install. Now, this started failing fairly recently, so I'm guessing it's actually a change of behaviour in the SCM plugin and/or setuptools. It makes sense though, since we're packaging from the tarball, which isn't in the Git context needed to actually include those data files. Signed-off-by: Simon Chopin <simon.chopin@canonical.com>
There are 2 (AFAIK) working workflows:
@RonnyPfannschmidt does that ring some bell? BTW, I rather would not like to start again manually managing the manifest like suggested in this PR, we did this in the past and it is error prone. |
I completely understand you not wanting to actually adopt this patch, it's mostly a workaround for the issue I've been seeing. I'm not the Debian maintainer for borgbackup2, just a Ubuntu developer that happened upon the build failure and tried to make things better. The following is based on wild guesses and assumptions:
Are the tarballs on your GH releases the same as the ones on PyPI? Anyway, I'll ask some people more versed into the fine art of Python packaging in Debian to have a look here. |
@schopin-pro The tarballs I put on github releases are precisely the ones I uploaded to pypi (plus the gpg signature, which pypi does not accept any more). But don't confuse these files with the archives autogenerated by github (I can't avoid that), these zip and tgz archives are not pypi / pip packages. |
My guess is that this is caused by our (Debian's) default cleaning egg-info, which we recently turned on. If you are relying on This PR looks correct in light of that. |
What's different is that we aren't in a git checkout. |
If you don't work based on a git checkout, you must use the sdist package from us as starting point, otherwise you will be missing information, because setuptools_scm needs the git information to build the manifest. |
Or you apply this change. If you don't want to support work from a tarball, and accept patches related to it, then you may as well drop your MANIFEST.in entirely. |
From our side, the reason we delete the existing egg-info is that when we build the package, it usually changes the egg-info. Building it cleanly makes the builds more reproducible (and stops our tooling from detecting changes not carried in a patch file). |
@stefanor see the comment at top of the MANIFEST.in. Basically, we already aren't using it for all files committed to git that shall be in the manifest, but there are a few exceptions and that's why we need it still, to enter these exceptions. |
Aha, I see, sorry missed that. Perfectly hidden in the diff on this PR by default :) I came as a drive-by reviewer, at the request of @schopin-pro. |
BTW, there were some packaging related changes in 1.4-maint (that just had its first release in form of 1.4.0a1):
Maybe it would be worth doing some early Debian/Ubuntu packaging and testing trials to see if this improved the situation for you. |
Closing this, not needed if one uses the correct workflow. Even if one does not use a git checkout, one can get this right by using the sdist .tgz provided by us and installing it using pip. |
We've started seeing some failures to build in Debian and Ubuntu that can be traced to those files missing from the manifest when we're calling setup.py install.
Now, this started failing fairly recently, so I'm guessing it's actually a change of behaviour in the SCM plugin and/or setuptools. It makes sense though, since we're packaging from the tarball, which isn't in the Git context needed to actually include those data files.