PyOWM v2 to v3 migration guide


You have PyOWM v2.x installed and your code uses it.


You want to swap in PyOWM v3.x and swap out PyOWM v2.x


  1. Is your code running on Python < 3 ? If so, migrate your code to Python 3 and then resume from here
  2. If you package and distribute PyOWM as a dependency of your code using please correct the PyOWM version: this includes patching, Pipfile, requirements.txt or any other mechanism you use to declare the dependency. Example for requirements.txt: from


  1. If you have tests for your code then you have a very good way to check that the PyOWM version update won’t break your code. If you don’t, then you might be at risk - this is a good time to start testing your stuff :-)
  2. Check all lines in your code that invoke PyOWM by reading and comparing the v2 and the v3 documentation - and patch the calls wherever they broke!
  3. Dry run your code