Questions tagged [validation]

Validation is used to check data to make sure it fits whatever required specifications are set for it. Typically Validation is used in checking input data, and in verifying data before storage.

validation
Filter by
Sorted by
Tagged with
0 votes
1 answer
26 views

Is there a standard way to do backend validation?

I'm writing a simple CRUD application in express.js and node.js and while developing the backend APIs this is what I came up with app.post("/signup", (req, res) => { const { name, email,...
Yash Burshe's user avatar
-1 votes
1 answer
15 views

Validate array of enums with Zod

Example enum: enum Day{ MONDAY = 1, TUESDAY = 2, ... } how do I validate with Zod an array of these type of enums? z.array(Day) doesn't work z.array(Day.MONDAY | Day.TUESDAY ...) doesn't work
Alex's user avatar
  • 67k
0 votes
2 answers
26 views

Form validation by JavaScript in Laravel 10.x won't work

I made a custom validation in Laravel 10.x blade using JavaScript and Bootstrap 5 classes. When I press the submit button, the store action doesn't work, and the form is reloaded empty without putting ...
Andrew_1979's user avatar
0 votes
0 answers
6 views

Setting an HTML5 form as invalid even when all elements are considered valid?

Often, a form's elements are valid based on the client-side validations, but the entire submission is invalid, based on the combined form's values and the state of the back-end. I'm trying to figure ...
davetron5000's user avatar
  • 24.5k
0 votes
0 answers
17 views

Validator geronimo-validation_1.0_spec not supporting spring 3

When i am using spring boot 3.2.0 with geronimo-validation_1.0_spec validator its not working throwing issue java.util.concurrent.ExecutionException: javax.validation.ValidationException: Could not ...
user2810698's user avatar
0 votes
0 answers
6 views

CPU Usage Increases Because Spring Boot Uses the Validation @Size Annotation to Verify Lists

I validate the List size using java validation @Size: @RestController @RequestMapping(value = "/", produces = {"application/json;charset=UTF-8"}) @Validated public class ...
user24450259's user avatar
0 votes
2 answers
41 views

Laravel validation: ignoring certain fields during update

How can I prevent Laravel from validating certain columns when editing an existing user? I'm trying to update a guest's information, but I want to ignore the phone and email fields if no changes have ...
Peter's user avatar
  • 31
0 votes
0 answers
31 views

My controller don't validate my Java Model

I'm trying to validate my Model, which I annotated with: @NotEmpty(message="name cannot be null") @Size(min=1, max=32) @Column(name="artist_name") for example, however when I send ...
southzonehorror's user avatar
0 votes
1 answer
28 views

Validate specific field in Laravel 10

I have a rating system with validation issues. Both fields need to be validated under certain conditions. f1 = field 1 -> radio from 1 to 5; f2 = field 2 -> textarea; Here are my validation ...
Robin Thijsen's user avatar
0 votes
1 answer
18 views

Fastify schema: return all validation errors

I'm trying to return all fields names which have not passed validation, because I need them to display the respective error messages under each input field on the frontend. But I haven't found a way ...
cs.edoardo's user avatar
0 votes
1 answer
33 views

How to test @Valid with JUnit5, @SpringBootTest?

This is my Controller class. import jakarta.validation.Valid; import jakarta.validation.constraints.NotNull; import org.springframework.http.ResponseEntity; import org.springframework.web.bind....
이성호's user avatar
0 votes
0 answers
20 views

VueJS form return undefined when form field doesn't have a value

I have an issue when using yup in VueJS. I created a form for submitting data. when submit data, if the value is not mentioned it returns as undefined. I want to remove undefined and set a default ...
Nipun Vidarshana's user avatar
-1 votes
0 answers
17 views

Exce vba macros, shifting data of few rows downwards based on the condition [closed]

STEP 1: Excel VBA, if value in column G is not equal to value in column C, then compare the value of G with value C with 5 more rows above the current row, and if matches then shift the data from the ...
Anudeep Nalukurthi's user avatar
0 votes
0 answers
32 views

Django: Adding unique together errors to one of the involved fields

Note: I asked this question on the Django forum, but since I did not receive any answers there, I'm asking here, too. I’m building an application with multi-tenancy, meaning that all data is ...
Timitry's user avatar
  • 2,776
0 votes
0 answers
18 views

Using Joi raw() with default()

I'm currently working with Joi for validation purposes and encountered an issue regarding date formatting and default values. Here's the scenario: date: Joi.date().format("YYYY-MM-DD").raw()....
Michał Sochacki's user avatar
0 votes
0 answers
10 views

HTML form custom validation via setCustomValidity / reportValidity is called only once [duplicate]

I have form with 2 inputs. At least one is required. I want to use setCustomValidity(message) function on form submit. This works but once the message is displayed it never goes away and ...
asdjfiasd's user avatar
  • 1,658
0 votes
0 answers
13 views

I am unable to read data validation cells values in excel when using excel package in flutter

I am using excel package in my flutter project to read excel file. When I try to read an excel file that contains dropdown values/ data validation cells , Excel.decodeBytes(bytes) unable to read the ...
usman ghani's user avatar
0 votes
0 answers
18 views

How to match the input and output shapes of my data in the encoder model?

I have entered it into the following code: from tensorflow.keras.models import Sequential from tensorflow.keras.layers import Conv1D, MaxPooling1D, UpSampling1D, Flatten, Dense # Define the input ...
Joy Chatterjee's user avatar
0 votes
1 answer
34 views

How to enhance server-side form validation in C# for updating forms?

I have implemented basic server-side validation in the Update action in Teacher Controller to check for empty or null values for certain fields such as TeacherFname, TeacherLname, EmployeeNumber, ...
Rutisha Patel's user avatar
0 votes
2 answers
39 views

Laravel - Access information with nested validation request

I want to access information within nested validation array to do a custom validation, here is my code: return [ ..., 'amount' => ['nullable', 'numeric'], 'currency_id' => ['nullable', 'integer',...
Hilal Najem's user avatar
0 votes
1 answer
57 views

Laravel 10 with FilamentPHP 3 - Overlapping Date Range Validation

How to prevent date overlapping for existing date range in database? I have SchoolPeriod model and school_periods table with date_from and date_to columns and it is defined as protected fillable for ...
Mr.Jepoyyy's user avatar
-1 votes
0 answers
14 views

Having an error while running my chatbot based project

(https://i.stack.imgur.com/bNPjU.jpg) getting this error - Traceback (most recent call last): File "app.py", line 23, in eng_swa_tokenizer = AutoTokenizer.from_pretrained("./...
Please help's user avatar
0 votes
2 answers
47 views

How to validate Unicode letters in .NET that contain invisible chars

In .NET, I have a simple line that asserts a string must consist of letters or digits only if (str.Any(c => !char.IsLetterOrDigit(c)) { throw new Exception(); } The problem is the string can be ...
user246392's user avatar
  • 2,735
1 vote
1 answer
48 views

Is length of generated column affected by both @Size and @Column annotations?

Having a following property in my entity: @Setter @Size(min = 3, max = 255) @Column(length = 500) private String xo; Generated column in h2 database is CHARACTER VARYING(255) I expected it to be 500....
bridgemnc's user avatar
  • 196
0 votes
1 answer
17 views

Pydantic - change data in nested model before validation

I have this small example of nested object with pydantic. from typing import Dict from pydantic import BaseModel, Field, ValidationError class UserType(BaseModel): name: str = Field(min_length=1) ...
piotrekkr's user avatar
  • 2,911
0 votes
1 answer
33 views

How do I find formula used in html calculator

I have searched and unable to find formula for this calculator. https://www.saltyunderground.com/support/berghia-calculator.html Open source page and locate formula then use to create custom ...
Tim Dalby's user avatar
0 votes
0 answers
18 views

How can I write and handle mixed character states with Python?

everyone, I am creating a dataset containing many animal species, and there are some species that possess multiple character states for a single feature. To give an example, I could have "...
Ivan Iofrida's user avatar
0 votes
0 answers
15 views

I need to restrict only | Pipe special character from input in angular [duplicate]

<dx-text-box (onKeyDown)="Submit($event)" (onValueChanged)="somthing()" maxLength="100"[(value)]="Description"> <dx-validator><dxi-validation-...
user24268988's user avatar
0 votes
0 answers
29 views

Validation Result is same as Training Result in YOLOV8

I'm a beginner please spare me, I'm running a YOLOV8 model in Google Colaboratory Environment. I've noticed that after training my model and validating it with the pretrained yolov8 model. Then I've ...
user24192861's user avatar
-1 votes
0 answers
9 views

jQuery UI Tabs - ONLY validate the current visible, active tab

I'm using Jquery UI's tabs in ASP.NET 4.0 (legacy) and have forms in each tab; when I click a button within a div, it validates not only the current (visible) tab, but data in the other tabs also. I ...
KrispyFlayvas's user avatar
1 vote
2 answers
82 views

How to pass values from input in form in Google Sheets sidebar to Google Sheets cell using TextFinder()

I've been puzzling over this problem for hours now. Here is what I am trying to achieve. The end goal is to be able to modify the name of a job using a sidebar in Google Sheets. The sidebar can be ...
Codedabbler's user avatar
-1 votes
1 answer
55 views

The problem with rendering and capturing form data.. REACT

I'm having an issue. I created a form, and when I click the button to add, which is in the index.tsx file, it's not adding. However, when I try to render the dummyProductList, it works. Let me share ...
Deivid Micael's user avatar
-2 votes
0 answers
34 views

Why is MudColorPicker validation not working

I can't seem to get the validation working for the MudColorPicker component. Am I using the component or attribute incorrectly? https://try.mudblazor.com/snippet/wuGeEolkSdRPrmFc @using System.Text....
Imogen's user avatar
  • 219
1 vote
0 answers
23 views

How to trigger fluent validation on change of a dependent property value change?

I have a Boolean property 'AnyLetter' depending on five other Boolean properties. The fluent validation is working when I hit on submit but I would like it trigger like 'Location' property, when value ...
Sivakrishnan's user avatar
1 vote
0 answers
20 views

JSON validation fails with binary file in Python

I'm trying to validate a JSON with a binary file. def upload_image(self, image_path, title, description): self.collection = self.db["images"] with open(image_path, "rb&...
user2436333's user avatar
0 votes
1 answer
28 views

Laravel Blade error directive to PHP equivalent

I'm having trouble understanding the logic behind the Laravel @error blade directive. How does it work with $message enclosed within the @error directive? How does it know which $message to display? I ...
Harpreet Singh's user avatar
0 votes
0 answers
18 views

Input Schema Validation in Graphql JAva

In Java, I have the Backend Service exposed in GraphQl . I want to do the input Schema Validation , before it hits the backend service . let's say my Schema is : Schema.graphqls type User{ id: ID! ...
Kasis Shrestha's user avatar
-1 votes
0 answers
10 views

Using Legend State for Post Queries, State Management, and Validation in Next.js (CRUD Operations)

I'm building a Next.js web application with a microservices backend using Express and TypeScript. I'm interested in incorporating Legend State for efficient state management, data fetching, and form ...
Sanjay Kumar Sah's user avatar
0 votes
1 answer
29 views

How to correctly use audio file type validation in Laravel?

I'm pretty new to Laravel and am trying to learn the framework. I'm currently making a simple posts/leaderboard page where users should be able to upload an audio file to it. Everything works fine ...
KylianJay's user avatar
0 votes
0 answers
23 views

Error: "The user field is required" when posting data to ASP.NET Core Web API

I am developing a Vue.js application that communicates with an ASP.NET Core Web API for user data management. I am encountering an issue when trying to POST user data to the API, where I consistently ...
Dwieght Dewey Fuentes's user avatar
0 votes
1 answer
31 views

Limit range from start to end in Joi validation

Add Joi validation in nodeJs to limit endDate to be no more than 3 years after startDate. Example : startDate 2024-03-29 , max endDate should be: 2027-03-29. I tried: const maxEndDate = Joi.ref('...
Mimi's user avatar
  • 13
0 votes
0 answers
16 views

Is there an option to create custom field on restx, with validate / format

I have create a Resource: signup_model = api.model('Signup', { 'email': Email(required=True), 'password': fields.String(required=True) }) @api.route('/signup_user') class SignupUser(Resource):...
Dr. Memory's user avatar
0 votes
0 answers
11 views

Create a ValidationPipe Middleware in nestjs

i have this ValidatorPipe that should be the same as ValidationPipe in my nestjs server: @Injectable() export class ValidatorPipe extends ValidationPipe implements PipeTransform<any> { ...
AvishayIDF's user avatar
0 votes
1 answer
37 views

Can you change locale of default form validation messages?

Is there a way to change locale of default form validation messages so that no matter the browser’s language they are always displayed in English. I don’t want to set custom messages via ...
Ealdjkflsa aCkad's user avatar
-1 votes
0 answers
9 views

Higher Accuracy in validation that test

I trained a model using the 80/10/10 split rule. The accuracy of my validation is around 80% (Pearson correlation), and the accuracy of my test data set is around 83%. Is this ok? I tried different ...
m sh's user avatar
  • 1
0 votes
1 answer
57 views

Why does Java java.util.regex Pattern Matcher Throw Runtime Exceptions?

The following code throw a runtime exception in my project Pattern pattern = Pattern.compile(""); Matcher matcher = pattern.matcher(null); Uncaught exception: java.lang.NullPointerException:...
Charlie's user avatar
  • 2,124
-2 votes
0 answers
35 views

Merging data classes in the validation step in python [closed]

In a classification problem I want to divide one class of the data into two subclasses in the training step in order to prevent the algorithm from tending to the majority class, then how can I merge ...
Ali's user avatar
  • 1
0 votes
1 answer
20 views

Uncaught TypeError: Cannot read properties of null (reading 'value') at HTMLButtonElement.submitEmail

So I recently deployed a newsletter sign-up form to my GitHub. I got the whole thing working in VS Code but when I tested it the link from GitHub pages, all of a sudden I get this TypeError in my ...
Trey Jablinske's user avatar
0 votes
1 answer
14 views

How to fix validation rule for jira-maven-plugin

I use the jira-maven-plugin to create a plugin for JIRA <build> <plugins> <plugin> <groupId>com.atlassian.maven.plugins</groupId> <...
Andreas Panagiotidis's user avatar
0 votes
0 answers
18 views

NestJs DTO Validation in a Monorepo Setup

I am new to the NestJs ecosystem and developing a NestJS App in a mono repo setup. My Nest app is in a package of its own while the DTOs are in a separate package as well such that the Client App can ...
Yemi Kudaisi's user avatar

1
2 3 4 5
1351