Parcourir la source

string from URF-8 encoded files have not the "unicode" type

develop^2
Zykino il y a 5 ans
Parent
révision
f66ba6cc21
2 fichiers modifiés avec 5 ajouts et 4 suppressions
  1. +2
    -1
      README.md
  2. +3
    -3
      prismedia_upload.py

+ 2
- 1
README.md Voir le fichier

@ -98,7 +98,8 @@ Options:
--disable-comments Disable comments (Peertube only as YT API does not support) (default: comments are enabled)
--nsfw Set the video as No Safe For Work (Peertube only as YT API does not support) (default: video is safe)
--nfo=STRING Configure a specific nfo file to set options for the video.
By default Prismedia search a .txt based on video name
By default Prismedia search a .txt based on the video name and will
decode the file as UTF-8 (so make sure your nfo file is UTF-8 encoded)
See nfo_example.txt for more details
--platform=STRING List of platform(s) to upload to, comma separated.
Supported platforms are youtube and peertube (default is both)

+ 3
- 3
prismedia_upload.py Voir le fichier

@ -167,17 +167,17 @@ if __name__ == '__main__':
schema = Schema({
'--file': And(str, validateVideo, error='file is not supported, please use mp4'),
Optional('--name'): Or(None, And(
unicode,
basestring,
lambda x: not x.isdigit(),
error="The video name should be a string")
),
Optional('--description'): Or(None, And(
unicode,
basestring,
lambda x: not x.isdigit(),
error="The video description should be a string")
),
Optional('--tags'): Or(None, And(
unicode,
basestring,
lambda x: not x.isdigit(),
error="Tags should be a string")
),

Chargement…
Annuler
Enregistrer