Incorrectly autogenerated image urls

I am having an issue with the autogenerated img tags. Here’s what I am getting:
<p><img src="//images/copied_from_nb/prod-ubiops.jpg" alt="How it Works"></p>

Those don’t work because of the double //

I have tried altering the baseurl parameter everywhere it is defined (which is quite a few places). Nothing has worked.

That’s interesting you should only have to modify it in config.yaml

Make sure you are doing a hard refresh, if you changed liquid tags yourself will be hard to help but this gets really tricky, if you are trying to change the liquid template you have to use a special operator to make urls relative

Not sure why this happened to you as this is not the case for fastpages by default?

I don’t have a config.yaml, mine is called _config.yaml

Since it’s happening in the notebook to html pipeline, do you have any idea how I would troubleshoot this?

I am building the site locally with make server
The images are getting copied all to the right place. If I go into the browser and change the // to / the image renders.

I am adding new layouts and pages.
The site is found at blog.prcvd.ai

I looked at the nbdev functions here, and it looks like you’re using the Path path join, which normally eliminates //

Yes that is what I mean. I don’t think its an error in nbdev, but potentially how you are specifying the baseurl in _config.yaml Here are the instructions for fastpages that perhaps may help you here as well

###########################################################
#########  Special Instructions for baseurl ###############
#
#### Scenario One: If you do not have a Custom Domain #####
#    -  if you are not using a custom domain, the baseurl *must* be set to your repo name
# 
####  Scenario Two: If you have a Custom Domain #####
# 1. If your domain does NOT have a subpath, this leave this value as ""
# 2. If your domain does have a subpath, you must preceed the value with a / and NOT have a / at the end.  
#      For example: 
#           "" is valid
#           "/blog"        is valid
#            "/blog/site/" is invalid  ( / at the end)
#            "/blog/site"  is valid
#            "blog/site"   is invalid  ( because doesn't begin with a /)
#
# 3. You must replace the parameter `baseurl` in _action_files/settings.ini with the same value as you set here but WITHOUT QUOTES.
#
baseurl: "" # the subpath of your site, e.g. "/blog".

Let me know if that helps.

That doesn’t fix it. Here, I think I was able to reproduce the issue:

from pathlib import Path

Path('//tmp//tep.a')

>> PosixPath('//tmp/tep.a')

Can you explain why you think this has anything to do with pathlib?

Right now because your url is // it seems like your baseurl is not being populated correctly? Or am I misunderstanding? Can you share a repo?

Yes I can share the repo. What github handle do you want to use?

I don’t think the issue is with pathlib, I was just illustrating that I could simulate the problem I am seeing even applying pathlib. Namely, It doesn’t eliminate the double slash if its the first 2 characters of the provided path.