All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] doc/conf.py: add missing import sys
@ 2020-11-17 21:22 Mert Kirpici
  2020-11-19 18:02 ` [bitbake-devel] " Nicolas Dechesne
  0 siblings, 1 reply; 2+ messages in thread
From: Mert Kirpici @ 2020-11-17 21:22 UTC (permalink / raw)
  To: bitbake-devel; +Cc: Mert Kirpici

From: Mert Kirpici <mert.kirpici@siemens.com>

Due to the calls to sys.stderr.write() and sys.exit() in exception
handling in case of sphinx_rtd_theme not being installed, the
following exception is raised by Python due to the fact that sys
module not being imported.

---

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/sphinx/config.py", line 368, in eval_config_file
    execfile_(filename, namespace)
  File "/usr/lib/python3/dist-packages/sphinx/util/pycompat.py", line 150, in execfile_
    exec_(code, _globals)
  File "/work/doc/conf.py", line 80, in <module>
    sys.stderr.write("The Sphinx sphinx_rtd_theme HTML theme was not found.\
NameError: name 'sys' is not defined

---

Signed-off-by: Mert Kirpici <mert.kirpici@siemens.com>
---
 doc/conf.py | 1 +
 1 file changed, 1 insertion(+)

diff --git a/doc/conf.py b/doc/conf.py
index 354dff36..fc2ee081 100644
--- a/doc/conf.py
+++ b/doc/conf.py
@@ -14,6 +14,7 @@
 # import sys
 # sys.path.insert(0, os.path.abspath('.'))
 
+import sys
 import datetime
 
 current_version = "dev"
-- 
2.29.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [bitbake-devel] [PATCH] doc/conf.py: add missing import sys
  2020-11-17 21:22 [PATCH] doc/conf.py: add missing import sys Mert Kirpici
@ 2020-11-19 18:02 ` Nicolas Dechesne
  0 siblings, 0 replies; 2+ messages in thread
From: Nicolas Dechesne @ 2020-11-19 18:02 UTC (permalink / raw)
  To: Mert Kirpici; +Cc: bitbake-devel, Mert Kirpici

On Tue, Nov 17, 2020 at 10:23 PM Mert Kirpici <smertk@gmail.com> wrote:
>
> From: Mert Kirpici <mert.kirpici@siemens.com>
>
> Due to the calls to sys.stderr.write() and sys.exit() in exception
> handling in case of sphinx_rtd_theme not being installed, the
> following exception is raised by Python due to the fact that sys
> module not being imported.
>
> ---
>
> During handling of the above exception, another exception occurred:
>
> Traceback (most recent call last):
>   File "/usr/lib/python3/dist-packages/sphinx/config.py", line 368, in eval_config_file
>     execfile_(filename, namespace)
>   File "/usr/lib/python3/dist-packages/sphinx/util/pycompat.py", line 150, in execfile_
>     exec_(code, _globals)
>   File "/work/doc/conf.py", line 80, in <module>
>     sys.stderr.write("The Sphinx sphinx_rtd_theme HTML theme was not found.\
> NameError: name 'sys' is not defined
>
> ---
>
> Signed-off-by: Mert Kirpici <mert.kirpici@siemens.com>

Nice catch, I could reproduce the issue, and this is a right fix!

Reviewed-by: Nicolas Dechesne <nicolas.dechesne@linaro.org>

> ---
>  doc/conf.py | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/doc/conf.py b/doc/conf.py
> index 354dff36..fc2ee081 100644
> --- a/doc/conf.py
> +++ b/doc/conf.py
> @@ -14,6 +14,7 @@
>  # import sys
>  # sys.path.insert(0, os.path.abspath('.'))
>
> +import sys
>  import datetime
>
>  current_version = "dev"
> --
> 2.29.2
>
>
> 
>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-11-19 18:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-17 21:22 [PATCH] doc/conf.py: add missing import sys Mert Kirpici
2020-11-19 18:02 ` [bitbake-devel] " Nicolas Dechesne

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.