Private GIT
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
CouchPotatoServer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
vlbox
CouchPotatoServer
Commits
6bed7978
Commit
6bed7978
authored
12 years ago
by
brinbois
Browse files
Options
Downloads
Patches
Plain Diff
Manual Download patch
parent
06d37bf6
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
couchpotato/core/providers/torrent/cPASbien/main.py
+17
-1
17 additions, 1 deletion
couchpotato/core/providers/torrent/cPASbien/main.py
couchpotato/core/providers/torrent/t411/main.py
+20
-1
20 additions, 1 deletion
couchpotato/core/providers/torrent/t411/main.py
with
37 additions
and
2 deletions
couchpotato/core/providers/torrent/cPASbien/main.py
+
17
−
1
View file @
6bed7978
...
@@ -238,4 +238,20 @@ class cPASbien(TorrentProvider):
...
@@ -238,4 +238,20 @@ class cPASbien(TorrentProvider):
except
:
except
:
log
.
error
(
'
Failed downloading from %s: %s
'
,
(
self
.
getName
(),
traceback
.
format_exc
()))
log
.
error
(
'
Failed downloading from %s: %s
'
,
(
self
.
getName
(),
traceback
.
format_exc
()))
def
download
(
self
,
url
=
''
,
nzb_id
=
''
):
if
not
self
.
login_opener
and
not
self
.
login
():
return
values
=
{
'
url
'
:
'
/
'
}
data_tmp
=
urllib
.
urlencode
(
values
)
req
=
urllib2
.
Request
(
url
,
data_tmp
)
try
:
log
.
error
(
'
Failed downloading from %s
'
,
self
.
getName
())
return
urllib2
.
urlopen
(
req
).
read
()
except
:
log
.
error
(
'
Failed downloading from %s: %s
'
,
(
self
.
getName
(),
traceback
.
format_exc
()))
\ No newline at end of file
This diff is collapsed.
Click to expand it.
couchpotato/core/providers/torrent/t411/main.py
+
20
−
1
View file @
6bed7978
...
@@ -12,6 +12,7 @@ import re
...
@@ -12,6 +12,7 @@ import re
import
time
import
time
import
traceback
import
traceback
import
urllib2
import
urllib2
import
urllib
import
unicodedata
import
unicodedata
log
=
CPLog
(
__name__
)
log
=
CPLog
(
__name__
)
...
@@ -184,3 +185,21 @@ class t411(TorrentProvider):
...
@@ -184,3 +185,21 @@ class t411(TorrentProvider):
'
remember
'
:
'
1
'
,
'
remember
'
:
'
1
'
,
'
url
'
:
'
/
'
'
url
'
:
'
/
'
})
})
def
download
(
self
,
url
=
''
,
nzb_id
=
''
):
if
not
self
.
login_opener
and
not
self
.
login
():
return
values
=
{
'
url
'
:
'
/
'
}
data_tmp
=
urllib
.
urlencode
(
values
)
req
=
urllib2
.
Request
(
url
,
data_tmp
)
try
:
log
.
error
(
'
Failed downloading from %s
'
,
self
.
getName
())
return
urllib2
.
urlopen
(
req
).
read
()
except
:
log
.
error
(
'
Failed downloading from %s: %s
'
,
(
self
.
getName
(),
traceback
.
format_exc
()))
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment