LuxDL / DocumenterVitepress.jl

Documentation with Documenter.jl and VitePress
https://luxdl.github.io/DocumenterVitepress.jl/
MIT License
73 stars 11 forks source link

Symlinkined paths like `stable` and `latest` dont work on some repos but not others #81

Open rafaqz opened 6 months ago

rafaqz commented 6 months ago

These get a 404 (after initially flashing the right page):

https://rafaqz.github.io/DimensionalData.jl/stable/ https://rafaqz.github.io/DimensionalData.jl/latest/

But dev works because it actually has a folder in the file system in the gh-pages branch https://rafaqz.github.io/DimensionalData.jl/dev/

I'm not sure what to do about this.

asinghvi17 commented 6 months ago

Https://asinghvi17.github.io/SwarmMakie.jl/stable was just built yesterday and seems to work - I have no clue where this is coming from for certain repos!

rafaqz commented 6 months ago

Your repos are all switching to the version url, for some reason DD is trying to keep the pretty url /stable and it fails.

I guess the only difference is DD has a custom vitepress config?

rafaqz commented 6 months ago

Or is there some other setting?

rafaqz commented 6 months ago

It happens here too! https://luxdl.github.io/DocumenterVitepress.jl/stable/

asinghvi17 commented 6 months ago

hmm, it might be the custom config - let me diff the DV and DD ones with the template, which seems to operate correctly...

lazarusA commented 6 months ago
Screenshot 2024-03-25 at 20 39 05

it looks like one of those REPLACE_ME things is still not getting applied properly.

lazarusA commented 6 months ago

not the cause, also happens in the good landing page:

Screenshot 2024-03-25 at 20 43 39
asinghvi17 commented 6 months ago

Yeah that's just the description, should be fixed in #80

lazarusA commented 6 months ago
Screenshot 2024-03-25 at 20 50 34

the ones that work don't have that issue of REPLACE_ME. (for favicon and description), so yeah, maybe is this thing what is messing up with the redirect.

avik-pal commented 6 months ago

It seems repos that don't have Hydration error do the symlinks correctly. But all the ones which have the error DimensionalData, Lux and Documentervitepress don't work image image

lazarusA commented 6 months ago

Ohhh... see https://github.com/vuejs/vitepress/issues/2293. Also, Also the main difference is the Vue component. Possible fix https://play.vuejs.org/#__SSR__eNp9UctOwzAQ/BXLl7RSlR7gFEIlqCoB4iXoDXOIkm3rktiWvS6Rqvw7fiQlSIAP0WZ2djzjPdIrpdKDBZrRHKFRdYGwYIKQvOKHULhyaQ3KZg0tkgzd95LRBMFgwiiZR/Y80vP5SCQ3peYKiQG0yv3zRkmNZKS20bIhSTpfyia4SLxCnFrQGR1gb65HTypHsiNdLxAnoQ2NCjaFrR3B+1JaKpO9ObctJu8zDwU3k9CYRhIh2mFakMmUXPaZCdlNEpcpmQ0cf7gQoG/WD/dZVE69blD1p5te+LJzQPczCJpSig3fpnsjhUsTJBktXT5eg35SyKUwjGbDZYwWdS0/7wKG2kJ/iZvZQfnxC743rccYfdZgQB+A0VMPC70FjO3V66PzPGo2srK1Y//TfAEja+s9Rtq1FZWzPeIFt7dhM1xs12bVIggzhPJGh5fxbLcvv9q/on/bPUvPw5x7UNp9AXyX3ws=

lazarusA commented 6 months ago

This is better. https://github.com/vuejs/vitepress/issues/1918. I don't have a lot of time today to test it. But, this might be it.

avik-pal commented 6 months ago

Removing the links in the Features https://github.com/LuxDL/Lux.jl/pull/571/files#diff-36c852523b6a7513a10b8a6bae21f1037eaa27484efc9042f75bbda46d9f529b seems to have fixed the hydration error in most of the lux pages, but when redirecting from stable it still has some hydration errors: image

avik-pal commented 5 months ago

(wouldn't recommend this) but if someone desperately needs a workaround till it is properly resolved, manually fixing the symlinks before deploying fixes the deployment https://github.com/LuxDL/Lux.jl/blob/daf571ac359fe602ba9ef773c444298c66bb1378/.github/workflows/DeployDocs.yml#L36-L39

lazarusA commented 5 months ago

which links is exactly fixing this?

Edit:

🤯 , the issue is setting base: '/repo/' ?, because those pages actually live in different versioned folders! 🤯 .

avik-pal commented 5 months ago

which links is exactly fixing this?

Makes all the symlinks into actual directories and recurses through all the files changes for example, v0.5.32 to stable.

Just changing the symlinks into proper directories does nothing.

oameye commented 2 weeks ago

I am unsure how to resolve this in my repo. I use julia-docdeploy to deploy the documtation. Will I have to change my github action to deploy-pages?

oameye commented 2 weeks ago

Is this commit from @lazarusA also a solution?

lazarusA commented 2 weeks ago

no, it didn't worked 😢 . But, there is a solution here: https://github.com/rafaqz/Rasters.jl/issues/709, this should be documented here, at some point.

oameye commented 2 weeks ago

That solved it. Thanks! <3