[GH-ISSUE #913] make docs fails with version too low #642

Closed
opened 2026-05-07 00:26:12 +02:00 by BreizhHardware · 1 comment

Originally created by @Comradin on GitHub (Oct 11, 2023).
Original GitHub issue: https://github.com/binwiederhier/ntfy/issues/913

🐞 Describe the bug
Hello,

I wanted to build the docs and ran into an issue with the make docs command or more precisely the docs-build step.

An error occurs during the version check:

(venv) marcus@NanElmoth ntfy % make docs-build
  File "<stdin>", line 1
    -e import sys\nif sys.version_info < (3,8):\n exit(1)
       ^^^^^^
SyntaxError: invalid syntax
ERROR: Python version too low. mkdocs-material needs >= 3.8
make: *** [docs-build] Error 1

As I am on macOS Sonoma already I guess this could be due to an incompatibility with the tool chain there.

Just did a build on a Raspberry Pi with Raspian installed and it worked.

💻 Components impacted

The build process for the docs on a current version of macOS

💡 Screenshots and/or logs

See the actual error message above, interestingly I checked the version of make on my Mac and on my Pi and
the Mac version is quite dated compared to the otherwise more dated packages with my Raspberry Pi.

# macOS Sonoma
marcus@NanElmoth ntfy % make -v
GNU Make 3.81
Copyright (C) 2006  Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.

This program built for i386-apple-darwin11.3.0
(venv) marcus@pione:~/git/ntfy $ make -v
GNU Make 4.3
Built for arm-unknown-linux-gnueabihf
Copyright (C) 1988-2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Okay, checked the versions, that isn't the real problem, as I installed a current release of (g)make from homebrew and it
fails with the same SyntaxError in the echo -e block.

(venv) marcus@NanElmoth ntfy % gmake docs-build
  File "<stdin>", line 1
    -e import sys\nif sys.version_info < (3,8):\n exit(1)
       ^^^^^^
SyntaxError: invalid syntax
ERROR: Python version too low. mkdocs-material needs >= 3.8
gmake: *** [Makefile:114: docs-build] Error 1

Whereas the actual version check runs just fine in my terminal.

(venv) marcus@NanElmoth ntfy % echo -e "import sys\nif sys.version_info < (3,8):\n exit(1)" | python3
(venv) marcus@NanElmoth ntfy % echo $?
0

And the actual build command for the docs works fine aswell:

(venv) marcus@NanElmoth ntfy % mkdocs build
INFO    -  Cleaning site directory
INFO    -  Building documentation to directory: /Users/marcus/git/Comradin/ntfy/server/docs
INFO    -  Doc file 'develop.md' contains an unrecognized relative link 'Add Firebase to your Apple project', it was left as is.
INFO    -  Doc file 'emojis.md' contains an unrecognized relative link '../publish/#tags-emojis', it was left as is. Did you mean 'publish.md#tags-emojis'?
INFO    -  Doc file 'emojis.md' contains an unrecognized relative link '../publish/#tags-emojis', it was left as is. Did you mean 'publish.md#tags-emojis'?
INFO    -  Doc file 'releases.md' contains an unrecognized relative link 'ntfy.sh/docs/publish/#e-mail-publishing', it was left as is.
INFO    -  Documentation built in 1.50 seconds

🔮 Additional context

Latest release of macOS Sonoma.
Go version 1.21.3
Python 3.11
make versions listed above

Originally created by @Comradin on GitHub (Oct 11, 2023). Original GitHub issue: https://github.com/binwiederhier/ntfy/issues/913 :lady_beetle: **Describe the bug** Hello, I wanted to build the docs and ran into an issue with the `make docs` command or more precisely the docs-build step. An error occurs during the version check: ```sh (venv) marcus@NanElmoth ntfy % make docs-build File "<stdin>", line 1 -e import sys\nif sys.version_info < (3,8):\n exit(1) ^^^^^^ SyntaxError: invalid syntax ERROR: Python version too low. mkdocs-material needs >= 3.8 make: *** [docs-build] Error 1 ``` As I am on macOS Sonoma already I guess this could be due to an incompatibility with the tool chain there. Just did a build on a Raspberry Pi with Raspian installed and it worked. :computer: **Components impacted** The build process for the docs on a current version of macOS :bulb: **Screenshots and/or logs** See the actual error message above, interestingly I checked the version of make on my Mac and on my Pi and the Mac version is quite dated compared to the otherwise more dated packages with my Raspberry Pi. ```sh # macOS Sonoma marcus@NanElmoth ntfy % make -v GNU Make 3.81 Copyright (C) 2006 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. This program built for i386-apple-darwin11.3.0 ``` ```sh (venv) marcus@pione:~/git/ntfy $ make -v GNU Make 4.3 Built for arm-unknown-linux-gnueabihf Copyright (C) 1988-2020 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. ``` Okay, checked the versions, that isn't the real problem, as I installed a current release of (g)make from homebrew and it fails with the same SyntaxError in the `echo -e` block. ```sh (venv) marcus@NanElmoth ntfy % gmake docs-build File "<stdin>", line 1 -e import sys\nif sys.version_info < (3,8):\n exit(1) ^^^^^^ SyntaxError: invalid syntax ERROR: Python version too low. mkdocs-material needs >= 3.8 gmake: *** [Makefile:114: docs-build] Error 1 ``` Whereas the actual version check runs just fine in my terminal. ```sh (venv) marcus@NanElmoth ntfy % echo -e "import sys\nif sys.version_info < (3,8):\n exit(1)" | python3 (venv) marcus@NanElmoth ntfy % echo $? 0 ``` And the actual build command for the docs works fine aswell: ```sh (venv) marcus@NanElmoth ntfy % mkdocs build INFO - Cleaning site directory INFO - Building documentation to directory: /Users/marcus/git/Comradin/ntfy/server/docs INFO - Doc file 'develop.md' contains an unrecognized relative link 'Add Firebase to your Apple project', it was left as is. INFO - Doc file 'emojis.md' contains an unrecognized relative link '../publish/#tags-emojis', it was left as is. Did you mean 'publish.md#tags-emojis'? INFO - Doc file 'emojis.md' contains an unrecognized relative link '../publish/#tags-emojis', it was left as is. Did you mean 'publish.md#tags-emojis'? INFO - Doc file 'releases.md' contains an unrecognized relative link 'ntfy.sh/docs/publish/#e-mail-publishing', it was left as is. INFO - Documentation built in 1.50 seconds ``` :crystal_ball: **Additional context** Latest release of macOS Sonoma. Go version 1.21.3 Python 3.11 make versions listed above
BreizhHardware 2026-05-07 00:26:13 +02:00
  • closed this issue
  • added the
    🪲 bug
    label
Author
Owner

@binwiederhier commented on GitHub (Nov 6, 2023):

Since everyone should now have Python 3.8+, I removed the version check entirely now: github.com/binwiederhier/ntfy@abe7275f0c

That said, I do not officially suppose building the ntfy server (or the docs for that matter) on macOS. The build targets are just there for devs to be able to work on the server if they like to.

Let me know if there are other issues.

<!-- gh-comment-id:1794559167 --> @binwiederhier commented on GitHub (Nov 6, 2023): Since everyone should now have Python 3.8+, I removed the version check entirely now: https://github.com/binwiederhier/ntfy/commit/abe7275f0cfceecb7e3027f02c47f3823291cd50 That said, I do not officially suppose building the ntfy server (or the docs for that matter) on macOS. The build targets are just there for devs to be able to work on the server if they like to. Let me know if there are other issues.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/ntfy#642
No description provided.