上一页 1 2 3 4 5 6 7 8 ··· 17 下一页
摘要: # coding:UTF-8import time# 获取当前时间time_now = int(time.time())# 转换成localtimetime_local = time.localtime(time_now)# 转换成新的时间格式(2016-05-09 18:59:20)dt = ti 阅读全文
posted @ 2020-02-04 21:52 知一以天 阅读(170) 评论(0) 推荐(0) 编辑
摘要: datetime的解决办法混合数据的表中有个日期:2016/9/18 通过table.row_values(row_number)[1]读取时,显示的结果为:42631.0 查看row_values方法的源码: def row_values(self, rowx, start_colx=0, end 阅读全文
posted @ 2020-02-04 21:50 知一以天 阅读(573) 评论(0) 推荐(0) 编辑
摘要: Python中super的用法【转载】 转载dxk_093812 最后发布于2019-02-17 20:12:18 阅读数 1143 收藏 展开 转载自 Python面向对象中super用法与MRO机制 1、 引言 最近在研究django rest_framework的源码,老是遇到super,搞得 阅读全文
posted @ 2020-02-04 21:47 知一以天 阅读(171) 评论(0) 推荐(0) 编辑
摘要: python类的继承和多态 现在属于是老年人的脑子,东西写着写着就忘了,东西记着记着就不知道了。之前学C++的时候就把类、对象这块弄得乱七八糟,现在是因为很想玩python,所以就看看python的类和对象。 就像说的,类有三个特征:封装、继承、多态。 1、封装:类封装了一些方法,可通过一定的规则约 阅读全文
posted @ 2020-02-04 21:45 知一以天 阅读(981) 评论(0) 推荐(0) 编辑
摘要: import os def check_filename_available(filename): n=[0] def check_meta(file_name): file_name_new=file_name if os.path.isfile(file_name): file_name_new 阅读全文
posted @ 2020-02-04 21:05 知一以天 阅读(136) 评论(0) 推荐(0) 编辑
摘要: 安装pip install C:\Users\道路\Documents\EGDownloads\pip-1.0.tar.gz 报错:Consider using the `--user` option or check the permissions. 解决:pip install --user C 阅读全文
posted @ 2020-02-04 14:18 知一以天 阅读(3146) 评论(0) 推荐(0) 编辑
摘要: pip._vendor.urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='files.pythonhosted.org', port=443): Read timed out. 上官瑾文 2018-07-26 14:57:3 阅读全文
posted @ 2020-02-03 23:21 知一以天 阅读(450) 评论(0) 推荐(0) 编辑
摘要: import tkinter import time import threading from tkinter import ttk event = threading.Event() once=0 def start(): global once if once==1: # event.set( 阅读全文
posted @ 2020-02-03 14:50 知一以天 阅读(1608) 评论(0) 推荐(0) 编辑
摘要: tkinter界面卡死的解决办法 1、如果点击按钮,运行了一个比较耗时的操作,那么界面会卡死 import tkinter as tk import time def onclick(text, i): time.sleep(3) text.insert(tk.END, '按了第{}个按钮\n'.f 阅读全文
posted @ 2020-02-03 12:31 知一以天 阅读(553) 评论(1) 推荐(0) 编辑
摘要: # !/usr/bin/env python # -*-coding:utf-8-*- """ @Author : xiaofeng @Time : 2018/12/25 10:26 @Desc : Less interests,More interest. @Project : python_ap 阅读全文
posted @ 2020-02-02 21:53 知一以天 阅读(230) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 ··· 17 下一页