Ticket #681 (reopened defect)
Submitting Transition event overseas: An illegal choice has been detected. Please contact the site administrator.
Reported by: | sam | Owned by: | sam |
---|---|---|---|
Priority: | minor | Milestone: | Maintenance |
Component: | Drupal modules & settings | Keywords: | |
Cc: | Estimated Number of Hours: | 0.0 | |
Add Hours to Ticket: | 0 | Billable?: | yes |
Total Hours: | 0.15 |
Description
Hi I'm using https://www.transitionnetwork.org/node/add/event
To create a Transition Training event in Belgium in the 'Limburg' region.
On submission I get the following error;
"An illegal choice has been detected. Please contact the site administrator."
It works for UK events.
I had a look at the fields in the event content type, but couldn't spot any problems
Change History
comment:2 Changed 3 years ago by sam
It seems this is also affecting the submission of new initiatives that are not in the UK.
comment:3 Changed 3 years ago by jim
- Add Hours to Ticket changed from 0.0 to 0.05
- Total Hours changed from 0.0 to 0.05
Initial thoughts: Our custom module https://github.com/transitionnetwork/transition_extras might be causing this now that Location has changed, or it's a bug in Location... Or something else!
comment:4 Changed 3 years ago by sam
I applied this patch https://drupal.org/files/issues/location.module_34.patch
To location.module on www.stg2.transitionnetwork.org and it has resolved the issue.
Shall I apply to live site? Any concerns?
Thanks
Sam
comment:5 Changed 3 years ago by jim
- Add Hours to Ticket changed from 0.0 to 0.05
- Owner changed from jim to sam
- Status changed from new to assigned
- Total Hours changed from 0.05 to 0.1
Good work... Yes, add it to the live site if it's proven to fix it, and also the makefile for the location module section.
Document this issue in the makefile to its progress can be followed.
Reassigning to you, cheers!
comment:6 Changed 3 years ago by sam
Hi Jim
So I went to download the location module (So I could then patch it);
tn@puffin:~/static/transition-network-d6-p009/modules$ drush dl location
Install location /data/disk/tn/static/transition-network-d6-p009/sites/all/modules/contrib/location already exists. Do you want to overwrite it? (y/n):n
However ls doesn't show a 'location' directory in there;
tn@puffin:~/static/transition-network-d6-p009/modules$ ls
aggregator book cookie_cache_bypass help o_contrib php README.txt syslog tracker upload
block color dblog locale openid ping search system translation user
blog comment filter menu path poll simpletest taxonomy trigger
blogapi contact forum node path_alias_cache profile statistics throttle update
comment:8 Changed 3 years ago by sam
- Owner changed from jim to sam
Ah got it. Should be looking here;
tn@puffin:~/static/transition-network-d6-p009/sites/all/modules/contrib$ ls
comment:10 Changed 3 years ago by sam
Hi Jim. I patched it and had a go at updating the Make file. Please sanity check the make file changes!
tn@puffin:~/static/transition-network-d6-p009/sites/all/modules/contrib/location$ wget https://drupal.org/files/issues/location.module_34.patch
--2014-01-29 16:42:49-- https://drupal.org/files/issues/location.module_34.patch
Resolving drupal.org (drupal.org)... 140.211.10.62, 140.211.10.16
Connecting to drupal.org (drupal.org)|140.211.10.62|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 575 [text/plain]
Saving to: `location.module_34.patch'
100%[====================================================================================>] 575 --.-K/s in 0s
2014-01-29 16:42:50 (8.33 MB/s) - `location.module_34.patch' saved [575/575]
tn@puffin:~/static/transition-network-d6-p009/sites/all/modules/contrib/location$ patch -p1 < location.module_34.patch
(Stripping trailing CRs from patch.)
can't find file to patch at input line 5
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
|Index: location.module
|===================================================================
|+++ location.module (working copy)
File to patch: location.module
patching file location.module
comment:11 Changed 3 years ago by chris
- Component changed from Live server to Drupal modules & settings
Component changed to Drupal modules and settings.
comment:12 Changed 3 years ago by sam
- Status changed from assigned to closed
- Resolution set to fixed
comment:13 Changed 3 years ago by jim
- Status changed from closed to reopened
- Resolution fixed deleted
This is not complete unless the patch is either;
- A: not needed as it's in the commited module
- B: included in the makefile -- in which case please complete the pull request https://github.com/transitionnetwork/transitionnetwork.org-d6.profile/pull/1
- C: Done already - in which case please link to the commit that fixes it here in this ticket.
Reopening.
comment:14 Changed 3 years ago by ed
Sam to follow up as discussed on 26/03. Obviously revolves around us doing code publishing, which Ed is asking Paul for help with, so stand by.
comment:15 Changed 3 years ago by sam
Hi so I should add
projects[location][patch] [tn02] = https://drupal.org/files/issues/location.module_34.patch
To the makefile?
Thanks
Sam
comment:16 Changed 3 years ago by jim
- Add Hours to Ticket changed from 0.0 to 0.05
- Total Hours changed from 0.1 to 0.15
Hi Sam, yes... That will ensure the patch gets added next time...
Actually, the 'correct' line would be:
projects[location][patch][tn02] = http://drupal.org/files/issues/location.module_34.patch
With no newline... The difference being a) no space in the array definition, b) no https -- I've had issues where the server can't see HTTPS stuff, but is fine with HTTP. Odd...
Naresh has asked me about this one again.
This might be relevant:
Changing country and then selecting a province returns error "An illegal choice has been detected. Please contact the site administrator."
https://drupal.org/node/2139429