GithubHelp home page GithubHelp logo

querkmachine / bat-bot Goto Github PK

View Code? Open in Web Editor NEW
0.0 0.0 0.0 326.61 MB

Mastodon bot that posts bats every now and then

Home Page: https://botsin.space/@batsbatsbats

License: MIT License

JavaScript 100.00%
bats fediverse mastodon mastodon-bot

bat-bot's Introduction

A white, green and black robot bat looks at and waves at you

Hello world, I'm beeps, a Bristol-based frontend developer currently working on the GOV.UK Design System, a product of the Government Digital Service.

Some things to know:

The government's views are not my own, or vice versa.

Follow me on Mastodon

bat-bot's People

Contributors

querkmachine avatar

Watchers

 avatar  avatar

bat-bot's Issues

Image description: Molossus rufus 2.jpg

Which image is this for?

Molossus rufus 2.jpg

What is your suggested image description?

Black mastif bat (Molossus rufus) in profile. It has red fur and a somewhat snub nose. It looks smug as hell for no reason.

Posting to Mastodon occassionally fails, doesn't retry

The "Post to Mastodon" step occassionally returns an error from Mastodon. If this occurs, bat-bot does not retry posting and the action is logged as having been successful, even though it wasn't.

Example: https://github.com/querkmachine/bat-bot/actions/runs/5753213678/job/15595925586

Stack trace:

Unhandled rejection Error: Error: JSON decode error: Mastodon HTTP response body was not valid JSON
    at file:///home/runner/work/bat-bot/bat-bot/index.js:53:11
    at tryCatcher (/home/runner/work/bat-bot/bat-bot/node_modules/bluebird/js/release/util.js:16:23)
    at Promise._settlePromiseFromHandler (/home/runner/work/bat-bot/bat-bot/node_modules/bluebird/js/release/promise.js:547:31)
    at Promise._settlePromise (/home/runner/work/bat-bot/bat-bot/node_modules/bluebird/js/release/promise.js:604:18)
    at Promise._settlePromise0 (/home/runner/work/bat-bot/bat-bot/node_modules/bluebird/js/release/promise.js:649:10)
    at Promise._settlePromises (/home/runner/work/bat-bot/bat-bot/node_modules/bluebird/js/release/promise.js:725:18)
    at _drainQueueStep (/home/runner/work/bat-bot/bat-bot/node_modules/bluebird/js/release/async.js:93:12)
    at _drainQueue (/home/runner/work/bat-bot/bat-bot/node_modules/bluebird/js/release/async.js:86:9)
    at Async._drainQueues (/home/runner/work/bat-bot/bat-bot/node_modules/bluebird/js/release/async.js:102:5)
    at Immediate.Async.drainQueues [as _onImmediate] (/home/runner/work/bat-bot/bat-bot/node_modules/bluebird/js/release/async.js:15:14)
    at processImmediate (internal/timers.js:462:21)

Stuff to do

  • Update the action so that it is considered failing if an unhandled error is received
  • Ideally, have it retry at least once if an error happens (repeated fails might be harder to handle or indicate the instance is down)

Image description: Mosia nigrescens 1.jpg

Which image is this for?

Mosia nigrescens 1.jpg

What is your suggested image description?

A small brown bat shown in the typical head down vertical position. The bat has ridged ears and large expressive eyes.

Image description: Myotis blythii 2.jpg

Which image is this for?

Myotis blythii 2.jpg

What is your suggested image description?

A Lesser mouse-eared bat gliding towards the viewer aganist a black background.

Image description: Pteropus hypomelanus 2.jpg

Which image is this for?

Pteropus hypomelanus 2.jpg

What is your suggested image description?

A flying fox is hanging off a bare tree branch in daylight. The fox is holding onto the branch with both feet, and the claws of his wings, leaving his wings half spread. The bat has a friendly face, a red chest, and it is very evident he is male.

Image description: Nyctimene robinsoni 1.jpg

Which image is this for?

Nyctimene robinsoni 1.jpg

What is your suggested image description?

A brown bat hanging in an inverted position. It has small ears which are edged with patches of white/pale skin. It's wings are also spotted with pale patches.

It has light brown eyes, a shortened muzzle and tubular nostrils which help it to avoid ingesting fruit juices and water through its nose.

Image description: Pteropus poliocephalus 8.jpg

Which image is this for?

Pteropus poliocephalus 8.jpg

What is your suggested image description?

Grey-headed flying fox flying over water with its legs touching the surface. Droplets are flying behind.

Image description: Scotorepens greyii 1.jpg

Which image is this for?

Scotorepens greyii 1.jpg

What is your suggested image description?

A pale, furry, silvery-winged little bat in flight against a solid black background.

Image description: Lasiurus semotus 2.jpg

Which image is this for?

Lasiurus semotus 2.jpg

What is your suggested image description?

A close-up photo of a Hawaiian hoary bat being held in somebody's hand.

Image description: Artibeus lituratus 2.jpg

Which image is this for?

Artibeus lituratus 2.jpg

What is your suggested image description?

A leaf-nosed bat about the size of the hand of the researcher holding it is biting the finger of the glove on the opposite hand. Because of the open mouth and small eye, the effect is of a very wide grin.

Image description: Harpyionycteris whiteheadi 1.jpg

Which image is this for?

Harpyionycteris whiteheadi 1.jpg

What is your suggested image description?

A Philippines harpy fruit bat, fills the main part of the screen, body is mostly a furry brown, with the wings outstretched and translucent. In the background are some mountainous green landscape.

Image description: Lasiurus semotus 2.jpg

Which image is this for?

Lasiurus semotus 2.jpg

What is your suggested image description?

A small furred bat with rounded ears and a pert, upturned snout. The fur is mottled light and dark shades of brown with a distinct ruffle around the neck.

Image description: Pipistrellus pipistrellus 2.jpg

Which image is this for?

Pipistrellus pipistrellus 2.jpg

What is your suggested image description?

Common pipistrelle (Pipistrellus pipistrellus), a very small bat with brown fur on the palm of a hand, nomming on a grub

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.