question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

text.validation.length.max error message not working properly in adminUI

See original GitHub issue

1: npm init keystone-app 2: add code to a text field and run dev server

fields: {
      name: text({
        validation: {
          length: {
            max: 8,  //this max property caused the bug
            min: 3,
          },
        },
      }),

3: go to adminUI and try to input a name longer then 8 character.

the error message show :Name must be no longer than 3 characters , the error message uses the min property for the max validation error.

chrome-capture

Issue Analytics

  • State:open
  • Created 2 years ago
  • Reactions:2
  • Comments:13 (5 by maintainers)

github_iconTop GitHub Comments

3reactions
gnadenthalcommented, Mar 31, 2022

I am getting related (but different) error when only validation.length.max is set. The error is using null as invalid length. The configured field is:

 model: text({
        label: "Model",
        validation: {
          length: {
            max: 19,
          },
        },
      }),

CleanShot 2022-03-30 at 21 23 10

1reaction
MohammadKurjiehcommented, May 13, 2022

@dcousens the issue is fixed now. The weird part was that I wasn’t able to reproduce on my local machine only on the deployment server. I was running the same versions of node-npm-…

We cleared the npm caches removed the node_modules and updated keystone to the latest release (12 May 2022). We think this issue is resolved by this update link

Note: the update didn’t take place until we cleared everything…

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error message appears at the Web UI when the max. text ...
​In this case, an error pop-up message appears and the user gets the hint for exceeding the "max. text length" for this field.​....
Read more >
Error message when a user enters more characters than max ...
First, count the entered characters and then print out the message you'd like to (here: "Characters left: X", the max length is 100...
Read more >
Admin UI Guide - ExtraHop Documentation
The Admin UI Guide provides detailed information about the administrator features and functionality of the ExtraHop Discover and Command appliances.
Read more >
Link field displays RecID instead of proper value. Error ...
Error Message: The following information does not satisfy validation constrains: <Link Field Name>: The maximum length for this field is 30.
Read more >
CA SiteMinder Policy Server Administration Guide
Resolve LDAP search timeout issues (see page 271)—Added another use case for ... Policy Server Exits with LDAP Admin Limit Exceeded Error ....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found