From cc7031c27e0f3cdcbbda49b6db0bb6bb543a49d8 Mon Sep 17 00:00:00 2001 From: Monty Taylor Date: Fri, 29 Nov 2013 10:02:55 -0500 Subject: [PATCH] Align projects list with mirror-needing projects If projects.txt is going to be the basis for select-mirror in the gate, we should also list projects in projects.txt that need to be constrained by the mirror for their testing. In order to do that, we need to not try to unconditionally update setup.py, since devstack and devstack-gate do not have it. openstack/requirements itself also does not use the mirror, so remove it from the list. Change-Id: Iea33e8f4d5453bf413f3d479b85eaed99938b302 --- projects.txt | 3 ++- update.py | 5 ++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/projects.txt b/projects.txt index 379aa87dda..3f90d857a9 100644 --- a/projects.txt +++ b/projects.txt @@ -26,7 +26,6 @@ openstack/python-openstackclient openstack/python-savannaclient openstack/python-swiftclient openstack/python-troveclient -openstack/requirements openstack/savanna openstack/savanna-dashboard openstack/savanna-image-elements @@ -34,7 +33,9 @@ openstack/savanna-extra openstack/swift openstack/tempest openstack/trove +openstack-dev/devstack openstack-dev/hacking +openstack-infra/devstack-gate stackforge/climate stackforge/solum stackforge/python-climateclient diff --git a/update.py b/update.py index be8384cc7f..ae7cd87a51 100644 --- a/update.py +++ b/update.py @@ -149,10 +149,13 @@ def _copy_requires(suffix, dest_dir): def _write_setup_py(dest_path): - print("Syncing setup.py") target_setup_py = os.path.join(dest_path, 'setup.py') + # If it doesn't have a setup.py, then we don't want to update it + if not os.path.exists(target_setup_py): + return has_pbr = 'pbr' in open(target_setup_py, 'r').read() if has_pbr: + print("Syncing setup.py") # We only want to sync things that are up to date with pbr mechanics with open(target_setup_py, 'w') as setup_file: setup_file.write(_setup_py_text)