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

Failed to serve the site - Found path collisions #1935

Closed
ralfbiedert opened this issue Jul 21, 2022 · 10 comments
Closed

Failed to serve the site - Found path collisions #1935

ralfbiedert opened this issue Jul 21, 2022 · 10 comments
Labels
bug Need Windows help We need someone using Windows to help us with this issue

Comments

@ralfbiedert
Copy link

Bug Report

Environment

Zola version: 0.16

Expected Behavior

Running zola serve should serve the site.

Current Behavior

When running zola serve with the latest 0.16 I get instead

PS C:\Users\rb\Development\Source\cheats.rs> zola serve --open
Building site...
Error: Failed to serve the site
Error: Found path collisions:
- `/` from files ["\\\\?\\C:\\Users\\rb\\Development\\Source\\cheats.rs\\content\\_index.md", "//?/C:/Users/rb/Development/Source/cheats.rs/content/_index.md"]

Running with 0.14 I get instead

PS C:\Users\rb\Development\Source\cheats.rs> zola_14 serve --open
Building site...
Checking all internal links with anchors.
> Successfully checked 0 internal link(s) with anchors.
-> Creating 1 pages (0 orphan), 0 sections, and processing 0 images
Done in 162ms.

Step to reproduce

  1. On Windows, clone https://github.com/ralfbiedert/cheats.rs
  2. Run zola serve
@Keats Keats added bug Need Windows help We need someone using Windows to help us with this issue labels Jul 21, 2022
@Keats
Copy link
Collaborator

Keats commented Jul 21, 2022

Another Windows issue :(

I might need to find a way to get a Windows environment considering how many of those we get.

@ralfbiedert
Copy link
Author

To develop, I'd probably set up a VirtualBox Windows environment. It's not perfect, but for occasional testing and development it should do the trick and, depending on your setup, you can still edit from your Linux / Mac IDE and only "alt tab" into the VM to run cargo build.

Let me know if I can help.

@Keats
Copy link
Collaborator

Keats commented Jul 24, 2022

It's a bit more complex as I have a M1. I'll figure it out or install it on my desktop. It would be great to have someone writing failing tests though since that's something clearly failing for Windows here.

@c-git
Copy link
Contributor

c-git commented Jul 25, 2022

Want to help if possible

Not sure if I can help there but would be happy to try. However, I'm not really sure how to get started.

Things I think I understand

I'm going to list the things that I think I understand and think are relevant. And maybe someone can point me in the right direction.

  • I am able to run windows in a VM (using virtual box) or if really necessary my laptop is dual boot but I don't like booting into Windows. Does the version of Windows matter? (I have a Windows 7 VM already that I use for some old software).
  • I'm new to rust but not programming, few years experience in other languages, most recently python. I recently finished the rust book and I feel fairly comfortable with the testing framework as described in the book. What I understand is that there is a section at the bottom of the file where tests go and only gets run when in testing mode.

Things that I'm wondering about

I might need more info than what is listed here but this is what I think I need to know to be able to try

  1. Confirmation that the test should fail independent of the OS that they are run on? Or am I making the problem harder than it needs to be.
  2. What is being requested is to try to reproduce the recent errors windows users are getting and write tests that fail under those conditions?
  3. Which file should these tests be added to?

@Keats
Copy link
Collaborator

Keats commented Jul 25, 2022

Thanks for the help! I've set up some Windows dev machine (well just missing Sass to work but eh) so I'll have a look as well.

  1. Those issues are all related to Windows style path so I guess new tests should fail only on Windows
  2. Yes
  3. Hard to say, I would have expected components/site/tests/site.rs to show those errors

@c-git
Copy link
Contributor

c-git commented Jul 25, 2022

Thanks will give it a go (I'll still try to make the tests OS independent if possible). Thanks for letting me know it's not required.

@c-git
Copy link
Contributor

c-git commented Jul 25, 2022

I just realized that the test are also run on windows so making it platform independent would actually make it confusing that it's a windows only problem.

@swiftcoder
Copy link
Contributor

I just checked, and this is also working once you pull the fix in #1941

@Keats
Copy link
Collaborator

Keats commented Jul 25, 2022

Yep, tested as well and it works. I'll publish 0.16.1 soon then to address that.

@c-git
Copy link
Contributor

c-git commented Aug 14, 2022

Thanks for the help! I've set up some Windows dev machine (well just missing Sass to work but eh) so I'll have a look as well.

1. Those issues are all related to Windows style path so I guess new tests should fail only on Windows

2. Yes

3. Hard to say, I would have expected `components/site/tests/site.rs` to show those errors

Thanks for your help but time has not permitted me to get this done. I've realized that it will be a while before I would have been able to get to it. Hopefully I'll be able to contribute in the future. I will save these instructions for future reference.

@Keats Keats closed this as completed Aug 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Need Windows help We need someone using Windows to help us with this issue
Projects
None yet
Development

No branches or pull requests

4 participants