This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Py_SetPath: Path components separated by colons
Type: behavior Stage: resolved
Components: Documentation Versions: Python 3.2, Python 3.3, Python 3.4, Python 3.5
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: docs@python Nosy List: docs@python, eryksun, fwalch, python-dev
Priority: normal Keywords:

Created on 2014-06-07 15:18 by fwalch, last changed 2022-04-11 14:58 by admin. This issue is now closed.

Messages (3)
msg219944 - (view) Author: Florian Walch (fwalch) Date: 2014-06-07 15:18
The documentation for Py_SetPath [1] states:

> The path components should be separated by semicolons.

I believe this should not say "semicolons", but "colons"; the default path as output by Py_GetPath is separated by colons.

[1] https://docs.python.org/3/c-api/init.html#c.Py_SetPath
msg219953 - (view) Author: Eryk Sun (eryksun) * (Python triager) Date: 2014-06-07 16:47
A Windows path uses ":" after the drive letter, e.g. "C:\\Windows", so the delimiter is a semicolon on Windows. Other platforms use a colon.

CPython uses DELIM, which is defined in osdefs.h. This header isn't included by Python.h.

http://hg.python.org/cpython/file/c0e311e010fc/Include/osdefs.h
msg229086 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2014-10-11 13:08
New changeset 2d150c01bf7e by Georg Brandl in branch '3.4':
Closes #21687: delimiter in Py_SetPath is platform dependent
https://hg.python.org/cpython/rev/2d150c01bf7e
History
Date User Action Args
2022-04-11 14:58:04adminsetgithub: 65886
2014-10-11 13:08:29python-devsetstatus: open -> closed

nosy: + python-dev
messages: + msg229086

resolution: fixed
stage: resolved
2014-06-07 16:47:51eryksunsetnosy: + eryksun
messages: + msg219953
2014-06-07 15:18:12fwalchcreate