Re: Add versions.json endpoint with latest release information - Mailing list pgsql-www

From Sehrope Sarkuni
Subject Re: Add versions.json endpoint with latest release information
Date
Msg-id CAH7T-aofk31G=UjbKSpZY47c6ZAD6-D+nDoSAoi2qeYxJpSyXA@mail.gmail.com
Whole thread Raw
In response to Re: Add versions.json endpoint with latest release information  ("Jonathan S. Katz" <jkatz@postgresql.org>)
Responses Re: Add versions.json endpoint with latest release information  (Magnus Hagander <magnus@hagander.net>)
List pgsql-www
Updated patch is attached with the renamed field.

Rather than use annotate(...), it defines a separate function to convert the Version model into a dict for serialization. That way the numtree function can be used for the major version (i.e. for 10.0 => 10). I think it ends up being cleaner anyway as all the fields in the resulting JSON are listed in one place.

Thanks for updating the sample data. New output is now:


[
  {
    "current": false,
    "eoldate": "2003-03-01",
    "latestMinor": "2",
    "major": "6.3",
    "reldate": "1998-02-23",
    "supported": false
  },
  {
    "current": false,
    "eoldate": "2003-10-30",
    "latestMinor": "2",
    "major": "6.4",
    "reldate": "1999-01-03",
    "supported": false
  },
  // ... truncated ...
  {
    "current": true,
    "eoldate": "2025-11-13",
    "latestMinor": "2",
    "major": "13",
    "reldate": "2021-02-11",
    "supported": true
  }
]


Regards,
-- Sehrope Sarkuni
Founder & CEO | JackDB, Inc. | https://www.jackdb.com/
 
Attachment

pgsql-www by date:

Previous
From: "Jonathan S. Katz"
Date:
Subject: Re: Add versions.json endpoint with latest release information
Next
From: Justin Clift
Date:
Subject: Re: Any Update on Reported Vulnerability