Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Outputs do not show up on collaborators screens #16670

Closed
krassowski opened this issue Aug 12, 2024 · 1 comment · Fixed by #16692
Closed

Outputs do not show up on collaborators screens #16670

krassowski opened this issue Aug 12, 2024 · 1 comment · Fixed by #16692
Labels
bug tag:Release Blocker A must-have bug for the milestone to which it is tagged
Milestone

Comments

@krassowski
Copy link
Member

krassowski commented Aug 12, 2024

Description

Here print(1 + 1) was executed by a collaborator, the output does not show

image

But an error shows up:

TypeError: Cannot read properties of undefined (reading 'streamText')
    at d._add (jlab_core.abd83dd7cfacd6da4d00.js?v=abd83dd7cfacd6da4d00:1:1264450)
    at d.add (jlab_core.abd83dd7cfacd6da4d00.js?v=abd83dd7cfacd6da4d00:1:1263879)
    at jlab_core.abd83dd7cfacd6da4d00.js?v=abd83dd7cfacd6da4d00:1:238322
    at 1168.8e5df3139aa020a611cb.js?v=8e5df3139aa020a611cb:1:551
    at q._onSharedModelChanged (jlab_core.abd83dd7cfacd6da4d00.js?v=abd83dd7cfacd6da4d00:1:238119)
    at m (jlab_core.abd83dd7cfacd6da4d00.js?v=abd83dd7cfacd6da4d00:1:1838868)
    at Object.l [as emit] (jlab_core.abd83dd7cfacd6da4d00.js?v=abd83dd7cfacd6da4d00:1:1838544)
    at a.emit (jlab_core.abd83dd7cfacd6da4d00.js?v=abd83dd7cfacd6da4d00:1:1836381)
    at Array._modelObserver (1168.8e5df3139aa020a611cb.js?v=8e5df3139aa020a611cb:1:7524)
    at Object.r (383.db345dbeef5ef774e50c.js?v=db345dbeef5ef774e50c:1:936)
e.exceptionHandler @ jlab_core.abd83dd7cfacd6da4d00.js?v=abd83dd7cfacd6da4d00:1
m @ jlab_core.abd83dd7cfacd6da4d00.js?v=abd83dd7cfacd6da4d00:1
l @ jlab_core.abd83dd7cfacd6da4d00.js?v=abd83dd7cfacd6da4d00:1
emit @ jlab_core.abd83dd7cfacd6da4d00.js?v=abd83dd7cfacd6da4d00:1
_modelObserver @ 1168.8e5df3139aa020a611cb.js?v=8e5df3139aa020a611cb:1
r @ 383.db345dbeef5ef774e50c.js?v=db345dbeef5ef774e50c:1
ji @ 383.db345dbeef5ef774e50c.js?v=db345dbeef5ef774e50c:1
(anonymous) @ 383.db345dbeef5ef774e50c.js?v=db345dbeef5ef774e50c:1
r @ 383.db345dbeef5ef774e50c.js?v=db345dbeef5ef774e50c:1
$o @ 383.db345dbeef5ef774e50c.js?v=db345dbeef5ef774e50c:1
Jo @ 383.db345dbeef5ef774e50c.js?v=db345dbeef5ef774e50c:1
Ci @ 383.db345dbeef5ef774e50c.js?v=db345dbeef5ef774e50c:1
Ai @ 383.db345dbeef5ef774e50c.js?v=db345dbeef5ef774e50c:1
vi @ 383.db345dbeef5ef774e50c.js?v=db345dbeef5ef774e50c:1
M @ 994.c290665e94ae9503337f.js?v=c290665e94ae9503337f:1
(anonymous) @ 994.c290665e94ae9503337f.js?v=c290665e94ae9503337f:1
J.<computed> @ 994.c290665e94ae9503337f.js?v=c290665e94ae9503337f:1
q @ 994.c290665e94ae9503337f.js?v=c290665e94ae9503337f:1
K.t.onmessage @ 994.c290665e94ae9503337f.js?v=c290665e94ae9503337f:1

Reproduce

  1. Install jupyter-collaboration and jupyterLab 4.3.0b0 or just use this binder
  2. Open a notebook
  3. Open a new view as a collaborator in a different browser
  4. Execute some cells producing text output
  5. See no output

Expected behavior

Output shows up

Context

@krassowski krassowski added bug status:Needs Triage Applied to new issues that need triage tag:Release Blocker A must-have bug for the milestone to which it is tagged labels Aug 12, 2024
@krassowski krassowski added this to the 4.3.0 milestone Aug 12, 2024
@krassowski
Copy link
Member Author

This error comes from:

// We append the new text to the current text.
// This creates a text change event.
const prev = this.list.get(this.length - 1) as IOutputModel;
const curText = prev.streamText!;

It looks like the code assumes that there always is a previous output of some kind.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug tag:Release Blocker A must-have bug for the milestone to which it is tagged
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants