why pywinauto with backend uia can not recognize some qt element? - qt

with pywinauto version 0.6.5, i try to automate some qt button click. after connecting to app window, print_ctrl_ids display something irrelevant controls excluding button.
|
| TitleBar - '' (L598, T165, R1340, B184)
| [u'', u'1', u'0', 'TitleBar']
| |
| | Menu - '系统' (L580, T165, R598, B183)
| | [u'Menu', u'\u7cfb\u7edfMenu', u'\u7cfb\u7edf', u'\u7cfb\u7edf1', u'\u
b\u7edf0']
| | child_window(title="系统", auto_id="MenuBar", control_type="MenuBar")
| | |
| | | MenuItem - '系统' (L580, T165, R598, B183)
| | | [u'\u7cfb\u7edfMenuItem', u'MenuItem', u'\u7cfb\u7edf2']
| | | child_window(title="系统", control_type="MenuItem")
| |
| | Button - '关闭' (L1321, T164, R1341, B184)
| | [u'\u5173\u95edButton', 'Button', u'\u5173\u95ed']
| | child_window(title="关闭", control_type="Button")
|
| Custom - '' (L580, T184, R1340, B853)
| ['Custom', u'Custom0', u'2', u'Custom1']
| |
| | Custom - '' (L580, T184, R1340, B853)
| | ['Custom', u'Custom0', u'2', u'Custom1']
| | |
| | | Custom - '' (L580, T184, R1340, B514)
| | | [u'4', 'Custom3']
| | | |
| | | | Custom - '' (L580, T461, R1340, B514)
| | | | [u'5', 'Custom4']
| | | | |
| | | | | Custom - '' (L652, T461, R1268, B514)
| | | | | [u'6', 'Custom5']
| | |
| | | Custom - '' (L652, T550, R1098, B569)
| | | [u'7', 'Custom6']
| | |
| | | Custom - '' (L652, T589, R1098, B647)
| | | [u'8', 'Custom7']
| | |
| | | Custom - '' (L1158, T550, R1268, B660)
| | | [u'9', 'Custom8']
| | |
| | | Custom - '' (L1158, T662, R1268, B710)
| | | [u'10', 'Custom9']

Related

How to update/change a created openstack flavor "name" field

I simply ask if there is any way to change an openstack flavor name after its creation with VMs using it as flavor, for example consider this flavor:
+----------------------------+--------------------+
| Field | Value |
+----------------------------+--------------------+
| OS-FLV-DISABLED:disabled | False |
| OS-FLV-EXT-DATA:ephemeral | 0 |
| access_project_ids | None |
| description | None |
| disk | 0 |
| id | g1-1-1-0 |
| name | g1-1-1-0 |
| os-flavor-access:is_public | True |
| properties | |
| ram | 1024 |
| rxtx_factor | 1.0 |
| swap | |
| vcpus | 1 |
+----------------------------+--------------------+
How to change its name field to g1-small?

Index behavior in select not using the key

This is my database table llamados
+-------------+----------------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------------+----------------------+------+-----+---------+-------+
| prospecto | int(10) unsigned | NO | PRI | NULL | |
| bis | tinyint(2) unsigned | NO | PRI | NULL | |
| id_usr | smallint(4) unsigned | NO | MUL | NULL | |
| fecha | date | NO | | NULL | |
| respuesta | tinyint(3) unsigned | NO | | NULL | |
| descripcion | char(255) | NO | | NULL | |
| hora_inicio | time | NO | | NULL | |
| hora_fin | time | NO | | NULL | |
+-------------+----------------------+------+-----+---------+-------+
And this are indexes
+---------------------+--------------+-------------+
| Key_name | Seq_in_index | Column_name |
+---------------------+--------------+-------------+
| PRIMARY | 1 | prospecto |
| PRIMARY | 2 | bis |
| prospecto_fecha_idx | 1 | prospecto |
| prospecto_fecha_idx | 2 | fecha |
| prospecto_fecha_idx | 3 | hora_inicio |
| usr_idx | 1 | id_usr |
+---------------------+--------------+-------------+
I testing this select statement
explain EXTENDED select * from llamados where id_usr = 2;
+------+-------------+----------+------+---------------+------+---------+------+------+----------+-------------+
| id | select_type | table | type | possible_keys | key | key_len | ref | rows | filtered | Extra |
+------+-------------+----------+------+---------------+------+---------+------+------+----------+-------------+
| 1 | SIMPLE | llamados | ALL | usr_idx | NULL | NULL | NULL | 37 | 62.16 | Using where |
+------+-------------+----------+------+---------------+------+---------+------+------+----------+-------------+
I dont understand why is scaning ALL the table and not using usr_idx to filtered the records

No 'users' table in nova database

After successful installation of Openstack RDO in multiple hosts, the mysql database doesn't show any users in nova.
Command SHOW TABLES; in the database does not show user or users table.
MariaDB [nova]> SHOW TABLES;
+--------------------------------------------+
| Tables_in_nova |
+--------------------------------------------+
| agent_builds |
| aggregate_hosts |
| aggregate_metadata |
| aggregates |
| allocations |
| block_device_mapping |
| bw_usage_cache |
| cells |
| certificates |
| compute_nodes |
| console_pools |
| consoles |
| dns_domains |
| fixed_ips |
| floating_ips |
| instance_actions |
| instance_actions_events |
| instance_extra |
| instance_faults |
| instance_group_member |
| instance_group_policy |
| instance_groups |
| instance_id_mappings |
| instance_info_caches |
| instance_metadata |
| instance_system_metadata |
| instance_type_extra_specs |
| instance_type_projects |
| instance_types |
| instances |
| inventories |
| key_pairs |
| migrate_version |
| migrations |
| networks |
| pci_devices |
| project_user_quotas |
| provider_fw_rules |
| quota_classes |
| quota_usages |
| quotas |
| reservations |
| resource_provider_aggregates |
| resource_providers |
| s3_images |
| security_group_default_rules |
| security_group_instance_association |
| security_group_rules |
| security_groups |
| services |
| shadow_agent_builds |
| shadow_aggregate_hosts |
| shadow_aggregate_metadata |
| shadow_aggregates |
| shadow_block_device_mapping |
| shadow_bw_usage_cache |
| shadow_cells |
| shadow_certificates |
| shadow_compute_nodes |
| shadow_console_pools |
| shadow_consoles |
| shadow_dns_domains |
| shadow_fixed_ips |
| shadow_floating_ips |
| shadow_instance_actions |
| shadow_instance_actions_events |
| shadow_instance_extra |
| shadow_instance_faults |
| shadow_instance_group_member |
| shadow_instance_group_policy |
| shadow_instance_groups |
| shadow_instance_id_mappings |
| shadow_instance_info_caches |
| shadow_instance_metadata |
| shadow_instance_system_metadata |
| shadow_instance_type_extra_specs |
| shadow_instance_type_projects |
| shadow_instance_types |
| shadow_instances |
| shadow_key_pairs |
| shadow_migrate_version |
| shadow_migrations |
| shadow_networks |
| shadow_pci_devices |
| shadow_project_user_quotas |
| shadow_provider_fw_rules |
| shadow_quota_classes |
| shadow_quota_usages |
| shadow_quotas |
| shadow_reservations |
| shadow_s3_images |
| shadow_security_group_default_rules |
| shadow_security_group_instance_association |
| shadow_security_group_rules |
| shadow_security_groups |
| shadow_services |
| shadow_snapshot_id_mappings |
| shadow_snapshots |
| shadow_task_log |
| shadow_virtual_interfaces |
| shadow_volume_id_mappings |
| shadow_volume_usage_cache |
| snapshot_id_mappings |
| snapshots |
| tags |
| task_log |
| virtual_interfaces |
| volume_id_mappings |
| volume_usage_cache |
+--------------------------------------------+
109 rows in set (0.00 sec)
user table is in keystone database and not in nova database.
MariaDB [keystone]> show tables;
+------------------------+
| Tables_in_keystone |
+------------------------+
..........................
| trust |
| trust_role |
| user |
..........................

Nova list fields

Is there any way to find the possible fields for the nova show --fields command? Currently I can fill the --fields parameter with anything and it never complains, just fails silently.
The docs say use the show command, but that reports a machines characteristics.
the nova show returns may different from version to version, here is an example:
$ nova show b3cdc6c0-85a7-4904-ae85-71918f734048
+-------------------------------------+-------------------------------------+
| Property | Value |
+-------------------------------------+-------------------------------------+
| OS-EXT-STS:task_state | scheduling |
| image | cirros-0.3.2-x86_64-uec |
| OS-EXT-STS:vm_state | building |
| OS-EXT-SRV-ATTR:instance_name | instance-00000002 |
| flavor | m1.small |
| id | b3cdc6c0-85a7-4904-ae85-71918f734048|
| security_groups | [{u'name': u'default'}] |
| user_id | 376744b5910b4b4da7d8e6cb483b06a8 |
| OS-DCF:diskConfig | MANUAL |
| accessIPv4 | |
| accessIPv6 | |
| progress | 0 |
| OS-EXT-STS:power_state | 0 |
| OS-EXT-AZ:availability_zone | nova |
| config_drive | |
| status | BUILD |
| updated | 2013-07-16T16:25:34Z |
| hostId | |
| OS-EXT-SRV-ATTR:host | None |
| key_name | KeyPair01 |
| OS-EXT-SRV-ATTR:hypervisor_hostname | None |
| name | myCirrosServer |
| adminPass | tVs5pL8HcPGw |
| tenant_id | 66265572db174a7aa66eba661f58eb9e |
| created | 2013-07-16T16:25:34Z |
| metadata | {u'KEY': u'VALUE'} |
+-------------------------------------+-------------------------------------+
The property column is all the fields available to specify to --fields

How to create very dynamic menu like Picnik's?

Picnik's left hand menu:
http://www.picnik.com/app#/create/shapes
Basic features:
Accordion like components (but multiple items can be selected)
Each stack has multiple child stacked
The whole menu resizes depending on how many stacks are selected and a scrollbar is also shown if necessary
So how Do I go about creating a menu like this? Any pointers to boot?
Thanks!
You might try a combination of VBox, collapsible panels and lists ( http://hasseg.org/blog/?p=113 ) That should give you all the tools you need.
My Vision of it: (cause I like drawing with pipes and dashes)
VBOX-------------------------
| |
| Collapsing Panel-------- |
| | | |
| | Tile List---------- | |
| | | | | |
| | | Tile | | |
| | | Tile | | |
| | ------------------ | |
| ----------------------- |
| |
| Collapsing Panel-------- |
| | | |
| | Tile List---------- | |
| | | | | |
| | | Tile | | |
| | | Tile | | |
| | ------------------ | |
| ----------------------- |
| |
| Collapsing Panel-------- |
| | | |
| | Tile List---------- | |
| | | | | |
| | | Tile | | |
| | | Tile | | |
| | ------------------ | |
| ----------------------- |
----------------------------

Resources