Closed ROBINRUGAN closed 6 months ago
I committed this change here: https://github.com/p4lang/tutorials/commit/6486f18dc151db07fa92f46849d0c568b6cd419d
My apologies if you would have preferred to have the commit in the commit log with your name on it. Earlier I saw that it was a simple change, and that. you had not yet signed the CLA, so I created a separate PR myself to make the change.
However, after submitting the PR, I went ahead and signed the CLA, and passed the automated code review by GitHub. I felt regretful upon receiving this news, but it's okay. I am happy to contribute to the official P4 tutorial and help more P4 beginners. Thank you for your review and correction. @jafingerhut
When I was implementing the “calc” P4 experiment, I correctly wrote the calc.p4 code. After entering the command
make
, the code was successfully compiled and the mininet CLI appeared. However, when I entered the commandh1 python calc.py
, it didn't work. It prompted thatbash: python: command not found
. I used the recommended image with the environment already configured by your official team. At first, I thought there might be a problem with the python environment. After various debugging and searching, I found that the version of python is 3.8.5, which means there is no problem with the Python environment. I also found the final solution: the command should be changed toh1 python3 calc.py
. This way, my calculator program could run successfully. It seems like a simple problem, but for beginners like me in P4 and those unfamiliar with Python, it could cause a lot of confusion. Solving this problem can help more beginners focus more on the P4 program itself.