Comments (4)
The RPC call should resolve as soon as a response is received, or after the default timeout, whichever happens first.
Can you give a specific example of different behavior?
the rpc call itself does resolve, but it creates another unresolved timeout or promise for checking the timeout that makes jest complain
Jest did not exit one second after the test run has completed.
'This usually means that there are asynchronous operations that weren't stopped in your tests. Consider running Jest with `--detectOpenHandles` to troubleshoot this issue.
jest test demonstrating this
import { HttpClient } from 'monero-ts';
import { connectToWalletRpc } from 'monero-ts';
//HttpClient.DEFAULT_TIMEOUT = 1000;
// uncomment to make jest test exit properly
test('rpc does not leave open handles', async () => {
const walletRpc = await connectToWalletRpc('http://localhost:18081');
expect(await walletRpc.getPrimaryAddress()).toBeTruthy();
});
from monero-ts.
The RPC call should resolve as soon as a response is received, or after the default timeout, whichever happens first.
Can you give a specific example of different behavior?
from monero-ts.
I haven't been able to recreate the issue in a jest project, but are you able to test this commit? c0651ab
It cancels the timeout promise on successful response.
Otherwise, maybe you have a project I could check out to recreate?
from monero-ts.
Fixed with the last release: 96daaa0
from monero-ts.
Related Issues (20)
- getBalances doc is not correct HOT 2
- Can't open wallet by keys HOT 3
- Failed to parse URL HOT 17
- Monero-ts in NextJS dev server leads to hangup HOT 9
- MoneroWalletKeys.createSubaddress() not supported HOT 1
- Bounty system test [0.1 XMR] HOT 1
- Remove --no-experimental-fetch flag HOT 1
- Nice work, but I got into two issues that I can't work around HOT 7
- Make monero-ts work with sveltekit HOT 1
- MoneroAccount dissapearing? HOT 3
- MoneroTxConfig has no way of setting ringSize. HOT 1
- Method not found | rpcMethod: 'open_wallet' HOT 9
- html5-fs is not compatible with monero-ts HOT 13
- vite browser example HOT 1
- Omitting port in server URI sets port to 0
- Concurrent calls to `save()` can fail
- Failed to parse URL to /path/to/monero_wallet_full.wasm HOT 2
- `startSyncing` does not allow to save wallet until sync completes
- Make use of github actions for CI and release [$1080] HOT 2
- MoneroError: Invalid mnemonic HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from monero-ts.