C:\Users\maf11_adm>dap --loglevel debug --logfile C:\Temp\dap.log initdb --connection-string postgresql://postgres:admin @localhost:5432/postgres --namespace canvas --table accounts DEBUG:asyncio:Using selector: SelectSelector 2024-03-27 13:11:50,343 - DEBUG - Checking for valid database connection string (abstract_db_command.py:14) 2024-03-27 13:11:50,346 - DEBUG - Checking connection to database (abstract_db_command.py:23) INFO:pysqlsync.postgres:connecting to postgres@localhost:5432/postgres INFO:pysqlsync.postgres:PostgreSQL version 16.0.2 final 2024-03-27 13:11:50,499 - DEBUG - Client region: us-east-1 (api.py:114) 2024-03-27 13:11:50,500 - DEBUG - initializing table: canvas.accounts (sql.py:31) INFO:pysqlsync.postgres:connecting to postgres@localhost:5432/postgres INFO:pysqlsync.postgres:PostgreSQL version 16.0.2 final DEBUG:pysqlsync:analyzing dataclass `database_version`: @dataclasses.dataclass class database_version: """ Table for storing meta-information about the database schema version. :param version: The version of the database schema. """ version: Annotated[Union[int, DefaultTag], Identity, PrimaryKey] DEBUG:pysqlsync:analyzing dataclass `table_sync`: @dataclasses.dataclass class table_sync: """ Table for storing meta-information about tables managed by the client library. :param source_namespace: The namespace of the source table exposed by DAP API (e.g. `canvas`). :param source_table: The name of the source table exposed by DAP API (e.g. `accounts`). :param timestamp: The timestamp of the source table that can be used by the client library in incremental queries during subsequent `syncdb` command executions. :param schema_version: The latest schema version of the source table at the time point when it was last initializedor synchronized with the DAP API. :param target_schema: The name of the target schema in the local database if applicable (e.g. in case of a PostgreSQL database the tables can be grouped into schemas). :param target_table: The name of the target table in the local database. In might differ from the name of the source table. For example in case of a MySQL database, the tables cannot be grouped in schemas. In this case, the implementor can use a prefix that reflects the namespace of the source table. For example, the qualified name `canvas.accounts` would become `canvas__accounts`. :param schema_description: The latest schema descriptor of the source table at the time point when it was initialized or last synchronized. :param schema_description_format: The format of the schema descriptor (e.g. `json`). """ id: Annotated[Union[int, DefaultTag], Identity, PrimaryKey] source_namespace: Annotated[str, MaxLength(64)] source_table: Annotated[str, MaxLength(64)] timestamp: datetime schema_version: int target_schema: Annotated[Optional[str], MaxLength(64)] target_table: Annotated[str, MaxLength(64)] schema_description_format: Annotated[str, MaxLength(64)] schema_description: str DEBUG:pysqlsync:desired state: CREATE SCHEMA IF NOT EXISTS "instructure_dap"; CREATE TABLE "instructure_dap"."database_version" ( "version" bigint GENERATED BY DEFAULT AS IDENTITY, CONSTRAINT "pk_database_version" PRIMARY KEY ("version") ); COMMENT ON TABLE "instructure_dap"."database_version" IS 'Table for storing meta-information about the database schema version.'; COMMENT ON COLUMN "instructure_dap"."database_version"."version" IS 'The version of the database schema.'; CREATE TABLE "instructure_dap"."table_sync" ( "id" bigint GENERATED BY DEFAULT AS IDENTITY, "source_namespace" varchar(64) NOT NULL, "source_table" varchar(64) NOT NULL, "timestamp" timestamp NOT NULL, "schema_version" bigint NOT NULL, "target_schema" varchar(64), "target_table" varchar(64) NOT NULL, "schema_description_format" varchar(64) NOT NULL, "schema_description" text NOT NULL, CONSTRAINT "pk_table_sync" PRIMARY KEY ("id") ); COMMENT ON TABLE "instructure_dap"."table_sync" IS 'Table for storing meta-information about tables managed by the client library.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."source_namespace" IS 'The namespace of the source table exposed by DAP API (e.g. `canvas`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."source_table" IS 'The name of the source table exposed by DAP API (e.g. `accounts`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."timestamp" IS 'The timestamp of the source table that can be used by the client library in incremental queries during subsequent `syncdb` command executions.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_version" IS 'The latest schema version of the source table at the time point when it was last initialized or synchronized with the DAP API.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."target_schema" IS 'The name of the target schema in the local database if applicable (e.g. in case of a PostgreSQL database the tables can be grouped into schemas).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."target_table" IS 'The name of the target table in the local database.In might differ from the name of the source table. For example in case of a MySQL database, the tables cannot be grouped in schemas. In this case, the implementor can use a prefix that reflects the namespace of the source table. For example, the qualified name `canvas.accounts` would become `canvas__accounts`.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_description_format" IS 'The format of the schema descriptor (e.g. `json`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_description" IS 'The latest schema descriptor of the source table at the time point when it was initialized or last synchronized.'; DEBUG:pysqlsync:query SQL with into PostgreSQLEnumMeta: SELECT t.typname as enum_name, e.enumlabel as enum_value FROM pg_catalog.pg_type t JOIN pg_catalog.pg_enum e ON t.oid = e.enumtypid JOIN pg_catalog.pg_namespace n ON n.oid = t.typnamespace WHERE n.nspname = 'instructure_dap' ORDER BY enum_name, e.enumsortorder ; DEBUG:pysqlsync:query SQL with into str: SELECT cls.relname FROM pg_catalog.pg_class AS cls INNER JOIN pg_catalog.pg_namespace AS nsp ON cls.relnamespace = nsp.oid WHERE nsp.nspname = 'instructure_dap' AND (cls.relkind = 'c') ; DEBUG:pysqlsync:query SQL with into str: SELECT cls.relname FROM pg_catalog.pg_class AS cls INNER JOIN pg_catalog.pg_namespace AS nsp ON cls.relnamespace = nsp.oid WHERE nsp.nspname = 'instructure_dap' AND (cls.relkind = 'r' OR cls.relkind = 'v') ; DEBUG:pysqlsync:found 1 namespaces DEBUG:pysqlsync:found 0 enum(s) in namespace "" DEBUG:pysqlsync:found 0 struct(s) in namespace "" DEBUG:pysqlsync:found 0 table(s) in namespace "" DEBUG:pysqlsync:discovered state: INFO:pysqlsync:synchronize schema with SQL: CREATE SCHEMA IF NOT EXISTS "instructure_dap"; CREATE TABLE "instructure_dap"."database_version" ( "version" bigint GENERATED BY DEFAULT AS IDENTITY, CONSTRAINT "pk_database_version" PRIMARY KEY ("version") ); COMMENT ON TABLE "instructure_dap"."database_version" IS 'Table for storing meta-information about the database schema version.'; COMMENT ON COLUMN "instructure_dap"."database_version"."version" IS 'The version of the database schema.'; CREATE TABLE "instructure_dap"."table_sync" ( "id" bigint GENERATED BY DEFAULT AS IDENTITY, "source_namespace" varchar(64) NOT NULL, "source_table" varchar(64) NOT NULL, "timestamp" timestamp NOT NULL, "schema_version" bigint NOT NULL, "target_schema" varchar(64), "target_table" varchar(64) NOT NULL, "schema_description_format" varchar(64) NOT NULL, "schema_description" text NOT NULL, CONSTRAINT "pk_table_sync" PRIMARY KEY ("id") ); COMMENT ON TABLE "instructure_dap"."table_sync" IS 'Table for storing meta-information about tables managed by the client library.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."source_namespace" IS 'The namespace of the source table exposed by DAP API (e.g. `canvas`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."source_table" IS 'The name of the source table exposed by DAP API (e.g. `accounts`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."timestamp" IS 'The timestamp of the source table that can be used by the client library in incremental queries during subsequent `syncdb` command executions.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_version" IS 'The latest schema version of the source table at the time point when it was last initialized or synchronized with the DAP API.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."target_schema" IS 'The name of the target schema in the local database if applicable (e.g. in case of a PostgreSQL database the tables can be grouped into schemas).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."target_table" IS 'The name of the target table in the local database.In might differ from the name of the source table. For example in case of a MySQL database, the tables cannot be grouped in schemas. In this case, the implementor can use a prefix that reflects the namespace of the source table. For example, the qualified name `canvas.accounts` would become `canvas__accounts`.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_description_format" IS 'The format of the schema descriptor (e.g. `json`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_description" IS 'The latest schema descriptor of the source table at the time point when it was initialized or last synchronized.'; DEBUG:pysqlsync:execute SQL: CREATE SCHEMA IF NOT EXISTS "instructure_dap"; CREATE TABLE "instructure_dap"."database_version" ( "version" bigint GENERATED BY DEFAULT AS IDENTITY, CONSTRAINT "pk_database_version" PRIMARY KEY ("version") ); COMMENT ON TABLE "instructure_dap"."database_version" IS 'Table for storing meta-information about the database schema version.'; COMMENT ON COLUMN "instructure_dap"."database_version"."version" IS 'The version of the database schema.'; CREATE TABLE "instructure_dap"."table_sync" ( "id" bigint GENERATED BY DEFAULT AS IDENTITY, "source_namespace" varchar(64) NOT NULL, "source_table" varchar(64) NOT NULL, "timestamp" timestamp NOT NULL, "schema_version" bigint NOT NULL, "target_schema" varchar(64), "target_table" varchar(64) NOT NULL, "schema_description_format" varchar(64) NOT NULL, "schema_description" text NOT NULL, CONSTRAINT "pk_table_sync" PRIMARY KEY ("id") ); COMMENT ON TABLE "instructure_dap"."table_sync" IS 'Table for storing meta-information about tables managed by the client library.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."source_namespace" IS 'The namespace of the source table exposed by DAP API (e.g. `canvas`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."source_table" IS 'The name of the source table exposed by DAP API (e.g. `accounts`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."timestamp" IS 'The timestamp of the source table that can be used by the client library in incremental queries during subsequent `syncdb` command executions.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_version" IS 'The latest schema version of the source table at the time point when it was last initialized or synchronized with the DAP API.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."target_schema" IS 'The name of the target schema in the local database if applicable (e.g. in case of a PostgreSQL database the tables can be grouped into schemas).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."target_table" IS 'The name of the target table in the local database.In might differ from the name of the source table. For example in case of a MySQL database, the tables cannot be grouped in schemas. In this case, the implementor can use a prefix that reflects the namespace of the source table. For example, the qualified name `canvas.accounts` would become `canvas__accounts`.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_description_format" IS 'The format of the schema descriptor (e.g. `json`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_description" IS 'The latest schema descriptor of the source table at the time point when it was initialized or last synchronized.'; DEBUG:pysqlsync:query SQL with into database_version: SELECT version FROM "instructure_dap"."database_version" 2024-03-27 13:11:50,674 - DEBUG - No version records found in "instructure_dap"."database_version" (db_version_upgrader.py:67) 2024-03-27 13:11:50,675 - DEBUG - Current version: 0; Latest version: 1 (db_version_upgrader.py:40) 2024-03-27 13:11:50,675 - DEBUG - Upgrading database (db_version_upgrader.py:45) 2024-03-27 13:11:50,675 - DEBUG - Running upgrade scripts from version 0 to 1 (db_version_upgrader.py:81) 2024-03-27 13:11:50,678 - DEBUG - Upgrading from version 0 to 1 (db_version_upgrader.py:85) 2024-03-27 13:11:50,678 - DEBUG - Running upgrade script: C:\Users\maf11_adm\AppData\Local\Programs\Python\Python312\Lib\site-packages\dap\version_upgrade\postgresql_0_to_1.sql (db_version_upgrader.py:89) 2024-03-27 13:11:50,680 - DEBUG - Executing SQL: DO $$ DECLARE ns VARCHAR[]; BEGIN ns := ARRAY ['canvas', 'catalog', 'canvas_logs']; EXECUTE ('TRUNCATE TABLE instructure_dap.table_sync'); FOR i IN 1..ARRAY_LENGTH(ns, 1) LOOP IF EXISTS (SELECT 1 FROM information_schema.tables WHERE table_schema = ns[i] AND table_name = 'dap_meta') THEN EXECUTE FORMAT(' INSERT INTO instructure_dap.table_sync ( source_namespace, source_table, timestamp, schema_version, target_schema, target_table, schema_description_format, schema_description ) SELECT namespace, source_table, timestamp, schema_version, target_schema, target_table, schema_description_format, schema_description FROM %I.dap_meta', ns[i]); EXECUTE FORMAT('ALTER TABLE %I.dap_meta RENAME TO dap_meta_backup', ns[i]); ELSE RAISE NOTICE 'Table %.dap_meta does not exist.', ns[i]; END IF; END LOOP; END $$; (db_version_upgrader.py:93) DEBUG:pysqlsync:execute SQL: DO $$ DECLARE ns VARCHAR[]; BEGIN ns := ARRAY ['canvas', 'catalog', 'canvas_logs']; EXECUTE ('TRUNCATE TABLE instructure_dap.table_sync'); FOR i IN 1..ARRAY_LENGTH(ns, 1) LOOP IF EXISTS (SELECT 1 FROM information_schema.tables WHERE table_schema = ns[i] AND table_name = 'dap_meta') THEN EXECUTE FORMAT(' INSERT INTO instructure_dap.table_sync ( source_namespace, source_table, timestamp, schema_version, target_schema, target_table, schema_description_format, schema_description ) SELECT namespace, source_table, timestamp, schema_version, target_schema, target_table, schema_description_format, schema_description FROM %I.dap_meta', ns[i]); EXECUTE FORMAT('ALTER TABLE %I.dap_meta RENAME TO dap_meta_backup', ns[i]); ELSE RAISE NOTICE 'Table %.dap_meta does not exist.', ns[i]; END IF; END LOOP; END $$; DEBUG:pysqlsync:execute SQL: DELETE FROM "instructure_dap"."database_version" DEBUG:pysqlsync:execute SQL: INSERT INTO "instructure_dap"."database_version" ("version") VALUES ($1) ON CONFLICT ("version") DO NOTHING ; 2024-03-27 13:11:50,704 - DEBUG - fetching schema for table: canvas.accounts (sql_op.py:103) 2024-03-27 13:11:50,704 - DEBUG - Get schema of table: accounts (api.py:428) 2024-03-27 13:11:50,704 - DEBUG - Authenticating to DAP in region us-east-1 (api.py:371) DEBUG:aiohttp_retry:Attempt 1 out of 3 2024-03-27 13:11:51,147 - DEBUG - GET/POST response payload: {'schema': {'$schema': 'https://json-schema.org/draft/2020-12/schema', 'type': 'object', 'properties': {'meta': {'type': 'object', 'properties': {'ts': {'type': 'string', 'format': 'date-time'}, 'action': {'type': 'string', 'enum': ['U', 'D'], 'title': 'Identifies if a record is to be upserted (inserted or updated) or (hard) deleted.'}}, 'additionalProperties': False, 'required': ['ts'], 'title': 'Meta-information associated with the record.'}, 'key': {'type': 'object', 'properties': {'id': {'type': 'integer', 'format': 'int64', 'description': 'The ID of the Account object.'}}, 'additionalProperties': False, 'required': ['id'], 'title': 'Stores data about account objects in the Canvas system.', 'description': 'Accounts are most often used to represent a hierarchy of colleges, schools, departments, campuses.'}, 'value': {'type':'object', 'properties': {'name': {'type': 'string', 'maxLength': 255, 'description': 'The display name of the account.'}, 'deleted_at': {'type': 'string', 'format': 'date-time', 'description': 'Timestamp of when the account was deleted. Will only ever be NULL for end customers.'}, 'parent_account_id': {'type': 'integer', 'format': 'int64', 'description': "The account's parent ID, or NULL if this is the root account."}, 'current_sis_batch_id': {'type': 'integer', 'format': 'int64', 'description': 'The ID of the currently processing SIS (Student Information System) batch (if submitted via UI, not API).'}, 'storage_quota': {'type': 'integer', 'format': 'int64', 'description': 'The storage quote for the account, in megabytes.'}, 'default_storage_quota': {'type': 'integer', 'format': 'int64', 'description': 'The storage quota for children accounts in megabytes, if not otherwise specified.'}, 'default_locale': {'type': 'string', 'maxLength': 255, 'description': 'Language for the account.'}, 'default_user_storage_quota': {'type': 'integer', 'format': 'int64', 'description': 'The default storage quota for users in the account in megabytes, if not otherwise specified.'}, 'default_group_storage_quota': {'type': 'integer', 'format': 'int64', 'description': 'The storage quota for a group in the account in megabytes, if not otherwise specified.'}, 'integration_id': {'type': 'string', 'maxLength': 255, 'description': "The account's identifier in the Student Information System."}, 'lti_context_id': {'type': 'string', 'maxLength': 255, 'description': 'UUID of the Canvas context in LTI standard. Secondary ID for this context, could be used in API to identify resource as well.'}, 'consortium_parent_account_id': {'type': 'integer', 'format': 'int64', 'description': 'The root account of the consortium account, if this root account is part of a consortium.'}, 'course_template_id': {'type': 'integer', 'format': 'int64', 'description': 'The course selected as a template for new courses created in this account. 0 if a template should not be used, nor inherited.'}, 'created_at': {'type': 'string', 'format': 'date-time', 'description': 'Timestamp of when the account was created.'}, 'updated_at': {'type': 'string', 'format': 'date-time', 'description': 'Timestamp ofwhen the account was updated.'}, 'workflow_state': {'type': 'string', 'enum': ['__dap_unspecified__', 'active', 'deleted', 'suspended'], 'description': 'Life-cycle state for account.'}, 'default_time_zone': {'type': 'string', 'maxLength': 255, 'description': 'The default time zone of the account. Allowed time zones are [IANA time zones](https://www.iana.org/time-zones) or friendlier [Ruby on Rails time zones](https://api.rubyonrails.org/classes/ActiveSupport/TimeZone.html).'}, 'uuid': {'type': 'string', 'maxLength': 255, 'description': 'The UUID of the account.'}, 'sis_source_id': {'type': 'string', 'maxLength': 255, 'description': 'Correlated id for the record for this course in the SIS system (assuming SIS integration is configured)'}}, 'additionalProperties': False, 'required': ['created_at', 'updated_at', 'workflow_state'],'title': 'Stores data about account objects in the Canvas system.', 'description': 'Accounts are most often used to represent a hierarchy of colleges, schools, departments, campuses.'}}, 'additionalProperties': False, 'required': ['key']},'version': 2} (api.py:351) DEBUG:pysqlsync:analyzing dataclass `database_version`: @dataclasses.dataclass class database_version: """ Table for storing meta-information about the database schema version. :param version: The version of the database schema. """ version: Annotated[Union[int, DefaultTag], Identity, PrimaryKey] DEBUG:pysqlsync:analyzing dataclass `table_sync`: @dataclasses.dataclass class table_sync: """ Table for storing meta-information about tables managed by the client library. :param source_namespace: The namespace of the source table exposed by DAP API (e.g. `canvas`). :param source_table: The name of the source table exposed by DAP API (e.g. `accounts`). :param timestamp: The timestamp of the source table that can be used by the client library in incremental queries during subsequent `syncdb` command executions. :param schema_version: The latest schema version of the source table at the time point when it was last initializedor synchronized with the DAP API. :param target_schema: The name of the target schema in the local database if applicable (e.g. in case of a PostgreSQL database the tables can be grouped into schemas). :param target_table: The name of the target table in the local database. In might differ from the name of the source table. For example in case of a MySQL database, the tables cannot be grouped in schemas. In this case, the implementor can use a prefix that reflects the namespace of the source table. For example, the qualified name `canvas.accounts` would become `canvas__accounts`. :param schema_description: The latest schema descriptor of the source table at the time point when it was initialized or last synchronized. :param schema_description_format: The format of the schema descriptor (e.g. `json`). """ id: Annotated[Union[int, DefaultTag], Identity, PrimaryKey] source_namespace: Annotated[str, MaxLength(64)] source_table: Annotated[str, MaxLength(64)] timestamp: datetime schema_version: int target_schema: Annotated[Optional[str], MaxLength(64)] target_table: Annotated[str, MaxLength(64)] schema_description_format: Annotated[str, MaxLength(64)] schema_description: str DEBUG:pysqlsync:analyzing dataclass `accounts`: @dataclasses.dataclass class accounts: """ :param id: The ID of the Account object. :param name: The display name of the account. :param deleted_at: Timestamp of when the account was deleted. Will only ever be NULL for end customers. :param parent_account_id: The account's parent ID, or NULL if this is the root account. :param current_sis_batch_id: The ID of the currently processing SIS (Student Information System) batch (if submitted via UI, not API). :param storage_quota: The storage quote for the account, in megabytes. :param default_storage_quota: The storage quota for children accounts in megabytes, if not otherwise specified. :param default_locale: Language for the account. :param default_user_storage_quota: The default storage quota for users in the account in megabytes, if not otherwise specified. :param default_group_storage_quota: The storage quota for a group in the account in megabytes, if not otherwise specified. :param integration_id: The account's identifier in the Student Information System. :param lti_context_id: UUID of the Canvas context in LTI standard. Secondary ID for this context, could be used in API to identify resource as well. :param consortium_parent_account_id: The root account of the consortium account, if this root account is part of a consortium. :param course_template_id: The course selected as a template for new courses created in this account. 0 if a template should not be used, nor inherited. :param created_at: Timestamp of when the account was created. :param updated_at: Timestamp of when the account was updated. :param workflow_state: Life-cycle state for account. :param default_time_zone: The default time zone of the account. Allowed time zones are [IANA time zones](https://www.iana.org/time-zones) or friendlier [Ruby on Rails time zones](https://api.rubyonrails.org/classes/ActiveSupport/TimeZone.html). :param uuid: The UUID of the account. :param sis_source_id: Correlated id for the record for this course in the SIS system (assuming SIS integration is configured) """ id: Annotated[int64, PrimaryKey] name: Optional[Annotated[str, MaxLength(255)]] deleted_at: Optional[datetime] parent_account_id: Optional[int64] current_sis_batch_id: Optional[int64] storage_quota: Optional[int64] default_storage_quota: Optional[int64] default_locale: Optional[Annotated[str, MaxLength(255)]] default_user_storage_quota: Optional[int64] default_group_storage_quota: Optional[int64] integration_id: Optional[Annotated[str, MaxLength(255)]] lti_context_id: Optional[Annotated[str, MaxLength(255)]] consortium_parent_account_id: Optional[int64] course_template_id: Optional[int64] created_at: datetime updated_at: datetime workflow_state: accounts__workflow_state default_time_zone: Optional[Annotated[str, MaxLength(255)]] uuid: Optional[Annotated[str, MaxLength(255)]] sis_source_id: Optional[Annotated[str, MaxLength(255)]] DEBUG:pysqlsync:desired state: CREATE SCHEMA IF NOT EXISTS "canvas"; CREATE SCHEMA IF NOT EXISTS "instructure_dap"; CREATE TYPE "canvas"."accounts__workflow_state" AS ENUM ('__dap_unspecified__', 'active', 'deleted', 'suspended'); CREATE TABLE "canvas"."accounts" ( "id" bigint NOT NULL, "name" varchar(255), "deleted_at" timestamp, "parent_account_id" bigint, "current_sis_batch_id" bigint, "storage_quota" bigint, "default_storage_quota" bigint, "default_locale" varchar(255), "default_user_storage_quota" bigint, "default_group_storage_quota" bigint, "integration_id" varchar(255), "lti_context_id" varchar(255), "consortium_parent_account_id" bigint, "course_template_id" bigint, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL, "workflow_state" "canvas"."accounts__workflow_state" NOT NULL, "default_time_zone" varchar(255), "uuid" varchar(255), "sis_source_id" varchar(255), CONSTRAINT "pk_accounts" PRIMARY KEY ("id") ); COMMENT ON COLUMN "canvas"."accounts"."id" IS 'The ID of the Account object.'; COMMENT ON COLUMN "canvas"."accounts"."name" IS 'The display name of the account.'; COMMENT ON COLUMN "canvas"."accounts"."deleted_at" IS 'Timestamp of when the account was deleted. Will only ever be NULL for end customers.'; COMMENT ON COLUMN "canvas"."accounts"."parent_account_id" IS 'The account''s parent ID, or NULL if this is the root account.'; COMMENT ON COLUMN "canvas"."accounts"."current_sis_batch_id" IS 'The ID of the currently processing SIS (Student Information System) batch (if submitted via UI, not API).'; COMMENT ON COLUMN "canvas"."accounts"."storage_quota" IS 'The storage quote for the account, in megabytes.'; COMMENT ON COLUMN "canvas"."accounts"."default_storage_quota" IS 'The storage quota for children accounts in megabytes,if not otherwise specified.'; COMMENT ON COLUMN "canvas"."accounts"."default_locale" IS 'Language for the account.'; COMMENT ON COLUMN "canvas"."accounts"."default_user_storage_quota" IS 'The default storage quota for users in the account in megabytes, if not otherwise specified.'; COMMENT ON COLUMN "canvas"."accounts"."default_group_storage_quota" IS 'The storage quota for a group in the account inmegabytes, if not otherwise specified.'; COMMENT ON COLUMN "canvas"."accounts"."integration_id" IS 'The account''s identifier in the Student Information System.'; COMMENT ON COLUMN "canvas"."accounts"."lti_context_id" IS 'UUID of the Canvas context in LTI standard. Secondary ID forthis context, could be used in API to identify resource as well.'; COMMENT ON COLUMN "canvas"."accounts"."consortium_parent_account_id" IS 'The root account of the consortium account, ifthis root account is part of a consortium.'; COMMENT ON COLUMN "canvas"."accounts"."course_template_id" IS 'The course selected as a template for new courses created in this account. 0 if a template should not be used, nor inherited.'; COMMENT ON COLUMN "canvas"."accounts"."created_at" IS 'Timestamp of when the account was created.'; COMMENT ON COLUMN "canvas"."accounts"."updated_at" IS 'Timestamp of when the account was updated.'; COMMENT ON COLUMN "canvas"."accounts"."workflow_state" IS 'Life-cycle state for account.'; COMMENT ON COLUMN "canvas"."accounts"."default_time_zone" IS 'The default time zone of the account. Allowed time zones are [IANA time zones](https://www.iana.org/time-zones) or friendlier [Ruby on Rails time zones](https://api.rubyonrails.org/classes/ActiveSupport/TimeZone.html).'; COMMENT ON COLUMN "canvas"."accounts"."uuid" IS 'The UUID of the account.'; COMMENT ON COLUMN "canvas"."accounts"."sis_source_id" IS 'Correlated id for the record for this course in the SIS system (assuming SIS integration is configured)'; CREATE TABLE "instructure_dap"."database_version" ( "version" bigint GENERATED BY DEFAULT AS IDENTITY, CONSTRAINT "pk_database_version" PRIMARY KEY ("version") ); COMMENT ON TABLE "instructure_dap"."database_version" IS 'Table for storing meta-information about the database schema version.'; COMMENT ON COLUMN "instructure_dap"."database_version"."version" IS 'The version of the database schema.'; CREATE TABLE "instructure_dap"."table_sync" ( "id" bigint GENERATED BY DEFAULT AS IDENTITY, "source_namespace" varchar(64) NOT NULL, "source_table" varchar(64) NOT NULL, "timestamp" timestamp NOT NULL, "schema_version" bigint NOT NULL, "target_schema" varchar(64), "target_table" varchar(64) NOT NULL, "schema_description_format" varchar(64) NOT NULL, "schema_description" text NOT NULL, CONSTRAINT "pk_table_sync" PRIMARY KEY ("id") ); COMMENT ON TABLE "instructure_dap"."table_sync" IS 'Table for storing meta-information about tables managed by the client library.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."source_namespace" IS 'The namespace of the source table exposed by DAP API (e.g. `canvas`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."source_table" IS 'The name of the source table exposed by DAP API (e.g. `accounts`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."timestamp" IS 'The timestamp of the source table that can be used by the client library in incremental queries during subsequent `syncdb` command executions.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_version" IS 'The latest schema version of the source table at the time point when it was last initialized or synchronized with the DAP API.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."target_schema" IS 'The name of the target schema in the local database if applicable (e.g. in case of a PostgreSQL database the tables can be grouped into schemas).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."target_table" IS 'The name of the target table in the local database.In might differ from the name of the source table. For example in case of a MySQL database, the tables cannot be grouped in schemas. In this case, the implementor can use a prefix that reflects the namespace of the source table. For example, the qualified name `canvas.accounts` would become `canvas__accounts`.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_description_format" IS 'The format of the schema descriptor (e.g. `json`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_description" IS 'The latest schema descriptor of the source table at the time point when it was initialized or last synchronized.'; DEBUG:pysqlsync:query SQL with into PostgreSQLEnumMeta: SELECT t.typname as enum_name, e.enumlabel as enum_value FROM pg_catalog.pg_type t JOIN pg_catalog.pg_enum e ON t.oid = e.enumtypid JOIN pg_catalog.pg_namespace n ON n.oid = t.typnamespace WHERE n.nspname = 'instructure_dap' ORDER BY enum_name, e.enumsortorder ; DEBUG:pysqlsync:query SQL with into str: SELECT cls.relname FROM pg_catalog.pg_class AS cls INNER JOIN pg_catalog.pg_namespace AS nsp ON cls.relnamespace = nsp.oid WHERE nsp.nspname = 'instructure_dap' AND (cls.relkind = 'c') ; DEBUG:pysqlsync:query SQL with into str: SELECT cls.relname FROM pg_catalog.pg_class AS cls INNER JOIN pg_catalog.pg_namespace AS nsp ON cls.relnamespace = nsp.oid WHERE nsp.nspname = 'instructure_dap' AND (cls.relkind = 'r' OR cls.relkind = 'v') ; DEBUG:pysqlsync:query SQL with into PostgreSQLTableMeta: SELECT dsc.description AS description FROM pg_catalog.pg_class AS cls INNER JOIN pg_catalog.pg_namespace AS nsp ON cls.relnamespace = nsp.oid LEFT JOIN pg_catalog.pg_description AS dsc ON dsc.objoid = cls.oid AND dsc.objsubid = 0 WHERE (cls.relname = 'database_version') AND (nsp.nspname = 'instructure_dap') AND ((cls.relkind = 'r') OR (cls.relkind= 'v')) DEBUG:pysqlsync:query SQL with into PostgreSQLColumnMeta: SELECT att.attname AS column_name, typ_nsp.nspname AS type_schema, CASE WHEN typ.typelem != 0 THEN typ_elem.typname ELSE typ.typname END AS type_name, pg_catalog.format_type(att.atttypid, att.atttypmod) AS type_def, NOT att.attnotnull AS is_nullable, att.attndims != 0 AS is_array, att.attidentity IN ('a', 'd') AS is_identity, pg_catalog.pg_get_expr(def.adbin, def.adrelid) AS default_value, dsc.description AS description FROM pg_catalog.pg_attribute AS att INNER JOIN pg_catalog.pg_type AS typ ON att.atttypid = typ.oid INNER JOIN pg_catalog.pg_namespace AS typ_nsp ON typ.typnamespace = typ_nsp.oid INNER JOIN pg_catalog.pg_class AS cls ON att.attrelid = cls.oid INNER JOIN pg_catalog.pg_namespace AS nsp ON cls.relnamespace = nsp.oid LEFT JOIN pg_catalog.pg_type AS typ_elem ON typ.typelem = typ_elem.oid LEFT JOIN pg_catalog.pg_attrdef AS def ON def.adrelid = cls.oid AND def.adnum = att.attnum LEFT JOIN pg_catalog.pg_description AS dsc ON dsc.objoid = cls.oid AND dsc.objsubid = att.attnum WHERE (cls.relname = 'database_version') AND (nsp.nspname = 'instructure_dap') AND ((cls.relkind = 'r') OR (cls.relkind= 'v')) AND (att.attnum > 0) ORDER BY att.attnum DEBUG:pysqlsync:query SQL with into PostgreSQLConstraintMeta: SELECT cons.contype AS constraint_type, cons.conname AS constraint_name, att_s.attname AS source_column, nsp_t.nspname AS target_namespace, cls_t.relname AS target_table, att_t.attname AS target_column FROM ( SELECT con.contype, con.conname, con.conrelid AS pkeyrel, tgt.pkeycol, con.confrelid AS fkeyrel, tgt.fkeycol FROM pg_catalog.pg_constraint AS con CROSS JOIN UNNEST(con.conkey, con.confkey) AS tgt(pkeycol, fkeycol) INNER JOIN pg_catalog.pg_class AS cls ON con.conrelid = cls.oid INNER JOIN pg_catalog.pg_namespace AS nsp ON cls.relnamespace = nsp.oid WHERE (cls.relname = 'database_version') AND (nsp.nspname = 'instructure_dap') AND ((cls.relkind = 'r') OR (cls.relkind= 'v')) AND con.contype IN ('p', 'u', 'f') ) AS cons INNER JOIN pg_catalog.pg_attribute AS att_s ON cons.pkeyrel = att_s.attrelid AND cons.pkeycol = att_s.attnum LEFT JOIN pg_catalog.pg_class AS cls_t ON cons.fkeyrel = cls_t.oid LEFT JOIN pg_catalog.pg_namespace AS nsp_t ON cls_t.relnamespace = nsp_t.oid LEFT JOIN pg_catalog.pg_attribute AS att_t ON cons.fkeyrel = att_t.attrelid AND cons.fkeycol = att_t.attnum DEBUG:pysqlsync:query SQL with into PostgreSQLTableMeta: SELECT dsc.description AS description FROM pg_catalog.pg_class AS cls INNER JOIN pg_catalog.pg_namespace AS nsp ON cls.relnamespace = nsp.oid LEFT JOIN pg_catalog.pg_description AS dsc ON dsc.objoid = cls.oid AND dsc.objsubid = 0 WHERE (cls.relname = 'table_sync') AND (nsp.nspname = 'instructure_dap') AND ((cls.relkind = 'r') OR (cls.relkind = 'v')) DEBUG:pysqlsync:query SQL with into PostgreSQLColumnMeta: SELECT att.attname AS column_name, typ_nsp.nspname AS type_schema, CASE WHEN typ.typelem != 0 THEN typ_elem.typname ELSE typ.typname END AS type_name, pg_catalog.format_type(att.atttypid, att.atttypmod) AS type_def, NOT att.attnotnull AS is_nullable, att.attndims != 0 AS is_array, att.attidentity IN ('a', 'd') AS is_identity, pg_catalog.pg_get_expr(def.adbin, def.adrelid) AS default_value, dsc.description AS description FROM pg_catalog.pg_attribute AS att INNER JOIN pg_catalog.pg_type AS typ ON att.atttypid = typ.oid INNER JOIN pg_catalog.pg_namespace AS typ_nsp ON typ.typnamespace = typ_nsp.oid INNER JOIN pg_catalog.pg_class AS cls ON att.attrelid = cls.oid INNER JOIN pg_catalog.pg_namespace AS nsp ON cls.relnamespace = nsp.oid LEFT JOIN pg_catalog.pg_type AS typ_elem ON typ.typelem = typ_elem.oid LEFT JOIN pg_catalog.pg_attrdef AS def ON def.adrelid = cls.oid AND def.adnum = att.attnum LEFT JOIN pg_catalog.pg_description AS dsc ON dsc.objoid = cls.oid AND dsc.objsubid = att.attnum WHERE (cls.relname = 'table_sync') AND (nsp.nspname = 'instructure_dap') AND ((cls.relkind = 'r') OR (cls.relkind = 'v')) AND (att.attnum > 0) ORDER BY att.attnum DEBUG:pysqlsync:query SQL with into PostgreSQLConstraintMeta: SELECT cons.contype AS constraint_type, cons.conname AS constraint_name, att_s.attname AS source_column, nsp_t.nspname AS target_namespace, cls_t.relname AS target_table, att_t.attname AS target_column FROM ( SELECT con.contype, con.conname, con.conrelid AS pkeyrel, tgt.pkeycol, con.confrelid AS fkeyrel, tgt.fkeycol FROM pg_catalog.pg_constraint AS con CROSS JOIN UNNEST(con.conkey, con.confkey) AS tgt(pkeycol, fkeycol) INNER JOIN pg_catalog.pg_class AS cls ON con.conrelid = cls.oid INNER JOIN pg_catalog.pg_namespace AS nsp ON cls.relnamespace = nsp.oid WHERE (cls.relname = 'table_sync') AND (nsp.nspname = 'instructure_dap') AND ((cls.relkind = 'r') OR (cls.relkind = 'v')) AND con.contype IN ('p', 'u', 'f') ) AS cons INNER JOIN pg_catalog.pg_attribute AS att_s ON cons.pkeyrel = att_s.attrelid AND cons.pkeycol = att_s.attnum LEFT JOIN pg_catalog.pg_class AS cls_t ON cons.fkeyrel = cls_t.oid LEFT JOIN pg_catalog.pg_namespace AS nsp_t ON cls_t.relnamespace = nsp_t.oid LEFT JOIN pg_catalog.pg_attribute AS att_t ON cons.fkeyrel = att_t.attrelid AND cons.fkeycol = att_t.attnum DEBUG:pysqlsync:query SQL with into PostgreSQLEnumMeta: SELECT t.typname as enum_name, e.enumlabel as enum_value FROM pg_catalog.pg_type t JOIN pg_catalog.pg_enum e ON t.oid = e.enumtypid JOIN pg_catalog.pg_namespace n ON n.oid = t.typnamespace WHERE n.nspname = 'canvas' ORDER BY enum_name, e.enumsortorder ; DEBUG:pysqlsync:query SQL with into str: SELECT cls.relname FROM pg_catalog.pg_class AS cls INNER JOIN pg_catalog.pg_namespace AS nsp ON cls.relnamespace = nsp.oid WHERE nsp.nspname = 'canvas' AND (cls.relkind = 'c') ; DEBUG:pysqlsync:query SQL with into str: SELECT cls.relname FROM pg_catalog.pg_class AS cls INNER JOIN pg_catalog.pg_namespace AS nsp ON cls.relnamespace = nsp.oid WHERE nsp.nspname = 'canvas' AND (cls.relkind = 'r' OR cls.relkind = 'v') ; DEBUG:pysqlsync:found 2 namespaces DEBUG:pysqlsync:found 0 enum(s) in namespace "instructure_dap" DEBUG:pysqlsync:found 0 struct(s) in namespace "instructure_dap" DEBUG:pysqlsync:found 2 table(s) in namespace "instructure_dap" DEBUG:pysqlsync:found 0 enum(s) in namespace "" DEBUG:pysqlsync:found 0 struct(s) in namespace "" DEBUG:pysqlsync:found 0 table(s) in namespace "" DEBUG:pysqlsync:discovered state: CREATE SCHEMA IF NOT EXISTS "instructure_dap"; CREATE TABLE "instructure_dap"."database_version" ( "version" bigint GENERATED BY DEFAULT AS IDENTITY, CONSTRAINT "pk_database_version" PRIMARY KEY ("version") ); COMMENT ON TABLE "instructure_dap"."database_version" IS 'Table for storing meta-information about the database schema version.'; COMMENT ON COLUMN "instructure_dap"."database_version"."version" IS 'The version of the database schema.'; CREATE TABLE "instructure_dap"."table_sync" ( "id" bigint GENERATED BY DEFAULT AS IDENTITY, "source_namespace" varchar(64) NOT NULL, "source_table" varchar(64) NOT NULL, "timestamp" timestamp NOT NULL, "schema_version" bigint NOT NULL, "target_schema" varchar(64), "target_table" varchar(64) NOT NULL, "schema_description_format" varchar(64) NOT NULL, "schema_description" text NOT NULL, CONSTRAINT "pk_table_sync" PRIMARY KEY ("id") ); COMMENT ON TABLE "instructure_dap"."table_sync" IS 'Table for storing meta-information about tables managed by the client library.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."source_namespace" IS 'The namespace of the source table exposed by DAP API (e.g. `canvas`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."source_table" IS 'The name of the source table exposed by DAP API (e.g. `accounts`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."timestamp" IS 'The timestamp of the source table that can be used by the client library in incremental queries during subsequent `syncdb` command executions.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_version" IS 'The latest schema version of the source table at the time point when it was last initialized or synchronized with the DAP API.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."target_schema" IS 'The name of the target schema in the local database if applicable (e.g. in case of a PostgreSQL database the tables can be grouped into schemas).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."target_table" IS 'The name of the target table in the local database.In might differ from the name of the source table. For example in case of a MySQL database, the tables cannot be grouped in schemas. In this case, the implementor can use a prefix that reflects the namespace of the source table. For example, the qualified name `canvas.accounts` would become `canvas__accounts`.'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_description_format" IS 'The format of the schema descriptor (e.g. `json`).'; COMMENT ON COLUMN "instructure_dap"."table_sync"."schema_description" IS 'The latest schema descriptor of the source table at the time point when it was initialized or last synchronized.'; INFO:pysqlsync:synchronize schema with SQL: CREATE SCHEMA IF NOT EXISTS "canvas"; CREATE TYPE "canvas"."accounts__workflow_state" AS ENUM ('__dap_unspecified__', 'active', 'deleted', 'suspended'); CREATE TABLE "canvas"."accounts" ( "id" bigint NOT NULL, "name" varchar(255), "deleted_at" timestamp, "parent_account_id" bigint, "current_sis_batch_id" bigint, "storage_quota" bigint, "default_storage_quota" bigint, "default_locale" varchar(255), "default_user_storage_quota" bigint, "default_group_storage_quota" bigint, "integration_id" varchar(255), "lti_context_id" varchar(255), "consortium_parent_account_id" bigint, "course_template_id" bigint, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL, "workflow_state" "canvas"."accounts__workflow_state" NOT NULL, "default_time_zone" varchar(255), "uuid" varchar(255), "sis_source_id" varchar(255), CONSTRAINT "pk_accounts" PRIMARY KEY ("id") ); COMMENT ON COLUMN "canvas"."accounts"."id" IS 'The ID of the Account object.'; COMMENT ON COLUMN "canvas"."accounts"."name" IS 'The display name of the account.'; COMMENT ON COLUMN "canvas"."accounts"."deleted_at" IS 'Timestamp of when the account was deleted. Will only ever be NULL for end customers.'; COMMENT ON COLUMN "canvas"."accounts"."parent_account_id" IS 'The account''s parent ID, or NULL if this is the root account.'; COMMENT ON COLUMN "canvas"."accounts"."current_sis_batch_id" IS 'The ID of the currently processing SIS (Student Information System) batch (if submitted via UI, not API).'; COMMENT ON COLUMN "canvas"."accounts"."storage_quota" IS 'The storage quote for the account, in megabytes.'; COMMENT ON COLUMN "canvas"."accounts"."default_storage_quota" IS 'The storage quota for children accounts in megabytes,if not otherwise specified.'; COMMENT ON COLUMN "canvas"."accounts"."default_locale" IS 'Language for the account.'; COMMENT ON COLUMN "canvas"."accounts"."default_user_storage_quota" IS 'The default storage quota for users in the account in megabytes, if not otherwise specified.'; COMMENT ON COLUMN "canvas"."accounts"."default_group_storage_quota" IS 'The storage quota for a group in the account inmegabytes, if not otherwise specified.'; COMMENT ON COLUMN "canvas"."accounts"."integration_id" IS 'The account''s identifier in the Student Information System.'; COMMENT ON COLUMN "canvas"."accounts"."lti_context_id" IS 'UUID of the Canvas context in LTI standard. Secondary ID forthis context, could be used in API to identify resource as well.'; COMMENT ON COLUMN "canvas"."accounts"."consortium_parent_account_id" IS 'The root account of the consortium account, ifthis root account is part of a consortium.'; COMMENT ON COLUMN "canvas"."accounts"."course_template_id" IS 'The course selected as a template for new courses created in this account. 0 if a template should not be used, nor inherited.'; COMMENT ON COLUMN "canvas"."accounts"."created_at" IS 'Timestamp of when the account was created.'; COMMENT ON COLUMN "canvas"."accounts"."updated_at" IS 'Timestamp of when the account was updated.'; COMMENT ON COLUMN "canvas"."accounts"."workflow_state" IS 'Life-cycle state for account.'; COMMENT ON COLUMN "canvas"."accounts"."default_time_zone" IS 'The default time zone of the account. Allowed time zones are [IANA time zones](https://www.iana.org/time-zones) or friendlier [Ruby on Rails time zones](https://api.rubyonrails.org/classes/ActiveSupport/TimeZone.html).'; COMMENT ON COLUMN "canvas"."accounts"."uuid" IS 'The UUID of the account.'; COMMENT ON COLUMN "canvas"."accounts"."sis_source_id" IS 'Correlated id for the record for this course in the SIS system (assuming SIS integration is configured)'; DEBUG:pysqlsync:execute SQL: CREATE SCHEMA IF NOT EXISTS "canvas"; CREATE TYPE "canvas"."accounts__workflow_state" AS ENUM ('__dap_unspecified__', 'active', 'deleted', 'suspended'); CREATE TABLE "canvas"."accounts" ( "id" bigint NOT NULL, "name" varchar(255), "deleted_at" timestamp, "parent_account_id" bigint, "current_sis_batch_id" bigint, "storage_quota" bigint, "default_storage_quota" bigint, "default_locale" varchar(255), "default_user_storage_quota" bigint, "default_group_storage_quota" bigint, "integration_id" varchar(255), "lti_context_id" varchar(255), "consortium_parent_account_id" bigint, "course_template_id" bigint, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL, "workflow_state" "canvas"."accounts__workflow_state" NOT NULL, "default_time_zone" varchar(255), "uuid" varchar(255), "sis_source_id" varchar(255), CONSTRAINT "pk_accounts" PRIMARY KEY ("id") ); COMMENT ON COLUMN "canvas"."accounts"."id" IS 'The ID of the Account object.'; COMMENT ON COLUMN "canvas"."accounts"."name" IS 'The display name of the account.'; COMMENT ON COLUMN "canvas"."accounts"."deleted_at" IS 'Timestamp of when the account was deleted. Will only ever be NULL for end customers.'; COMMENT ON COLUMN "canvas"."accounts"."parent_account_id" IS 'The account''s parent ID, or NULL if this is the root account.'; COMMENT ON COLUMN "canvas"."accounts"."current_sis_batch_id" IS 'The ID of the currently processing SIS (Student Information System) batch (if submitted via UI, not API).'; COMMENT ON COLUMN "canvas"."accounts"."storage_quota" IS 'The storage quote for the account, in megabytes.'; COMMENT ON COLUMN "canvas"."accounts"."default_storage_quota" IS 'The storage quota for children accounts in megabytes,if not otherwise specified.'; COMMENT ON COLUMN "canvas"."accounts"."default_locale" IS 'Language for the account.'; COMMENT ON COLUMN "canvas"."accounts"."default_user_storage_quota" IS 'The default storage quota for users in the account in megabytes, if not otherwise specified.'; COMMENT ON COLUMN "canvas"."accounts"."default_group_storage_quota" IS 'The storage quota for a group in the account inmegabytes, if not otherwise specified.'; COMMENT ON COLUMN "canvas"."accounts"."integration_id" IS 'The account''s identifier in the Student Information System.'; COMMENT ON COLUMN "canvas"."accounts"."lti_context_id" IS 'UUID of the Canvas context in LTI standard. Secondary ID forthis context, could be used in API to identify resource as well.'; COMMENT ON COLUMN "canvas"."accounts"."consortium_parent_account_id" IS 'The root account of the consortium account, ifthis root account is part of a consortium.'; COMMENT ON COLUMN "canvas"."accounts"."course_template_id" IS 'The course selected as a template for new courses created in this account. 0 if a template should not be used, nor inherited.'; COMMENT ON COLUMN "canvas"."accounts"."created_at" IS 'Timestamp of when the account was created.'; COMMENT ON COLUMN "canvas"."accounts"."updated_at" IS 'Timestamp of when the account was updated.'; COMMENT ON COLUMN "canvas"."accounts"."workflow_state" IS 'Life-cycle state for account.'; COMMENT ON COLUMN "canvas"."accounts"."default_time_zone" IS 'The default time zone of the account. Allowed time zones are [IANA time zones](https://www.iana.org/time-zones) or friendlier [Ruby on Rails time zones](https://api.rubyonrails.org/classes/ActiveSupport/TimeZone.html).'; COMMENT ON COLUMN "canvas"."accounts"."uuid" IS 'The UUID of the account.'; COMMENT ON COLUMN "canvas"."accounts"."sis_source_id" IS 'Correlated id for the record for this course in the SIS system (assuming SIS integration is configured)'; 2024-03-27 13:11:51,217 - DEBUG - Start operation - initialize. Namespace: canvas, table: accounts, conn: (sql_op_init.py:49) 2024-03-27 13:11:51,217 - DEBUG - fetching meta-data about table accounts (sql_op_init.py:53) DEBUG:pysqlsync:query SQL with into table_sync: SELECT id, source_namespace, source_table, timestamp, schema_version, target_schema, target_table, schema_description_format, schema_description FROM "instructure_dap"."table_sync" WHERE source_namespace = 'canvas' AND source_table = 'accounts' 2024-03-27 13:11:51,219 - DEBUG - fetching data for table from DAP API (sql_op_init.py:58) 2024-03-27 13:11:51,219 - DEBUG - Query snapshot of table: accounts. Query: SnapshotQuery(format=, mode=) (api.py:391) 2024-03-27 13:11:51,220 - DEBUG - POST request payload: {'format': 'tsv', 'mode': 'condensed'} (api.py:304) 2024-03-27 13:11:52,127 - DEBUG - GET/POST response payload: {'id': '1a07316d-2970-4ac1-973e-27d847e3a5b9', 'status': 'complete', 'objects': [{'id': '1a07316d-2970-4ac1-973e-27d847e3a5b9/part-00000-d3fd12ff-73d3-4370-8a99-0339937f0567-c000.tsv.gz'}], 'expires_at': '2024-03-28T16:48:26Z', 'schema_version': 2, 'at': '2024-03-27T16:13:58Z'} (api.py:351) 2024-03-27 13:11:52,128 - INFO - Query started with job ID: 1a07316d-2970-4ac1-973e-27d847e3a5b9 2024-03-27 13:11:52,129 - DEBUG - Query job finished with status: complete (api.py:620) 2024-03-27 13:11:52,129 - DEBUG - Retrieving object IDs for job 1a07316d-2970-4ac1-973e-27d847e3a5b9 (api.py:478) DEBUG:aiohttp_retry:Attempt 1 out of 3 2024-03-27 13:11:52,258 - DEBUG - GET/POST response payload: {'id': '1a07316d-2970-4ac1-973e-27d847e3a5b9', 'status': 'complete', 'objects': [{'id': '1a07316d-2970-4ac1-973e-27d847e3a5b9/part-00000-d3fd12ff-73d3-4370-8a99-0339937f0567-c000.tsv.gz'}], 'expires_at': '2024-03-28T16:48:26Z', 'schema_version': 2, 'at': '2024-03-27T16:13:58Z'} (api.py:351) 2024-03-27 13:11:52,259 - INFO - Data has been successfully retrieved: {"id": "1a07316d-2970-4ac1-973e-27d847e3a5b9", "status": "complete", "expires_at": "2024-03-28T16:48:26Z", "objects": [{"id": "1a07316d-2970-4ac1-973e-27d847e3a5b9/part-00000-d3fd12ff-73d3-4370-8a99-0339937f0567-c000.tsv.gz"}], "schema_version": 2, "at": "2024-03-27T16:13:58Z"} 2024-03-27 13:11:52,264 - DEBUG - Retrieve resource URLs for objects: (api.py:487) 2024-03-27 13:11:52,264 - DEBUG - ['1a07316d-2970-4ac1-973e-27d847e3a5b9/part-00000-d3fd12ff-73d3-4370-8a99-0339937f0567-c000.tsv.gz'] (api.py:488) 2024-03-27 13:11:52,265 - DEBUG - POST request payload: [{'id': '1a07316d-2970-4ac1-973e-27d847e3a5b9/part-00000-d3fd12ff-73d3-4370-8a99-0339937f0567-c000.tsv.gz'}] (api.py:304) 2024-03-27 13:11:52,556 - DEBUG - GET/POST response payload: {'urls': {'1a07316d-2970-4ac1-973e-27d847e3a5b9/part-00000-d3fd12ff-73d3-4370-8a99-0339937f0567-c000.tsv.gz': {'url': 'https://data-access-platform-output-prod-iad.s3.amazonaws.com/output/rootAccountId%3DWxEkP3KbeKvs2QRKgR0zMx3yEbV8cBhjevC6PPdU/queryId%3D1a07316d-2970-4ac1-973e-27d847e3a5b9/part-00000-d3fd12ff-73d3-4370-8a99-0339937f0567-c000.tsv.gz?X-Amz-Security-Token=FwoGZXIvYXdzELv%2F%2F%2F%2F%2F%2F%2F%2F%2F%2FwEaDPGMRR7Q7KHjfqKq8SK7AVqczfez2qVlxMOtRkAh6Re3jQ7xN3SO1N%2BwJcJzDQ5JlQc47YN%2BezqIypmttJZZ8pBR9cu4a4fgdZRowlk8RDbAvXwZ%2FCKbRbj%2BUe0cZ4EEyRcRECVuEvjXCFlmyoPv%2B6Uv6GHybssu%2BFkujRB7PnAqdsphFJfZUv2AzEjzJ4RPVORRc94GP9aJ5jBS1B1ejZX%2F2FbZnEY8iqaNF5yM6ggGxvu3XV1mtWXZ5gPG1thcfGvWqnBJ3YYd4Ksot6SRsAYyLWmGuFVK4w88PLf%2Bbh0lnuNWTSYzr8jXHb7bV%2FS3ZdiZRqGtma1k9DYTR979mg%3D%3D&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20240327T171152Z&X-Amz-SignedHeaders=host&X-Amz-Expires=3599&X-Amz-Credential=ASIAXX2PINZLN4AENHX6%2F20240327%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Signature=8483b3190dbfe3e80e41660ae1c4771116c256429e4425a2d0f462bfc67fece3'}}} (api.py:351) 2024-03-27 13:11:52,557 - DEBUG - Downloading: https://data-access-platform-output-prod-iad.s3.amazonaws.com/output/rootAccountId%3DWxEkP3KbeKvs2QRKgR0zMx3yEbV8cBhjevC6PPdU/queryId%3D1a07316d-2970-4ac1-973e-27d847e3a5b9/part-00000-d3fd12ff-73d3-4370-8a99-0339937f0567-c000.tsv.gz?X-Amz-Security-Token=FwoGZXIvYXdzELv%2F%2F%2F%2F%2F%2F%2F%2F%2F%2FwEaDPGMRR7Q7KHjfqKq8SK7AVqczfez2qVlxMOtRkAh6Re3jQ7xN3SO1N%2BwJcJzDQ5JlQc47YN%2BezqIypmttJZZ8pBR9cu4a4fgdZRowlk8RDbAvXwZ%2FCKbRbj%2BUe0cZ4EEyRcRECVuEvjXCFlmyoPv%2B6Uv6GHybssu%2BFkujRB7PnAqdsphFJfZUv2AzEjzJ4RPVORRc94GP9aJ5jBS1B1ejZX%2F2FbZnEY8iqaNF5yM6ggGxvu3XV1mtWXZ5gPG1thcfGvWqnBJ3YYd4Ksot6SRsAYyLWmGuFVK4w88PLf%2Bbh0lnuNWTSYzr8jXHb7bV%2FS3ZdiZRqGtma1k9DYTR979mg%3D%3D&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20240327T171152Z&X-Amz-SignedHeaders=host&X-Amz-Expires=3599&X-Amz-Credential=ASIAXX2PINZLN4AENHX6%2F20240327%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Signature=8483b3190dbfe3e80e41660ae1c4771116c256429e4425a2d0f462bfc67fece3 to C:\Users\MAF11_~1\AppData\Local\Temp\tmpvnzntl9f\part-00000-d3fd12ff-73d3-4370-8a99-0339937f0567-c000.tsv (api.py:535) DEBUG:aiohttp_retry:Attempt 1 out of 3 2024-03-27 13:11:52,714 - DEBUG - Download complete of https://data-access-platform-output-prod-iad.s3.amazonaws.com/output/rootAccountId%3DWxEkP3KbeKvs2QRKgR0zMx3yEbV8cBhjevC6PPdU/queryId%3D1a07316d-2970-4ac1-973e-27d847e3a5b9/part-00000-d3fd12ff-73d3-4370-8a99-0339937f0567-c000.tsv.gz?X-Amz-Security-Token=FwoGZXIvYXdzELv%2F%2F%2F%2F%2F%2F%2F%2F%2F%2FwEaDPGMRR7Q7KHjfqKq8SK7AVqczfez2qVlxMOtRkAh6Re3jQ7xN3SO1N%2BwJcJzDQ5JlQc47YN%2BezqIypmttJZZ8pBR9cu4a4fgdZRowlk8RDbAvXwZ%2FCKbRbj%2BUe0cZ4EEyRcRECVuEvjXCFlmyoPv%2B6Uv6GHybssu%2BFkujRB7PnAqdsphFJfZUv2AzEjzJ4RPVORRc94GP9aJ5jBS1B1ejZX%2F2FbZnEY8iqaNF5yM6ggGxvu3XV1mtWXZ5gPG1thcfGvWqnBJ3YYd4Ksot6SRsAYyLWmGuFVK4w88PLf%2Bbh0lnuNWTSYzr8jXHb7bV%2FS3ZdiZRqGtma1k9DYTR979mg%3D%3D&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20240327T171152Z&X-Amz-SignedHeaders=host&X-Amz-Expires=3599&X-Amz-Credential=ASIAXX2PINZLN4AENHX6%2F20240327%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Signature=8483b3190dbfe3e80e41660ae1c4771116c256429e4425a2d0f462bfc67fece3 to C:\Users\MAF11_~1\AppData\Local\Temp\tmpvnzntl9f\part-00000-d3fd12ff-73d3-4370-8a99-0339937f0567-c000.tsv (api.py:546) 2024-03-27 13:11:52,714 - DEBUG - init: insert data from resources saved to disk into database table (sql_op_init.py:87) 2024-03-27 13:11:52,716 - DEBUG - processing file 1 of 1 (sql_op_init.py:100) C:\Users\maf11_adm>