Skip to content

Curse Polling

Pedro Cunha edited this page May 12, 2022 · 6 revisions

Curse Polling

Here is information on how we poll Curse mods.
We poll using the widget that is made by a curse team member named citricsquid. The project must have a beta or a release and must not be marked as experimental as they do not sync across sites. The Widget polls curse.com. We poll the file name you entered. If it isn't in the mod's json file, then Renol will not know about it. Due to the way the widget api polls curse.com, it has a one hour caching period before it resets and updates. Data between CurseForge and curse.com is also cached for one hour, so the total delay can be up to two hours.

Example: In the case of Dark Menagerie, RWTema set the file name to be "Dark Menagerie Beta 2". The regex for retrieving the mod version would be "Dark Menagerie (?P.+)".

    "DarkMenagerie": {
     "function": "CheckCurse",
     "active": false,
     "curse": {
          "id": "224039",
          "regex": "Dark Menagerie (?P<version>.+)"
        }
     },

Now i will explain what that code block Represents.

"DarkMenagerie" is the name of the mod.

"function": "CheckCurse", tells Nemp to use the CheckCurse parser for this mod.

"active": false, tells nemp if it should actively check that mod.

"curse": { starts the curse block.

"id": "224039" tells the CheckCurse function the id of the project.

"regex": "Dark Menagerie (?P<version>.+)" tells the CheckCurse Function how to find the version, using a Regular Expression, or regex. http://regex101.com/ is a good place to test these, as the site also runs on Python. NOTE: Unlike the other nemp parsers, CheckCurse will always be ?P<version> as it uses the API to determine if its a version or dev.

Clone this wiki locally