hungdluit / flowlib

Automatically exported from code.google.com/p/flowlib
0 stars 0 forks source link

Filelist download error #48

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Use the attached code with r563
2. Connect to opendchub
3. Request user filelist

What is the expected output?
Downloaded filelist

What do you see instead?
Error

What version of the product are you using? 
r563

On what operating system?
Fedora 15 x64

Call Stack? (Console output)
bofh tool
OUT: HSUP ADBAS0 ADBASE ADTIGR

IN: $Lock Sending_key_isn't_neccessary,_key_won't_be_checked. Pk=Same_goes_here.
OUT: $Supports NoHello NoGetINFO |
OUT: $Key 
Ác° ÐpƒCàÁbc¡Ñ”5²°/%DCN096%//%DCN000%//%DCN096%/a/%DCN000%/!1°U
7CàÁb‚”5²Óp£Ã°Ð/%DCN096%/€à¤|
OUT: $ValidateNick FlowLib|
IN: $HubName Open DC Hub
IN: <Hub-Security> This hub is running version 0.8.2 of Open DC Hub.
IN: $Hello FlowLib
OUT: $Version 1.0091|
OUT: $GetNickList|
OUT: $MyINFO $ALL FlowLib <FlowLib,M:A,H:1/0/0,S:0>$ $$$0$|
IN: Welcome to the hub. Enjoy your stay.
IN: $NickList FlowLib$$bofh$$
IN: 
IN: $OpList 
IN: 
IN: $MyINFO $ALL FlowLib <FlowLib,M:A,H:1/0/0,S:0>$ $$$0$
OUT: $ConnectToMe bofh 127.0.0.1:12345|
DIS:127.0.0.146099FlowLib.Utils.FmdcException: Exception of type 
'FlowLib.Utils.FmdcException' was thrown.
action=21 data=bofh

Original issue reported on code.google.com by stephenc...@gmail.com on 20 Sep 2011 at 6:50

Attachments:

GoogleCodeExporter commented 8 years ago
To have more to go on you will have to listen on the event:
trans.ConnectionStatusChange.
event.Data will contain a FmdcException with more information about the error.

Or you could change the code in function "trans_ConnectionStatusChange" in 
class: "TransferManager" so it will give you more information about the 
exception.

Let me know what turns up.

Original comment by blomman84 on 20 Sep 2011 at 7:33

GoogleCodeExporter commented 8 years ago
The e.data on that event only has "Exception of type 
'FlowLib.Utils.FmdcException' was thrown."

But if I change this code:
ContentInfo info = new ContentInfo(ContentInfo.FILELIST, BaseFilelist.UNKNOWN);
                            info.Set(ContentInfo.STORAGEPATH, currentDir + "Filelists\\" + usr.ID + ".filelist");
                            downloadManager.AddDownload(new DownloadItem(info), new Source(hub.RemoteAddress.ToString(), usr.ID));

to this:
ontentInfo info = new ContentInfo(ContentInfo.FILELIST, BaseFilelist.XMLBZ);
                        string id = FlowLib.Utils.Convert.Base32.Encode(System.Text.Encoding.UTF8.GetBytes(usr.StoreID.ToLower().Trim()));
                        info.Set(ContentInfo.STORAGEPATH, "filelists" + System.IO.Path.DirectorySeparatorChar + id + ".filelist");
                        info.Set("USR", usr.ID);
                        info.Set("FUNC", "cd");
                        downloadManager.AddDownload(new DownloadItem(info), new Source(hub.HubSetting.Address + hub.HubSetting.Port, usr.StoreID));

It downloads and gets an inactivity exception.

Original comment by stephenc...@gmail.com on 21 Sep 2011 at 5:53

GoogleCodeExporter commented 8 years ago
I get the same with verlihub 1.0.0:

IN: $Lock EXTENDEDPROTOCOL_verlihub Pk=version1.0.0
OUT: $Supports NoHello NoGetINFO |
OUT: $Key uÑÀ° A ѱ±ÀÀ01’1qáPÑq|
OUT: $ValidateNick FlowLib|
IN: <VerliHub> This hub is running version 1.0.0 (lun lug 18 2011) of VerliHub 
(RunTime: 12 mins 57 secs  / User count: 1)
IN: $Supports OpPlus NoGetINFO NoHello UserIP2 HubINFO ZPipe
IN: $HubName hub
IN: $Hello FlowLib
OUT: $Version 1.0091|
OUT: $GetNickList|
OUT: $MyINFO $ALL FlowLib <ArpmanetBot V:1,M:A,H:1/0/0,S:2>$ $$$0$|
IN: $MyINFO $ALL VerliHub Hub-Security for broadcasting messages$ $ $$0$
IN: $MyINFO $ALL OpChat Operator chat - only for OPs$ $ $$0$
IN: $MyINFO $ALL bofh <++ V:0.698,M:A,H:1/0/0,S:5>$ $100$$193501733844$
IN: 
IN: <MOTD> 
This file contains the text that will be displayed to users upon entering the 
hub.
Change it to suit your needs or use the file trigger definition to store your 
motd.

Welcome to VerliHub

+rules      -- Display a list of hub rules.
+faq        -- Display a list of helpful links if you are having trouble.
+motd       -- Display this message.
+help       -- Display a list of all available commands to you.

Some usefull links for you:

* Verlihub homepage: http://www.verlihub-project.org
* Verlihub forums: http://www.verlihub-project.org/discussions
* Verlihub manual: http://www.verlihub-project.org/page

IN: $HubTopic 
IN: <VerliHub> 
[::] Your info: 
[*] Nickname                 FlowLib [GUEST]
[*] IP                       127.0.0.1
[*] Country Code             --

IN: $OpList VerliHub$$OpChat$$
IN: $MyINFO $ALL FlowLib <ArpmanetBot V:1,M:A,H:1/0/0,S:2>$ $$$0$
OUT: $ConnectToMe bofh 127.0.0.1:12345|
    File:0, 65536/102458
    File:0, 36922/102458
DIS:127.0.0.143888FlowLib.Utils.FmdcException: Inactivity

Original comment by stephenc...@gmail.com on 21 Sep 2011 at 6:34

GoogleCodeExporter commented 8 years ago
Is the filelist that is downloaded complete?
Can you open it and see what files that was shared?

If the answer is * yes* to the above questions, everything is as it should be.
If there is no activity on the connection for X seconds it will be terminated.

Original comment by blomman84 on 23 Sep 2011 at 10:01

GoogleCodeExporter commented 8 years ago
Attached the downloaded filelist.

Original comment by stephenc...@gmail.com on 24 Sep 2011 at 9:56

Attachments:

GoogleCodeExporter commented 8 years ago
Sorry for being away for a while.
Well, I can't open that filelist..

Have you tried to connect to the latest dc++ version?
Have you tried the Passive examples? How did that work?

Original comment by blomman84 on 13 Oct 2011 at 6:47