| 145 | return seconds |
| 146 | |
| 147 | def check_submit(self, div): |
| 148 | remaining = f"/html/body/div[{div}]/div/div/h4" |
| 149 | |
| 150 | try: |
| 151 | element = self.driver.find_element("xpath", remaining) |
| 152 | except: |
| 153 | return None, None |
| 154 | |
| 155 | if "READY" in element.text: |
| 156 | return True, True |
| 157 | |
| 158 | if "seconds for your next submit" in element.text: |
| 159 | output = element.text.split("Please wait ")[1].split(" for")[0] |
| 160 | minutes = element.text.split("Please wait ")[1].split(" ")[0] |
| 161 | seconds = element.text.split("(s) ")[1].split(" ")[0] |
| 162 | sleep_duration = self.convert(minutes, seconds) |
| 163 | |
| 164 | return sleep_duration, output |
| 165 | |
| 166 | return element.text, None |
| 167 | |
| 168 | def check_status(self): |
| 169 | statuses = {} |