On tutor-cairn#12, a couple of primary key data types were converted from Int64 to UInt64, these migrations are failing as when applied via the tutor-cairn initialization, since this uses the clickhouse client to apply migrations, and clickhouse refuses to change the representation of a primary key.
Log Excerpt:
Applying migration 0009_add_graded_column_to_course_blocks.sql... OK
Applying migration 0010_modify_graded_bool.sql... OK
Received exception from server (version 22.1.3):
Code: 524. DB::Exception: Received from cairn-clickhouse:9000. DB::Exception: ALTER of key column user_id from type Int64 to type UInt64 is not safe because it can change the representation of primary key. (ALTER_OF_COLUMN_IS_FORBIDDEN)
(query: ALTER TABLE events
MODIFY COLUMN user_id UInt64;)
Applying migration 0011_modify_events_type.sql... Traceback (most recent call last):
File "/scripts/cairn", line 120, in <module>
main()
File "/scripts/cairn", line 47, in main
args.func(args)
File "/scripts/cairn", line 76, in command_migrate
run_command("--queries-file", path)
File "/scripts/cairn", line 89, in run_command
result = subprocess.check_output(get_client_command(*args))
File "/usr/lib/python3.8/subprocess.py", line 415, in check_output
return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
File "/usr/lib/python3.8/subprocess.py", line 516, in run
raise CalledProcessError(retcode, process.args,
@FahadKhalid210 or @regis, is there another way I should be applying this migration?