* [PATCH 0/1] Disable mirrors for connectivity checks
@ 2011-09-14 22:09 Joshua Lock
2011-09-14 22:09 ` [PATCH 1/1] sanity: disable mirrors for connectivity check Joshua Lock
0 siblings, 1 reply; 4+ messages in thread
From: Joshua Lock @ 2011-09-14 22:09 UTC (permalink / raw)
To: openembedded-core
I realised today that we are using mirrors when running the network connectivity
checks. This could significantly reduce the utility of this sanity check.
The single patch in this series rectifies the issue.
Regards,
Joshua
The following changes since commit 8df322abfd3fa8c460fd73c83c1ef0b5e419dc11:
core-image-minimal: Add missing POKY_EXTRA_IMAGE variable (2011-09-14 01:27:08 +0100)
are available in the git repository at:
git://git.openembedded.org/openembedded-core-contrib josh/work
http://cgit.openembedded.org/cgit.cgi/openembedded-core-contrib/log/?h=josh/work
Joshua Lock (1):
sanity: disable mirrors for connectivity check
meta/classes/sanity.bbclass | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
--
1.7.6
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH 1/1] sanity: disable mirrors for connectivity check
2011-09-14 22:09 [PATCH 0/1] Disable mirrors for connectivity checks Joshua Lock
@ 2011-09-14 22:09 ` Joshua Lock
2011-09-16 17:07 ` Richard Purdie
2011-09-16 17:12 ` Joshua Lock
0 siblings, 2 replies; 4+ messages in thread
From: Joshua Lock @ 2011-09-14 22:09 UTC (permalink / raw)
To: openembedded-core
It's difficult to test a range of fetchers when using mirrors, therefore create a throwaway
copy of the datastore and delete the MIRROR and PREMIRROR variables to ensure they aren't
used in the connectivity check.
Signed-off-by: Joshua Lock <josh@linux.intel.com>
---
meta/classes/sanity.bbclass | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass
index 93008cc..6ed43b2 100644
--- a/meta/classes/sanity.bbclass
+++ b/meta/classes/sanity.bbclass
@@ -94,14 +94,18 @@ def check_connectivity(d):
# CONNECTIVITY_CHECK_URIS are set
network_enabled = not bb.data.getVar('BB_NO_NETWORK', d, True)
check_enabled = len(test_uris)
+ # Take a copy of the data store and unset MIRRORS and PREMIRROS
+ data = bb.data.createCopy(d)
+ data.delVar('PREMIRRORS')
+ data.delVar('MIRRORS')
if check_enabled and network_enabled:
try:
- fetcher = bb.fetch2.Fetch(test_uris, d)
+ fetcher = bb.fetch2.Fetch(test_uris, data)
fetcher.checkstatus()
except Exception:
# Allow the message to be configured so that users can be
# pointed to a support mechanism.
- msg = bb.data.getVar('CONNECTIVITY_CHECK_MSG', d, True) or ""
+ msg = bb.data.getVar('CONNECTIVITY_CHECK_MSG', data, True) or ""
if len(msg) == 0:
msg = "Failed to fetch test data from the network. Please ensure your network is configured correctly.\n"
retval = msg
--
1.7.6
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 1/1] sanity: disable mirrors for connectivity check
2011-09-14 22:09 ` [PATCH 1/1] sanity: disable mirrors for connectivity check Joshua Lock
@ 2011-09-16 17:07 ` Richard Purdie
2011-09-16 17:12 ` Joshua Lock
1 sibling, 0 replies; 4+ messages in thread
From: Richard Purdie @ 2011-09-16 17:07 UTC (permalink / raw)
To: Patches and discussions about the oe-core layer
On Wed, 2011-09-14 at 15:09 -0700, Joshua Lock wrote:
> It's difficult to test a range of fetchers when using mirrors, therefore create a throwaway
> copy of the datastore and delete the MIRROR and PREMIRROR variables to ensure they aren't
> used in the connectivity check.
>
> Signed-off-by: Joshua Lock <josh@linux.intel.com>
> ---
> meta/classes/sanity.bbclass | 8 ++++++--
> 1 files changed, 6 insertions(+), 2 deletions(-)
Merged to master, thanks.
Richard
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 1/1] sanity: disable mirrors for connectivity check
2011-09-14 22:09 ` [PATCH 1/1] sanity: disable mirrors for connectivity check Joshua Lock
2011-09-16 17:07 ` Richard Purdie
@ 2011-09-16 17:12 ` Joshua Lock
1 sibling, 0 replies; 4+ messages in thread
From: Joshua Lock @ 2011-09-16 17:12 UTC (permalink / raw)
To: openembedded-core
Any comments?
On Wed, 2011-09-14 at 15:09 -0700, Joshua Lock wrote:
> It's difficult to test a range of fetchers when using mirrors, therefore create a throwaway
> copy of the datastore and delete the MIRROR and PREMIRROR variables to ensure they aren't
> used in the connectivity check.
>
> Signed-off-by: Joshua Lock <josh@linux.intel.com>
> ---
> meta/classes/sanity.bbclass | 8 ++++++--
> 1 files changed, 6 insertions(+), 2 deletions(-)
>
> diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass
> index 93008cc..6ed43b2 100644
> --- a/meta/classes/sanity.bbclass
> +++ b/meta/classes/sanity.bbclass
> @@ -94,14 +94,18 @@ def check_connectivity(d):
> # CONNECTIVITY_CHECK_URIS are set
> network_enabled = not bb.data.getVar('BB_NO_NETWORK', d, True)
> check_enabled = len(test_uris)
> + # Take a copy of the data store and unset MIRRORS and PREMIRROS
> + data = bb.data.createCopy(d)
> + data.delVar('PREMIRRORS')
> + data.delVar('MIRRORS')
> if check_enabled and network_enabled:
> try:
> - fetcher = bb.fetch2.Fetch(test_uris, d)
> + fetcher = bb.fetch2.Fetch(test_uris, data)
> fetcher.checkstatus()
> except Exception:
> # Allow the message to be configured so that users can be
> # pointed to a support mechanism.
> - msg = bb.data.getVar('CONNECTIVITY_CHECK_MSG', d, True) or ""
> + msg = bb.data.getVar('CONNECTIVITY_CHECK_MSG', data, True) or ""
> if len(msg) == 0:
> msg = "Failed to fetch test data from the network. Please ensure your network is configured correctly.\n"
> retval = msg
--
Joshua Lock
Yocto Project "Johannes factotum"
Intel Open Source Technology Centre
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2011-09-16 17:17 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-09-14 22:09 [PATCH 0/1] Disable mirrors for connectivity checks Joshua Lock
2011-09-14 22:09 ` [PATCH 1/1] sanity: disable mirrors for connectivity check Joshua Lock
2011-09-16 17:07 ` Richard Purdie
2011-09-16 17:12 ` Joshua Lock
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox