jupyterlab / jupyter-collaboration

A Jupyter Server Extension Providing Support for Y Documents
https://jupyterlab-realtime-collaboration.readthedocs.io/en/latest/
Other
170 stars 31 forks source link

Extract out ICollaborativeDrive to `@jupyter/collaborative-drive` #353

Closed davidbrochart closed 1 month ago

davidbrochart commented 2 months ago

See https://github.com/jupyterlab/jupyter-collaboration/issues/352#issuecomment-2353809355.

github-actions[bot] commented 2 months ago

Binder :point_left: Launch a Binder on branch _davidbrochart/jupytercollaboration/extract-icollaborativedrive

davidbrochart commented 2 months ago

Should there be a new projects/jupyter-collaborativedrive?

davidbrochart commented 2 months ago

I'm wondering if this failure:

Error: src/yprovider.ts(6,35): error TS2307: Cannot find module '@jupyter/collaborativedrive' or its corresponding type declarations.
Error: src/ydrive.ts(16,8): error TS2307: Cannot find module '@jupyter/collaborativedrive' or its corresponding type declarations.

is caused by the fact that @jupyter/collaborativedrive is not yet published to NPM? I cannot reproduce it, it works locally.

davidbrochart commented 1 month ago

@krassowski What do you think about getting this in before releasing v3? We would need to publish @jupyter/collaborativedrive to NPM.

davidbrochart commented 1 month ago

@jtpio do you have the rights to publish @jupyter/collaborativedrive to NPM?

davidbrochart commented 1 month ago

@krassowski @jtpio ok to merge and publish @jupyter/collaborative-drive?

davidbrochart commented 1 month ago

I'm planning to merge today.

jtpio commented 1 month ago

Thanks @davidbrochart. I'll try to have another look today.

davidbrochart commented 1 month ago

Same error:

    src/yprovider.ts:6:35 - error TS2307: Cannot find module '@jupyter/collaborative-drive' or its corresponding type declarations.
    6 import { IDocumentProvider } from '@jupyter/collaborative-drive';
                                        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

I guess the published package is useless without code. I'll add jlpm build back.

jtpio commented 1 month ago

I guess the published package is useless without code.

What do you mean by "without code"? The package was published from this branch directly.

davidbrochart commented 1 month ago

Oh my bad, yes the code is there. Then I don't know what is wrong.

jtpio commented 1 month ago

Having to add jlpm run build makes it look like something is wrong in the setup of the new package, since it was not needed before.

davidbrochart commented 1 month ago

I guess the published package is useless without code.

What do you mean by "without code"? The package was published from this branch directly.

Actually yes, there is no code here.

davidbrochart commented 1 month ago

I published @jupyter/collaborative-drive v3.0.0-beta.7, and there is no IDocumentProvider in lib/tokens.js here. It is in lib/tokens.d.ts but it's not enough, right?

davidbrochart commented 1 month ago

In the end, I just think that jlpm build is needed because the test in docprovider now needs @jupyter/collaborative-drive through yprovider.ts, so it has to be compiled.

davidbrochart commented 1 month ago

I'll take the risk to merge this PR and release jupyter-collaboration v3.0.0beta7. We can still revert the changes and release v3.0.0beta8 if it doesn't work.

jtpio commented 1 month ago

Arf, I wanted to help you more on this yesterday but didn't have time.

At the very least it would have been great to leave a TODO, or open an issue...

Maybe check the tsconfig.json to see if it needs a references?