*Plugin 'connection with server could not be established'

Writing and using plugins for Version 5 and above.
Ian_T
Silver
Posts: 6
Joined: 08 Oct 2017 13:07
Family Historian: V6.2

Plugin 'connection with server could not be established'

Postby Ian_T » 08 Oct 2017 13:58

Hi, I have only started to try and run FH Plugins within the last week.

I am trying to run Plugin 'Improve Website or CD DVD HTML 2.9' against the as-installed 'Family Historian Sample Project' under FH 6.2.5 on a Win7 pc.

But when trying to run the 'Hyperlinks/Text' tab, I get the error message:-
+++++++++++++++++++++++++++++++++++++

COM exception:(.srclibrarytLuaCOM.cpp,394):A connection with the server could not be established

stack traceback:
[C]: in function 'Send'
[string "C:ProgramDataCalico PieFamily Historian..."]:3025: in function 'DownloadIcons'
[string "C:ProgramDataCalico PieFamily Historian..."]:3366: in function 'IntImproveHTML'
[string "C:ProgramDataCalico PieFamily Historian..."]:4599: in function <[string "C:ProgramDataCalico PieFamily Historian..."]:4596>
(tail call): ?
[C]: in function 'MainLoop'
[string "C:ProgramDataCalico PieFamily Historian..."]:2261: in function 'ShowDialogue'
[string "C:ProgramDataCalico PieFamily Historian..."]:4806: in function 'GUI_MainDialogue'
[string "C:ProgramDataCalico PieFamily Historian..."]:20994: in main chunk

++++++++++++++++++++++++++++++

It has been suggested (by Mike) that this means either my internet connection is down, else the FHUG server is/was temporarily unavailable.

However I was able to reload the Plugin, and a pc command-line 'netstat 109.228.16.38' receives an 'active connection' response from server 109.228.16.38 (which I believe to be the http://www.fhug.org.server), so I assume it is a more subtle issue.

Any ideas/fixes how I can make the Plugin establish a bi-directional connection with the server ?

(Another downloaded Plugin e.g. Top 20 Surnames In Bar Chart Form' works fine).

Regards, Ian_T
08-Oct-2017

User avatar
tatewise
Megastar
Posts: 14364
Joined: 25 May 2010 11:00
Family Historian: V6.2
Location: Torbay, Devon, UK
Contact:

Re: Plugin 'connection with server could not be established'

Postby tatewise » 08 Oct 2017 17:24

This is a strange problem, and I cannot repeat the symptoms in Windows 10.

Most Plugins do NOT require an Internet connection, but many of mine do.
What is very odd is that this Plugin will have already used the Internet to check the FH Plugin Store for a later version, using an almost identical COM and Send function.

The background to the feature is given in Knowledge Base > Improve Website or CD DVD HTML ~ Non-Image Media URL under Icon Files. It is also associated with Knowledge Base > Hyperlink & Text Conversions for the {{MEDIA:file|text}} code.

The Plugin downloads Icon files to the C:\ProgramData\Calico Pie\Family Historian\Plugin Data folder, but only if they do not already exist, so it usually only happens on first usage.
It is downloading the Icon files from FHUG using the URL:
http://www.fhug.org.uk/pushfile.php?filename=improve_***_icon.jpg&name=improve_***_icon&ns=/plugins/help/improve_html/
where *** is etc, pdf, doc & txt in turn.
i.e.
It is communicating with the http://www.fhug.org.uk/pushfile.php service to access Knowledge Base files in the Plugins > Help > Improve Website or CD DVD HTML name space.

It is when establishing this COM link that the failure arises, and it is not obvious why?
Usually it means that there is no Internet connection or no service (http://www.fhug.org.uk/pushfile.php in this case).

Does anyone else get similar symptoms?

I wonder if it is a browser/firewall/security software package interfering with the connection?
Ian, do you have any unusual anti-virus/firewall settings that may be getting in the way?

Try these tests by entering the URL into your browser address bar:
  1. URL: http://www.family-historian.co.uk/lnk/checkpluginversion.php?
    Should respond with:
    Error: No ID or Name
  2. URL: https://www.fhug.org.uk/pushfile.php?
    Should respond with:
    FHUG - Missing Download File
    The file does not exist.
    Please email admin@fhug.org.uk with the error shown above.
  3. URL: https://www.fhug.org.uk/pushfile.php?filename=improve_etc_icon.jpg&name=improve_etc_icon&ns=/plugins/help/improve_html/
    That should produce an open/save file popup for improve_etc_icon.jpg file.


BTW: 109.228.16.38 http://www.fhug.org.server is Northgate Housing User Group Forum and nothing to do with our fhug.org.uk
Mike Tate ~ researching the Tate and Scott family history.

Ian_T
Silver
Posts: 6
Joined: 08 Oct 2017 13:07
Family Historian: V6.2

Re: Plugin 'connection with server could not be established'

Postby Ian_T » 09 Oct 2017 16:56

Hi Mike, Thank you very much for your reply and suggested diagnostic steps

0) I'm using browser IE 11 update v11.0.46 (patched up to date)
with AVGfree antivirus s/w running (latest version + latest virus definition)
So from control panel-> admin tools-> services
stop AVG firewall service + stop AVG antivirus service
start fh v6.2.5
open family historian sample project
run plugin improve website or cd dvd html v2.9
plugin execution fails with same error messages
I concluded the firewall and/or avg interference were therefore unlikely
So I rebooted my win7 pc to restart avg/firewall

1) http://www.family-historian.co.uk/lnk/c ... ersion.php?
- returns your expected result

2) https://www.fhug.org.uk/pushfile.php?
- returns your expected result

3) https://www.fhug.org.uk/pushfile.php?fi ... rove_html/
- offers to download/save jpg file as you expected
- so downloaded/saved to my pc 'download' folder

I reran the plugin again:- which failed with exactly the same error messages

I had a quick look at your code, the relevent lines appearing (to me) to be
http:Open("GET",strSource,false)
http:Send()
http:WaitForResponse(30)
if http.StatusText == "OK" then
else
error
But as no program error string message is generated,
It seems (to me) that the line http:Send() is failing
for some reason, which is perplexing if it has
worked for you in the past
(and I found that your test step 3 worked, so proving
connectivity in general was working).

To try and workaround the problem, I decided to manually download the other 3 files

4) https://www.fhug.org.uk/pushfile.php?fi ... rove_html/
- offers to download/save jpg file
- so downloaded/daved to my pc 'download' folder

5) https://www.fhug.org.uk/pushfile.php?fi ... rove_html/
- offers to download/save jpg file
- so downloaded/saved to my pc 'download' folder

6) https://www.fhug.org.uk/pushfile.php?fi ... rove_html/
- offers to download/save jpg file
- so downloaded/saved to my pc 'download' folder

7) moved the 4x *.jpg files to c:\Program Files (x86)\Family Historian\Program\*.jpg
(not sure if this is the right target directory)

8) reran the plugin :- run failed with exactly the same error messages

Did I get the wrong target directory ? I was hoping that if I could
manually xfer the files, the above coding lines might be bypassed.

Anything else you can suggest for me to try ?

Thank you for your help.

Regards, Ian_T
09-Oct-201

User avatar
tatewise
Megastar
Posts: 14364
Joined: 25 May 2010 11:00
Family Historian: V6.2
Location: Torbay, Devon, UK
Contact:

Re: Plugin 'connection with server could not be established'

Postby tatewise » 09 Oct 2017 17:23

That is certainly very mysterious, and you have found the Plugin script at the heart of the problem.
The error message comes from the Lua interpreter when handling the Send() operation.

One thing you could try is to download from http://www.family-historian.co.uk/downloads/latest-free-upgrade and re-install FH V6.2.5 to ensure there is no glitch in the Lua interpreter. Try that first.

You have read my mind, because if the browser download worked, I was going to suggest exactly the workaround you tried.

BUT you chose the wrong folder ~ never ever touch the C:\Program Files (x86)\... installation folder for any product.
I suggest you carefully remove those 4x *.jpg files from that folder.

The C:\ProgramData\Calico Pie\Family Historian\Plugin Data\ folder is where they need to go.
See Knowledge Base > Family Historian Program Data Folder ~ you will encounter this folder often.
When successfully saved there the Plugin will skip the Send() operation.
Mike Tate ~ researching the Tate and Scott family history.

Ian_T
Silver
Posts: 6
Joined: 08 Oct 2017 13:07
Family Historian: V6.2

Re: Plugin 'connection with server could not be established'

Postby Ian_T » 10 Oct 2017 11:35

Hi Mike, Thank you for your response, and further suggestions which I noted.

I was initially somewhat confused until I realised that 'ProgramData' and its subdirectories were hidden Windows files.
So I used Organise>Folder Options>View to "show hidden files" them, and then copied across from my temporary directory the 4 files:
improve_etc_icon.jpg improve_doc_icon.jpg improve_pdf_icon.jpg improve_txt_icon.jpg
into directory C:\ProgramData\Calico Pie\Family Historian\Plugin Data\
(noted that the file move operation required Admin authorisation to succeed).
Then I just tried to run the Plugin 'Improve Web or CD DVD HTML 2.9' tab 'Hyperlinks/Text' - and it worked okay !!
Reset Folder Options to "don't show hidden files"

This Workaround has solved the problem for me.

And the ability of the above plugin tab - to shrink down the URL string lengths - and to allow opening of the URL in its
own window - works well and functionally achieves just what I wanted before I publish my website externally at my ISP !

Thank you again for your quick & expert help.

Regards, Ian_T
10-Oct-2017
(FH6.2.5 + Win7 Home SP1 + IE11 + HP 64-bit Desktop PC)

User avatar
tatewise
Megastar
Posts: 14364
Joined: 25 May 2010 11:00
Family Historian: V6.2
Location: Torbay, Devon, UK
Contact:

Re: Plugin 'connection with server could not be established'

Postby tatewise » 10 Oct 2017 11:50

Glad that all got resolved, but cannot explain the Send() glitch.
Did you try re-installing FH V6.2.5 first, to see if that fixed the Plugin error?
Otherwise, I am left wondering what is causing the problem.

I would advise leaving the ProgramData folder as "show hidden files" because I predict you will be returning there from time to time.

It sounds like you are a relatively new FH user, so I suggest you study Knowledge Base > Key Features for Newcomers and related to this posting the topic Backup & Recovery that explains how to backup the C:\ProgramData\Calico Pie\Family Historian\ folder plus the Windows Registry to preserve your FH customisations.
Mike Tate ~ researching the Tate and Scott family history.

Ian_T
Silver
Posts: 6
Joined: 08 Oct 2017 13:07
Family Historian: V6.2

Re: Plugin 'connection with server could not be established'

Postby Ian_T » 10 Oct 2017 16:22

Hi Mike, Thanks for your follow up comments.

I first purchased fh4.0.2 cd on 29-Dec-2009 running under Win XP; with
various fh application s/w upgrades and pc h/w & o/s upgrades since.
I recently purchased a new fh6.2 cd to test out fh website creation
(as I now want to mount a website of my fh research at my isp).

As per your suggestion, I have tried to do a full reinstall of fh6.2.5 to
see if this makes any difference to the Plugin download.
The precise steps I took are recorded below:-

open fh6.2.5
take fh full backup
delete all plugins
close fh6.2.5
backup all pc user data to usb stick
control panel>programs and features
select fh6.2.5 (01/09/2017 35.3MB)
uninstall
-> "Family Historian uninstall complete.
Some elements could not be removed.
These can be removed manually"
navigate to c:\ProgramData\Calico Pie\Family Historian
rename directory 'Plugin Data' -> 'Plugin Data OLD' (still contains 4 x *.jpg files)
reboot pc
clean install of fh6.2.2 again from cd (bought 01/09/2017)
-> accept all defaults
but decline (re)registration as already done 01/09/2017
open fh6.2.2
open my project
-> click help -> check for updates -> upgrade now
-> fh setup wizard -> install 6.2.5 -> finished okay
reboot
open fh6.2.5
open my project
Publish -> (re)Create my website
Help -> Family Historian on the Web -> Downloads
-> Plugin Store -> 1004 Improve Website or CD HTML 2.9
-> Download -> Open -> Successful Install
Tools -> Plugins -> Improve Website .. -> Run > Select Hyperlinks/Text tab
-> select URL pages options 'In new tab/window' '>30 chars' 'None'
-> click 'Convert' button
-> error messages received
++++++++++++++++++++++++++++++++++++++++
COM exception:(.\src\library\tLuaCOM.cpp,394):A connection with the server could not be established

stack traceback:
[C]: in function 'Send'
[string "C:\ProgramData\Calico Pie\Family Historian\..."]:3025: in function 'DownloadIcons'
[string "C:\ProgramData\Calico Pie\Family Historian\..."]:3366: in function 'IntImproveHTML'
[string "C:\ProgramData\Calico Pie\Family Historian\..."]:4599: in function <[string "C:

\ProgramData\Calico Pie\Family Historian\..."]:4596>
(tail call): ?
[C]: in function 'MainLoop'
[string "C:\ProgramData\Calico Pie\Family Historian\..."]:2261: in function 'ShowDialogue'
[string "C:\ProgramData\Calico Pie\Family Historian\..."]:4806: in function 'GUI_MainDialogue'
[string "C:\ProgramData\Calico Pie\Family Historian\..."]:20994: in main chunk
++++++++++++++++++++++++++++++++++++++++
windows file navigate to c:\ProgramData\calico Pie\Family Historian\Plugin Data\
only file there is 'Improve Website or CD DVD HTML.dat' size 13 bytes created 10-Oct-2017 16:26 hrs
so I copied in 4x *.jpg file from old directory 'Plugin Data OLD' to new 'Plugin Data' directory
Repeat
Tools -> Plugins -> Improve Website .. -> Run > Select Hyperlinks/Text tab
-> select URL pages options 'In new tab/window' '>30 chars' 'None'
-> click 'Convert' button
-> incremented through records
-> finished okay
Checked website results -> urls shortened + urls open in new windows- both okay

Not the results you were hoping for after a new clean install. Sorry.

(But I am very happy to run with the Workaround, as your
Plugin does exactly what I hoped that it would. Thank you again.)

Regards, Ian_T
10-Oct-2017

User avatar
tatewise
Megastar
Posts: 14364
Joined: 25 May 2010 11:00
Family Historian: V6.2
Location: Torbay, Devon, UK
Contact:

Re: Plugin 'connection with server could not be established'

Postby tatewise » 10 Oct 2017 18:41

That is disappointing, and you clearly understand the concepts.

Have you used the Plugin Help & Advice button that displays help & advice in another window?
It downloads that help text also from the FHUG Knowledge Base and may suffer the same problem.

Could you try one other technique, because the Help > Check for Updates wizard sometimes misbehaves.

Please download from http://www.family-historian.co.uk/downloads/latest-free-upgrade and re-install FH V6.2.5 by running the downloaded installation file with Administrator privileges, i.e. use right-click Run as Administrator as described in the Knowledge Base > Family Historian Installation Problems Introduction.

You do NOT need to uninstall the existing FH V6.2.5. Just install over the top of it.
I assume you will install from an Administrator account, but still use the right-click Run as Administrator option, which forces the Administrator privileges to penetrate deeper.
Temporarily 'hide' the 4 x *.jpg files as you did before to checkout the Plugin Send() problem.
If it still fails then, restore the Plugin Data folder as before.

BTW: Why did you buy a new FH V6.2 CD instead of obtaining the V4 to V6 Upgrade discount?
Mike Tate ~ researching the Tate and Scott family history.

Ian_T
Silver
Posts: 6
Joined: 08 Oct 2017 13:07
Family Historian: V6.2

Re: Plugin 'connection with server could not be established'

Postby Ian_T » 11 Oct 2017 16:16

Hi Mike,
In answer to your query, I bought a new copy of fh 6.2.2 cd in anticipation of having to clean install
fh again on a new pc h/w + win10 o/s at some stage before 2020 :- as my current win7 pc (which is
running very well since I cloned the Win7 o/s from a HDD to a SSD) self-analyses as not upgradeable
to Win10. And I do not want to start a clean install from my fh4.0.2 install cd (of winXP vintage).

I have tried to refresh the fh 6.2.5 upgrade as per your request; steps as below:-
open browser and navigate to http://www.family-historian.co.uk/downl ... ee-upgrade
click download 6.2.5 upgrade button
saved file 'upgrade_fh6_to_6.2.5_dl.exe' size 21,931KB to download directory on my pc
navigate to windows download directory
right-click file 'upgrade_fh6_to_6.2.5_dl.exe' to run as administrator
click 'next' to all questions
upgrade completed without any reported errors
fh6.2.5 started up by default
open up own user project
select tools->plugins
delete 'improve website or cd dvd html plugin'
plugin deleted ok (& no other plugins remaining)
close own fh project
exit fh application
navigate to hidden windows directory C:\ProgramData\Calico Pie\Plugin Data\
delete 4x improve_***_icon.jpg files + 1x Improve Website or CD DVD HTML.dat file
directory now empty
empty recycle bin
reboot
open my project
Publish -> (re)create my website
Help -> Family Historian on the Web -> Downloads
-> Plugin Store -> 1004 Improve Website or CD HTML 2.9
-> Download -> Open -> Successful Install
Tools -> Plugins -> Improve Website .. -> Run > Select Hyperlinks/Text tab
-> select URL pages options 'In new tab/window' '>30 chars' 'None'
-> click 'Convert' button
-> error messages as before received
++++++++++++++++++++++++++++++++++++++++
COM exception:(.\src\library\tLuaCOM.cpp,394):A connection with the server could not be established
..etc..
++++++++++++++++++++++++++++++++++++++++
windows file navigate to c:\ProgramData\calico Pie\Family Historian\Plugin Data\
only file there is 'Improve Website or CD DVD HTML.dat' size 13 bytes created 11-Oct-2017 16:21 hrs
so copied in 4x *.jpg file from directory Plugin Data OLD
Tools -> Plugins -> Improve Website .. -> Run > Select Hyperlinks/Text tab
-> select URL pages options 'In new tab/window' '>30 chars' 'None'
-> click 'Convert' button
-> incremented through records
-> finished okay
checked website results -> urls shortened and urls opened in new windows okay

No difference, sorry. But I am happy with the Workaround.

Regards, Ian_T
11-Oct-2017

User avatar
tatewise
Megastar
Posts: 14364
Joined: 25 May 2010 11:00
Family Historian: V6.2
Location: Torbay, Devon, UK
Contact:

Re: Plugin 'connection with server could not be established'

Postby tatewise » 11 Oct 2017 16:28

Thank you for trying that, and sorry it made no difference.
I appreciate you are happy with the workaround, but it is annoying the problem cannot be resolved.

Have you used the Plugin Help & Advice button that displays help & advice in another window?
It downloads that help text also from the FHUG Knowledge Base and may suffer the same problem.

BTW: Since FH V5 you can do a clean install from the upgrade versions without needing to install previous versions.
All you need is the latest media and the last two licence keys.
See Knowledge Base > Family Historian Installation Details.
Mike Tate ~ researching the Tate and Scott family history.

Ian_T
Silver
Posts: 6
Joined: 08 Oct 2017 13:07
Family Historian: V6.2

Re: Plugin 'connection with server could not be established'

Postby Ian_T » 12 Oct 2017 18:59

Have tried the 'Help & Advice' button on your Plugin, and it opened up a new Window which displayed correct context help, okay.

So I have been trying to clone your Plugin to try and insert some diagnostic lines around the <http:Open("GET",strSource,false)> area of code.
But I have come to the conclusion that Lua is as confusing to me as C++, so I am admitting defeat at this time ! Sorry.

Will run with the workaround.

Many thanks for your help.
Regards, Ian_T
12-Oct-2017

User avatar
tatewise
Megastar
Posts: 14364
Joined: 25 May 2010 11:00
Family Historian: V6.2
Location: Torbay, Devon, UK
Contact:

Re: Plugin 'connection with server could not be established'

Postby tatewise » 12 Oct 2017 19:20

Ian, given your clear software expertise, I am certain you would soon master Lua.
See the Knowledge Base > Family Historian Plugins Developer Guide.

However, in this case, it is not possible to add diagnostics to the Lua script, because the problem is within the Lua interpreter when handling the Send() function. There must be some glitch in the interpreter to Windows 7 interface that raises the error.

The best that could be achieved is to trap the error, bypass the icon download, and refer the user to a Help & Advice page where the workaround would be documented.
Mike Tate ~ researching the Tate and Scott family history.


Return to “Plugin Discussions”

Who is online

Users browsing this forum: Google [Bot] and 7 guests