Code Monkey home page Code Monkey logo

aerialbot's Introduction

🏡 To find out more about my projects and me-as-a-person, go and visit my website at noahdoersing.com.

📫 Want to get in touch? Feel free to drop me an email to the address that the following JavaScript snippet evaluates to.

((crypt) => {
    const rot13 = c => {
        c = c.codePointAt(0);
        let d = c + 13;
        if (d > (c <= 90 ? 90 : 122)) {
            d -= 26;
        }
        return String.fromCodePoint(d);
    }
    const backwards = s => s.split("").reverse().join("");
    return backwards(crypt.replace(/[a-z]/gi, rot13));
})("zbp.tavferbqunba@vu");

aerialbot's People

Contributors

dependabot[bot] avatar doersino avatar kengggg avatar wegge avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

aerialbot's Issues

'GeoPoint' object does not support indexing

When using a point instead of shapefile in config, the while True loop is not stopped by break, because shapefile is None. In the second try, one gets the error

Traceback (most recent call last):
  File "aerialbot.py", line 940, in <module>
    main()
  File "aerialbot.py", line 838, in main
    point = GeoPoint(point[0], point[1])
TypeError: 'GeoPoint' object does not support indexing

Because point was already converted to GeoPoint in the first run.

Add Instagram posting support

This is really more of a "this could be cool and is now finally possible" rather than "will implement ASAP" kind of issue, prompted by a conversation with @btutal.

After years of systematically shutting down third-party libraries and tools that utilize private posting APIs, Instagram has finally added official support for automated posting via its Graph API – but there's a few catches:

  • It's only available for business accounts. No biggie, those are easily created.
  • Standard Instagram image aspect ratio and format (i.e., only JPEG) rules apply. No biggie either, just configure ærialbot to emit matching images.
  • For API access, the Instagram account needs to be connected to a Facebook page for the "business", which requires a Facebook account. Major hassle to set up. (It's 2021, who creates Facebook accounts anymore?)
  • Posting works by specifying a URL where the image is publicly available, there's no direct upload method. Some image hosting services like good ol' Imgur offer relevant APIs, but this adds complexity and another failure point.

Here's a Python-based tool that implements automated image (and video) posting to Instagram via this API: https://github.com/killianmcshane/autogram – its README.md also lists the steps required to set things up.

With posting through Instagram's website rumored to be on its way, perhaps some of these limitations and annoyances will fall away in the not-too-distant future, so it might be beneficial to be patient.

Add tips about where to find more shapefiles

Very cool and interesting project. What about adding support for other countries? For example, there are shapefiles for European countries available here: https://www.eea.europa.eu/data-and-maps/data/eea-reference-grids-2/gis-files/folder_listing. Some have different resolution (?) - 1km, 10km, 100km (ex. Sweden).

Does it make sense to add them to the repository, make tool download files or maybe just mention in the README.md?

This might both save time for others and could be used as extra way to demonstrate aerialbot for others.

Suggest to loosen the dependency on tweepy

Hi, your project aerialbot requires "tweepy==3.10.0" in its dependency. After analyzing the source code, we found that the following versions of tweepy can also be suitable without affecting your project, i.e., tweepy 3.9.0. Therefore, we suggest to loosen the dependency on tweepy from "tweepy==3.10.0" to "tweepy>=3.9.0,<=3.10.0" to avoid any possible conflict for importing more packages or for downstream projects that may use aerialbot.

May I pull a request to further loosen the dependency on tweepy?

By the way, could you please tell us whether such dependency analysis may be potentially helpful for maintaining dependencies easier during your development?



We also give our detailed analysis as follows for your reference:

Your project aerialbot directly uses 3 APIs from package tweepy.

tweepy.api.API.__init__, tweepy.auth.OAuthHandler.__init__, tweepy.auth.OAuthHandler.set_access_token

Beginning from the 3 APIs above, 1 functions are then indirectly called, including 0 tweepy's internal APIs and 1 outsider APIs. The specific call graph is listed as follows (neglecting some repeated function occurrences).

[/doersino/aerialbot]
+--tweepy.api.API.__init__
|      +--tweepy.parsers.ModelParser.__init__
+--tweepy.auth.OAuthHandler.__init__
|      +--requests_oauthlib.OAuth1Session
+--tweepy.auth.OAuthHandler.set_access_token

We scan tweepy's versions and observe that during its evolution between any version from [3.9.0] and 3.10.0, the changing functions (diffs being listed below) have none intersection with any function or API we mentioned above (either directly or indirectly called by this project).

diff: 3.10.0(original) 3.9.0
['tweepy.parsers.JSONParser', 'tweepy.cursor.Cursor.__init__', 'tweepy.models.Model', 'tweepy.api.API.mutes', 'tweepy.cursor.NextIterator', 'tweepy.api.API.update_profile_background_image', 'tweepy.binder.pagination', 'tweepy.api.API.search_full_archive', 'tweepy.api.API.search_30_day', 'tweepy.cursor.NextIterator.next', 'tweepy.api.API.media_upload', 'tweepy.models.Model.parse_list', 'tweepy.cursor.NextIterator.prev', 'tweepy.models.User.lists_memberships', 'tweepy.cursor.NextIterator.__init__', 'tweepy.models.User.lists', 'tweepy.api.API.mutes_ids', 'tweepy.api.API.home_timeline', 'tweepy.models.User.lists_subscriptions', 'tweepy.api.API', 'tweepy.api.API.get_oembed', 'tweepy.api.API._pack_image', 'tweepy.parsers.JSONParser.parse', 'tweepy.models.User', 'tweepy.cursor.Cursor', 'tweepy.binder.bind_api']

As for other packages, the APIs of requests_oauthlib are called by tweepy in the call graph and the dependencies on these packages also stay the same in our suggested versions, thus avoiding any outside conflict.

Therefore, we believe that it is quite safe to loose your dependency on tweepy from "tweepy==3.10.0" to "tweepy>=3.9.0,<=3.10.0". This will improve the applicability of aerialbot and reduce the possibility of any further dependency conflict with other projects.

How to add a new geocoder?

I've set up a copy of the script to post a random square kilometer of Denmark. The reverse geocoding for Denmark is very coarse, so I'd like to use a local API instead, to get a better resolution. Where in the code would be a good place to add this in a way that will make it suitable for addition?

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.