|
Ok here's a dumb question: I want to make a unicornhat (which uses a Python library) on a raspberry pi do something when a new order is placed, and according to the Shopify API, you would use their webhook to do it and you supply them with the URL for the webhook to deliver a HTTP POST payload to in json format. I understand the concept of json stuff after working with the discord API but I've never worked with webhooks before, so correct me if I'm wrong but does that mean I have to have my own server running and listening for the HTTP POST payload? Since it's a raspberry pi would it be easier to try to sniff for like an email notification to trigger the light_sign action? Any pointers would be great, I'm doing this for a friend's company in exchange for some of the neat t-shirts that he sells so I'd really like to find a way to make it work that doesn't take me a million years to figure out
|
# ¿ Mar 31, 2017 05:53 |
|
|
# ¿ May 3, 2024 10:14 |
|
I got promoted to developer recently and my first project has been building a file directory browser in php and Ajax and HTML and it's a fuckton to take in in two weeks so ya idk what it is with web stuff that is so hard to learn (probably all the acronyms and different languages/frameworks interfacing) but ya appreciate it! Flask looks like the way to go 😊 thanks!
|
# ¿ Mar 31, 2017 19:13 |
|
Dex posted:condolences week 2: i genuinely lust for death
|
# ¿ Mar 31, 2017 23:21 |
|
I use Python 2.7 anyways so yayyy Edit: how much does Zappa cost amper month for a server for a single webhook that is triggered maybe 5-10 times per day? FAT32 SHAMER fucked around with this message at 00:57 on Apr 1, 2017 |
# ¿ Apr 1, 2017 00:52 |
|
Tigren posted:How do you trigger local raspberry pi functions with Lambda? It's a unicornhat Python library so I can just call the function that I already wrote to light the UH when the webhook gets a hit, I think
|
# ¿ Apr 1, 2017 06:38 |
|
I'm working on rewriting a jython library and the wanker who wrote this spaghetti should be drawn and quartered just for using jython
|
# ¿ Apr 12, 2017 17:39 |
|
Jetbrains makes a lot of really nice stuff and I really like IntelliJ for Java and JavaScript. I found Pycharm to be frustrating to use because most small Python apps aren't organized the way Pycharm seems to try to organize them
|
# ¿ Apr 12, 2017 21:25 |
|
Dominoes posted:PyCharm doesn't like to work with files unless they're in a folder that includes PyCharm meta files (.idea directory). Maybe that's it? Ya basically Most of my Python projects are small enough to not need auto complete and linting and grammar or however you say it and having to fire up Pycharm to do 150 lines of code isn't really worth it to me so I use vim instead
|
# ¿ Apr 16, 2017 06:56 |
|
Dumb question: using flask, how would I push POST to my IP address so I don't have to deal with registering a domain to push to? I have already set up Dynu since my friend's IP is dynamic, so now I would assume I just need to forward the UDP ports (80 and 110? idk web poo poo is hard) and launch the flask app it's just powering a small web hook catcher that lights up a sign via a raspberry pi so we don't really care if it gets owned by some script kiddy
|
# ¿ May 23, 2017 00:34 |
|
fletcher posted:Not really sure I fully understand your request, but here's a couple of comments: Welp that covers that! Thanks for the input
|
# ¿ May 23, 2017 01:09 |
|
Basically his port 80 and 443 were blocked by Comcast and those are the only ports the webhooks would work with so we spent a bunch of time, energy, (and he spent money) for naught which feels super bad (only because I wasted his time by not even thinking about this in the planning stages and telling him his little sign that lights up on a webhook won't work)
|
# ¿ May 23, 2017 02:04 |
|
fletcher posted:Ah bummer. I suppose you could use AWS or Heroku free tier to host something listening on :80 or :443 and then whatever message could get passed along to the raspberry pi by a number of other methods. Yeah probably, but that would be significantly more work than my pay grade (free) haha
|
# ¿ May 23, 2017 02:48 |
|
Here's an idea: don't try fancy package managers that I don't even fully get when you have pip and plain old Python that work just fine (Also sit down and learn Pycharm because it's super simple once you get the hang of it)
|
# ¿ Jun 6, 2017 05:24 |
|
One day you too will reach the point where all the links in a google search for something are purple and you have to click through them to figure it out
|
# ¿ Jun 9, 2017 01:00 |
|
Lol if u have to think about the 64th decimal place in your code just lol
|
# ¿ Jun 11, 2017 01:45 |
|
I was lost on the floating point topic until I found this on quora quote:Most answers here address this question in very dry, technical terms. I'd like to address this in terms that normal human beings can understand.
|
# ¿ Jun 11, 2017 02:29 |
|
what if quantum computer creates a black hole right in the middle of silicon valley? it'd be a net positive
|
# ¿ Jun 11, 2017 05:26 |
|
KernelSlanders posted:Not everyone in this thread builds web apps.
|
# ¿ Jun 11, 2017 18:15 |
|
|
# ¿ May 3, 2024 10:14 |
|
Eela6 posted:By the way, you shouldn't store currency in floats. I'm assuming that you should use doubles but please expand on this
|
# ¿ Jun 11, 2017 21:07 |