Avatar

ZazzedCoffee

@zazzedcoffee

It's a free fursona
Avatar
reblogged
Avatar
staff

Ok folks. Everybody stay calm. It’s happening. Polls are here.

We’re starting to roll out a polls feature for the post editor across all platforms. Yes, that’s all platforms. That’s iOS, Android, and web. You should all have access to this in the next few days. And what’s more, it’s super easy to use.

  • Simply select the newly added orange poll icon (on web, it appears when you start a new content block in the post editor, on mobile it’s in your toolbar).
  • Write your question.
  • Add at least 2, at most 10 response options for people to choose from. There's a character limit on these, it's about as long as the Puss in Boots option offered above.
  • Set the poll duration to one day or one week. 
  • You can add some commentary to your poll or let it speak for itself. 
  • And, just as with any post, you can toggle who sees the poll by using your community labels. Or you can go wild and blaze it if it meets the content guidelines for blazing. 

Come across a poll in the wild? Have your say! Click on your chosen response. Congratulations, you’ve just voiced an opinion.

And that’s all there is to it. Have fun out there.

Avatar
zazzedcoffee
Avatar

Polls Are Under A Fucking Tack!!

In a recent post I described how I had been making polls (like the 50 year horsie poll). Unfortunately, Tumblr has patched much of the wacky poll behaviour. Those zany polls that double count votes or last 50 years have sadly been zapped. Blasted from existence. Now, not to equate this with the burning of Library of Alexandria or anything but it definitely evokes some strong emotions. You can't even have more than one poll per post anymore. I have updated my tumblr API client python package to adjust to these changes. And remember, even if you're dusted, you may be gone. But out here in the desert your shadow lives on without you.

Avatar

There are polls on 𝐭𝐮𝐦𝐛𝐥𝐫 dot com

Quite a few people have been asking how I have been making these polls. To make them I have been using the Tumblr API. While it is currently undocumented – there is a polls API route that allows you to post and get poll data. While the Tumblr UI puts quite a few restrictions on how many polls can be in a single post and when polls finish, the API currently has no restrictions on this*.

Poll Behaviour

Each poll and poll answer has a uuid tag (a "client_id") that should, ideally, uniquely identify each poll and poll answer. Silly things start to happen when you make a post with two polls with the same client_id, or one poll with several answers with the same client_id. This is how I made this monstrosity.

Polls also have an "expire_after" tag that allows you to set the deadline for the poll. While the UI restricts this to one day or one week, you can put in any time you like for this. This is how I made the 50-year horsie poll and whatever this is.

There are other fun things like being able to put newlines in polls which only display on mobile for some reason.

Can you make polls like this too?

Yes. In fact, from the beginning, I have had a python package that handles posting polls in a public GitHub repository. All you would need to do is register an app on the Tumblr API to get the various necessary authentication tokens and go ham**. Just be warned, I don't intend for this to be a fully-fledged implementation of the Tumblr API, but it gets the job done and will be useful for a few other projects I'm working on. I don't know when they are planning on adding polls to the API docs, or the official Tumblr clients – but I presume that by the time they do, these zany polls will sadly be no more. It seems like the polls API is still being worked on and I can imagine a lot of these issues (I call them features) being fixed. So let's have fun with it while it lasts.

Making your own fun poll

Let's try to recreate this post using my tumblr-dot-com package. Following the example on the readme to set up a tumblr object for your blog with the necessary auth tokens, the post can be constructed as:

# ... snip content = ( Content() .poll( "Wie cool ist das bitte?", [ "Jetzt zocke ich Fortnite", "und trinke Cola", "YIPPEE!" ], option_uuids=[uuid4()] * 3 ) )
res = tumblr.post( content=content, tags=["Yippee!!", "polls"], )
# ... snip

Here, the post content is being constructed with a single poll block – the option_uuids is an optional list parameter that allows you to pass custom uuids for the poll options. Here, the option_uuids is being set to the same uuid repeated three times – which causes votes to be counted for all three options at once.

I hope you enjoy this fun little tumblr client – again, it doesn't implement everything from the tumblr API but should be good enough a least to have a play around. Just a final note – since the polls API is not yet final, I am expecting some of the poll-specific behaviour of this client to break at some point – so be warned.

Notes:

* Beyond the other API post restrictions. And, this is probably going to be patched (see this comment).

** This may make your Tumblr account look suspiciously like one of the pretty lady spam bot accounts causing your account to get blasted like mine did.