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

Promise returned by puter.ui.createWindow() never resolves #483

Closed
1 of 4 tasks
AtkinsSJ opened this issue Jun 19, 2024 · 1 comment
Closed
1 of 4 tasks

Promise returned by puter.ui.createWindow() never resolves #483

AtkinsSJ opened this issue Jun 19, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@AtkinsSJ
Copy link
Collaborator

Issue Description
puter.ui.createWindow() returns a Promise that never resolves.

Steps to Reproduce
Run this and observe that the alert never happens.

await puter.ui.createWindow({ content: 'I am a window' });
alert("Hello!");

Expected & Actual Behavior
I'm not sure when the Promise should resolve. But either we should resolve it (perhaps when the window is created) or we shouldn't return one.

Addition Information or Screenshots (if applicable)

Deployment

  • Production (puter.com)
  • Development (npm run start)
  • Docker (via docker run)
  • Docker (via docker-compose)

Puter version (if accessible)

Click the profile button on the top-right, then "Settings". The version number will be printed at the bottom

@AtkinsSJ AtkinsSJ added the bug Something isn't working label Jun 19, 2024
@jelveh jelveh closed this as completed in 1500f84 Jun 20, 2024
@jelveh
Copy link
Contributor

jelveh commented Jun 20, 2024

Done. This should work now:

let win = await puter.ui.createWindow({ content: 'I am a window' });
puter.ui.setWindowTitle('New Title', win);
puter.ui.setWindowHeight(100, win);
puter.ui.setWindowWidth(100, win);
...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants