Skip to content

无法翻页问题 #22

Closed
Closed

Description

@FelixChen056

章节跳转到该章节的第一页时无法点击;

增加以下下代码,解决;

n = 2
while True:
.....
 # go to next page or chapter ;266行
            try:
                next_btn.click()
            except Exception:
                self.switch_to_context(tag=n + 1)
            n += 1

修改方法

 def switch_to_context(self, tag=2):
        """switch to main body of the book"""
        self.S('button.catalog').click()
        self.S(f'li.chapterItem:nth-child({tag})').click()

Activity

  1. Algebra-FUN commented on Aug 15, 2022

    @Algebra-FUN
    Owner

    首先,感谢你对本项目的支持!
    你可以直接进行pull requests, 从而将你对代码的修改合并入本项目的代码之中.

  2. Repository owner locked and limited conversation to collaborators on Aug 26, 2022
  3. converted this issue into a discussion #25 on Aug 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions