MCPcopy
hub / github.com/psycopg/psycopg / main

Function main

tools/update_oids.py:35–44  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

33
34
35def main() -> None:
36 opt = parse_cmdline()
37
38 if CrdbConnection.is_crdb(conn := psycopg.connect(opt.dsn, autocommit=True)):
39 conn = CrdbConnection.connect(opt.dsn, autocommit=True)
40 update_crdb_python_oids(conn)
41 else:
42 update_python_oids(conn)
43 update_python_types(conn)
44 update_cython_oids(conn)
45
46
47def update_python_types(conn: Connection) -> None:

Callers 1

update_oids.pyFile · 0.70

Calls 7

update_crdb_python_oidsFunction · 0.85
update_python_oidsFunction · 0.85
update_python_typesFunction · 0.85
update_cython_oidsFunction · 0.85
is_crdbMethod · 0.80
parse_cmdlineFunction · 0.70
connectMethod · 0.45

Tested by

no test coverage detected