← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1630833] Re: Horizon image upload via URL fails with "TypeError: Cannot read property 'data' of undefined"

 

Reviewed:  https://review.openstack.org/457840
Committed: https://git.openstack.org/cgit/openstack/horizon/commit/?id=9d2c4b0485cdf1826f0f1ec80094c80aa244665e
Submitter: Jenkins
Branch:    master

commit 9d2c4b0485cdf1826f0f1ec80094c80aa244665e
Author: gugl <gloria.fang.gu@xxxxxxxx>
Date:   Tue Apr 18 19:17:42 2017 -0700

    Reject result when createImage call has error
    
    When there is an error from createImage, it still invokes
    onCreateImage function which should be invoked only when
    successful service call. Fixed onError function to throw
    the error and the error will show up in the modal toast
    message.
    
    Change-Id: I20725f894835714d8245ec8b192937110cf11ab5
    Closes-bug: #1630833


** Changed in: horizon
       Status: In Progress => Fix Released

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Dashboard (Horizon).
https://bugs.launchpad.net/bugs/1630833

Title:
  Horizon image upload via URL fails with "TypeError: Cannot read
  property 'data' of undefined"

Status in OpenStack Dashboard (Horizon):
  Fix Released

Bug description:
  We have deployed Newton, and trying to upload image via URL on horizon , however it fails on horizon displaying :
  "TypeError: Cannot read property 'data' of undefined"

  However, in Chrome developer mode i see this :

  https://10.240.128.120/horizon/api/glance/images/ Failed to load
  resource: the server responded with a status of 403  (FORBIDDEN)

  i have tried all settings for HORIZON_IMAGES_UPLOAD_MODE as True, False, legacy and direct, 
  and for all settings i get same error. 

  Rest assured , my cors settings for glance look fine.
  In glance-api.conf:
  [cors]
  allowed_origin = https://10.240.128.120/horizon,https://10.240.128.120
  allow_methods=GET,POST,PUT,DELETE

  Also in glance-api-paste.ini:
  [filter:cors]
  paste.filter_factory =  oslo_middleware.cors:filter_factory
  allowed_origin = https://10.240.128.120/horizon,https://10.240.128.120
  allow_methods=GET,POST,PUT,DELETE

  the screenshots might help understand better where the problem lies.
  http://imgur.com/a/nmypx

  A quick google search of "TypeError: Cannot read property 'data' of undefined"
   reveals its related to angular JS however we cannot confirm where exactly the error is happening.

To manage notifications about this bug go to:
https://bugs.launchpad.net/horizon/+bug/1630833/+subscriptions


References