{"action":"closed","issue":{"url":"https://api.github.com/repos/scylladb/scylla/issues/1465","repository_url":"https://api.github.com/repos/scylladb/scylla","labels_url":"https://api.github.com/repos/scylladb/scylla/issues/1465/labels{/name}","comments_url":"https://api.github.com/repos/scylladb/scylla/issues/1465/comments","events_url":"https://api.github.com/repos/scylladb/scylla/issues/1465/events","html_url":"https://github.com/scylladb/scylla/issues/1465","id":166125153,"number":1465,"title":"Adding a column to a user type is broken with nested types","user":{"login":"tgrabiec","id":283695,"avatar_url":"https://avatars.githubusercontent.com/u/283695?v=3","gravatar_id":"","url":"https://api.github.com/users/tgrabiec","html_url":"https://github.com/tgrabiec","followers_url":"https://api.github.com/users/tgrabiec/followers","following_url":"https://api.github.com/users/tgrabiec/following{/other_user}","gists_url":"https://api.github.com/users/tgrabiec/gists{/gist_id}","starred_url":"https://api.github.com/users/tgrabiec/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tgrabiec/subscriptions","organizations_url":"https://api.github.com/users/tgrabiec/orgs","repos_url":"https://api.github.com/users/tgrabiec/repos","events_url":"https://api.github.com/users/tgrabiec/events{/privacy}","received_events_url":"https://api.github.com/users/tgrabiec/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/scylladb/scylla/labels/bug","name":"bug","color":"eb6420"}],"state":"closed","locked":false,"assignee":{"login":"tgrabiec","id":283695,"avatar_url":"https://avatars.githubusercontent.com/u/283695?v=3","gravatar_id":"","url":"https://api.github.com/users/tgrabiec","html_url":"https://github.com/tgrabiec","followers_url":"https://api.github.com/users/tgrabiec/followers","following_url":"https://api.github.com/users/tgrabiec/following{/other_user}","gists_url":"https://api.github.com/users/tgrabiec/gists{/gist_id}","starred_url":"https://api.github.com/users/tgrabiec/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tgrabiec/subscriptions","organizations_url":"https://api.github.com/users/tgrabiec/orgs","repos_url":"https://api.github.com/users/tgrabiec/repos","events_url":"https://api.github.com/users/tgrabiec/events{/privacy}","received_events_url":"https://api.github.com/users/tgrabiec/received_events","type":"User","site_admin":false},"assignees":[{"login":"tgrabiec","id":283695,"avatar_url":"https://avatars.githubusercontent.com/u/283695?v=3","gravatar_id":"","url":"https://api.github.com/users/tgrabiec","html_url":"https://github.com/tgrabiec","followers_url":"https://api.github.com/users/tgrabiec/followers","following_url":"https://api.github.com/users/tgrabiec/following{/other_user}","gists_url":"https://api.github.com/users/tgrabiec/gists{/gist_id}","starred_url":"https://api.github.com/users/tgrabiec/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tgrabiec/subscriptions","organizations_url":"https://api.github.com/users/tgrabiec/orgs","repos_url":"https://api.github.com/users/tgrabiec/repos","events_url":"https://api.github.com/users/tgrabiec/events{/privacy}","received_events_url":"https://api.github.com/users/tgrabiec/received_events","type":"User","site_admin":false}],"milestone":null,"comments":0,"created_at":"2016-07-18T15:43:02Z","updated_at":"2016-07-18T17:14:27Z","closed_at":"2016-07-18T17:14:27Z","body":"*Installation details*\r\nScylla version (or git commit hash): 4eca7632ec479aa7d0977c6d75e01e56f187239d\r\nCluster size: 3\r\n\r\nFound while trying to make cassandra-unit-tests work with driver version 3.0.2.\r\n\r\nSetup:\r\n```\r\ncreate keyspace ks1 WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 };\r\nuse ks1;\r\nCREATE TYPE t1 (a int, b int);\r\nCREATE TABLE test (a int PRIMARY KEY, b frozen<tuple<int,ks1.t1>>);\r\nINSERT INTO test (a, b) VALUES(1, (1, {a:1, b:1}));\r\nselect * from test;\r\n\r\n a | b\r\n---+-------------------\r\n 1 | (1, {a: 1, b: 1})\r\n\r\n(1 rows)\r\n```\r\n\r\nThe interesting part:\r\n```\r\nALTER TYPE ks1.t1 add c int;\r\nselect * from test;\r\n\r\n a | b\r\n---+-------------------------\r\n 1 | (1, {a: 1, b: 1}, None)\r\n\r\n(1 rows)\r\n\r\nINSERT INTO test (a, b) VALUES(2, (2, {a: 2, b: 2, c: 2}));\r\nselect * from test;\r\n\r\n a | b\r\n---+-------------------------\r\n 1 | (1, {a: 1, b: 1}, None)\r\n 2 | (2, {a: 2, b: 2}, None)\r\n\r\n(2 rows)\r\n```\r\n\r\nAfter restarting the cqlsh client:\r\n\r\n```\r\ncqlsh:ks1> select * from test;\r\n\r\n a | b\r\n---+----------------------------------\r\n 1 | (1, {a: 1, b: 1, c: null}, None)\r\n 2 |    (2, {a: 2, b: 2, c: 2}, None)\r\n\r\n(2 rows)\r\n\r\n```\r\n\r\nExpected result:\r\n\r\n```\r\ncqlsh:ks1> select * from test;\r\n\r\n a | b\r\n---+-------------------------\r\n 1 | (1, {a: 1, b: 1, c: null})\r\n\r\n(1 rows)\r\ncqlsh:ks1> INSERT INTO test (a, b) VALUES(2, (2, {a: 2, b: 2, c: 2}));\r\ncqlsh:ks1> select * from test;\r\n\r\n a | b\r\n---+----------------------------\r\n 1 | (1, {a: 1, b: 1, c: null})\r\n 2 |    (2, {a: 2, b: 2, c: 2})\r\n\r\n(2 rows)\r\n```\r\n\r\n"}}
{"actor":{"display_login":"avikivity"}}