`The current directory is not a valid dolt repository` error message after two users, one authenticated and one not, tried to access the same cloned repository
- Dominant language
- Go
- Stars
- 24.4k
- Forks
- 873
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 120
Description
Original error message was seen after two users, one authenticated and one not, tried to access the same cloned repository.
```
[doltUser]$ dolt clone dolthubDB
cloning https://doltremoteapi.dolthub.com/dolthubDB
[doltUser]$ cd dolthubDB/
[doltUser]$ dolt status
The current directory is not a valid dolt repository.
```
```
[root]$ dolt sql -q "select 1 from branchMetadata"
ERRO[0002] invalid replication configuration, replication disabled: failed to load replica database from remote 'origin'; could not access dolt url 'https://doltremoteapi.dolthub.com/dolthubDB': rpc error: code = PermissionDenied desc = permission denied
+---+
| 1 |
+---+
| 1 |
+---+
```
Attempted repro steps taken:
```
$ dolt login
$ dolt clone dolthubDB
$ cd dolthubDB
$ dolt sql -q "set @@persist.dolt_read_replica_remote = 'origin'"
$ dolt sql -q "set @@persist.dolt_replicate_heads = main"
$ dolt creds rm
$ dolt sql -q "select 1 from dolt_branches"
ERRO[0000] invalid replication configuration, replication disabled: failed to load replica database from remote 'origin'; invalid creds file
$ dolt login
$ dolt status
everything normal, no errors
```
In other words, able to reproduce all steps from the original issue except the last error message of `The current directory is not a valid dolt repository.`
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the reported dolt clone, dolt status, and replica-configuration commands, then compare the invalid-credentials path with the final unauthenticated access path. Done means the two-user scenario no longer produces the misleading “not a valid dolt repository” message, with an actionable error instead.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, sql
- Domain
- authentication, databases
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100