Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

core: refactor http webclient part 17 #8529 #9589

Merged
merged 1 commit into from
Sep 22, 2020

Conversation

ngosang
Copy link
Member

@ngosang ngosang commented Sep 21, 2020

Print HTML in debug mode. Fix bugs in old implementation too

@ngosang
Copy link
Member Author

ngosang commented Sep 21, 2020

@garfield69 @ilike2burnthing This is working. The only concern is I'm printing the binary responses too (eg .torrent files) because it's really hard to know if the content is binary or plain text. In my Linux this is working fine. Could you try this PR in Windows downloading a .torrent in debug mode? I tried with yourbittorrent indexer.
If this is working for you, you can merge.

@ngosang
Copy link
Member Author

ngosang commented Sep 21, 2020

Wait

@ilike2burnthing
Copy link
Contributor

Yea, working in Windows. Only side effect is:

WebClient(HttpWebClient2).GetResultAsync(Method: GET Url: https://yourbittorrent.com/down/29978989.torrent)
WebClient(HttpWebClient2): Returning OK => 23138 bytes
d8:announce43:udp://tracker.coppersurfer.tk:6969/announce13:announce-listll43:udp://tracker.coppersurfer.tk:6969/announceel49:udp://tracker.leechers-paradise.org:6969/announceel38:udp://tracker.cyberia.is:6969/announceel41:udp://tracker.iamhansen.xyz:2000/announceel35:udp://p4p.arenabg.com:1337/announceel32:udp://explodie.org:6969/announceel42:udp://tracker.opentrackr.org:1337/announceel40:udp://tracker.tiny-vps.com:6969/announceel37:udp://exodus.desync.com:6969/announceel41:udp://tracker.torrent.eu.org:451/announceel38:udp://tracker.moeking.me:6969/announceel39:udp://ipv4.tracker.harry.lu:80/announceel33:udp://open.stealth.si:80/announceel30:udp://9.rarbg.to:2710/announceel31:udp://opentor.org:2710/announceel48:udp://tracker.internetwarriors.net:1337/announceel49:udp://tracker.leechers-paradise.org:6969/announceel43:udp://tracker.coppersurfer.tk:6969/announceel42:udp://tracker.pirateparty.gr:6969/announceel38:udp://tracker.cyberia.is:6969/announceel35:udp://open.demonii.si:1337/announceel30:udp://open.stealth.si/announceel37:udp://exodus.desync.com:6969/announceel33:http://explodie.org:6969/announceel30:udp://9.rarbg.me:2740/announceel30:udp://9.rarbg.to:2790/announceee7:comment31:Torrent from yourbittorrent.com10:created by13:mktorrent 1.113:creation datei1600720043e4:infod5:filesld6:lengthi1125765616e4:pathl59:The.72nd.Annual.Primetime.Emmy.Awards.2020.WEB.h264-BAE.mkveed6:lengthi678e4:pathl42:[TGx]Downloaded from torrentgalaxy.to .txteed6:lengthi73e4:pathl59:the.72nd.annual.primetime.emmy.awards.2020.web.h264-bae.nfoeee4:name60:The.72nd.Annual.Primetime.Emmy.Awards.2020.WEB.h264-BAE[TGx]12:piece lengthi1048576e6:pieces21480:�Ie��[H�&�����	��U
�V�EZ��I�"�$^�|���Qe�uw��g������C�� �����sq�R��¦������N+�]���1��,������F�������Y�7����wN|��l��T����
uG#v�����y�ӝD�,m��iD@�cy�䅰�j��p������l��U�\E��;1�*��Д���f_��]c�j�'���������_LE��`�Gهsp�����G����㎏�����4/��\�3ػH��'Х��Ĭ~�JC6 �e}V��z�9
���ik20`�L�vj�5���)ˍ�BZ��*L�����k����Z �S�k�%34/i>n���4x�D^$�x���7ɾs|f�|�_�`�-C?1��F�*��R���;�[e�.������4�H;���@+�:�M�O��$Փ@�e�Ѓō����ző�2������0��qR���*�
����.'�'�A��8�suD���3!�K:�5��
�/Xb
[...and on and on and on...]
Executing {FileResultType}, sending file with download name '{FileDownloadName}' ...
The file result has not been enabled for processing range requests. To enable it, set the property 'EnableRangeProcessing' on the result to 'true'.
Response compression is not enabled for the Content-Type '{header}'.

Print HTML in debug mode. Fix bugs in old implementation too
@ngosang
Copy link
Member Author

ngosang commented Sep 21, 2020

The only concern is I'm printing the binary responses too (eg .torrent files) because it's really hard to know if the content is binary or plain text.

Fixed. Do some tests and merge.

@ilike2burnthing
Copy link
Contributor

Works here

Copy link
Contributor

@garfield69 garfield69 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fantastic improvement to the debug html dump
at last I get to see output from the post to a thankyou before download!
tested on win10home.

@garfield69 garfield69 merged commit 24bffe9 into Jackett:master Sep 22, 2020
@ngosang ngosang deleted the feature/debuglog branch December 20, 2020 19:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants