04 2021 档案
摘要:自动触发器 Generic Webhook Trigge
        阅读全文
            
摘要:type in msconfig to start System Configuration tool Switch to Tools Tab, and choose Change UAC Settings And finally modify settings by choosing Never 
        阅读全文
            
摘要:getattr class ObjectDict(dict): def __init__(self, *args, **kwargs): super(ObjectDict, self).__init__(*args, **kwargs) def __getattr__(self, name): va
        阅读全文
            
摘要:需要将list以字符串的形式输出,但是list中有不是字符串的情况 ls1 = [1,'ab','cd'] ls2 = [str(i) for i in ls1] # 方法1 ls3 = map(lambda i:str(i), ls1) # 方法2 str_1 = ''.join(ls2) str
        阅读全文
            
摘要:robot中比较难理解的【元类和描述符类】 【重点1】with_metaclass,init,new 【重点2】get,set with_metaclass见如下文章: https://stackoverflow.com/questions/18513821/python-metaclass-und
        阅读全文
            
摘要:基础 class C(object): @staticmethod def f(): print('runoob'); C.f(); # 静态方法无需实例化 cobj = C() cobj.f() # 也可以实例化后调用 进阶【staticmethod 参数要求是 Callable, 也就是说 Cl
        阅读全文
            
摘要:bool,len__和bool相关,在if中会被调用,优先调用__bool,没有就调用__len__ class Test: def __bool__(self): print('__bool__') return False def __len__(self): print('__len__') 
        阅读全文
            
摘要:import os import sys JYTHON = sys.platform.startswith('java') IRONPYTHON = sys.platform == 'cli' PYPY = 'PyPy' in sys.version PYTHON = not (JYTHON or 
        阅读全文
            
摘要:使用next() def foo(): print("starting...") while True: res = yield 4 # yield 在等式的右边,执行完就返回了,没有进行赋值 ;类似于 a = return 1【return这样用非法】,a 是NONE print("res:",r
        阅读全文
            
摘要:sys.exc_info() 获取异常 import sys try: raise ValueError('this is a exp') except Exception as ex: ex_type, ex_val, ex_stack = sys.exc_info() print(ex_type
        阅读全文
            
摘要:def _split_camel_case(string): tokens = [] token = [] for prev, char, next in zip(' ' + string, string, string[1:] + ' '): print(prev, char, next) if 
        阅读全文
            
摘要:import sys from collections import MutableMapping from .platform import PY3, IRONPYTHON from .robottypes import is_dict_like, is_unicode def normalize
        阅读全文
            
摘要:robot中的timestamp的概念 20210406-104142.897 字符串类型 源码 import time import sys IRONPYTHON = sys.platform == 'cli' def is_number(item): return isinstance(item
        阅读全文
            
摘要:定义 if PY2: # io.StringIO only accepts u'foo' with Python 2. from StringIO import StringIO def py2to3(cls): if hasattr(cls, '__unicode__'): cls.__str__
        阅读全文
            
摘要:https://mp.weixin.qq.com/s/ZnBzGL3wlWIVONrUV7_EPQ Echarts # 1. from django.http import JsonResponse from django.shortcuts import render def index_view
        阅读全文
            
摘要:def 函数定义不会执行里面的语句 class 类的定义会执行里面的语句 def test_func(): print("test_func") # 不会执行 class setter(object): def __init__(self, method): self.method = method
        阅读全文
            
摘要:分类 在变量、方法命名中有下列几种情况: 0. xx 公有变量/方法 1. _xx 前置单下划线 2. __xx 前置双下划线 3. __xx__ 前后双下划线 4. xx_ 后置单下划线 结论 1. _名 的变量、函数、类在使用 from xxx import * 时都不会被导入。 2. __名字
        阅读全文
            
摘要:https://www.cnblogs.com/liaohuiqiang/p/7247393.html 概述 # 1 # coding:utf-8 # 开头的encoding是对于文件内容的编码 # 2 import sys reload(sys) sys.setdefaultencoding('u
        阅读全文
            
摘要:https://zhuanlan.zhihu.com/p/88048361 https://pythonav.com/wiki/detail/6/88/
        阅读全文
            
摘要:* C&M plane:控制和管理数据流,用于节点的操作,管理和维护。 * User Plane: User Plane涵盖下面三个数据流: * a)	数据流将从无线电基站传输到用户设备(UE),反之亦然。 * b)	与a)相关的实时控制数据。 * c)	其他协议平面/流 未涵盖的其他eCPRI流。
        阅读全文
            
摘要:https://mp.weixin.qq.com/s/FjR0K5LGKoLHi4JsRqj02A https://pythonav.com/wiki/detail/6/88/ Python的赋值语句:a=1 整数1为一个对象。而a是一个引用。利用赋值语句,引用a指向对象1。Python是动态类型的
        阅读全文
            
浙公网安备 33010602011771号