Search code examples
pythonpython-3.xmkdocs

MKDocs Can't make document


I will use MKDocs to make the document but it says:

Error: MkDocs encountered an error parsing the configuration file: mapping values are not allowed here
  in "/home/phao/桌面/python/Bayesian/mkdocs.yml", line 4, column 15

I had pushed the contents in github commit e8221fc1f0402834b6db92280e67e9fcac4a2b10 in Commits on Oct 23, 2022. How can I finish it? Why it failed?

P.S. This is /home/phao/桌面/python/Bayesian/mkdocs.yml:

site_name: Bayesian v0.1 Documentation
plugins:
  - mkdocstrings
      handlers:
          python:
            setup_commands:
              - import sys
              - sys.path.insert(0, "..")

And this is the issue in Github.


Solution

  • This is yaml format error. Correct format like this:

    site_name: Bayesian v0.1 Documentation
    plugins:
      - mkdocstrings:
          handlers:
              python:
                setup_commands:
                  - import sys
                  - sys.path.insert(0, "..")