OpenSimulationInterface / open-simulation-interface

A generic interface for the environmental perception of automated driving functions in virtual scenarios.
Other
269 stars 124 forks source link

Consolidate Hosted OSI Documentation Sources #832

Open TimmRuppert opened 1 week ago

TimmRuppert commented 1 week ago

Describe the bug

Currently, there are three separate sources for OSI documentation hosted online:

Describe how to reproduce the bug

  1. Visit the links mentioned above.
  2. Observe that the documentation is split across three sources.

Describe the expected behavior

A unified and streamlined documentation experience. Specifically, the following changes are recommended:

Show some screenshots

If applicable, add screenshots to help explain your problem. OSI Documentation

jdsika commented 1 week ago

What kind of approval do you need to do as you proposed?

TimmRuppert commented 1 week ago

I am not entirely sure as I have not used github pages or antora yet. Furthermore, I am not familiar with the idea behind the release chains and the OSI repo split. But I think I understand the issue now a little bit better and want to summarize it for clarification:

My naive approach would be:

But this is just my naive way of looking at the problem, e.g. there is also the ASAM Antora Extensions responsible for the doxygen conversion etc. Most of the documentation setup seems to come from @pmai and @philipwindecker. Maybe one of them can have a look at my proposal and point out potential flaws or pitfall.

One issue is that (external) links to the osi-documentation (wrong version anyways) page or the doxygen page would break. E.g. the esmini readme is not pointing to the Antora version. But I think this is still acceptable as it would unify the documentation to a single source.

jdsika commented 1 week ago

@engelben is there still support from the office regarding these setup of documentation etc?

philipwindecker commented 1 week ago

Hi @TimmRuppert , @jdsika

I had to check with the ASAM office first, but we cleared everything and I can now support you on this. At first glance, the proposed solutions look good. I will just have to check a few things (e.g. if the doxygen job was used for anything else that would still be relevant), but I am quite positive that there should be no hidden hiccups.

I will check everything and get back to you here with my insights.

philipwindecker commented 1 week ago

Ok, I went through the repositories and tried to check everything by eye. I would say that the suggested approach works, some small additions might be useful though.

List of correct links

Type Latest v3.5.0
Specification https://opensimulationinterface.github.io/osi-antora-generator/asamosi/latest/specification/index.html https://opensimulationinterface.github.io/osi-antora-generator/asamosi/V3.5.0/specification/index.html
Doxygen https://opensimulationinterface.github.io/osi-antora-generator/asamosi/latest/gen/index.html https://opensimulationinterface.github.io/osi-antora-generator/asamosi/V3.5.0/gen/index.html
OSMP https://opensimulationinterface.github.io/osi-antora-generator/asamosi/latest/sensor-model/osi-sensor-model-packaging_spec.html https://opensimulationinterface.github.io/osi-antora-generator/asamosi/V3.5.0/sensor-model/osi-sensor-model-packaging_spec.html
DCO https://opensimulationinterface.github.io/osi-antora-generator/asamosi/latest/specification/contributing/dco.html https://opensimulationinterface.github.io/osi-antora-generator/asamosi/V3.5.0/specification/contributing/dco.html

Redirect page content

<!DOCTYPE html>
<meta charset="utf-8">
<meta http-equiv="refresh" content="0; url=https://opensimulationinterface.github.io/osi-antora-generator/asamosi/latest/specification/index.html">
<meta name="robots" content="noindex">
<title>Redirect Notice</title>
<h1>Redirect Notice</h1>
<p>The page you requested has been relocated to <a href="https://opensimulationinterface.github.io/osi-antora-generator/asamosi/latest/specification/index.html">https://opensimulationinterface.github.io/osi-antora-generator/asamosi/latest/specification/index.html</a>.</p>

open-simulation-interface

osi-documentation

philipwindecker commented 6 days ago

Side notes:

GitHub Pages is quite simple for us. We just have a specific action run that pushes content to a given branch ("gh-pages") and then host that based on what it finds. This, it may work if we just replace the index.html`s content in each of these branches (and remove the rest as it is not needed any longer). If this does not work, we could run a simple once-and-done pipeline that does this with an action (basically the same as the current job, just using different input).

Regarding the extensions: That topic is a bit more complicated. The repository with them is available on ASAM GitLab, so if you have access there, you can also get to that repository (the url can be found in the submodules of the generator). However, it is a lot of code to be digested, so the interesting information here should be that the doxygen extension I wrote basically runs doxygen for each version of the specification where the required configuration is found (currently, everything from 3.5.0 forward). This generated doxygen output is then converted into a format that Antora (and, by extension, Asciidoctor) understands and added as virtual files similar to those that Antora creates in the background when generating the Antora output. The original doxygen job is therefore not needed for any Antora output. One major reason for this approach was that the content of each version may differ from the previous or the next, meaning that also the doxygen output would be different. The original approach with a dedicated doxygen job, however, only creates the output for the latest version and would thus not allow access to previous definitions if needed. Since Antora already works with versions, we decided to create the Doxygen extension that runs for each version separately.

In case there is more interest in this, I could also offer a deep dive into both the (release) pipelines and the Antora extensions. Just let me know. :)

philipwindecker commented 6 days ago

@TimmRuppert would you like to apply these changes yourself or would you rather have me do them? In any case, I can offer to review your changes (or involve you in the review).

I am, however, a bit tight on time this week, so I may only get to it next week or so.

P.S.: I also noted that both release candidates are still included and, by naming convention from Antora, the rc-2 is considered "latest" (not the released version).

Related info on this: https://docs.antora.org/antora/latest/how-component-versions-are-sorted/#version-schemes

jdsika commented 6 days ago

I would be happy if you could do it @philipwindecker next week, thank you very much!

philipwindecker commented 6 days ago

Alright, will do. I'll let you know when I have everything prepared and ready for review.

TimmRuppert commented 6 days ago

Thank you very much for the side not and the summery!

@TimmRuppert would you like to apply these changes yourself or would you rather have me do them? In any case, I can offer to review your changes (or involve you in the review).

I would be happy if you could do it @philipwindecker next week, thank you very much!

Even though @jdsika has already asked you to do it, I would also have preferred if you had done it: You are clearly the expert, and you found even more places that need changes.

P.S.: I also noted that both release candidates are still included and, by naming convention from Antora, the rc-2 is considered "latest" (not the released version).

This happens to us all the time and it is a little bit annoying, is there any chance we can address (in a separate issue/PR) as well? Seems like the is a prerelease key but I have basically no idea how Antora works.

philipwindecker commented 6 days ago

Yes, you can explicitely exclude certain versions from the build (in the site.yml in the generator). That way, the tag can persist without it being included in future builds.

philipwindecker commented 22 hours ago

I integrated all suggested changes above and linked to the relevant issues, where needed. Please review and provide feedback.