-
Notifications
You must be signed in to change notification settings - Fork 7
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
@contents and any canonical bibliography do not work together #16
Comments
You have to have one (or at least one, with caveats) canonical bibliography. By definition, that's where all citation links go. Is "Scenario 3" identical to "Scenario 1" except for removing Scenarios 2 seems unrelated. I don't think I'm not really sure what's going on in Scenario 3. It could be some weird interaction with the Markdown parser, similar to #14? |
Just for fun, try removing the colon from your citation keys |
Removed the colon already, all 3 scenarios are the same then. Yes 3 is just 1 without Canonical=false. |
Ah yes I missed the caveat that a canonical reference list has to exist and added such a page (just covering the canonical one). Then I still get (concistently) The error from 3 now also in 1. |
Havin only one
still yields
but no warnings that the cites do not exist before, still also no single rendered output html page. If I remove said references file (still not bibliography command in the index.md) I only get warnings about non existing links of course. I am not sure what this error is trying to tell me. Seems like it wants to treat a BibTeX entry as a heading? edit: The error appears as soon as I have a reference to be linked/added in the literature of a canonical bibliography. So If
|
If I do
I get a bit further until I hit
but I fear I might be missing something tremendously before that I get the first error actually? I am just not sure what and I am lost by now. |
Not sure if related, but note that Documenter works with all markdown files in
got me thinking perhaps you have some garbage files left from previous tries in |
I am aware that Documenter renders all markdown, But, no, sadly not that I am aware of. Everything works fine as long as long as I have either zero cites or no canonical bibliography. As soon as I have both, it seems fail to reference the bib entries since those do not have a header level? |
Can you try using this |
Sure, will try. My current file is already really minimal and just @book{AbsilMahonySepulchre:2008,
title = {Optimization Algorithms on Matrix Manifolds},
author = {Absil, P.-A. and Mahony, R. and Sepulchre, R.},
year = {2008},
publisher = {Princeton University Press},
doi = {10.1515/9781400830244}
} |
Try removing the colon from the key name |
I did try that a lot of times already, that does not change anything. |
Ok, very weird… I’ll try to dig into this when I’m back at my computer |
No problem, I will try to narrow it down to a as-few-as-possible-file/lines example later today. |
Did you restart Julia in between? Perhaps the caching is causing the problem if it has already cached some bad entry? |
I usually start my documenter run from terminal, since there I can decide with |
The error also appears when I switch from my edit: even when my index md is the only file with citation code and is minimised to
|
Okay, that’s good to know, at least |
So! I went first for the approach of an MWE, but that suddenly worked, so I slowly in a binary fashion deleted files from (a copy of) my relatively large documentation to find the page that issues the error. 😴 If you do a
and an
and a
That one fails! So it seems to be some interplay between table of contents and bibliography! Luckily at least for some time I can ignore the |
Ah, so this is the "old" issue ali-ramadhan/DocumenterCitations.jl#24 Well, good to know that's still an issue, I guess. We'll have to really figure out why that happens and fix it at some point. I'm sorry this caused you so much trouble. Quite a rabbit hole! For now, my recommendation would be to have your canonical reference on a separate page, and specifically not in |
Well, it was not that nice to start with this. It does not matter whether And I was not aware that this was even an old issue, well. Now I wasted this afternoon. It is what it is, and at least now it seems to work and I just have to rewrite my two styles of references into one (but hopefully only do such thing once). |
Yeah, I understand. I'm sorry about the frustrating experience. We'll definitely look into improving this situation, but it might take some time. |
Sure, no problem :) Thanks for providing this package, I am looking forward to new docs with nicer references (and might let you know once I have finished that). |
Right! So based on ali-ramadhan/DocumenterCitations.jl#24 (comment) and ali-ramadhan/DocumenterCitations.jl#33 (comment), as well as my own testing just now, the current workaround is to have your canonical bibliography on a separate page, and exclude that page from the Definitely not an ideal situation. |
Now that I can reproduce this, I'm not sure if this is really a bug in The error gets triggered by the code handling the @fredrikekre Should we open an issue for this at https://github.com/JuliaDocs/Documenter.jl/issues? Or maybe we should figure out exactly why this happens, first. |
Does it also error when you use #3 and Documenter#master? With all the changes to the AST-related internals, maybe this has fixed itself. |
Unfortunately, yes. But in the latest iteration of #3 I've added a |
Alright, I looked into this, and the problem was that we were storing the However, the internals of The correct thing to do here is for Fixed in #42 |
I narrowed my make file down to
Scenario 1
and in my index.md
This does not find the cites and warns that the links do not exist like
But generates the right bibliography at the end of the index page.
Scenario 2
If I instead set line 2 to
I get
If I leave out the
format=
keyword in the makedocs I am back to references not being found.Scenario 3
I leave out the
Canonical=false
in the index.md (maybe one needs at least one canonical one for the links to work?)The I get
The reduced makefile is submitted currently also on the corresponding branch, cf. https://github.com/JuliaManifolds/Manopt.jl/blob/kellertuer/documentercitations/docs/make2.jl
and I am running with
And I am by now a bit lost how to get this to run, I can either not have working links (but a correct bibliography at the end) or error messages. Is there some magic I am missing?
The text was updated successfully, but these errors were encountered: