Replace double-width parentheses "()" to single-width parentheses "()" of sheet's names.
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
from logging import getLogger | |
import pandas as pd | |
from core.db import get_new_user_id | |
from user_management import tasks # celery tasks | |
logger = getLogger(__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
""" | |
https://docs.python.org/3/library/abc.html | |
https://qiita.com/kaneshin/items/269bc5f156d86f8a91c4 | |
https://stackoverflow.com/questions/13646245/is-it-possible-to-make-abstract-classes-in-python | |
https://docs.djangoproject.com/en/2.1/topics/db/models/ | |
https://stackoverflow.com/questions/33335005/is-there-any-difference-between-using-abc-vs-abcmeta | |
""" | |
from abc import ABC |
def greeting(user_id):
"""Parent func"""
try:
user_name = get_user_name(user_id)
except User.DoesNotExists as e:
logger.error("[greeting] user: {user_id} not found.")
return None
print(f"Hello, {user_name}")
$ sudo -u postgres psql postgres
$ ssh -L 6432:localhost:5432 remote-server
$ pg_dump -Fc -U username -p 6432 -h localhost dbname > dbname.dump
$ pg_restore -h localhost -p 6432 -U username -d dbname dbname.dump
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
If this error cause, | |
``` | |
Received disconnect from UNKNOWN port 65535:2: Too many authentication failures | |
Disconnected from UNKNOWN port 65535 | |
``` | |
``` | |
$ ssh host-name -o 'IdentitiesOnly yes' | |
``` |
- I want uninstall Java 1.6 which is downloaded from https://support.apple.com/kb/DL1572?locale=en_US.
$ sudo rm -fr /Library/Internet\ Plug-Ins/JavaAppletPlugin.plugin
$ sudo rm -fr /Library/PreferencePanes/JavaControlPanel.prefpane
$ sudo rm -rf /Library/Java/JavaVirtualMachines/1.6.0.jdk
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
from third_party_lib import make_service, make_credentials | |
class MyClass(object): | |
@classmethod | |
def from_json(cls, json): | |
credentials = make_credentials(json) | |
return cls(credentials) |