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

Failed to unmarshal response #47

Open
mesb1 opened this issue Jul 17, 2024 · 24 comments
Open

Failed to unmarshal response #47

mesb1 opened this issue Jul 17, 2024 · 24 comments
Labels
bug Something isn't working

Comments

@mesb1
Copy link

mesb1 commented Jul 17, 2024

After some time of success work, it has stopped with:

Failed to unmarshal response

I tried to relogin, nothing helps.
Is there any ideas how to diag?

@devhindo
Copy link
Owner

devhindo commented Jul 18, 2024

Relogging should be done by running x auth -c (clear) to clear the previous configuration and start the auth process again by running x auth and continue from there.

Can you provide the CLI command that caused this error? Was it a normal text tweet? Maybe you exceeded the 280-character limit set by Twitter? I don't have error handling for that yet.

Also, Did you achieve a successful post? Or it still doesn't work on your remote machine.

@mesb1
Copy link
Author

mesb1 commented Jul 18, 2024

It doesn't work for my remote machine after some time.
It was successfully verified, but I when post something now there is a error and nothing posted on my twitter.

@mesb1
Copy link
Author

mesb1 commented Jul 18, 2024

Relogging should be done by running x -c

Not working, only: x auth -c

@mesb1
Copy link
Author

mesb1 commented Jul 18, 2024

Was it a normal text tweet? Maybe you exceeded the 280-character limit set by Twitter?

Yep, just like example, only number added.

@devhindo
Copy link
Owner

Did you move the .tempxcli file to the remote machine home directory? What is the OS used on your remote machine?
Also can you check this and provide the full prompt and the error message

@devhindo devhindo added the bug Something isn't working label Jul 18, 2024
@mesb1
Copy link
Author

mesb1 commented Jul 18, 2024

Did you move the .tempxcli file to the remote machine home directory?

No, i was able to make your app working for some moment.
Not really clear, but i did.
I have shared info of what i have done inside issue #46

@mesb1
Copy link
Author

mesb1 commented Jul 18, 2024

What is the OS used on your remote machine?

Almalinux 8 minimal, no gui, no any additional software, just base system, streamer, my scripts and your app.

@mesb1
Copy link
Author

mesb1 commented Jul 18, 2024

It looks like last time it was working about couple of days, from 14 upto 17 of july.
Posts includes some hashtags, link to streaming project and track author - name.
It is about 200 symbols limits was set since i was using oysttyer.

@mesb1
Copy link
Author

mesb1 commented Jul 18, 2024

For now it is working again, from this point, so let's see how it goes for the next day.

@devhindo
Copy link
Owner

What is the OS used on your remote machine?

Almalinux 8 minimal, no gui, no any additional software, just base system, streamer, my scripts and your app.

That's cool

@mesb1
Copy link
Author

mesb1 commented Jul 18, 2024

If possible there is a sense to add a bit more debug via --debug key as it is not clear on which side it was broken, between app and 3rd party server or 3rdparty server and twitter itself.

@mesb1
Copy link
Author

mesb1 commented Jul 19, 2024

Looks like i have run into problem again.
It happens about 3 hours ago, app stops working again:

./x -t "testing2"
Failed to unmarshal response

Also it looks like this message doesn't have start from new line.
As my automated part looks like after a few fails:
Failed to unmarshal responseFailed to unmarshal responseFailed to unmarshal response
How can i assist with diag?

@mesb1
Copy link
Author

mesb1 commented Jul 19, 2024

And now working again, tried 7 times before with no luck.

@mesb1
Copy link
Author

mesb1 commented Jul 20, 2024

And same happens again.

Do we have some limitations somewhere?

@devhindo
Copy link
Owner

devhindo commented Jul 20, 2024

So the X API is responsible for this. They are blocking the tweet with statusText: 'Too Many Requests' according to their free API plan

image

1500 tweets are allowed under the free plan, distributed in 30 days. That means only 50 tweets per day (and we exceeded this today, So your tweet is not getting posted. Tomorrow the counter will reset to 0 and you will be able to post again).

image

image

The only way to bypass this is to pay for their API pro plans and I don't have the capabilities to this right now as they are ridiculously overpriced.

image

Sadly this sets a limitation for this tool. I was hoping to do further development to allow scheduling future tweets and some other cool ideas but now I might reconsider as their paid plans are ridiculously overpriced.

tho I might find a workaround to post tweets using another way other than their API maybe using their implicit API used in the browser when you're posting from x.com. This could be tough but I might give it a shot anyway

Thank you for informing me ❤️. as this is the first time for this tool to reach that limit lol that's something I'm proud of but also the end of an exciting story.

Thanks.

@mesb1
Copy link
Author

mesb1 commented Jul 20, 2024

Oh, sounds sad.
Did i get it right, this is whole limit across allthe users?

I mean for example my limit was ended, and you also will be limited even if doing only one tweet for a whole day?

@devhindo
Copy link
Owner

Yeah I just tried it and I couldn't post. For all users. Funny.

@devhindo
Copy link
Owner

Your limit didn't end. The app itself is only allowed to post 50 tweets for all its current user. This is what Elon did when he bought Twitter. It was unlimited before.

@mesb1
Copy link
Author

mesb1 commented Jul 20, 2024

Well, i assume there is a sense to add some limitation to the xcli then for local or server side.

We can share 50 tweets across 10 users for 5 posts per day for example.

I will stop my autoposter for tracks and will use this for some specific things like just random posts sometimes from server.

@mesb1
Copy link
Author

mesb1 commented Jul 20, 2024

If you ever decide to move for some paid options for this api we can try to continue streamer data posting.

@mesb1
Copy link
Author

mesb1 commented Jul 20, 2024

By the way, is it possible to create xcli2 xcli3 xcliN app for twitterconnection for making it about 50 requests each?

@mesb1
Copy link
Author

mesb1 commented Jul 22, 2024

I will stop my autoposter for tracks and will use this for some specific things like just random posts sometimes from server.

FYI:
I have reordered my automation scripts to make posting twice less with combination of two tracks data in one post.
So let's see how it goes hope will not hit limits too fast.

Ping me if it is a problem and I will stop it again.

@mesb1
Copy link
Author

mesb1 commented Jul 22, 2024

Just realized I can do even 3 times less.
Will take a look today's evening.

@mesb1
Copy link
Author

mesb1 commented Aug 1, 2024

Found small issue with my script and fixed it.
Posts should be a bit less also.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants