sleep 1s to avoid too many requests - #23
Open
RuixiangJiang wants to merge 1 commit into
Open
Conversation
RuixiangJiang
commented
Sep 7, 2024
- choose each class in the list only once to make the following classes have more opportunities to be chosen
- sleep one second between two threads
- remove some description messages when running the program
GhostFrankWu
requested changes
Sep 8, 2024
GhostFrankWu
left a comment
Owner
There was a problem hiding this comment.
意见
由于Tis开放时间不太稳定(有概率在12:57-13:01期间开放而非13:00),所以先前没频率限制时候手动操作还是必要的
但我也不确定现在哪种策略更好点,所以我的想法是都加上,然后给个开关
修改的必要性
如果脚本不等的话,你的是对同一课程连续发三条,只有第一条有效
其实可以多开,就是一直改class.txt然后运行多个脚本
其他事项
- 请不要在最终的代码中包含被注释的测试代码
- 请保留
verify=False以应对Tis证书不完整的情况 - 我更希望保留输入密码不显示的设定
My comment
Since the opening time of Tis is not stable (there is a chance that it will be open between 12:57-13:01 instead of 13:00), manual operation was still necessary when there was no frequency limit before.
But I am not sure which strategy is better now, so my idea is to add both and then give a switch choice to user.
Necessity
If the scripts do not sleep and wait, it'll send three consecutive messages for the same course, and only the first one is valid.
In fact, you can run scirpt multiple times by keep changing class.txt and only leave one class at the same time
Other Suggestions:
- Please do not include the commented test code in the final code
- Please keep
verify=Falseto handle the case where the Tis certificate is incomplete - I prefer not to display the password when entering it
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.