def make_table(self, obj):
        if not isinstance(obj, dict):
            raise ModuleError(self, "JSON file is not an object")
        key_name = self.get_input('key_name', True)
        iterator = obj.iteritems()
        try:
            first_key, first_value = next(iterator)
        except __HOLE__:
            raise ModuleError(self, "No entry in JSON object")
        count = 1
        if isinstance(first_value, ListType):
            keys = None
            columns = [[] for i in xrange(1 + len(first_value))]
            self.add_list(columns, first_key, first_value)
            for key, value in iterator:
                self.add_list(columns, key, value)
                count += 1
        elif isinstance(first_value, dict):
            keys = first_value.keys()
            key_set = set(keys)
            columns = [[] for i in xrange(1 + len(keys))]
            self.add_dict(columns, keys, key_set, first_key, first_value)
            for key, value in iterator:
                self.add_dict(columns, keys, key_set, key, value)
                count += 1
        else:
            raise ModuleError(self, "Values should be lists or objects")

        if keys is not None:
            names = [key_name] + keys
        else:
            names = None
        return TableObject(columns, count, names)
dataset/ETHPy150Open VisTrails/VisTrails/vistrails/packages/tabledata/read/convert.py/BaseDictToTable.make_table