tim-smart / tim-smart/receipts
can't get sync server to work
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 43
- Forks
- 2
- PR merge metrics
- No merged PRs in 30d
Description
Also I don't understand how this would work, we have the remoteAtom like this:
export const remoteAtom = Atom.runtime((get) =>
Effect.gen(function* () {
const identity = yield* get.some(identityAtom)
const remoteAddress = yield* get.some(remoteAddressAtom)
const url = new URL(remoteAddress)
url.searchParams.set("publicKey", identity.publicKey)
return EventLogRemote.layerWebSocketBrowser(url.toString()).pipe(
Layer.provide(get(eventLogAtom.layer)),
)
}).pipe(Layer.unwrapEffect),
)
But the runtime inside remoteAtom isn't used anywhere as far as I can tell?
Im running the sync server like
docker run -d -p 3000:3000 -v /Users/dev/data:/data timsmart/effect-eventlog-sqlite
And I tried setting remote URL to ws://localhost:3000 and http://localhost:3000 and neither worked.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing usages of remoteAtom and the EventLogRemote.layerWebSocketBrowser call in the TypeScript code. Reproduce the setup with the documented docker run command and test the configured ws://localhost:3000 and http://localhost:3000 URLs. Done means the sync server connects and synchronization works, with the runtime usage or required configuration clarified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, typescript
- Domain
- backend, distributed-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100