diff mbox series

[01/26] devtool/upgrade: do not delete the workspace/recipes directory

Message ID 20230309151958.3619193-1-alex@linutronix.de
State Accepted, archived
Commit af82e59e8f08369aabd5fa6eb43022982d4e59a7
Headers show
Series [01/26] devtool/upgrade: do not delete the workspace/recipes directory | expand

Commit Message

Alexander Kanavin March 9, 2023, 3:19 p.m. UTC
If it exists, there is no need to delete it, and if it does not,
devtool prints an ugly traceback.

Signed-off-by: Alexander Kanavin <alex@linutronix.de>
---
 scripts/lib/devtool/upgrade.py | 3 ---
 1 file changed, 3 deletions(-)

Comments

Alexander Kanavin March 9, 2023, 3:32 p.m. UTC | #1
Just to make sure: this set (like all of my big patchsets) did get an
all-clear from a-full test matrix, so I believe it's not particularly
risky to take in, despite the feature freeze.

Alex

On Thu, 9 Mar 2023 at 16:20, Alexander Kanavin <alex.kanavin@gmail.com> wrote:
>
> If it exists, there is no need to delete it, and if it does not,
> devtool prints an ugly traceback.
>
> Signed-off-by: Alexander Kanavin <alex@linutronix.de>
> ---
>  scripts/lib/devtool/upgrade.py | 3 ---
>  1 file changed, 3 deletions(-)
>
> diff --git a/scripts/lib/devtool/upgrade.py b/scripts/lib/devtool/upgrade.py
> index 967d157077..6c4a62b558 100644
> --- a/scripts/lib/devtool/upgrade.py
> +++ b/scripts/lib/devtool/upgrade.py
> @@ -125,11 +125,8 @@ def _write_append(rc, srctreebase, srctree, same_dir, no_same_dir, rev, copied,
>      return af
>
>  def _cleanup_on_error(rd, srctree):
> -    rdp = os.path.split(rd)[0] # recipes folder
>      if os.path.exists(rd):
>          shutil.rmtree(rd)
> -    if not len(os.listdir(rdp)):
> -        os.rmdir(rdp)
>      srctree = os.path.abspath(srctree)
>      if os.path.exists(srctree):
>          shutil.rmtree(srctree)
> --
> 2.30.2
>
Martin Jansa March 9, 2023, 3:44 p.m. UTC | #2
Major ffmpeg upgrade might not be risky for components in oe-core (as
you've already patched gst-libav).

But considering how many other projects are still using ffmpeg-4, because
upgrade to ffmpeg-5 api is far from simple, I don't think it's good fit to
merge ffmpeg during feature-freeze - already said the same to Randy.

e.g. gentoo tracker for ffmpeg-5 update:
https://bugs.gentoo.org/showdependencytree.cgi?id=831437&hide_resolved=1

Cheers,

On Thu, Mar 9, 2023 at 4:32 PM Alexander Kanavin <alex.kanavin@gmail.com>
wrote:

> Just to make sure: this set (like all of my big patchsets) did get an
> all-clear from a-full test matrix, so I believe it's not particularly
> risky to take in, despite the feature freeze.
>
> Alex
>
> On Thu, 9 Mar 2023 at 16:20, Alexander Kanavin <alex.kanavin@gmail.com>
> wrote:
> >
> > If it exists, there is no need to delete it, and if it does not,
> > devtool prints an ugly traceback.
> >
> > Signed-off-by: Alexander Kanavin <alex@linutronix.de>
> > ---
> >  scripts/lib/devtool/upgrade.py | 3 ---
> >  1 file changed, 3 deletions(-)
> >
> > diff --git a/scripts/lib/devtool/upgrade.py
> b/scripts/lib/devtool/upgrade.py
> > index 967d157077..6c4a62b558 100644
> > --- a/scripts/lib/devtool/upgrade.py
> > +++ b/scripts/lib/devtool/upgrade.py
> > @@ -125,11 +125,8 @@ def _write_append(rc, srctreebase, srctree,
> same_dir, no_same_dir, rev, copied,
> >      return af
> >
> >  def _cleanup_on_error(rd, srctree):
> > -    rdp = os.path.split(rd)[0] # recipes folder
> >      if os.path.exists(rd):
> >          shutil.rmtree(rd)
> > -    if not len(os.listdir(rdp)):
> > -        os.rmdir(rdp)
> >      srctree = os.path.abspath(srctree)
> >      if os.path.exists(srctree):
> >          shutil.rmtree(srctree)
> > --
> > 2.30.2
> >
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#178254):
> https://lists.openembedded.org/g/openembedded-core/message/178254
> Mute This Topic: https://lists.openembedded.org/mt/97497957/3617156
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [
> Martin.Jansa@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
>
diff mbox series

Patch

diff --git a/scripts/lib/devtool/upgrade.py b/scripts/lib/devtool/upgrade.py
index 967d157077..6c4a62b558 100644
--- a/scripts/lib/devtool/upgrade.py
+++ b/scripts/lib/devtool/upgrade.py
@@ -125,11 +125,8 @@  def _write_append(rc, srctreebase, srctree, same_dir, no_same_dir, rev, copied,
     return af
 
 def _cleanup_on_error(rd, srctree):
-    rdp = os.path.split(rd)[0] # recipes folder
     if os.path.exists(rd):
         shutil.rmtree(rd)
-    if not len(os.listdir(rdp)):
-        os.rmdir(rdp)
     srctree = os.path.abspath(srctree)
     if os.path.exists(srctree):
         shutil.rmtree(srctree)