Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some Tumblr blogs are falsely reported as offline #206

Closed
thomas694 opened this issue Jan 16, 2022 · 11 comments · Fixed by #213
Closed

Some Tumblr blogs are falsely reported as offline #206

thomas694 opened this issue Jan 16, 2022 · 11 comments · Fixed by #213
Assignees
Labels
beginner Estimated level of difficulty bug Something isn't working help wanted Extra attention is needed

Comments

@thomas694
Copy link
Contributor

Describe the bug
When a blog changes its state to hidden (dashboard blog), Tumblthree shows this blog as offline, even it can still be viewed in the web browser.

To Reproduce
Steps to reproduce the behavior:

  1. select a offline blog that is now a hidden blog
  2. click 'check blog online status' in the context menu
  3. after the check the blog still shows as offline

Expected behavior
At least when doing a manual "check online status", it should be recognized that the blog is still available, but now needs to be accessed as hidden blog through the dashboard.
Tumblthree should make a double check, if necessary, and automatically change the blog type to hidden blog, if possible.

Screenshots

Desktop (please complete the following information):

  • TumblThree version: 2.4.8.243
  • OS: Windows 10 Pro
  • Browser: Chrome
  • Version: current

Additional context
At the moment a workaround is to go to the blog settings and change the crawler type to "SVC" for blogs that changed their state to hidden.

@thomas694 thomas694 added beginner Estimated level of difficulty bug Something isn't working help wanted Extra attention is needed labels Jan 16, 2022
@kulesy
Copy link
Contributor

kulesy commented Feb 7, 2022

What makes a tumblr blog become offline?

@thomas694
Copy link
Contributor Author

A blog is marked offline in the app, when the API returns a http error on the request (e.g. for a list of posts).
That can be for example when the blog is no longer existing or in the case here changed to hidden by the blog owner.

@kulesy
Copy link
Contributor

kulesy commented Feb 8, 2022

Okay, so when a previously online blog which has the Tumblrblog class becomes hidden I assume you want to change the class to TumblrHiddenBlog. However (if I'm wrong please correct), the process to change this classes would be to remove the blog and re-add it manually through the UI (unless there is another way to call the ManagerController methods). As this would then be a manual process on the user's part, would it be sufficient to display an error message as a guide?

@kulesy
Copy link
Contributor

kulesy commented Feb 8, 2022

Never mind it seems all you need to do is change the blog type to tmblrpriv, is this correct?

@thomas694
Copy link
Contributor Author

Of course, you can call the ManagerController methods or change a method if needed.
Yes, if this condition is detected, the blog type needs to be changed. The user can already change the blog's (crawler) type in the blog settings. So, I think, it should be possible to do it programmatically, at least for the manual online check through the context menu in the blog manager list.

@kulesy
Copy link
Contributor

kulesy commented Feb 8, 2022

I've got the status check to recognise and update the blog as hidden and through changing the type to hidden, it should automatically change the crawler type as well. I also found that making a blog unhidden on tumblr also needs to be updated through the status check. However there is a 30-60 second delay for the tumblrBlogDetector to recognize the post being switched to and from hidden and in this time the blog will be shown as offline (not sure how this can be fixed).

@thomas694
Copy link
Contributor Author

As the hidden/SVC crawler also can download normal blogs, it maybe wouldn't be necessary to change it back, but how ever.
TumblrBlogDetector is mainly a helper class, so I'm not totally sure what you mean by recognize it. Do you mean this 30-60 secs is a timeout it is waiting for?

@kulesy
Copy link
Contributor

kulesy commented Feb 8, 2022

I'm using the IsHiddenTumblrBlogAsync method in the TumblrBlogDetector class to recognize the selected blog as hidden. The 30-60 secs delay is how long it takes - I believe - tumblr to update the URL of the blog with the parameters of a hidden blog. I will make it so the unhidden blog stays hidden in the manager list.

@thomas694
Copy link
Contributor Author

Oh, got it, sounds good. I think this delay is only a problem during your tests, because you are waiting for it, isn't it? The normal user comes back after a longer period of time and wants to download the blog again. Otherwise a different approach would be necessary.

@kulesy
Copy link
Contributor

kulesy commented Feb 9, 2022

Yeah its doesn't seem like it would be a problem as long as the user doesn't check the status within a minute of the blog being switched to hidden. If this is fine with you I can submit a PR.

@thomas694
Copy link
Contributor Author

Yes, this should be ok. You can create a PR.

kulesy added a commit to kulesy/TumblThree that referenced this issue Feb 9, 2022
kulesy added a commit to kulesy/TumblThree that referenced this issue Feb 10, 2022
thomas694 pushed a commit that referenced this issue Feb 12, 2022
)

* Update hidden blog type through controllers
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
beginner Estimated level of difficulty bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants