Получение аудиозаписей из поста пользователя или сообщества#323
Merged
python273 merged 5 commits intopython273:masterfrom Jan 4, 2020
qwertyadrian:master
Merged
Получение аудиозаписей из поста пользователя или сообщества#323python273 merged 5 commits intopython273:masterfrom qwertyadrian:master
python273 merged 5 commits intopython273:masterfrom
qwertyadrian:master
Conversation
Updated VkApi.http.cookies for audio parsing in posts
python273
requested changes
Dec 24, 2019
| link = bs.select_one('.ai_body input[type=hidden]').attrs['value'] | ||
| return decode_audio_url(link, self.user_id) | ||
|
|
||
| def get_wall_audio(self, owner_id, wall_id): |
Owner
There was a problem hiding this comment.
ну post тут больше подходит, wall это если бы со стены
Contributor
Author
There was a problem hiding this comment.
Тогда я верну прежнее имя метода:
Suggested change
| def get_wall_audio(self, owner_id, wall_id): | |
| def get_post_audio(self, owner_id, post_id): |
Comment on lines
+114
to
+116
| self.http.cookies.update({ | ||
| 'remixmdevice': '1920/1080/1/!!-!!!!' | ||
| }) |
Owner
There was a problem hiding this comment.
Видимо оно не работает если: нет сохраненных кук, вызывается auth, получены новые куки, вызывается get_wall_audio. Думаю стоит в VkAudio копировать сессию и там ставить куки
Contributor
Author
There was a problem hiding this comment.
Я думаю тогда вставку куки в VkAudio.__init__ делать.
Moved cookie insert from VkApi.__init__ in VkAudio.__init__
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Подробнее в #157