Announcement

Collapse
No announcement yet.

Error 500 on saving

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Error 500 on saving

    Hi,

    in the some custom entities I get the Error 500 on saving. Nevertheless, after refreshing the browser, the record is saved and further editig is possible without the error. I have two custom relationships in the entities and I guess it is due to these.
    The log says:

    Code:
    [2021-03-05 10:52:48] ERROR: Slim Application Error Type: TypeError Code: 0 Message: Argument 1 passed to Espo\ORM\Repository\RDBRelation::relateById() must be of the type string, null given, called in G:\laragon\www\Werkverzeichnis\application\Espo\Core\Repositories\Database.php on line 596
    I see, that there seems to be a wrong type in database, but I do not find, where that is.
    Last edited by shalmaxb; 03-16-2021, 10:29 PM.

  • #2
    Although it is very difficult to find the reason for this error, I made some researches. I see from the log-file, that the type of the Id should be string, but 0 is given.
    I than looked in the referenced file RDBRelation.php on line 366 there is "string" for Id.
    I changed this to "array" (I know, it would be wrong, but I wanted to see the provoked error message after that).
    The error message now says:

    Code:
    relateById() must be of the type array, given is string
    This means, that the type really is string.
    But why the error log puts out as given type 0, when it in fact is string?

    Comment


    • #3
      Anybody an idea with this?

      Comment


      • #4
        Hi, I apologize for pushing this again, but I am struggling for weeks to get rid of this error and no help so far. My custom entities worked before and suddenly this error appeared. I don`t even know, where to search, lot of guessing, but nothing so far solved.

        So please, could anybody have a look into this? Thank you!

        Comment


        • #5
          I read it but no idea where to start or can give you any input. I'm quite stump at this, so here is a bump.

          Only suggestion that is almost pointless to suggest is: to see if it reproducible with the demo version.

          Comment


          • #6
            Hello,
            there was a bug with these files : throw new InvalidArgumentException(); class not found.
            Yuri have just make a correction.
            see my post in bug section..

            Comment


            • #7
              Hi,
              I see this while I try to create new field.
              This was working normally so far
              Please help

              Error 500
              Error while rebuilding database. See log file for details.​

              Comment


              • shalmaxb
                shalmaxb commented
                Editing a comment
                Post your log file please
            Working...
            X