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
sitemap not being included in robots.txt #13
Comments
Same here. Doesn't resolve or appear in "robots.txt". |
In my case it looks like rverse() doesn't respect the cache_page() decorator.
|
woo! wayback machine here. I dont even remember creating this issue. |
👍 |
I know this is a pretty old issue, but I wanted to clarify that Alternatively, if you just had 1 sitemap, it seems to work fine if you create an alias view and don't use # views.py
from django.contrib.sitemaps import views as sitemaps_views
from django.views.decorators.cache import cache_page
@cache_page(10 * 60)
def sitemap_index(*args, **kwargs):
return sitemaps_views.index(*args, **kwargs) |
4 years guys. |
@myusuf3 For the record, that type of snark is counter-productive and I think you should know better. Please be so kind and stop giving this type of feedback. |
@yakky the link to that commit doesn't work either lol. I'll check out your branch this evening. |
@mheppner 🤦♂️ |
@yakky I tried the features/djangos branch and that didn't seem to change anything. Everything else was fine though. I think the problem me and @andreyshipilov were having is just how What about adding a setting to django-robots for specifying a named URL to reverse to? |
@mheppner I'm not super fond of adding settings, but it seems adequate to cover this case |
@mheppner @andreyshipilov could you please check the linked pr? |
@yakky looks good to me, thanks! 😃 |
@mheppner thanks for the review! |
@yakky Works for me too :) |
@andreyshipilov 👍 thanks |
@yakky For when have you planned release a new version? |
@SalahAdDin with a little luck this weekend |
@yakky, oh i hope! |
@SalahAdDin 3.0rc1 has been released on Pypi. I'm going to check if everything is ok and I will release 3.0 final in a couple of days (sooner if you could confirm rc1 is fine! ;) ) |
@SalahAdDin Can you give more information about this? Where is that argument you're talking about? For what it's worth, Wagtail doesn't use Django's sitemap framework, they're rolling their own, which means django-robots won't be reversing to it automatically. Can you try giving your URL a name and setting it to |
@mheppner Yes, i did it, i only delete these argument, and works fine. |
@SalahAdDin @mheppner thanks for helping with this. Would you check if linked PR clarifies how to correctly configure robots in the case above? |
Ah, now I see what @SalahAdDin was talking about. @yakky, yeah I think that clears it up 👍 |
@yakky I just tried 3.0rc1 and everything seems to be working, thanks! 🥇 |
I have tried both default discovery as well as specifying it manually using the
ROBOTS_SITEMAP_URLS
setting but I am still unable to get the site map to show up on therobots.txt
The text was updated successfully, but these errors were encountered: