Extra dot in requirements file detected twice and not updated
I have an issue with PyUP on Cookiecutter Django project. This is a project template for Cookiecutter to quickly generate boilerplate for a Django project
We have 4 requirements file:
- One at the top of the project:
requirements.txt - 3 in the project template under
{{cookiecutter.project_slug}}/requirements:base.txtlocal.txtproduction.txt
We're receiving updates for all of them except base.txt, and I can't really understand why.
When looking at the PyUP dashboard, I can see the file is detected twice, with a dot in the name:
{{cookiecutter.project_slug}}/requirements/./base.txt{{cookiecutter.project_slug}}/requirements/base.txt
Somehow, I assume this is preventing the update from arriving...?
I've tried to add them to the config file, or click "reload" in the dashboard, but the problem persists.
@browniebroke thank you for this catch. This is an unusual bug causing strange behavior. I added it to the list of bugfixes.
Just adding here a new piece of info I've just discovered in case it helps. Pyup creates the branches to run the updates, but doesn't open a pull reques:
https://github.com/pydanny/cookiecutter-django/branches/all
I tracked it down to this recursive call to add_requirement_file:
https://github.com/pyupio/pyup/blob/6fb86387f58c5a345d7c44ebdbb02a6a1d1ba07d/pyup/bot.py#L519
Which doesn't play nice with our production.txt and local.txt including the base requirements with a relative path: -r ./base.txt
https://github.com/pydanny/cookiecutter-django/blob/3dedd4dd4b55254a0fe6ef272c70c0a54c5e5188/%7B%7Bcookiecutter.project_slug%7D%7D/requirements/production.txt#L3
Changed the -r ./base.txt to -r base.txt fixed it, all good on my end now!
Do you want to keep this issue open to improve how you deal with this use case?