All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/1] fetch2/local.py: avoid using PREMIRROR
@ 2016-01-04 10:15 Robert Yang
  2016-01-04 10:15 ` [PATCH 1/1] " Robert Yang
  0 siblings, 1 reply; 6+ messages in thread
From: Robert Yang @ 2016-01-04 10:15 UTC (permalink / raw)
  To: bitbake-devel

The following changes since commit 2cd061a29a94fdcdfec86732e6bcbb71c12c4afc:

  bluez5: include the patch only for 5.36 (2015-12-28 13:02:11 +0000)

are available in the git repository at:

  git://git.pokylinux.org/poky-contrib rbt/local
  http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=rbt/local

Robert Yang (1):
  fetch2/local.py: avoid using PREMIRROR

 bitbake/lib/bb/fetch2/local.py |    5 +++++
 1 file changed, 5 insertions(+)

-- 
1.7.9.5



^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH 1/1] fetch2/local.py: avoid using PREMIRROR
  2016-01-04 10:15 [PATCH 0/1] fetch2/local.py: avoid using PREMIRROR Robert Yang
@ 2016-01-04 10:15 ` Robert Yang
  2016-01-11 13:23   ` Richard Purdie
  0 siblings, 1 reply; 6+ messages in thread
From: Robert Yang @ 2016-01-04 10:15 UTC (permalink / raw)
  To: bitbake-devel

The PREMIRROR isn't useful for "file://", so avoid using it, this is
good for searching speed and can reduce useless lines in log.do_fetch.

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
 bitbake/lib/bb/fetch2/local.py |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/bitbake/lib/bb/fetch2/local.py b/bitbake/lib/bb/fetch2/local.py
index 2d921f7..7245651 100644
--- a/bitbake/lib/bb/fetch2/local.py
+++ b/bitbake/lib/bb/fetch2/local.py
@@ -126,3 +126,8 @@ class Local(FetchMethod):
     def clean(self, urldata, d):
         return
 
+    def try_premirror(self, urldata, d):
+        """
+        Should premirrors be used?
+        """
+        return False
-- 
1.7.9.5



^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/1] fetch2/local.py: avoid using PREMIRROR
  2016-01-04 10:15 ` [PATCH 1/1] " Robert Yang
@ 2016-01-11 13:23   ` Richard Purdie
  2016-01-12  1:31     ` Robert Yang
  0 siblings, 1 reply; 6+ messages in thread
From: Richard Purdie @ 2016-01-11 13:23 UTC (permalink / raw)
  To: Robert Yang, bitbake-devel

On Mon, 2016-01-04 at 02:15 -0800, Robert Yang wrote:
> The PREMIRROR isn't useful for "file://", so avoid using it, this is
> good for searching speed and can reduce useless lines in
> log.do_fetch.
> 
> Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
> ---
>  bitbake/lib/bb/fetch2/local.py |    5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/bitbake/lib/bb/fetch2/local.py
> b/bitbake/lib/bb/fetch2/local.py
> index 2d921f7..7245651 100644
> --- a/bitbake/lib/bb/fetch2/local.py
> +++ b/bitbake/lib/bb/fetch2/local.py
> @@ -126,3 +126,8 @@ class Local(FetchMethod):
>      def clean(self, urldata, d):
>          return
>  
> +    def try_premirror(self, urldata, d):
> +        """
> +        Should premirrors be used?
> +        """
> +        return False

Hi Robert,

I applied this but I think I'm going to have to revert this since it is
in fact a valid use case.

The sstate.bbclass code sets up SSTATE_MIRRORS as PREMIRRORS. Its quite
common to map those file:// urls to remote http:// urls and with the
above change, this no longer works.

Cheers,

Richard




^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/1] fetch2/local.py: avoid using PREMIRROR
  2016-01-11 13:23   ` Richard Purdie
@ 2016-01-12  1:31     ` Robert Yang
  2016-01-12  8:19       ` Richard Purdie
  0 siblings, 1 reply; 6+ messages in thread
From: Robert Yang @ 2016-01-12  1:31 UTC (permalink / raw)
  To: Richard Purdie, bitbake-devel


On 01/11/2016 09:23 PM, Richard Purdie wrote:
> On Mon, 2016-01-04 at 02:15 -0800, Robert Yang wrote:
>> The PREMIRROR isn't useful for "file://", so avoid using it, this is
>> good for searching speed and can reduce useless lines in
>> log.do_fetch.
>>
>> Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
>> ---
>>   bitbake/lib/bb/fetch2/local.py |    5 +++++
>>   1 file changed, 5 insertions(+)
>>
>> diff --git a/bitbake/lib/bb/fetch2/local.py
>> b/bitbake/lib/bb/fetch2/local.py
>> index 2d921f7..7245651 100644
>> --- a/bitbake/lib/bb/fetch2/local.py
>> +++ b/bitbake/lib/bb/fetch2/local.py
>> @@ -126,3 +126,8 @@ class Local(FetchMethod):
>>       def clean(self, urldata, d):
>>           return
>>
>> +    def try_premirror(self, urldata, d):
>> +        """
>> +        Should premirrors be used?
>> +        """
>> +        return False
>
> Hi Robert,
>
> I applied this but I think I'm going to have to revert this since it is
> in fact a valid use case.
>
> The sstate.bbclass code sets up SSTATE_MIRRORS as PREMIRRORS. Its quite
> common to map those file:// urls to remote http:// urls and with the
> above change, this no longer works.

Sorry, I didn't realize that sstate.bbclass code sets up SSTATE_MIRRORS
as PREMIRRORS. If file:// urls map to http://, I think that it should use
bitbake/lib/bb/fetch2/wget.py ? Here is a patch for wget.py:

   git://git.pokylinux.org/poky-contrib rbt/local.py
   http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=rbt/local.py

Robert Yang (1):
   wget.py: use PREMIRROR


Subject: [PATCH 1/1] wget.py: use PREMIRROR

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
  bitbake/lib/bb/fetch2/wget.py |    7 +++++++
  1 file changed, 7 insertions(+)

diff --git a/bitbake/lib/bb/fetch2/wget.py b/bitbake/lib/bb/fetch2/wget.py
index c8c6d5c..200f9aa 100644
--- a/bitbake/lib/bb/fetch2/wget.py
+++ b/bitbake/lib/bb/fetch2/wget.py
@@ -540,3 +540,10 @@ class Wget(FetchMethod):

          return (self._check_latest_version(uri, package, package_regex,
                  current_version, ud, d), '')
+
+    def try_premirror(self, urldata, d):
+        """
+        Should premirrors be used?
+        """
+        return True
+
-- 
1.7.9.5


// Robert

>
> Cheers,
>
> Richard
>
>
>


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/1] fetch2/local.py: avoid using PREMIRROR
  2016-01-12  1:31     ` Robert Yang
@ 2016-01-12  8:19       ` Richard Purdie
  2016-01-13  3:02         ` Robert Yang
  0 siblings, 1 reply; 6+ messages in thread
From: Richard Purdie @ 2016-01-12  8:19 UTC (permalink / raw)
  To: Robert Yang, bitbake-devel

On Tue, 2016-01-12 at 09:31 +0800, Robert Yang wrote:
> On 01/11/2016 09:23 PM, Richard Purdie wrote:
> > On Mon, 2016-01-04 at 02:15 -0800, Robert Yang wrote:
> > > The PREMIRROR isn't useful for "file://", so avoid using it, this
> > > is
> > > good for searching speed and can reduce useless lines in
> > > log.do_fetch.
> > > 
> > > Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
> > > ---
> > >   bitbake/lib/bb/fetch2/local.py |    5 +++++
> > >   1 file changed, 5 insertions(+)
> > > 
> > > diff --git a/bitbake/lib/bb/fetch2/local.py
> > > b/bitbake/lib/bb/fetch2/local.py
> > > index 2d921f7..7245651 100644
> > > --- a/bitbake/lib/bb/fetch2/local.py
> > > +++ b/bitbake/lib/bb/fetch2/local.py
> > > @@ -126,3 +126,8 @@ class Local(FetchMethod):
> > >       def clean(self, urldata, d):
> > >           return
> > > 
> > > +    def try_premirror(self, urldata, d):
> > > +        """
> > > +        Should premirrors be used?
> > > +        """
> > > +        return False
> > 
> > Hi Robert,
> > 
> > I applied this but I think I'm going to have to revert this since
> > it is
> > in fact a valid use case.
> > 
> > The sstate.bbclass code sets up SSTATE_MIRRORS as PREMIRRORS. Its
> > quite
> > common to map those file:// urls to remote http:// urls and with
> > the
> > above change, this no longer works.
> 
> Sorry, I didn't realize that sstate.bbclass code sets up
> SSTATE_MIRRORS
> as PREMIRRORS. If file:// urls map to http://, I think that it should
> use
> bitbake/lib/bb/fetch2/wget.py ? Here is a patch for wget.py:
> 
>    git://git.pokylinux.org/poky-contrib rbt/local.py
>    http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=rbt/local.py
> 
> Robert Yang (1):
>    wget.py: use PREMIRROR
> 
> 
> Subject: [PATCH 1/1] wget.py: use PREMIRROR
> 
> Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
> ---
>   bitbake/lib/bb/fetch2/wget.py |    7 +++++++
>   1 file changed, 7 insertions(+)
> 
> diff --git a/bitbake/lib/bb/fetch2/wget.py
> b/bitbake/lib/bb/fetch2/wget.py
> index c8c6d5c..200f9aa 100644
> --- a/bitbake/lib/bb/fetch2/wget.py
> +++ b/bitbake/lib/bb/fetch2/wget.py
> @@ -540,3 +540,10 @@ class Wget(FetchMethod):
> 
>           return (self._check_latest_version(uri, package,
> package_regex,
>                   current_version, ud, d), '')
> +
> +    def try_premirror(self, urldata, d):
> +        """
> +        Should premirrors be used?
> +        """
> +        return True
> +

With your patch reverted, sstate works as it should. The above is also
the default so this second patcg doesn't change anything that I can
see?

Cheers,

Richard



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/1] fetch2/local.py: avoid using PREMIRROR
  2016-01-12  8:19       ` Richard Purdie
@ 2016-01-13  3:02         ` Robert Yang
  0 siblings, 0 replies; 6+ messages in thread
From: Robert Yang @ 2016-01-13  3:02 UTC (permalink / raw)
  To: Richard Purdie, bitbake-devel



On 01/12/2016 04:19 PM, Richard Purdie wrote:
> On Tue, 2016-01-12 at 09:31 +0800, Robert Yang wrote:
>> On 01/11/2016 09:23 PM, Richard Purdie wrote:
>>> On Mon, 2016-01-04 at 02:15 -0800, Robert Yang wrote:
>>>> The PREMIRROR isn't useful for "file://", so avoid using it, this
>>>> is
>>>> good for searching speed and can reduce useless lines in
>>>> log.do_fetch.
>>>>
>>>> Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
>>>> ---
>>>>    bitbake/lib/bb/fetch2/local.py |    5 +++++
>>>>    1 file changed, 5 insertions(+)
>>>>
>>>> diff --git a/bitbake/lib/bb/fetch2/local.py
>>>> b/bitbake/lib/bb/fetch2/local.py
>>>> index 2d921f7..7245651 100644
>>>> --- a/bitbake/lib/bb/fetch2/local.py
>>>> +++ b/bitbake/lib/bb/fetch2/local.py
>>>> @@ -126,3 +126,8 @@ class Local(FetchMethod):
>>>>        def clean(self, urldata, d):
>>>>            return
>>>>
>>>> +    def try_premirror(self, urldata, d):
>>>> +        """
>>>> +        Should premirrors be used?
>>>> +        """
>>>> +        return False
>>>
>>> Hi Robert,
>>>
>>> I applied this but I think I'm going to have to revert this since
>>> it is
>>> in fact a valid use case.
>>>
>>> The sstate.bbclass code sets up SSTATE_MIRRORS as PREMIRRORS. Its
>>> quite
>>> common to map those file:// urls to remote http:// urls and with
>>> the
>>> above change, this no longer works.
>>
>> Sorry, I didn't realize that sstate.bbclass code sets up
>> SSTATE_MIRRORS
>> as PREMIRRORS. If file:// urls map to http://, I think that it should
>> use
>> bitbake/lib/bb/fetch2/wget.py ? Here is a patch for wget.py:
>>
>>     git://git.pokylinux.org/poky-contrib rbt/local.py
>>     http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=rbt/local.py
>>
>> Robert Yang (1):
>>     wget.py: use PREMIRROR
>>
>>
>> Subject: [PATCH 1/1] wget.py: use PREMIRROR
>>
>> Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
>> ---
>>    bitbake/lib/bb/fetch2/wget.py |    7 +++++++
>>    1 file changed, 7 insertions(+)
>>
>> diff --git a/bitbake/lib/bb/fetch2/wget.py
>> b/bitbake/lib/bb/fetch2/wget.py
>> index c8c6d5c..200f9aa 100644
>> --- a/bitbake/lib/bb/fetch2/wget.py
>> +++ b/bitbake/lib/bb/fetch2/wget.py
>> @@ -540,3 +540,10 @@ class Wget(FetchMethod):
>>
>>            return (self._check_latest_version(uri, package,
>> package_regex,
>>                    current_version, ud, d), '')
>> +
>> +    def try_premirror(self, urldata, d):
>> +        """
>> +        Should premirrors be used?
>> +        """
>> +        return True
>> +
>
> With your patch reverted, sstate works as it should. The above is also
> the default so this second patcg doesn't change anything that I can
> see?

Yes, you're right, it doesn't change anything, I had misunderstood. Please
revert it.

// Robert

>
> Cheers,
>
> Richard
>
>


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2016-01-13  3:02 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-01-04 10:15 [PATCH 0/1] fetch2/local.py: avoid using PREMIRROR Robert Yang
2016-01-04 10:15 ` [PATCH 1/1] " Robert Yang
2016-01-11 13:23   ` Richard Purdie
2016-01-12  1:31     ` Robert Yang
2016-01-12  8:19       ` Richard Purdie
2016-01-13  3:02         ` Robert Yang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.