def gen_hot_url(hot_index, page=1):
        """拼接 首页热门文章 URL

        Parameters
        ----------
        hot_index : WechatSogouConst.hot_index
            首页热门文章的分类（常量）：WechatSogouConst.hot_index.xxx
        page : int
            页数

        Returns
        -------
        str
            热门文章分类的url
        """

        assert hasattr(WechatSogouConst.hot_index, hot_index)
        assert isinstance(page, int) and page > 0

        index_urls = {
            WechatSogouConst.hot_index.hot: 0,  # 热门
            WechatSogouConst.hot_index.gaoxiao: 1,  # 搞笑
            WechatSogouConst.hot_index.health: 2,  # 养生
            WechatSogouConst.hot_index.sifanghua: 3,  # 私房话
            WechatSogouConst.hot_index.gossip: 4,  # 八卦
            WechatSogouConst.hot_index.technology: 5,  # 科技
            WechatSogouConst.hot_index.finance: 6,  # 财经
            WechatSogouConst.hot_index.car: 7,  # 汽车
            WechatSogouConst.hot_index.life: 8,  # 生活
            WechatSogouConst.hot_index.fashion: 9,  # 时尚
            WechatSogouConst.hot_index.mummy: 10,  # 辣妈 / 育儿
            WechatSogouConst.hot_index.travel: 11,  # 旅行
            WechatSogouConst.hot_index.job: 12,  # 职场
            WechatSogouConst.hot_index.food: 13,  # 美食
            WechatSogouConst.hot_index.history: 14,  # 历史
            WechatSogouConst.hot_index.study: 15,  # 学霸 / 教育
            WechatSogouConst.hot_index.constellation: 16,  # 星座
            WechatSogouConst.hot_index.sport: 17,  # 体育
            WechatSogouConst.hot_index.military: 18,  # 军事
            WechatSogouConst.hot_index.game: 19,  # 游戏
            WechatSogouConst.hot_index.pet: 20,  # 萌宠

        }
        return 'http://weixin.sogou.com/wapindex/wap/0612/wap_{}/{}.html'.format(index_urls[hot_index], page - 1)
def gen_hot_url ( hot_index , page = 1 ) : assert hasattr ( WechatSogouConst . hot_index , hot_index ) assert isinstance ( page , int ) and page > 0 index_urls = { WechatSogouConst . hot_index . hot : 0 , WechatSogouConst . hot_index . gaoxiao : 1 , WechatSogouConst . hot_index . health : 2 , WechatSogouConst . hot_index . sifanghua : 3 , WechatSogouConst . hot_index . gossip : 4 , WechatSogouConst . hot_index . technology : 5 , WechatSogouConst . hot_index . finance : 6 , WechatSogouConst . hot_index . car : 7 , WechatSogouConst . hot_index . life : 8 , WechatSogouConst . hot_index . fashion : 9 , WechatSogouConst . hot_index . mummy : 10 , WechatSogouConst . hot_index . travel : 11 , WechatSogouConst . hot_index . job : 12 , WechatSogouConst . hot_index . food : 13 , WechatSogouConst . hot_index . history : 14 , WechatSogouConst . hot_index . study : 15 , WechatSogouConst . hot_index . constellation : 16 , WechatSogouConst . hot_index . sport : 17 , WechatSogouConst . hot_index . military : 18 , WechatSogouConst . hot_index . game : 19 , WechatSogouConst . hot_index . pet : 20 , } return 'http://weixin.sogou.com/wapindex/wap/0612/wap_{}/{}.html' . format ( index_urls [ hot_index ] , page - 1 )
拼接 首页热门文章 URL

        Parameters
        ----------
        hot_index : WechatSogouConst.hot_index
            首页热门文章的分类（常量）：WechatSogouConst.hot_index.xxx
        page : int
            页数

        Returns
        -------
        str
            热门文章分类的url