question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

RxResult's summary method is not there

See original GitHub issue

I’m trying to run a simple delete query using the latest reactive session API with neo4j-driver@4.0.1 using node 12.12.0.

Example of the query I am trying to run

MATCH (n)
DETACH DELETE n

The way I’m running this is the following. I’m getting an RxSession from the driver

rxSession.writeTransaction(trx =>
  trx
    .run(statement)
    .summary() // fails on this line
    .pipe(
       map(result => ({ message: `Deleted ${result.counters.updates().nodesDeleted || 0} record(s)` })),
       tap(mappedResult => console.log(mappedResult.message)),
    ),
)

The exported types from result-rx.d.ts seem to indicate there is a summary() which gives back an observable of the result summary. Didn’t find anything in result-rx.js but did find a _summary tied to a ReplaySubject.

My stacktrace looks like this right now if it helps

TypeError: trx.run(...).summary is not a function
    at <project_directory>\dist\worker\worker.service.js:53:14
    at <project_directory>\node_modules\neo4j-driver\lib\session-rx.js:219:20
    at Observable._subscribe (<project_directory>\node_modules\rxjs\internal\observable\defer.js:10:21)
    at Observable._trySubscribe (<project_directory>\node_modules\rxjs\internal\Observable.js:44:25)
    at Observable.subscribe (<project_directory>\node_modules\rxjs\internal\Observable.js:30:22)
    at CatchOperator.call (<project_directory>\node_modules\rxjs\internal\operators\catchError.js:32:23)
    at Observable.subscribe (<project_directory>\node_modules\rxjs\internal\Observable.js:25:31)
    at Object.subscribeToResult (<project_directory>\node_modules\rxjs\internal\util\subscribeToResult.js:12:23)
    at MergeMapSubscriber._innerSub (<project_directory>\node_modules\rxjs\internal\operators\mergeMap.js:82:53)
    at MergeMapSubscriber._tryNext (<project_directory>\node_modules\rxjs\internal\operators\mergeMap.js:76:14)

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

0reactions
snurby7commented, Feb 27, 2020

Thanks @zhenlineo, consume worked exactly like I expected after telling TypeScript to let me do my thing and thank you again for the link, must have missed that when upgrading to 4.x

Read more comments on GitHub >

github_iconTop Results From Across the Web

RxResults - Evidence Based Rx -current
When it comes to evidence-based pharmacy risk management, RxResults does all the heavy lifting. Through our proven model of analysis, implementation, and ...
Read more >
Tabula Rasa HealthCare Partners with RxResults to Provide ...
The TRHC process outshines commonly used methodologies for identifying at-risk patients, and their outcomes speak for themselves—their services ...
Read more >
Index (Neo4j Java Driver 4.3.3 API) - javadoc.io
Returns a string telling the address of the server the query was executed. agent() - Method in interface org.neo4j.driver.summary.ServerInfo. Returns server ...
Read more >
RxResults - Crunchbase Company Profile & Funding
RxResults is a pharmacy benefits risk management company developing a suite of clinical tools to reduce cost. ... 1 email found 2 phone...
Read more >
API Help (rxjava2 2.0.0 API) - GitHub Pages
Nested Class Summary; Field Summary; Constructor Summary; Method Summary ... While there is no link in the navigation bar, you can get to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found