sopel气象模块的工作再实现

sopel-modules.weather的Python项目详细描述


PyPI versionBuild StatusCoverage Status

sopel天气

sopel weather是sopel的天气查找模块。

由于雅虎在2019年1月3日否决了他们的天气api,因此有必要重新实现天气模块

用法

# Allows the user to set their current location
.setlocation london # Sets location by city name
.setlocation w2643743 # Sets location by WOEID (We are prepending w in front of WOEIDs because they collide with zips)
.setlocation 98101 # Sets location by zip code

# Gets a 24h forecast
.forecast # Only works if setlocation has been previously run
.forecast seattle, us
.forecast london

# Gets the current weather
.weather # Only works if setlocation has been previously run
.weather seattle, us
.weather london

要求

API键

https://openweathermap.org/api

python需求

requests
sopel

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
tomcat java。lang.NoClassDefFoundError:无法初始化类com。太阳代理$Proxy8   java Spring引导CommandLineRunner异常处理建议   java文件。getParentFile()。mkdirs();在osx中创建重复文件夹   java Lucene IndexWriter线程安全   HashMapJava加速了哈希映射的创建   java执行器服务从Servlet线程启动   guava在Java中创建异构列表   泛型Java将比较器传递给构造函数   在Java中生成公钥和私钥的加密会生成类似的所有密钥,包括私钥和公钥   java ResourceLocation抛出FileNotFoundException Minecraft Forge 1.12.2   java使用动态键序列化JSON响应   在空映射上调用方法时发生java NullPointerException   java在Selenium中选择不同行中的按钮   优化在Java中,降低时间和空间复杂性的最佳方法是什么?   java表。setValueAt(…)不为JTable工作   javajsonrpc与JSON   ant从java编译中排除类的特定方法