linux-rt-users.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] srt_create: Make sure series output is sorted
@ 2019-04-12 17:31 Tom Zanussi
  2019-04-15 10:45 ` Daniel Wagner
  0 siblings, 1 reply; 2+ messages in thread
From: Tom Zanussi @ 2019-04-12 17:31 UTC (permalink / raw)
  To: Daniel Wagner; +Cc: linux-rt-users

Hi Daniel,

I actually used your stable-rt-tools srt tool this time to do the
latest 3.18-rt update release - overall it works well and did the job
nicely!

I did run into one serious problem in that the series file that gets
created for the patches tarball lists the patches in essentially random
order on my system, so using it to apply the series with quilt failed
immediately.  The patch below fixes the problem for me.

There were a few other things I ran into which boiled down to
essentially lack of documentation and/or informative enough error
messages, and one or two things having to do with my workflow on two
separate machines that I'll have to think about.  I'll write some
patches addressing those and sent when I get the chance.

Anyway, thanks for the useful tool!

Tom 

--

From: Tom Zanussi <tom.zanussi@linux.intel.com>

os.listdir() doesn't guarantee ordering, so using its output directly
as input for the series file can result in a randomly ordered series
that quilt can't apply.

Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com>
---
 srt_create.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srt_create.py b/srt_create.py
index 7314988..90d1e1b 100644
--- a/srt_create.py
+++ b/srt_create.py
@@ -47,7 +47,7 @@ def create_series(old_tag, new_tag, dirname):
     cmd(['git', 'format-patch', '-q', '-o', dirname,
          '{0}..{1}'.format(old_tag, new_tag)])
 
-    patches = [f for f in os.listdir(dirname)
+    patches = [f for f in sorted(os.listdir(dirname))
                if os.path.isfile(os.path.join(dirname, f))]
     with open(dirname + '/series', 'w') as file:
         for p in patches:
-- 
2.14.1


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

* Re: [PATCH] srt_create: Make sure series output is sorted
  2019-04-12 17:31 [PATCH] srt_create: Make sure series output is sorted Tom Zanussi
@ 2019-04-15 10:45 ` Daniel Wagner
  0 siblings, 0 replies; 2+ messages in thread
From: Daniel Wagner @ 2019-04-15 10:45 UTC (permalink / raw)
  To: Tom Zanussi; +Cc: linux-rt-users

Hi Tom,

On 12.04.19 19:31, Tom Zanussi wrote:
> Hi Daniel,
> 
> I actually used your stable-rt-tools srt tool this time to do the
> latest 3.18-rt update release - overall it works well and did the job
> nicely!

Glad you tried it! Thanks!

> I did run into one serious problem in that the series file that gets
> created for the patches tarball lists the patches in essentially random
> order on my system, so using it to apply the series with quilt failed
> immediately.  The patch below fixes the problem for me.

Oh, something I haven't written a test yet for it :(

> There were a few other things I ran into which boiled down to
> essentially lack of documentation and/or informative enough error
> messages, and one or two things having to do with my workflow on two
> separate machines that I'll have to think about.  I'll write some
> patches addressing those and sent when I get the chance.

Sure, just send them. I am sure I forgot a few things to document or
described it wrongly. Also I think the workflow could be improved. I am
not so happy with the 'OLD_TAG NEW_TAG' arguments stuff. It would be
cool if the tool would figure that out on itself.

> Anyway, thanks for the useful tool!

:)

Patch applied.

Thanks,
Daniel


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

end of thread, other threads:[~2019-04-15 10:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-04-12 17:31 [PATCH] srt_create: Make sure series output is sorted Tom Zanussi
2019-04-15 10:45 ` Daniel Wagner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).