Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[readme] Should Python 3.10 be mentioned as prerequisite #2397

Closed
kshitij12345 opened this issue Oct 27, 2023 · 4 comments · Fixed by #2402
Closed

[readme] Should Python 3.10 be mentioned as prerequisite #2397

kshitij12345 opened this issue Oct 27, 2023 · 4 comments · Fixed by #2402

Comments

@kshitij12345
Copy link

The readme mentions Python 3.10 as a prerequisite but it gets installed whenever the lp environment is created with conda (as it is mentioned in the environment_{unix|windows}.yaml).

This may confuse new developers to the project (like me) to have a native Python installation even though it is not required.

I think conda should be the only prerequisite.

Thanks!

Ref: https://github.com/lcompilers/lpython#step-0-prerequisites

@certik
Copy link
Contributor

certik commented Oct 27, 2023

@kshitij12345 CPython is not needed for end users of LPython, unless they want to call into CPython.

For LPython developers however, we need CPython for the following reasons:

  • We have some Python scripts to generate C++ code for AST/ASR
  • Our test runners (both tests in tests and integration_tests) are implemented in Python
  • We test every test in integration_tests in CPython, to ensure it is compatible with it

So you need CPython for developing LPython.

@kshitij12345
Copy link
Author

Right, I understand that we need CPython for development.

What I meant was while reading the below instruction
image

I installed Python 3.10 natively on my system but then in the step below, we do install the required Python 3.10 using conda for the development environment. So essentially the manual installation I did was not required.

conda env create -f environment_unix.yml
conda activate lp

I guess, this may not be a common issue and maybe I followed the instructions incorrectly 😅 , but the instruction seemed a bit confusing to me.

Thanks!

@certik
Copy link
Contributor

certik commented Oct 27, 2023

Ah I see! We should clarify this. Do you mind submitting a PR fixing this please? That would be very helpful.

@kshitij12345
Copy link
Author

Sure, will send a PR soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants