Code

Opened 5 years ago

Closed 5 years ago

Last modified 3 years ago

#11551 closed (duplicate)

URL not parsing file locator

Reported by: adamnelson Owned by: nobody
Component: Forms Version: 1.0
Severity: Keywords: validation url
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

Issue

When trying to save a form, the error 'Enter a valid URL.' appears for file:///Users/adam/blah.html

Expected

Either an error "file:// is not valid" should appear (for safety reasons?) or it should be allowed. The generic error message isn't true because file:// is a valid URL descriptor.

Resolution

I've attached a preliminary patch. Ideally we would use a library but I see that there's not easy and robust way to do this with standard Python.

Attachments (1)

forms.fields.diff (806 bytes) - added by adamnelson 5 years ago.
Allows file:/// url type

Download all attachments as: .zip

Change History (4)

Changed 5 years ago by adamnelson

Allows file:/// url type

comment:1 Changed 5 years ago by dc

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to duplicate
  • Status changed from new to closed

Duplicate of #6092

comment:2 Changed 5 years ago by adamnelson

I respectfully disagree as #6092 is 2 years old and is actually a large enhancement. This patch (or something similar) is simply a minor change to allow the file:// resource handler without changing anything else (i.e. this should be approvable/disapprovable quickly - the other is a major change).

comment:3 Changed 3 years ago by jacob

  • milestone 1.2 deleted

Milestone 1.2 deleted

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.