Page MenuHomeSoftware Heritage

db_utils: Add missing import of psycopg2.errors
ClosedPublic

Authored by vlorentz on Mar 3 2022, 1:35 PM.

Details

Summary

This may be needed depending on import order; but it makes mypy complain when
types-psycopg2 is installed.

@bchauvet This solves some of your mypy errors

Diff Detail

Repository
rDCORE Foundations and core functionalities
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

Build is green

Patch application report for D7281 (id=26366)

Rebasing onto 20da92e353...

Current branch diff-target is up to date.
Changes applied before test
commit d58973501d0e9e8f7517db435c937fcd9408cfab
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Thu Mar 3 13:35:37 2022 +0100

    db_utils: Add missing import of psycopg2.errors
    
    This may be needed depending on import order; but it makes mypy complain when
    types-psycopg2 is installed.

See https://jenkins.softwareheritage.org/job/DCORE/job/tests-on-diff/368/ for more details.

olasd added a subscriber: olasd.

Weird that we've never noticed this before.

This revision is now accepted and ready to land.Mar 3 2022, 6:17 PM