Skip to content

Update module github.com/lib/pq to v1.12.0#2136

Merged
red-hat-konflux[bot] merged 1 commit intomasterfrom
konflux/mintmaker/master/github.com-lib-pq-1.x
Mar 30, 2026
Merged

Update module github.com/lib/pq to v1.12.0#2136
red-hat-konflux[bot] merged 1 commit intomasterfrom
konflux/mintmaker/master/github.com-lib-pq-1.x

Conversation

@red-hat-konflux
Copy link
Copy Markdown
Contributor

@red-hat-konflux red-hat-konflux bot commented Mar 30, 2026

This PR contains the following updates:

Package Change Age Confidence
github.com/lib/pq v1.11.2 -> v1.12.0 age confidence

Warning

Some dependencies could not be looked up. Check the warning logs for more information.


Release Notes

lib/pq (github.com/lib/pq)

v1.12.0

Compare Source

  • The next release may change the default sslmode from require to prefer.
    See #​1271 for details.

  • CopyIn() and CopyInToSchema() have been marked as deprecated. These are
    simple query builders and not needed for COPY [..] FROM STDIN support (which
    is not deprecated). (#​1279)

    // Old
    tx.Prepare(CopyIn("temp", "num", "text", "blob", "nothing"))
    
    // Replacement
    tx.Prepare(`copy temp (num, text, blob, nothing) from stdin`)
    
Features
  • Support protocol 3.2, and the min_protocol_version and
    max_protocol_version DSN parameters (#​1258).

  • Support sslmode=prefer and sslmode=allow (#​1270).

  • Support ssl_min_protocol_version and ssl_max_protocol_version (#​1277).

  • Support connection service file to load connection details (#​1285).

  • Support sslrootcert=system and use ~/.postgresql/root.crt as the default
    value of sslrootcert (#​1280, #​1281).

  • Add a new pqerror package with PostgreSQL error codes (#​1275).

    For example, to test if an error is a UNIQUE constraint violation:

    if pqErr, ok := errors.AsType[*pq.Error](err); ok && pqErr.Code == pqerror.UniqueViolation {
        log.Fatalf("email %q already exsts", email)
    }
    

    To make this a bit more convenient, it also adds a pq.As() function:

    pqErr := pq.As(err, pqerror.UniqueViolation)
    if pqErr != nil {
        log.Fatalf("email %q already exsts", email)
    }
    
Fixes
  • Fix SSL key permission check to allow modes stricter than 0600/0640#1265 (#​1265).

  • Fix Hstore to work with binary parameters (#​1278).

  • Clearer error when starting a new query while pq is still processing another
    query (#​1272).

  • Send intermediate CAs with client certificates, so they can be signed by an
    intermediate CA (#​1267).

  • Use time.UTC for UTC aliases such as Etc/UTC (#​1282).


Configuration

📅 Schedule: Branch creation - Between 03:00 AM and 10:59 AM, only on Monday ( * 3-10 * * 1 ) in timezone Europe/Prague, Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

To execute skipped test pipelines write comment /ok-to-test.


Documentation

Find out how to configure dependency updates in MintMaker documentation or see all available configuration options in Renovate documentation.

Summary by Sourcery

Build:

  • Bump github.com/lib/pq from v1.11.2 to v1.12.0 in go.mod and go.sum.

@red-hat-konflux red-hat-konflux bot enabled auto-merge (rebase) March 30, 2026 01:26
@red-hat-konflux red-hat-konflux bot requested a review from a team as a code owner March 30, 2026 01:26
Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>
@red-hat-konflux red-hat-konflux bot force-pushed the konflux/mintmaker/master/github.com-lib-pq-1.x branch from c3f3149 to f50e88c Compare March 30, 2026 01:26
@sourcery-ai
Copy link
Copy Markdown

sourcery-ai bot commented Mar 30, 2026

Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Bumps the PostgreSQL driver dependency github.com/lib/pq from v1.11.2 to v1.12.0 in go.mod (and go.sum), pulling in upstream feature, deprecation, and bugfix changes while leaving application code untouched.

File-Level Changes

Change Details Files
Update the PostgreSQL driver dependency github.com/lib/pq from v1.11.2 to v1.12.0.
  • Change the required version of github.com/lib/pq in go.mod to v1.12.0.
  • Refresh go.sum entries to match the new github.com/lib/pq version and its checksums.
go.mod
go.sum

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@red-hat-konflux red-hat-konflux bot merged commit 87ae0e0 into master Mar 30, 2026
7 of 10 checks passed
@github-actions
Copy link
Copy Markdown

SC Environment Impact Assessment

Overall Impact:NONE

No SC Environment-specific impacts detected in this PR.

What was checked

This PR was automatically scanned for:

  • Database migrations
  • ClowdApp configuration changes
  • Kessel integration changes
  • AWS service integrations (S3, RDS, ElastiCache)
  • Kafka topic changes
  • Secrets management changes
  • External dependencies

Copy link
Copy Markdown

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey - I've left some high level feedback:

  • Given the upstream note that the next lib/pq release may change the default sslmode from require to prefer, it would be good to scan existing DSNs and explicitly set sslmode where you rely on current defaults to avoid subtle behavioral changes in a future bump.
  • Since CopyIn/CopyInToSchema are now deprecated, check whether this codebase uses them and, if so, plan a follow-up PR to migrate those call sites to raw COPY ... FROM STDIN statements as suggested in the changelog.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- Given the upstream note that the next lib/pq release may change the default `sslmode` from `require` to `prefer`, it would be good to scan existing DSNs and explicitly set `sslmode` where you rely on current defaults to avoid subtle behavioral changes in a future bump.
- Since `CopyIn`/`CopyInToSchema` are now deprecated, check whether this codebase uses them and, if so, plan a follow-up PR to migrate those call sites to raw `COPY ... FROM STDIN` statements as suggested in the changelog.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Mar 30, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 59.18%. Comparing base (c4888aa) to head (f50e88c).
⚠️ Report is 7 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #2136   +/-   ##
=======================================
  Coverage   59.18%   59.18%           
=======================================
  Files         134      134           
  Lines        8624     8624           
=======================================
  Hits         5104     5104           
  Misses       2985     2985           
  Partials      535      535           
Flag Coverage Δ
unittests 59.18% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@red-hat-konflux red-hat-konflux bot deleted the konflux/mintmaker/master/github.com-lib-pq-1.x branch March 30, 2026 05:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant