luckyy
V2EX  ›  问与答

Python 自定义命令 BaseCommand 提示: Using proactor: IocpProactor

  •  
  •   luckyy · Aug 18, 2020 · 1832 views
    This topic created in 2105 days ago, the information mentioned may be changed or developed.

    class Command(BaseCommand): def handle(self, *args, **options): with open('user.json', 'a', encoding='utf-8') as f: f.write(json.dumps({'name': name, 'phone': phone, 'sex': sex_code[sex], 'birthday': birthday, 'profession': profession_code[profession], 'region': region.code, 'corporation_type': corporation_code[corporation_type], 'corporation': corporation, 'title': title_code[title] }, ensure_ascii=False) + '\n')

    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   890 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 23ms · UTC 19:51 · PVG 03:51 · LAX 12:51 · JFK 15:51
    ♥ Do have faith in what you're doing.