Commit graph

58 commits

Author SHA1 Message Date
eb4a3ce0d9 More gracefully handle batches that fail to save
I noticed a thing with like, an asset that I think referenced an item that
doesn't exist, which caused an error in the `body_specific?` validation
step?

Tbh that validation step needs fixed up in a number of ways, but I'm
scared to, since it's hard to know what will break modeling lol.

But in any case, more graceful handling is nice! If something happens,
I'd rather leave it null and try again later than have the job crash!
2023-11-10 17:42:56 -08:00
80bd229bc6 Clarify an error message in swf_assets:manifests task
It's not just that none of them were 200 OK, it's that they were all 404.
In the event that something returns not-200 and not-404, we immediately
abort, so we shouldn't get to this case unless they were all 404!
2023-11-10 17:27:35 -08:00
dc22a458bf Move manifest backfill to swf_assets:manifests task
Okay, I've simplified the migration to *just* add the column, and
instead added a task to find assets without manifest URLs and backfill
them.

Performance is a lot better now, using the `async-http` library, which
as I understand it supports both persistent connections when invoked
like this, and maybe also HTTP/2 multiplexing?? (Though I'm not
actually sure images.neopets.com does lol)

I'm not sure about the number of concurrent tasks I picked here, 100
seems okay for an internet thing and for such small requests, but I
worry that the CDN is gonna get annoyed or something. Well, we'll see!
This task is very resumable if it turns out we get frozen out or
something.
2023-11-10 16:52:50 -08:00
22e3f4240a Update most URLs to use HTTPS
I noticed we didn't have the little lock icon in the browser, and yeah
huh there's a lot of `http://` still floating around! Let's fix that!
2023-10-25 15:22:57 -07:00
cbad00f32d Fix AMFPHP requests
Okay, right, if we're just using www.neopets.com (like we are for now), it fails on http://www.neopets.com because it triggers a redirect that we don't follow.

So here I 1) change the default to HTTPS, and 2) add HTTPS support to our little RocketAMF lib
2023-10-23 19:05:09 -07:00
700e26d7df Remove old OpenNeo ID auth code
This removes login/logout/session logic for integrating with OpenNeo ID, replacing them with stubs that just redirect to `/?TODO` when you click login, and helpers that act as if you're not logged in.

This gives us a clean slate to plug in new Devise logic to integrate with the `openneo_id` database directly!
2023-10-23 19:05:07 -07:00
f80d220a62 Upgrade to Rails 4.2.11.3 and Ruby 2.4.10
Some tricks required here to get the dependencies to work out, but we got it!!

Oh also, we move away from the rbenv in Ubuntu's package manager, because it doesn't support more recent Rubies like 2.4.10.
2023-10-23 19:05:05 -07:00
0d4c6ca077 Delete utf8 backfill for old Ruby
Idk if the replacement `require` is necessary exactly, but it's the one-to-one replacement for this lib, so let's start there for now!
2023-10-23 19:05:05 -07:00
7e0971eac6 Delete unused deferred_attributes lib
No idea what this was! Goodbye!
2023-10-23 19:05:05 -07:00
Matchu
fd263ea82f Remove mall spider cron jobs
I don't think these work anymore, and our volunteers get new items into the db fast anyway, Impress 2020 is doing better spidering these days. And then we get to remove the cron job `whenever` gem!
2023-10-23 19:05:05 -07:00
Matchu
1195a6190b Uninstall resque
Yay, we've deleted all our background tasks!

We'll probably want to replace some of the basic functionality like certain caching? But we can deal with that as we run into it.

The direct motivation here was a seeming version conflict between Rails 4.2's rack dependency and latest Resque's rack dependency... but this is just nice complexity elimination regardless, we want this anyway :3
2023-10-23 19:05:04 -07:00
Matchu
8ea74b737e Remove outfit image saving
This has already been moved to Impress 2020 too, so we can delete all the image generation and saving!
2023-10-23 19:05:04 -07:00
Matchu
72a08901c8 Upgrade to Ruby 2.2.4, Rails 4.0.13
NOTE: This doesn't boot yet! There's something changed in the `devise` API that we'll need to fix!

```
/vagrant/config/initializers/devise.rb:46:in `block in <top (required)>': undefined method `encryptor=' for Devise:Module (NoMethodError)
```

But yeah, we navigated the gem upgrades, and also I ran `rake rails:update` and hand-processed the suggestions it had for our config files.
2023-10-23 19:05:02 -07:00
d8038f2fbf prefer scraped rainbow pool images over pet images 2015-09-05 18:48:41 +00:00
Matchu
1fa7031bac force utf8 on a copy of the openneo auth secret, instead of mutating input 2015-07-17 18:36:22 -04:00
8ccc2fd741 set the right asset id in the rake task :P 2014-03-28 00:12:04 -05:00
e62d52bbd4 use body zone (15) instead of static so that most items look good 2014-03-27 22:28:48 -05:00
173c1eab5d fit the asset ID in the 8-char image_hash limit 2014-03-27 22:28:48 -05:00
58fdb3d6ac rake task to quickly create prank pet types 2014-03-27 22:28:48 -05:00
b583254397 create colors from rake 2014-03-27 22:28:48 -05:00
2b870cf91b add pet state replacement task 2013-11-30 20:33:48 -05:00
edc61e9cb4 fix NoMethodError when pet not found
Looks like I forgot to update the RemoteGateway code to consider
that RocketAMF now returns strings. Like in the Pet code, I opted
to dump it into a HashWithIndifferentAccess rather than assume
that we'll forever use strings and it'll never get switched back
to symbols.
2013-04-25 16:39:13 -05:00
f547a75c40 ruby 2.0.0 compatibility... hopefully. 2013-02-25 01:14:45 -05:00
6c3ff09f5d make en-MEEP translatable - because sorting by translations doesnt work well with fallbacks 2013-01-27 20:43:08 -06:00
9c37e894f7 translate species/color 2013-01-26 10:34:48 -06:00
361b5df256 translate zones 2013-01-26 09:54:29 -06:00
29ed401238 load pet by locale, prepare needed translations 2013-01-24 18:24:34 -06:00
1571a10500 shoot, included in the wrong spot. this is rspec issue hard to test :( 2013-01-02 23:58:25 -05:00
b6f1b73738 fix(?) rake issues in production when rspec is missing 2013-01-02 23:56:44 -05:00
202f1dc527 update Rakefile and tasks to match new version of rake 2013-01-02 23:40:37 -05:00
2016216d42 stricter timeout on neopets gateway requests 2012-09-29 14:02:11 -05:00
7dfc6d81a2 add timeout to pet load 2012-08-11 18:47:25 -04:00
38a9e620c4 Merge branch 'outfit_thumbnails' 2012-07-31 11:21:28 -04:00
05acae3cb8 retroactively enqueue outfit images 2012-07-31 10:20:37 -04:00
0633f6012a fix cron job scheduler 2012-07-24 12:05:34 -04:00
91c1ac2acf rake task to update spotlight pets 2011-12-20 21:00:02 -05:00
69ca36e75a rake task to add/remove image mode access for given users 2011-07-01 15:10:13 -04:00
cf94c7ef59 utf-8 support in both ruby 1.9 and 1.8 2011-06-04 18:40:15 -04:00
4e919aca04 ree compatibility 2011-05-31 10:36:32 -04:00
b13fd7ae99 moving toward s3 image storage 2011-05-20 19:19:14 -04:00
2a7fea11e6 handle timeout errors for pet data, swfs, pet images 2011-02-19 22:49:13 -05:00
ac3e9c0051 no more eventmachine for http requests 2011-02-09 18:39:16 -05:00
28b387d4ca fix bug with eventmachine in dev 2011-02-06 17:49:30 -05:00
b07456cc30 make openneo auth strategy a devise strategy, so it can inherit rememberable 2011-02-05 10:33:34 -05:00
8c8776ff63 devise implemented, but not remembering 2011-01-26 13:40:15 -05:00
d28e297656 prep for newid server 2011-01-10 17:52:26 -05:00
ea4a4e6ee0 thread safety breaks class autoloading in rake; move mall spider cron jobs to runner 2010-12-01 19:28:16 -05:00
3d29f7784f asset spider, yaaay 2010-11-27 18:41:06 -05:00
d63da31ac2 add rake items:mall_spider
includes allowing null on some item fields, and putting the swf_assets
type and id index in an actual migration, or this commit would have removed
it upon migrating
2010-11-25 11:10:21 -05:00
e92e9947b8 rake task to, hopefully, repair duplicate pet state ids cleanly 2010-11-15 21:15:33 -05:00