installation pyenv on Mac 1. 2. 3.
first line second line
This file contains 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
s3_client.upload_fileobj(file_obj.file._file, bucket, f'{object_name}') |
This file contains 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
1. Docker | |
2. Kubernetis | |
3. Base of DS | |
4. Sockets and network understanding.(https://www.amazon.com/Learn-PYTHON-Multiplayer-Adventure-Games/dp/B01ETTRZ3M) | |
5. Async python | |
6. Create custom descriptor. @property. |
This file contains 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
# parameterize decorator | |
def args_info():pass | |
@args_info(all_values=False) | |
def power(n:int, pwr: int) -> int: | |
"""Put in the power""" | |
return n**pwr | |
# >>> power(2, 4) |
This file contains 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
python installation custom. | |
a. create custom short path | |
b. update PATH | |
After Pycharm installation | |
a. by admin run WindowsPowerShell | |
PS C:\WINDOWS\system32> Get-ExecutionPolicy | |
Restricted | |
PS C:\WINDOWS\system32> Set-ExecutionPolicy remotesigned | |
RemoteSigned | |
b.delete venv folder during creating new project. Because new venv will not created. |
This file contains 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
"""serializers""" | |
import logging | |
from collections import Mapping, OrderedDict | |
from typing import Dict | |
from django.core.exceptions import ValidationError as DjangoValidationError | |
from rest_framework import serializers | |
from rest_framework.exceptions import ValidationError | |
from rest_framework.fields import get_error_detail, set_value, SkipField | |
from rest_framework.settings import api_settings |
Собираем то, что нас спрашивали. https://ccbv.co.uk/projects/Django/3.0/django.views.generic.edit/DeleteView/ Рекомендую к просмотру: - книжечка по типам питона: https://book.pythontips.com/en/latest/ -чистый код Книга
- Що почитати по чистому python: Mark Lutz: Learning Python David Beazley & Brian K. Jones: Python Cookbook
This file contains 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
import logging.config | |
LOGGING_CONFIG = None | |
LOGGING = { | |
'version': 1, | |
'disable_existing_loggers': False, | |
'handlers': { | |
'console': { | |
'class': 'logging.StreamHandler', | |
'formatter': 'file_format', |