IronLanguages / IronLanguages/ironpython3

PYTHON environment variables are ignored

Open
#1,694 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
2.8k
Forks
316
Avg merge
1d 9h
Merged PRs (30d)
1

Description

Python defines a number of environment variables which we currently ignore. This is a placeholder issue for any tests failing because of this.

My initial thought is that ignoring the environment variables is probably fine when embedding in .NET but that we should probably handle the ones that make sense when running ipy.

We currently handle some of the variables with a prefix "IRON" (e.g. IRONPYTHONPATH) where it makes sense, but it's probably not necessary to have a prefix all the time (e.g. PYTHONVERBOSE).

Specific examples which I've run into recently:

  • PYTHONVERBOSE: this is ignored even though it's listed in the cli help (I'll file a PR to remove it from the help).
  • PYTHONUTF8: I'm currently adding utf8 mode (new in 3.7) which can be enabled via a cli argument or an option, however I will probably not add support for the environment variable in the initial implementation.
  • PYTHONIOENCODING: not implemented...

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Python environment-variable documentation linked in the issue and review the existing IRON-prefixed variable handling. Define which variables should apply when running ipy rather than embedding in .NET, then verify that supported variables and CLI help are consistent.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.