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

Running trunk serve on examples results in blank web pages #2480

Closed
4 tasks done
ChocolateLoverRaj opened this issue Jun 25, 2024 · 5 comments · Fixed by #2574
Closed
4 tasks done

Running trunk serve on examples results in blank web pages #2480

ChocolateLoverRaj opened this issue Jun 25, 2024 · 5 comments · Fixed by #2574
Labels
bug Something isn't working

Comments

@ChocolateLoverRaj
Copy link

Is your issue REALLY a bug?

  • My issue is indeed a bug!
  • I am not crazy! I will not fill out this form just to ask a question or request a feature. Pinky promise.

Is there an existing issue for this?

  • I have searched the existing issues.

Is this issue related to iced?

  • My hardware is compatible and my graphics drivers are up-to-date.

What happened?

When I run cargo r on the examples, a window is created and it works as expected. When I run trunk serve on the examples which are also supposed to work on the web, the page just has a title and blank canvas. I'm not getting an error with trunk itself:

test@test-Standard-PC-Q35-ICH9-2009:~/iced/examples/counter$ trunk serve
2024-06-25T17:39:37.269355Z  INFO \U0001f680 Starting trunk 0.20.2
2024-06-25T17:39:37.274371Z  INFO \U0001f4e6 starting build
    Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.44s
2024-06-25T17:39:45.058106Z  INFO applying new distribution
2024-06-25T17:39:45.060747Z  INFO \u2705 success
2024-06-25T17:39:45.061741Z  INFO \U0001f4e1 serving static assets at -> /
2024-06-25T17:39:45.061967Z  INFO \U0001f4e1 server listening at:
2024-06-25T17:39:45.061991Z  INFO     \U0001f3e0 http://127.0.0.1:8080/
2024-06-25T17:39:45.062031Z  INFO     \U0001f3e0 http://[::1]:8080/

To reproduce:

  • Clone this repo (commit b9eb86199afe0f2d936eb4ab90af5b2a2c32a87a)
  • cd examples/counter
  • trunk serve

I tried it on NixOS and also in a Ubuntu VM and both had the same result.

What is the expected behavior?

The counter and TODO examples should have text and buttons showing up on the web page.

Version

master

Operating System

Linux

Do you have any log output?

Console at http://localhost:8080:

WEBGL_debug_renderer_info is deprecated in Firefox and will be removed. Please use RENDERER. counter-91af9f8a594c1ec3.js:1366:37
WebGL warning: texSubImage: Uploads from a buffer with a final row with a byte count smaller than the row stride can incur extra overhead. 2
WebGL warning: drawArraysInstanced: Drawing to a destination rect smaller than the viewport rect. (This warning will only be given once) 
@ChocolateLoverRaj ChocolateLoverRaj added the bug Something isn't working label Jun 25, 2024
@theoparis
Copy link

I am having the same issue on a PopOS machine with the latest iced commit 😕 I am also using firefox.

@dahefanteng
Copy link

I am having the same issue on a mint linux 21 with firefox.

@theoparis
Copy link

I just tested with chromium with chrome://flags webgpu enabled and the --enable-features=Vulkan and the same issue happens, except there are no error messages. I guess this isn't a firefox specific issue then.

@derezzedex
Copy link
Member

Could you check #2574 to see if it fixes your problem?

@theoparis
Copy link

Yes, the mentioned PR fixes the issue on both Chromium and Firefox on my machine.

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

Successfully merging a pull request may close this issue.

4 participants