Compare commits

...

4 Commits

Author SHA1 Message Date
Alex Fedosov
5971ca0d1d Merge branch 'main' into devin/1750944861-remove-no-event-triggers-flag 2025-06-30 10:36:33 +02:00
Devin AI
7610702026 Fix Python codestyle: remove whitespace from blank line
Co-Authored-By: Daniel <daniel@neon.tech>
2025-06-26 15:35:58 +00:00
Devin AI
1cf6eea861 Fix test_fast_import_event_triggers to expect event triggers to be imported
Since we removed the --no-event-triggers flag, event triggers are now
imported as expected. Update the test to verify this new behavior.

Co-Authored-By: Daniel <daniel@neon.tech>
2025-06-26 14:36:44 +00:00
Devin AI
1b5a3eb775 Remove --no-event-triggers flag from fast_import
Neon now supports event triggers, so this flag is no longer needed.
The flag was preventing event triggers from being included in database
imports, but since Neon supports them, we should allow them to be
imported along with other database objects.

Co-Authored-By: Daniel <daniel@neon.tech>
2025-06-26 13:36:26 +00:00
2 changed files with 4 additions and 2 deletions

View File

@@ -346,7 +346,6 @@ async fn run_dump_restore(
"--no-security-labels".to_string(),
"--no-subscriptions".to_string(),
"--no-tablespaces".to_string(),
"--no-event-triggers".to_string(),
// format
"--format".to_string(),
"directory".to_string(),

View File

@@ -1001,7 +1001,10 @@ def test_fast_import_event_triggers(
conn = PgProtocol(dsn=f"postgresql://cloud_admin@localhost:{pg_port}/neondb")
res = conn.safe_psql("SELECT count(*) FROM pg_event_trigger;")
log.info(f"Result: {res}")
assert res[0][0] == 0, f"Neon does not support importing event triggers, got: {res[0][0]}"
assert res[0][0] == 1, f"Expected 1 event trigger to be imported, got: {res[0][0]}"
conn.safe_psql("CREATE TABLE test_drop_table (id int);")
conn.safe_psql("DROP TABLE test_drop_table;")
def test_fast_import_restore_to_connstring(