From notifications-return-21131-archive-asf-public=cust-asf.ponee.io@superset.apache.org Mon May 20 06:08:26 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id 9C7A1180627 for ; Mon, 20 May 2019 08:08:26 +0200 (CEST) Received: (qmail 36281 invoked by uid 500); 20 May 2019 06:08:25 -0000 Mailing-List: contact notifications-help@superset.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@superset.apache.org Delivered-To: mailing list notifications@superset.apache.org Received: (qmail 36272 invoked by uid 99); 20 May 2019 06:08:25 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 20 May 2019 06:08:25 +0000 From: GitBox To: notifications@superset.apache.org Subject: [GitHub] [incubator-superset] elukey commented on issue #7379: Remove the use of Pandas' iloc() in WorldMapViz Message-ID: <155833250579.17337.9913357510972879077.gitbox@gitbox.apache.org> Date: Mon, 20 May 2019 06:08:25 -0000 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit elukey commented on issue #7379: Remove the use of Pandas' iloc() in WorldMapViz URL: https://github.com/apache/incubator-superset/pull/7379#issuecomment-493850581 > `iloc` was introduced because pandas' behavior changed when dealing with multiple columns with the same key. Before it would return the first one, now it returns a dataframe which broke things. > > Does this work when the same metric is used twice? I am running superset 0.32 with some extra patches, including this one, and charts using worlmap with the same metric reused as bubble size work fine now. I have checked a couple of times the pandas' changelog to spot any new feature that could have changed its behavior, but found none. After checking git blame for WorldMapViz though, I noticed that the following bit in the commit that I have indicated seems now the responsible for the need of .iloc or not: ``` def query_obj(self): qry = super(WorldMapViz, self).query_obj() - qry['metrics'] = [ - self.form_data['metric'], self.form_data['secondary_metric']] qry['groupby'] = [self.form_data['entity']] return qry ``` ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: users@infra.apache.org With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org For additional commands, e-mail: notifications-help@superset.apache.org