influxdata / Litmus

testing framework
0 stars 0 forks source link

Need to schedule an update of python 2.7. Its supported end on January 1, 2020. #160

Open gshif opened 5 years ago

gshif commented 5 years ago
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7
dangilkerson commented 4 years ago

Starting the work to python 3.

Branch https://github.com/influxdata/idpe/tree/test/litmus-python-3

Need to update dependencies and get all tests passing

gshif commented 4 years ago

The latest stable version of python (as of today) is 3.8.2, the version 3.9 is in dev mode. Link to the 3.8.2 python documentation: https://docs.python.org/3/whatsnew/index.html#whatsnew-index Links defining a few key differences between python 3.8.x and 2.37: https://jaxenter.com/differences-python-2-3-148432.html https://www.guru99.com/python-2-vs-python-3.html

The latest version of pytest is 5.4.1. I could not find whether pytest 5.4.1 is (not) working with python 3.8.2. I can suggest to take major versions of pytest and python and go with it, i.e. pytest - 5.4.0 and python 3.8.0

gshif commented 4 years ago

Here are a few things to consider.

gshif commented 4 years ago

[ ] cloud environment [ ] oss [ ] local dev

dangilkerson commented 4 years ago

Docker error


INFO     src.cloud.rest_api.smoke.test_smoke:conftest.py:1033 create_org() fixture : cleaning up tasks
INFO     src.cloud.rest_api.smoke.test_smoke:conftest.py:1034 ----------------------------------------
_______________ ERROR at setup of TestSmoke.test_tasks_smoke[-] ________________
Fixture "reset_tasks" called directly. Fixtures are not meant to be called directly,
but are created automatically when test functions request them as parameters.
See https://docs.pytest.org/en/latest/fixture.html for more information about fixtures, and
https://docs.pytest.org/en/latest/deprecations.html#calling-fixtures-directly about how to update your code.
-------------------- generated xml file: /Litmus/result.xml --------------------
--------------- generated html file: file:///Litmus/report.html ----------------
======================== 2 warnings, 2 errors in 0.10s =========================
SAVING THE RESULTS OF THE TEST RUN IN INFLUXDB

+ EXIT_STATUS=1
+ rm -rf result/config
COPYING report.html TO result DIRECTORY
+ '[' -f report.html ']'
+ echo 'COPYING report.html TO result DIRECTORY'
+ cp report.html result
+ '[' -f result.xml ']'
+ echo 'COPYING result.xml TO result DIRECTORY'
+ cp result.xml result
COPYING result.xml TO result DIRECTORY
+ '[' -d assets ']'
+ echo 'COPYING assets DIRECTORY TO result DIRECTORY'
+ cp -r assets result
COPYING assets DIRECTORY TO result DIRECTORY
+ chown -R 10000:10000 result
+ chmod -R 777 result
+ '[' 1 -eq 0 ']'
+ PASSED=false
+ false
dangilkerson commented 4 years ago

Add pytest source locally to litmus

stephanie-engel commented 4 years ago

Paired with Gershon and Dan. Fixed encoding and direct fixture calls. Ran test_smoke.py and test_gateway_get_bucket.py and they passed!