Bug 1413881 - local variable 'img_obj' referenced before assignment
Summary: local variable 'img_obj' referenced before assignment
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: atomic
Version: 7.3
Hardware: x86_64
OS: Linux
high
high
Target Milestone: rc
: ---
Assignee: Lokesh Mandvekar
QA Contact: atomic-bugs@redhat.com
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-01-17 08:44 UTC by Alex Jia
Modified: 2017-05-26 14:28 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-05-26 14:28:28 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2017:1323 0 normal SHIPPED_LIVE atomic bug fix and enhancement update 2017-05-26 18:13:56 UTC

Description Alex Jia 2017-01-17 08:44:45 UTC
Description of problem:
To try to delete all of images, we will hit error like this
"local variable 'img_obj' referenced before assignment".

Version-Release number of selected component (if applicable):

[root@atomic-host-test-986 ~]# atomic host status
State: idle
Deployments:
● rhel-atomic-host-ostree:rhel-atomic-host/7/x86_64/standard
       Version: 7.3.2 (2017-01-13 22:00:41)
        Commit: 96826a0d917d7ff10f9fd0289581649f2ffbddd76f3b80efd3d95cc11915cacb
        OSName: rhel-atomic-host

[root@atomic-host-test-986 ~]# rpm -q atomic docker skopeo
atomic-1.14.1-5.el7.x86_64
docker-1.12.5-14.el7.x86_64
skopeo-0.1.17-1.el7.x86_64

[root@atomic-host-test-986 ~]# cat /etc/redhat-release 
Red Hat Enterprise Linux Atomic Host release 7.3


How reproducible:
always

Steps to Reproduce:
1. atomic pull <images>
2. atomic images delete -a


Actual results:

$ atomic images delete -a
Do you wish to delete the following images?

IMAGE STORAGE
systemd_inside:latest docker
e1dc8e08c83b docker
aa12bb74b8f6 docker
docker.io/busybox:latest docker
docker.io/fedora:latest docker

Confirm (y/N) y
local variable 'img_obj' referenced before assignment

Expected results:
fix it.

Additional info:

I submitted a PR to fix this: https://github.com/projectatomic/atomic/pull/827

Comment 2 Brent Baude 2017-02-01 23:24:59 UTC
I think this was already fixed upstream.

Comment 3 Brent Baude 2017-02-27 16:09:19 UTC
Alex, are we good?

Comment 4 Daniel Walsh 2017-02-27 17:08:41 UTC
Brent if it is fixed in atomic-1.15.4-2.el7 then move this to Modified, if it is in atomic-1.16.2 we should move it to fixed there but put it in POST.

Comment 5 Alex Jia 2017-02-28 14:39:58 UTC
(In reply to Brent Baude from comment #3)
> Alex, are we good?

Yes, it works well for me.

Comment 6 Daniel Walsh 2017-03-01 19:45:03 UTC
Alex which version?

Comment 9 Alex Jia 2017-04-28 00:17:06 UTC
It also works well in latest atomic-1.17.1-1.gitf304570.el7.x86_64 w/ skopeo-0.1.18-1.el7.x86_64 and docker-1.12.6-18.git29d6f69.el7.x86_64.

Comment 10 Alex Jia 2017-05-17 02:18:25 UTC
It also works in atomic-1.17.2-2.git2760e30.el7.x86_64.

Comment 12 errata-xmlrpc 2017-05-26 14:28:28 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2017:1323


Note You need to log in before you can comment on or make changes to this bug.