Skip to content

fix(postgres): enable whoami/std feature#4275

Open
svnrb wants to merge 1 commit into
launchbadge:mainfrom
svnrb:whoami-feature-std
Open

fix(postgres): enable whoami/std feature#4275
svnrb wants to merge 1 commit into
launchbadge:mainfrom
svnrb:whoami-feature-std

Conversation

@svnrb
Copy link
Copy Markdown

@svnrb svnrb commented May 22, 2026

Commit 1dd526a bumped whoami to v2, but it seems that version now needs to have the std feature enabled to do anything useful.

In earlier sqlx versions, connection strings like postgresql:///dbname correctly used the current user's name, matching psql's behavior. Now, it falls back to anonymous. Enabling the std feature fixes that.

Does your PR solve an issue?

Yes, but I don't think it's been reported on GitHub yet.

Is this a breaking change?

Unlikely; it does of course change behavior but I'd classify it as a bug fix.

Commit 1dd526a bumped whoami to v2, but
it seems that version now needs to have the `std` feature enabled to do
anything useful.

In earlier sqlx versions, connection strings like `postgresql:///dbname`
correctly used the current user's name, matching psql's behavior. Now,
it falls back to `anonymous`. Enabling the `std` feature fixes that.
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