Happy Birthday, MLP:FiM! MLP:FiM turns 10 years old this year! Let's celebrate with an art event!

Philomena open beta / breaking API changes

DarthBarf
My Little Pony - 1992 Edition
Friendship, Art, and Magic (2020) - Took part in the 2020 Community Collab
The Magic of Friendship Grows - For helping others attend the 2020 Community Collab
Dream Come True! - Participated in the MLP 9th Anniversary Event
Toola Roola - For helping others attend the 2019 Community Collab
Wallet After Summer Sale -
Friendship, Art, and Magic (2019) - Celebrated Derpibooru's seventh year anniversary with friends.
A Really Hyper Artist - 500+ images under their artist tag
Best Artist - Providing quality, Derpibooru-exclusive artwork
Friendship, Art, and Magic (2018) - Celebrated Derpibooru's six year anniversary with friends.

1. Tags with apostrophes in them give 404 errors. Example

2. Text parser for description fields breaks links that end with .php extension. Example: Example

The code for the above link was "Example":https://example.com/index.php

3. Profile badges are drawn out of chronological order.

4. No way to access list of associated user links nor the creation link from user's page. User links , User links/New
Angius

The Ponut Eater
Not sure I understand the API changes…

Once the migration to Philomena is done, the old API stays under that /v1/ route. But do the new API routes stay the same as they are now? Because I can see that this has the exact same structure ans is on the exact same route as the old API was. The current API docs are also the same as the new API docs.

While we're talking about the API, will the new backend (if not now then maybe in the future) have OAuth or something that'd let users using 3rd party apps vote on and fave pictures, comment, stuff like that?
byte[]

Philomena Contributor
@DarthBarf
Yeah I'm trying to figure it out. It works in local development environments but not in production (the best kind of bug).


@Angius
That's the backwards-compatible fill for old API clients, as mentioned in the OP. The new API is exclusively under /api/v1/json (and /api/v1/rss for the watched feed). If you're confused, please have a look at the router:

https://github.com/derpibooru/philomena/blob/5f9fe0cb98cee76c3b58b932f7103dea4975a859/lib/philomena_web/router.ex#L77-85
byte[]

Philomena Contributor
@Angius
I'll also throw in that the API docs are just a blob of HTML in the database and so they're rendering the same. I haven't updated the page yet.
RicardW
Silver Bit -
Ruby -
Bronze Supporter - Bronze Patron
Happy Derpy! - For Patreon supporters

@byte[]
First, thanks for doing that so quickly! Also, thanks for resolving confusion about slugs vs tag ids that was in the previous API.

There might be an escaping problem with tag slugs in general in the new codebase. I looked in my local tag json directory and started testing anything which looked like it had a slug with a lot of escaping. Sure enough, there's at least a problem with the url escaping of '(' and ')'. It looks like this is a more general problem with tags though. If you go to https://philomena.derpibooru.org/1790981 and click on the bass guitar tag, you get a valid page, but if you click on you spin me round (like a record) (dead or alive) , you get a 404.
Rainboom Dash
Magnificent Metadata Maniac - #1 Assistant
My Little Pony - 1992 Edition
Wallet After Summer Sale -
Artist -
A Tale For The Ages - Celebrated MLP's 35th Anniversary and FiM's 8th Anniversary
Birthday Cake - Celebrated MLP's 7th birthday
Not a Llama - Happy April Fools Day!

Rainbooms4Ever
@RicardW
It's because of the parentheses

I already reported it in here and is being/has been looked into
Also happens with ! and according to Darthbarf it also happens with apostrophes
doloresbridge
My Little Pony - 1992 Edition

Peace to all
@byte[]
When I first saw this I immediately became scared of a massive makeover and/or functionality changes. (not saying it's always a bad thing, but I've seen many sites confuse changes and improvements are not synonymous). Glad that fear isn't being realized and best of luck with it.
byte[]

Philomena Contributor
I forgot that Elixir doesn't sort dates according to their natural order, it sorts them by the order of the fields in the struct. Badges now appear in the correct order.
Marker
My Little Pony - 1992 Edition
Wallet After Summer Sale -
Magnificent Metadata Maniac - #1 Assistant
Not a Llama - Happy April Fools Day!

Misanthrope
- In settings Philomena caps the comments per page at 50, whereas it's 100 on the main site. Is this an intended change?

- On images with locked comment section, the comment reply links are not formatted.
e.g. >>409163 NSFW

- Using the next/previous link on a image without any query supplied (/images/2175695/navigate?rel=next) will just lead back to itself.

- Is there/will there be a new API equivalent for accessing an image's next/previous page?

[Current API] /next/2175695.json?q=featured+image
Angius

The Ponut Eater
I'm compiling changes to the API in a gist. At least the changes that affect my project. It's public, so feel free to submit any revisions and use it in general.

That out of the way, random image seems to be broken. Old API returned just an ID of a random image, the new API returns basically the entire search results.

[Old API] /search.json?q=pinkie+pie&random_image=y
[New API] /api/v1/json/search?q=pinkie+pie&random_image=y
byte[]

Philomena Contributor
@Marker
- No, I'll change it back tomorrow.
- Parser bug. Will fix.
- Oops.
- Sure

@Angius
There is no random_image parameter in the new API. Set sf to random and pick the first image out of the response.

There is also some other stuff that was not intended to be removed (like totals). I'll add them back.
JP
My Little Pony - 1992 Edition
Friendship, Art, and Magic (2020) - Took part in the 2020 Community Collab
Dream Come True! - Participated in the MLP 9th Anniversary Event
Wallet After Summer Sale -
Best Artist - Providing quality, Derpibooru-exclusive artwork
Friendship, Art, and Magic (2019) - Celebrated Derpibooru's seventh year anniversary with friends.
Artist -
A Tale For The Ages - Celebrated MLP's 35th Anniversary and FiM's 8th Anniversary
Friendship, Art, and Magic (2018) - Celebrated Derpibooru's six year anniversary with friends.
Cool Crow - "Caw!" An awesome tagger

The magic's gone :-(
- When searching for comments, the "Search" button changes to say "false" during the search. It is correctly grayed out, just the text is incorrect. The same also happens during forum post search.

- "Most commented-on images" does not work (just returns the same results as the front page).

- Site statistics page is missing Galleries, Commissions, Moderation and Uploads by day sections
JP
My Little Pony - 1992 Edition
Friendship, Art, and Magic (2020) - Took part in the 2020 Community Collab
Dream Come True! - Participated in the MLP 9th Anniversary Event
Wallet After Summer Sale -
Best Artist - Providing quality, Derpibooru-exclusive artwork
Friendship, Art, and Magic (2019) - Celebrated Derpibooru's seventh year anniversary with friends.
Artist -
A Tale For The Ages - Celebrated MLP's 35th Anniversary and FiM's 8th Anniversary
Friendship, Art, and Magic (2018) - Celebrated Derpibooru's six year anniversary with friends.
Cool Crow - "Caw!" An awesome tagger

The magic's gone :-(
Tag implication lists have no commas (on the Rails side there are commas) separating tags; combined with the decreased line height, it makes tag implication lists really messy and almost impossible to read.
Interested in advertising on Derpibooru? Click here for information!
Furbooru - A furry-centric imageboard

Derpibooru costs over $25 a day to operate - help support us financially!

Syntax quick reference: *bold* _italic_ [spoiler]hide text[/spoiler] @code@ +underline+ -strike- ^sup^ ~sub~