Zun

Refactor code

Bug #1702587 reported by Kien Nguyen
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Zun
Fix Released
Undecided
Kien Nguyen

Bug Description

At the moment, Zun code still has many `ugly` codes: meaningless naming, unused vars, methods,...
So I think we need to improve it, refactor codes:
- Remove unused method, variable, class.
- Remove unnecessary methods, vars, etc.
- Optimize code.
- Rename variables, methods.

Kien Nguyen (kiennt2609)
Changed in zun:
assignee: nobody → Kien Nguyen (kiennt26)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to zun (master)

Fix proposed to branch: master
Review: https://review.openstack.org/481418

Changed in zun:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Fix proposed to branch: master
Review: https://review.openstack.org/481563

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to zun (master)

Reviewed: https://review.openstack.org/481418
Committed: https://git.openstack.org/cgit/openstack/zun/commit/?id=c2ea4329fa2f7c546e8adb272cec272fbbe0ad1c
Submitter: Jenkins
Branch: master

commit c2ea4329fa2f7c546e8adb272cec272fbbe0ad1c
Author: Kien Nguyen <email address hidden>
Date: Fri Jul 7 11:51:57 2017 +0700

    Rename kw to kwargs

    Change-Id: I0530dd63f5960c9df1e791a419c5c43f19b689ec
    Partial-Bug: #1702587

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to zun (master)

Fix proposed to branch: master
Review: https://review.openstack.org/482489

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Fix proposed to branch: master
Review: https://review.openstack.org/482787

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to zun (master)

Reviewed: https://review.openstack.org/482489
Committed: https://git.openstack.org/cgit/openstack/zun/commit/?id=56592105f9538c5961984d50df321a1f219381a0
Submitter: Jenkins
Branch: master

commit 56592105f9538c5961984d50df321a1f219381a0
Author: Kien Nguyen <email address hidden>
Date: Tue Jul 11 16:52:36 2017 +0700

    Refactor code

    - Fix pep8 error H903: [1]
    - Add method _update_task_state to reduce code lines.
    - Change single quotes to double quotes in docstring - PEP8 docstring
    convention [2].

    [1] http://paste.openstack.org/show/614990/
    [2] https://www.python.org/dev/peps/pep-0257/

    Partials-Bug: #1702587

    Change-Id: Idd125665a2a5f0a73337d36f0259a9f9107946ad

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.openstack.org/482787
Committed: https://git.openstack.org/cgit/openstack/zun/commit/?id=4fcb465879f904cb04da99a7f48cd71db486edbd
Submitter: Jenkins
Branch: master

commit 4fcb465879f904cb04da99a7f48cd71db486edbd
Author: Kien Nguyen <email address hidden>
Date: Wed Jul 12 10:41:02 2017 +0700

    Fix some errors and warnings

    - Dictionary contains duplicate keys.
    - Unexpected arguments.
    - Missed call to __init__ of super class.
    - Missing import i18n marker function in zun/api/controllers/v1/images.py.

    Change-Id: I75c3ce3049ff62ae08868fdcce680945783690fd
    Partials-Bug: #1702587

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.openstack.org/481563
Committed: https://git.openstack.org/cgit/openstack/zun/commit/?id=d7d1b6821f48a1a0fcc56e85496c9d0a0c73aedb
Submitter: Jenkins
Branch: master

commit d7d1b6821f48a1a0fcc56e85496c9d0a0c73aedb
Author: Kien Nguyen <email address hidden>
Date: Fri Jul 7 17:22:20 2017 +0700

    Refactor Glance Image driver

    - In update_image method, has tag arg or not, always return
      update_image_format. The called method, update_image_tags,
      doesn't do any works.
    - Add new method download_image_in_chunks like another methods.
      Init glanceclient in utils module.
    - Update testcases.

    Change-Id: I3a3e9ec38c39ae4abc12196d907b1f32096ad9b6
    Partial-Bug: #1702587

Kien Nguyen (kiennt2609)
Changed in zun:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.