Simplify your stack and build anything. Or everything.
Build tomorrow’s web with a modern solution you truly own.
Code-based nature means you can build on top of it to power anything.
It’s time to take back your content infrastructure.

Versioning compare versions against dropdown failed to load on payload version 3.17.1,

default discord avatar
chincheng4756last year
6

error log


ERROR: invalid input syntax for type integer: "NaN"


err: {


"type": "DatabaseError",


"message": "invalid input syntax for type integer: "NaN"",


"stack":


error: invalid input syntax for type integer: "NaN"


at C:\admin\node_modules\pg-pool\index.js:45:11


at process.processTicksAndRejections (node:internal/process/task_queues:105:5)


at async eval (webpack-internal:///(rsc)/./node_modules/drizzle-orm/node-postgres/session.js:96:22)


....


"length": 146,


"name": "error",


"severity": "ERROR",


"code": "22P02",


"where": "unnamed portal parameter $1 = '...'",


"file": "numutils.c",


"line": "619",


"routine": "pg_strtoint32_safe"


}

  • default discord avatar
    gargasamalast year

    I am also on payload 3.17.1 and also getting the an error on versions compare. However my devtools show a 404 instead of a 500 error. This is the 404 query

    /api/patients/versions?depth=0&limit=10&page=1&where%5Band%5D%5B0%5D%5Bid%5D%5Bnot_equals%5D=678a32e6b610eddb2084ae7b&where%5Band%5D%5B1%5D%5Bparent%5D%5Bequals%5D=678a32d9b610eddb2084ae61

    . I'm have not set any access restrictions on the versions. Both the parent Id and version ID in this query seem ok. There are 4 other versions listed in the admin UI. Not sure how I can fix this at this point. Thank you.

  • default discord avatar
    chincheng4756last year

    usually should not be 404, not sure whether you have set any base url in the payload config, double check whether it match the url of your admin portal in the browser

  • default discord avatar
    gargasamalast year

    hi. thanks. yes it does. the full URL is still the default dev one actually:

    http://localhost:3000/api/patients/versions?depth=0&limit=10&page=1&where%5Band%5D%5B0%5D%5Bid%5D%5Bnot_equals%5D=678a477cb610eddb2084b704&where%5Band%5D%5B1%5D%5Bparent%5D%5Bequals%5D=678a330cb610eddb2084aed7
  • default discord avatar
    chincheng4756last year

    newer version of payload cms is released, i think it will fix the versioning route issue, you can check it out

  • default discord avatar
    gargasamalast year

    Hi. Yes ! Just tried the new version and now the 404 is gone. And I can select a version to compare against. However, the version name (in the version dropdown select) remains to "Loading..." . This is probably just a UI bug, since I can select a random version and the diff shows.



    I reinstalled a fresh payload instance and now the "loading..." state is gone. Maybe my upgrade process went wrong or something was in the data. I consider my issue fixed 🎉 .

    @474772813706821652

    feel free to mark your issue as resolved if it is also resolved for you.

  • default discord avatar
    chincheng4756last year

    run /solve

Star on GitHub

Star

Chat on Discord

Discord

online

Can't find what you're looking for?

Get dedicated engineering support directly from the Payload team.