Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
nielsm
Jun 1, 2009



Install an old-school C compiler in DOSbox and write some demoscene-style graphical effects. Then obtain some 1992-1994 PC hardware and make your code run acceptably on that. Try to do it all with mostly period-appropriate tools and references.
Doing all that will require some very different problem-solving to any modern environment for business or web applications. The main points of the exercise is probably to be more appreciative of what current environments offer, and also offer some perspective on "can this be done in a more pragmatic, performant way".

Adbot
ADBOT LOVES YOU

downout
Jul 6, 2009

Ive found it helpful to find the most manual, tedious, time consuming parts of my job and automatting them with an application to be pretty useful. I usually ended up having to solve novel problems and my boss loves when they find out why this time consuming and 'easy to f up' process now goes so quickly and without errors. Really any process in your company like this is costing them money and if it can be automatted then it will save/make money.

pokeyman
Nov 26, 2006

That elephant ate my entire platoon.

downout posted:

Except sourcetree is garbage. I mean I use it, but I hate it. And I revert to the cli when doing anything more complicated than checkout, merge, etc.

Agreed, that’s what I was going for. Totally see how I was ambiguous though. Now I am the bad interface.

Mr Shiny Pants
Nov 12, 2012

nielsm posted:

Thirding that having cursory knowledge in a large diversity of areas has been a great help to me. I spent hours upon hours just reading about random things I didn't have any immediate use for, and often barely understood, but it still helped me become aware of ideas and approaches I've later had use of and been better able to understand. However getting that kind of breadth of (shallow) knowledge might be hard if you don't have a natural curiosity, then it's just dreadful homework.

This, it helps to know that stuff exists, if only so you know how something is called or that there probably is something you can use.

CJacobs
Apr 17, 2011

Reach for the moon!
This is only really tangentially related to programming but I'm having a weird task scheduler problem that I think this thread might be able to help with (win 10 64-bit). I'm having this weird issue where my internet disconnects just long enough to drop my connection, but not long enough to trigger Windows to reconnect automatically when it comes back up. According to my ISP the error is on their end and is a problem with my neighborhood's node and they won't fix it any time soon because they're dickheads. To resolve this, basically, I have set up a task to monitor my internet connection with a batch file by doing a ping to google (just for simplicity's sake) and if it's unsuccessful then disable and reenable my ethernet network.



This is all of the code, there's nothing more to it than this. The problem I'm having is that I set up the task to run, but I don't know how to make it execute indefinitely once I start it running. Currently it activates at startup, but goes back to 'ready' after checking the scheduler again and does not work when my internet drops. It also gives a 'last run result' of (0x1). If I just run this by itself when I'm having connectivity problems it works fine.







edit: Alternatively, is there a way to have Windows monitor my connection by itself and then execute a task if it disconnects? That way I can just avoid doing the ping at all.

CJacobs fucked around with this message at 18:46 on Sep 27, 2018

Scaramouche
Mar 26, 2001

SPACE FACE! SPACE FACE!

Off the cuff but I've seen 0x1 for cases where there's some weird permission thing tied to "run only when used is logged in" versus "run whether user is logged in or not" and assigning some kind of super account to it (e.g. \SYSTEM or whatnot).

I also don't see any "Repeat task every (x)" settings in your screen shots on the schedule part.

CJacobs
Apr 17, 2011

Reach for the moon!
Unfortunately "repeat task every (x)" only goes down to 1 minute, there's no way that I can find that makes the task continually run. I think this idea is dead, so if the alternative I mentioned is possible I'd like to hear it. Is there a way for the task scheduler to detect that my internet was just connected, but just now is not, so execute a task?

CJacobs fucked around with this message at 20:37 on Sep 27, 2018

mystes
May 31, 2006

CJacobs posted:

Unfortunately "repeat task every (x)" only goes down to 1 minute, there's no way that I can find that makes the task continually run. I think this idea is dead, so if the alternative I mentioned is possible I'd like to hear it.
If you want it to run continuously you just need a loop, possibly using "timeout" to sleep in the middle; you don't need task scheduler to relaunch it every couple seconds.

However, there's got to be a better solution than pinging google 24 hours a day, like using performance counters or something.

Scaramouche
Mar 26, 2001

SPACE FACE! SPACE FACE!

I've seen some people ping their routers for this, but I have no idea if that'll work given the nature of whatever is wrong at your ISP.

CJacobs
Apr 17, 2011

Reach for the moon!
I agree there's probably a better solution out there, I am pretty out of my element here so I was using what little I already knew to put that together. I really have no idea what I'm doing. If anyone has any advice to give I'd definitely listen!

edit: For the record, adding a simple loop did work and made the script run forever once it started. But uh... having watched it generate a cmd prompt a thousand miles long in seconds, I think I would rather not go this route.

CJacobs fucked around with this message at 20:50 on Sep 27, 2018

LLSix
Jan 20, 2010

The real power behind countless overlords

mystes posted:

If you want it to run continuously you just need a loop, possibly using "timeout" to sleep in the middle; you don't need task scheduler to relaunch it every couple seconds.

However, there's got to be a better solution than pinging google 24 hours a day, like using performance counters or something.

Helicity posted:

Apologies for not being clearer - I was thinking along the lines of learn a second language, get good on the command line, really understand functional programming, etc. Things anyone can do while they're in the process of getting more experience that in retrospect are like "holy poo poo I leveled up when I did that". The interns and other new devs I end up interacting with are begging for advice that is beyond "get more experience". Just looking for more ideas outside of my own experience that I might be able to share with them.


Do you live in a rural swamp or have a swastika tattoo on your forehead? Even during the recession, developers had a pretty easy go of it.

edit: VVV I'll go check it out

Comments are controversial, but in my experience, I spend much more time fixing code that has no or poor comments than I do in code with good comments. Not only do good comments make code easier to maintain, but when someone can't write good comments, they usually don't understand what they're doing well enough to write good code. When working with interns, even just getting them to write pseudo code comments can help them organize their thoughts and write much cleaner code. Once they've started laying out their work with comments it's just a short step to teaching them how to break projects down into smaller chunks that they have a better chance of completing in a single day and estimating time on accurately.

On a related note, learning not to re-invent the wheel is really important for newer developers. A codebase that consistently uses the same patterns is much more maintainable than one where every file is its own special snowflake. So you could encourage them to start looking at how the healthier parts of the code base do things and reuse those same idioms and functions.

For slightly more developed engineers, contributing to and participating in code reviews will really help them move to the next level. Looking back I think starting to code review was one of the major milestones in my own development. For one thing, once you've had to tell someone 100 times not to do something stupid like ignoring function return values or forgetting to check for null you get much better about such things yourself. It's also a great opportunity to develop breadth by seeing other developer's approaches. I don't do a lot of bit flipping or binary math but the handful of times I've had to, I've done so much more efficiently and cleanly by emulating approaches I remember from code reviewing for developers who did do a lot of it. Code reviews on fresh out of college hires also helps me stay current on what schools are teaching these days and I've learned a few things I wouldn't have otherwise.


CJacobs posted:

I agree there's probably a better solution out there, I am pretty out of my element here so I was using what little I already knew to put that together. I really have no idea what I'm doing. If anyone has any advice to give I'd definitely listen!

edit: For the record, adding a simple loop did work and made the script run forever once it started. But uh... having watched it generate a cmd prompt a thousand miles long in seconds, I think I would rather not go this route.

mystes posted:

If you want it to run continuously you just need a loop, possibly using "timeout" to sleep in the middle; you don't need task scheduler to relaunch it every couple seconds.

However, there's got to be a better solution than pinging google 24 hours a day, like using performance counters or something.
Alternately https://unix.stackexchange.com/questions/60767/bash-script-needed-to-run-every-second or I think even just:
sleep 1;
somewhere in your script

Also, I'd point it at your ISP instead of Google. I know I'd feel a lot better about pinging my thoroughly disagreeable ISP a million times a day than Google.

LLSix fucked around with this message at 21:08 on Sep 27, 2018

Scaramouche
Mar 26, 2001

SPACE FACE! SPACE FACE!

I don't know if you're willing to jump through hoops to get Gadgets working (I already had with Windows Desktop Gadgets) but this Gadget might do what you want:
https://windows10gadgets.pro/network/networkmonitorii/networkmonitorii.html

(Download button is ad-blocked by default but it works, I installed it on mine)

It has a setting to run a program when connection is detected as OFF (not sure if you specific problem will register as such, though it does have an option to ping live servers) and another when it comes back ON.

If you don't know Gadgets used to be a way on Windows Vista/7 to embed systray like apps into the desktop, and was replaced by the "live tiles" crap in Win 10. The feature still exists but you have to re-enable it with another download (like Windows Desktop Gadgets or other).

That said, you could probably find a program that's not tied to the old gadget format that does the same thing, this is just the first one I found.

EDIT-the site looks sketchy but Igor is actually pretty well known

CJacobs
Apr 17, 2011

Reach for the moon!
Unfortunately the program didn't work, I was unable to get it to launch anything. I can confirm that it didn't destroy my computer though at least. I managed to find this trigger:



and it works just fine, when it detects my internet has gone down it executes a simple batch file I made to disable and reenable the network adapter. So, problem solved, I guess!



The only remaining weirdness is that my network icon is the "nope it aint connected" gray even though it definitely is connected because I'm using it right now.

Khorne
May 1, 2002

CJacobs posted:

Unfortunately the program didn't work, I was unable to get it to launch anything. I can confirm that it didn't destroy my computer though at least. I managed to find this trigger:



and it works just fine, when it detects my internet has gone down it executes a simple batch file I made to disable and reenable the network adapter. So, problem solved, I guess!



The only remaining weirdness is that my network icon is the "nope it aint connected" gray even though it definitely is connected because I'm using it right now.
Why do you have to do this with your adapter? If your connection to your router is stable then there should be no need for you to reconnect. Reconnection will happen on the router itself.

If you are renting a modem+router combo from your isp, it's likely just your router that is crapping out.

If you don't have a router, everything makes more sense.

CJacobs
Apr 17, 2011

Reach for the moon!
I am unsure why it happens, but it happens to every device in my house. Phone, TV, other computers besides my own. None of them reconnect when the connection comes back up. I am currently renting a modem and router combo box but the same thing happened with a separate self-owned modem and router. This has been going on for about a year now, multiple times a day, every day, and it's quite frustrating.

Scaramouche
Mar 26, 2001

SPACE FACE! SPACE FACE!

Not sure if this goes here but I'm not sure where to ask.

We've got an SFTP (external) for EDI type transactions that is going very slow. The set up is this:
- Customer Receives/Sends Orders that create acknowledgement/order files
- Our application SFTPs to a 3PL warehouse to tell them to fulfill orders
- 3PL fulfills orders, puts shipping acknowledgements on SFTP for our app to retrieve
- Our app marks Orders as shipped after downloading/parsing shipping acknowledgements

It's been slow all along and I haven't paid too much attention to it because I know SFTP is just slow in general, but this is now being hella slow, and the 3PL is blaming us. On the first go round our app wasn't doing good connection management; it was opening a connection, putting one file, closing a connection, moving on to the next, etc. We updated it to re-use connections and batching, and things got even slower. Our app is using the Renci SSH.NET dll.

I've been doing some reading, and found this Stack Overflow that implies that this is an artifact of SFTP having a different buffer file timing than the underlying TCP frame on default OpenSSH:
https://stackoverflow.com/questions/8849240/why-when-i-transfer-a-file-through-sftp-it-takes-longer-than-ftp
(the first upvoted answer is from the author of a patch HPN-SSH that is supposed to help speed this up)

I've confirmed that the 3PL is running OpenSSH_6.6.1, using SSH-2, SFTP-3, aes, and compression=no. WinSCP properties shot:


The thing is, I can't determine if OpenSSH has incorporated this guy's patch (SO post was from 2014), or if it's something I can ask the 3PL to do, or if that's even the underlying problem. Any SFTP gurus out there with insight?

EDIT-Hmm there's some github discussion implying we should mess with the buffer size on instantiation but it kind of peters out:
https://github.com/sshnet/SSH.NET/issues/100
(the library we're using github, not OpenSSH or HPN-SSH)

Scaramouche fucked around with this message at 19:23 on Sep 28, 2018

Shibawanko
Feb 13, 2013

I want to try to learn ArcGIS and data visualization tools, since there seems to be a lot of demand for that where I live and I've always enjoyed working with maps and stuff. Is there a good place to learn that stuff for free, and is there a programming language that I should learn that is helpful if I want to get into that (Java maybe?)? I couldn't find anything about ArcGIS on codeacademy but I might have overlooked it.

return0
Apr 11, 2007

Shibawanko posted:

I want to try to learn ArcGIS and data visualization tools, since there seems to be a lot of demand for that where I live and I've always enjoyed working with maps and stuff. Is there a good place to learn that stuff for free, and is there a programming language that I should learn that is helpful if I want to get into that (Java maybe?)? I couldn't find anything about ArcGIS on codeacademy but I might have overlooked it.

I'd start with QGis tutorials and play about with the pyshp library.

Emmideer
Oct 20, 2011

Lovely night, no?
Grimey Drawer
This is a question of my own curiosity.

Let's say I have some function F(x) and another function F(y, z) such that F(x) = F(y=x, z) where z is set to some value. E.g. F(x) is actually just F(y) because z is no longer variable. If I create, say, F(x) = F(y, 4), and then call F(x) later on the in the program, will it run F(y) or will it run F(y, z)? Obviously it doesn't matter if I'm just running F(x) just once, but if I'm using it a million different times, the extra time spent computing F(y, z) over F(y) adds up. If it does call F(y, z) every time, is there some trick most programming languages would have access to get around this, as opposed to creating a seperate F(y) function by hand?

Allow me to be very specific with a simple case:

F(y, z) = 2z - y. F(x) = F(y=x, z=0). You'll recognize F(x) as an implimentation of reversing the sign, whereas F(y, z) reverses around some number. If calling F(x) needs to calculate 2 * 0 every time, that takes longer than if it already knows F(x) = 0 - y, and just uses that every time. Now I could just write F(y) = 0 - y instead and use that, but for any case where the equations involved are more complex and tracking logic is priority, it becomes ineffecient to create every specific case by hand. It gets even more important if you're dealing with a very general case and have multiple levels of common specific cases, e.g. F(a, b, c), F(d, e) = F(a=d, b=e, c=3), F(g) = F(d=g, e=71).

Sorry if this question isn't very exact, I'm not an expert in any of this kind of stuff.

mystes
May 31, 2006

Jon Joe posted:

This is a question of my own curiosity.

Let's say I have some function F(x) and another function F(y, z) such that F(x) = F(y=x, z) where z is set to some value. E.g. F(x) is actually just F(y) because z is no longer variable. If I create, say, F(x) = F(y, 4), and then call F(x) later on the in the program, will it run F(y) or will it run F(y, z)? Obviously it doesn't matter if I'm just running F(x) just once, but if I'm using it a million different times, the extra time spent computing F(y, z) over F(y) adds up. If it does call F(y, z) every time, is there some trick most programming languages would have access to get around this, as opposed to creating a seperate F(y) function by hand?

Allow me to be very specific with a simple case:

F(y, z) = 2z - y. F(x) = F(y=x, z=0). You'll recognize F(x) as an implimentation of reversing the sign, whereas F(y, z) reverses around some number. If calling F(x) needs to calculate 2 * 0 every time, that takes longer than if it already knows F(x) = 0 - y, and just uses that every time. Now I could just write F(y) = 0 - y instead and use that, but for any case where the equations involved are more complex and tracking logic is priority, it becomes ineffecient to create every specific case by hand. It gets even more important if you're dealing with a very general case and have multiple levels of common specific cases, e.g. F(a, b, c), F(d, e) = F(a=d, b=e, c=3), F(g) = F(d=g, e=71).

Sorry if this question isn't very exact, I'm not an expert in any of this kind of stuff.
Apparently the answer is yes at least in your simple case. Looking at the assembly output on godbolt.org (which is great for this kind of thing), with the -O3 optimization level gcc turns the following c code:
code:
int f(int z, int y) {
    return 2 * z - y;
}

int f2(int num) {
    return f(0, num);
}
into this:
code:
f:
  lea eax, [rdi+rdi]
  sub eax, esi
  ret
f2:
  mov eax, edi
  neg eax
  ret
So f2 has turned into a function that just reverses the sign without actually calling f!

Probably what happens is that gcc first inlines f in f2 (includes its code rather than calling it as a separate function) because f is so short, and then it is smart enough to write out the unnecessary arithmetic as a separate optimization.

mystes fucked around with this message at 01:51 on Oct 1, 2018

ultrafilter
Aug 23, 2007

It's okay if you have any questions.


That probably only works if both functions are in the same translation unit as the caller. And that's definitely not something you can count on if you're using an interpreted language.

But really, this is the sort of optimization that you only need to worry about if you're working on something that absolutely must be as efficient as possible. Outside of video game graphics, embedded systems and high frequency trading, there just aren't that many applications where this sort of thing is going to matter.

Hunt11
Jul 24, 2013

Grimey Drawer
So I am trying to use open refine to find the latitude and longitude data of the neighborhoods in a city, and while I do get some results that I am looking for, other times I get this error message "Keyless access to Google Maps Platform is deprecated. Please use an API key with all your API calls to avoid service interruption. For further details please refer to http://g.co/dev/maps-no-account"
Do I just need to find a way to add in a personal api code or is there something else that I am supposed to do entirely?

Scaramouche
Mar 26, 2001

SPACE FACE! SPACE FACE!

Hunt11 posted:

So I am trying to use open refine to find the latitude and longitude data of the neighborhoods in a city, and while I do get some results that I am looking for, other times I get this error message "Keyless access to Google Maps Platform is deprecated. Please use an API key with all your API calls to avoid service interruption. For further details please refer to http://g.co/dev/maps-no-account"
Do I just need to find a way to add in a personal api code or is there something else that I am supposed to do entirely?

Google changed all the mapping stuff to make a stronger link to the paid/developer account. I think it's still "free" if you are below a certain usage threshold, but they are forcing people to enter payment information in case the usage balloons up.

Hunt11
Jul 24, 2013

Grimey Drawer

Scaramouche posted:

Google changed all the mapping stuff to make a stronger link to the paid/developer account. I think it's still "free" if you are below a certain usage threshold, but they are forcing people to enter payment information in case the usage balloons up.

I will try messing around with it a bit more but upon taking a closer look at the data sometimes instead of the error message I get exactly what I am looking for.

downout
Jul 6, 2009

Hunt11 posted:

I will try messing around with it a bit more but upon taking a closer look at the data sometimes instead of the error message I get exactly what I am looking for.

You have to create a google account and register your app for an api key. They do offer a free tier under a certain number of requests monthly. I didnt enter cc info ~4 months ago when setting up an account.

mystes
May 31, 2006

downout posted:

I didnt enter cc info ~4 months ago when setting up an account.
I think that was before the changes took effect.

https://cloud.google.com/maps-platform/pricing/

quote:

Is a credit card or billing account required?

Yes. Even though the first $200 a month is free, we ask for your credit card or billing account to cover any amount you spend over this free credit. When you’re billed, we'll credit your account for the first $200 of monthly usage. If your estimated usage will be above $200 a month and you don’t have a credit or debit card to set up a billing account, a local Google Maps Partner may be able to help.

dirby
Sep 21, 2004


Helping goons with math
I don't work in IT/code much, but is every IT job as much about things other than coding as it seems to an outsider? Like ensuring someone else follows a style guide, making sure to use the VCS the right way, project management stuff, setting up a framework for testing of code that works well, etc.

Maybe this is just bias because the above are what people usually argue/complain about, but I'm curious about what is typical/if it depends a lot on the job, etc.

ultrafilter
Aug 23, 2007

It's okay if you have any questions.


IT and programming are two separate job categories. On the programming side, when you're just starting out you spend most of your time writing code, but as you get more senior you do need to start worrying about other things. I think it's unusual to have a programming job that's mostly not programming unless you're a tech lead or in management, but different companies and different industries are different.

Khorne
May 1, 2002

dirby posted:

I don't work in IT/code much, but is every IT job as much about things other than coding as it seems to an outsider? Like ensuring someone else follows a style guide, making sure to use the VCS the right way, project management stuff, setting up a framework for testing of code that works well, etc.

Maybe this is just bias because the above are what people usually argue/complain about, but I'm curious about what is typical/if it depends a lot on the job, etc.
All of these things come into play because if you don't do them then you end up in situations that take up more of everyone's time later on. Anyone who has grown organically as a coder knows the benefits of most of these things and the perils of not doing them. Not every piece of that is necessary for every project, but they all bring definite benefits and have predictable costs.

Whether you should use certain things there depends on the scope of your project. It's not as time consuming as it sounds. And in cases where it is, like say you have 50+ people working on a single product, you just have a person or people who are in charge of project management type things.

The style guide and VCS work flow is something that should be decided early on and the 'leader' or 'team' can adapt it as needed later on. Everyone else just follows it and maybe complains because they just want to do exactly what they did before even though most reasonable styles and work flows are the same garbage. Companies, or units within companies, tend to standardize on styles and tools between projects so it becomes real predictable with a few changes here and there.

Depending on where someone works, there's usually a code review process and any flagrant style violations would come up there. Lots of times, places just go with what the language prefers or some big company's style guide maybe with a few minor changes. There are also tools that offer some degree of automatic compliance with style guides or at the very least notifications that you're violating them right in the editor/ide. Generally, you aren't 'forcing' people to do things. They want the project to be maintainable and for new releases to not go up in flames. Once things are established they're self enforced with a bit of peer review to catch oversights.

You see lots of posts about it because some workplaces don't, or perhaps didn't, have solid processes in place. Sometimes there are ridiculous rules or rules lawyers and people with bad opinions can be in charge. It's easier to complain on forums than to become a pariah or bully at work. There's also the reality that many people have only been exposed to a few ways, and seeing what other people think helps a lot. I may post strong opinions often, but I'm often very wrong and have learned a whole lot from the people here.

How much of your workday this kinda stuff takes up depends on who you are and what you're doing. As an estimate, I'd wager it takes up almost none of your day until it does. Like meetings. Imagine you have two 1-2 hour meetings in a week but every now and then you have a day or series of days where it's all meetings. This kind of thing is like that.

My view is probably biased, and someone who has worked in other areas of programming and IT may have a different view.

Khorne fucked around with this message at 15:29 on Oct 3, 2018

luchadornado
Oct 7, 2004

A boombox is not a toy!

dirby posted:

I don't work in IT/code much, but is every IT job as much about things other than coding as it seems to an outsider?

Most of us are not working on anything that hasn't been solved and repeated many times. I think once you get past the hurdle of making it work, most developers start focusing on improving data integrity and service availability and how to iterate as quickly as the business can come up with new ideas. That's where people get into debates about architecture, code style, tooling, patterns, and other best practices.

huhu
Feb 24, 2006
I've got a python script that I'd like to run once a day that checks a site and if there's a change, send me a message. My hosting is pretty bad with cron jobs. What would be the cheapest/simplest way to have this script run? It also needs a way to store the results for future requests.

The Fool
Oct 16, 2003


Storing the results is trickier, what form does that need to take? Db, flat file, email?

Just running the script I'd consider setting it up on some free tier ci/cd tool like circleci or azure pipelines.

huhu
Feb 24, 2006

The Fool posted:

Storing the results is trickier, what form does that need to take? Db, flat file, email?

Just running the script I'd consider setting it up on some free tier ci/cd tool like circleci or azure pipelines.

It basically does a diff between today and yesterday.

pokeyman
Nov 26, 2006

That elephant ate my entire platoon.
I’d make a lil App Engine standard environment project and turn the slider down to the one free instance. Python 3 support is in beta though and I’ve not used it yet so this might only be a good option if your thinger is Python 2.

edit: the cron equivalent is called cron, and you can shove your data into the datastore. Shouldn’t cost a penny.

mystes
May 31, 2006

You could just run the script from cron and pickle the previous day's output.

I'm not sure saving one webpage a day requires all the cloud stuff people are suggesting.

mystes fucked around with this message at 00:29 on Oct 4, 2018

Thermopyle
Jul 1, 2003

...the stupid are cocksure while the intelligent are full of doubt. —Bertrand Russell

huhu posted:

I've got a python script that I'd like to run once a day that checks a site and if there's a change, send me a message. My hosting is pretty bad with cron jobs. What would be the cheapest/simplest way to have this script run? It also needs a way to store the results for future requests.

I've got a digitalocean droplet that costs $5 a month that I've got a whole mish-mash of different things like this running on. It's seriously useful and cost-effective.

luchadornado
Oct 7, 2004

A boombox is not a toy!

Thermopyle posted:

I've got a digitalocean droplet that costs $5 a month that I've got a whole mish-mash of different things like this running on. It's seriously useful and cost-effective.

Seconding DO. Cheap, easy, and super useful.

b0lt
Apr 29, 2005

huhu posted:

I've got a python script that I'd like to run once a day that checks a site and if there's a change, send me a message. My hosting is pretty bad with cron jobs. What would be the cheapest/simplest way to have this script run? It also needs a way to store the results for future requests.

You can get a permanently free micro instance on Google Compute Engine.

LLSix
Jan 20, 2010

The real power behind countless overlords

code:
ResultSet rs = blah;
try { if (rs.next()) {
// a zillion lines of code
// no closing brackets
EOF
Is there anything not wrong with that code snippet?

It's Java's implementation of ResultSet so next already throws an exception.

Adbot
ADBOT LOVES YOU

Peristalsis
Apr 5, 2004
Move along.
I've been doing the minimum amount of JavaScript/JQuery I can to get by for 10 years now, and it's time to make an effort to learn the language well enough not to cringe every time I see it come up. I'm hoping for a resource that explains the language itself, rather than just enough syntax and theory to use it to manipulate DOM objects, and since most of my reading/research time is on the bus, I'd prefer to have a physical/paper book to a tutorial or web site, though I can be flexible on that. Has anyone had any particular good experience with anything?

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply