Skip to contentSkip to conversation

b4 not finding patches

DISCUSSION Mark Brown 2 participants 6 messages Mar 18, 2020 – Mar 20, 2020

lore
Share & tools
lore

Mark Brown

author
#0 lore raw

When I run

b4 am -t [email protected]

it says:

| Grabbing thread from lore.kernel.org
| Analyzing 13 messages in the thread
| Found new series v1
| Will use the latest revision: v3
| You can pick other revisions using the -vN flag
| ---
| Writing ./v3_20200316_kuninori_morimoto_gx_renesas_com.mbx
|   ERROR: missing [1/6]!
|   ERROR: missing [2/6]!
|   ERROR: missing [3/6]!
|   ERROR: missing [4/6]!
|   ERROR: missing [5/6]!
|   ERROR: missing [6/6]!
| ---
| Total patches: 0
| ---

even though lore appears to have the full thread:

https://lore.kernel.org/alsa-devel/[email protected]/

Thanks,
Mark

#1 lore raw
Quoted 23 lines · Mark Brown

When I run

b4 am -t [email protected]

it says:

| Grabbing thread from lore.kernel.org
| Analyzing 13 messages in the thread
| Found new series v1
| Will use the latest revision: v3
| You can pick other revisions using the -vN flag
| ---
| Writing ./v3_20200316_kuninori_morimoto_gx_renesas_com.mbx
|   ERROR: missing [1/6]!
|   ERROR: missing [2/6]!
|   ERROR: missing [3/6]!
|   ERROR: missing [4/6]!
|   ERROR: missing [5/6]!
|   ERROR: missing [6/6]!
| ---
| Total patches: 0
| ---
Quoted 3 lines

even though lore appears to have the full thread:

https://lore.kernel.org/alsa-devel/[email protected]/

This is because the cover letter is the only bit where we see "v3":

Quoted 1 line

[PATCH v3 0/6]

all other messages have

Quoted 1 line

[PATCH N/6]

I'm not sure if there is a reliably clean way of handling this situation, but I'll think about it. For this particular case, you can just pass -v1 to "b4 am" to grab the actual patches.

-K

author
#2 lore raw
Quoted 8 lines · Konstantin Ryabitsev
Quoted 1 line · Mark Brown

https://lore.kernel.org/alsa-devel/[email protected]/

This is because the cover letter is the only bit where we see "v3":

Quoted 1 line

[PATCH v3 0/6]

Quoted 7 lines

all other messages have

Quoted 1 line

[PATCH N/6]

I'm not sure if there is a reliably clean way of handling this situation, but I'll think about it. For this particular case, you can just pass -v1 to "b4 am" to grab the actual patches.

...but not the tags added to the cover letter which is the main reason I'm doing this :/ . I do see the issue given people sending new serieses in reply to existing ones though. Perhaps some heuristic about lack of ambiguity (eg, if we're looking for six patches and find exactly six patches)?

#3 lore raw
Quoted 14 lines · Mark Brown
Quoted 6 lines
Quoted 1 line

https://lore.kernel.org/alsa-devel/[email protected]/

This is because the cover letter is the only bit where we see "v3":

Quoted 1 line

[PATCH v3 0/6]

Quoted 7 lines

all other messages have

Quoted 1 line

[PATCH N/6]

I'm not sure if there is a reliably clean way of handling this situation, but I'll think about it. For this particular case, you can just pass -v1 to "b4 am" to grab the actual patches.

Quoted 5 lines

...but not the tags added to the cover letter which is the main reason I'm doing this :/ . I do see the issue given people sending new serieses in reply to existing ones though. Perhaps some heuristic about lack of ambiguity (eg, if we're looking for six patches and find exactly six patches)?

This case is probably easier, because it properly threads those patches below the cover letter. I'll work in some logic to handle cases like that:

- patches have no explicit version info
- the 00/NN immediately upthread specifies version

in this case we can fairly safely apply the cover letter version info to all patches.

-K

#4 lore raw
In reply to Mark Brown
Quoted 9 lines · Mark Brown
Quoted 3 lines

I'm not sure if there is a reliably clean way of handling this situation, but I'll think about it. For this particular case, you can just pass -v1 to "b4 am" to grab the actual patches.

...but not the tags added to the cover letter which is the main reason I'm doing this :/ . I do see the issue given people sending new serieses in reply to existing ones though. Perhaps some heuristic about lack of ambiguity (eg, if we're looking for six patches and find exactly six patches)?

I have code that properly handles this situation in master:

------

$ python3 b4/command.py am -o/tmp [email protected] -t
Looking up https://lore.kernel.org/r/[email protected]
Grabbing thread from lore.kernel.org
Analyzing 13 messages in the thread
---
Writing /tmp/v3_20200316_kuninori_morimoto_gx_renesas_com.mbx
  [PATCH 1/6] ASoC: soc-core: Merge CPU/Codec DAIs
    Added: Reviewed-by: Ranjani Sridharan <[email protected]>
    Added: Reviewed-by: Pierre-Louis Bossart <[email protected]>
  [PATCH 2/6] ASoC: soc-core: Merge for_each_rtd_cpu/codec_dais()
    Added: Reviewed-by: Ranjani Sridharan <[email protected]>
    Added: Reviewed-by: Pierre-Louis Bossart <[email protected]>
  [PATCH 3/6] ASoC: soc-dapm: Merge for_each_rtd_cpu/codec_dais()
    Added: Reviewed-by: Ranjani Sridharan <[email protected]>
    Added: Reviewed-by: Pierre-Louis Bossart <[email protected]>
  [PATCH 4/6] ASoC: soc-pcm: Merge for_each_rtd_cpu/codec_dais()
    Added: Reviewed-by: Ranjani Sridharan <[email protected]>
    Added: Reviewed-by: Pierre-Louis Bossart <[email protected]>
  [PATCH 5/6] ASoC: soc-core: Merge CPU/Codec for soc_dai_pcm_new()
    Added: Reviewed-by: Ranjani Sridharan <[email protected]>
    Added: Reviewed-by: Pierre-Louis Bossart <[email protected]>
  [PATCH 6/6] ASoC: soc-pcm: Merge CPU/Codec MSB at soc_pcm_apply_msb()
    Added: Reviewed-by: Ranjani Sridharan <[email protected]>
    Added: Reviewed-by: Pierre-Louis Bossart <[email protected]>
---
Total patches: 6
---
Cover: /tmp/v3_20200316_kuninori_morimoto_gx_renesas_com.cover
 Link: https://lore.kernel.org/r/[email protected]
 Base: not found, sorry
       git checkout -b v3_20200316_kuninori_morimoto_gx_renesas_com master
       git am /tmp/v3_20200316_kuninori_morimoto_gx_renesas_com.mbx
------

You can try that directly from the repo (if you set PYTHONPATH=.), or build your own package.

Alternatively, you can run:

b4 mbox [email protected] (edit all subjects to add v3 to them)
b4 am [email protected] -m that.mbox

I'll probably release 0.3.4 tomorrow with a couple more fixes.

Best,
-K

author
#5 lore raw
Quoted 9 lines · Konstantin Ryabitsev
Quoted 5 lines · Mark Brown

...but not the tags added to the cover letter which is the main reason I'm doing this :/ . I do see the issue given people sending new serieses in reply to existing ones though. Perhaps some heuristic about lack of ambiguity (eg, if we're looking for six patches and find exactly six patches)?

I have code that properly handles this situation in master:

That works, thanks (and the shell script to run from git is super helpful too!).