ckan / ckan/ckanext-validation

404 error when uploading a file that fails postgres rules

Open
#94 17 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
30
Forks
33
PR merge metrics
No merged PRs in 30d

Description

There is a bug in this extension when creating a new resource that contains an invalid structure (e.g. duplicate column names).

After clicking on "Add", the user is directed to a non-existent page (`dataset/dataset-page-name/resource/new`) with a 404 error:

Screenshot 2023-11-02 at 14 21 04

## What should happen
After clicking "Add", if the validation status is not "success":
1. the user should be kept on the add resource page
2. the validation report should be shown at the top of the page, in the same way that it is displayed for updates of existing resources
3. only after the user uploads a valid file should the application redirect to the resource page

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.