One form of jsonCall not working in Comet context
Nobody has claimed this yet.
- Dominant language
- Scala
- Stars
- 1.3k
- Forks
- 275
- PR merge metrics
- No merged PRs in 30d
Description
**[Mailing List](https://groups.google.com/forum/#!topic/liftweb/PxOkDLEjmso) thread**
No example project available.
When using this form of jsonCall:
```
def jsonCall(jsCalcValue: JsExp, jsonContext: JsonContext, func: (JValue) ⇒ JValue): GUIDJsExp
```
When "func" is called in a comet context, the client receives an empty response.
Antonio said:
> Got it. This is the interaction of https://github.com/lift/framework/blob/master/web/webkit/src/main/scala/net/liftweb/http/CometActor.scala#L934
with https://github.com/lift/framework/blob/master/web/webkit/src/main/scala/net/liftweb/http/LiftServlet.scala#L637,
which means that a JsonResponse isn't ever generated correctly from a CometActor.
>
> That's going to be a doozy to fix… We may end up wanting to push notices via the comet
response while pushing JSON via the AJAX response. But always doing that could result
in strange ordering issues, and sometimes doing that could lead to lack of clarity about when
that will happen vs not.
>
> Will ponder it a bit; can you open an issue?
Contributor guide
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 the interaction between CometActor.scala at line 934 and LiftServlet.scala at line 637 for the jsonCall overload using JsonContext and func. Determine how a JsonResponse should be generated from a CometActor so the client no longer receives an empty response, then verify the behavior in a Comet context.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- scala
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100