问题标签 [pythomnic3k]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
1 回答
118 浏览

python - 使用 Pythomnic3k 和 OpenSLL

我需要制作一个可以通过 SMPP 协议发送消息的客户端脚本。所以,到目前为止,我已经开始使用 Pythomnic3k。在设置的一部分中,您需要安装以下内容:

现在,我知道该怎么做。我需要下载还是需要下载 Python 3 的特殊版本。另外,我当前安装的版本是 3.3.2,这是否与使用3.2 版pyOpenSSLWindows的 PyOpenSSL 库兼容?

0 投票
1 回答
8904 浏览

python - AttributeError:'function'对象没有属性'get'

下午好,

  1. 我正在使用 pythomnic3k python 框架和分片 solr、redis 数据库服务器。

    以下是我的 api 请求:

    http://1.2.3.4:8090/api20/account2/addnewemail?Email=foo@yahoo.com&Token=[redacted]&AccountID=[redacted]

    错误:AttributeError: 'function' object has no attribute 'get'

  2. 出现此错误的函数:

    r 是 redis 实例和Namespance.Mappings + ':count' = ytk:map:count

  3. solr schema xml 文件有这些分片实例:

    /li>
  1. Redis 实例 r 在 redis_utils.py

    /li>
  2. 这是count_maps(r)在 solr_manager.py 中调用的函数:

    • 我了解这个 redis 对象尝试计算 solr 实例,对吗?

    • 请帮助我解决我的 redis 对象为 None 的可能原因?我检查了我的日志相同的“获取属性..”错误并且无法调试它。

0 投票
3 回答
37 浏览

python - TypeError:“列表”对象不可调用,最大成对积

当我运行这个函数时,我得到这个错误,我不知道问题出在哪里?

0 投票
0 回答
45 浏览

pythomnic3k - AttributeError:“time.struct_time”对象没有属性“perf_counter”

从时间导入 perf_counter 导入时间

xg_cl = XGBClassifier(n_estimators=70)

time = time.localtime(time.time()) training_start = time.perf_counter()

xg_cl.fit(X_train, y_train) training_end = time.perf_counter()

prediction_start = time.perf_counter()

preds = xg_cl.predict(X_test)

prediction_end = time.perf_counter()

acc_xg_cl = (preds == y_test).sum().astype(float) / len(preds)*70

xg_cl_train_time = training_end-training_start

xg_cl_prediction_time = prediction_end-prediction_start

print("训练所用时间:%4.3f" % (xgb_train_time))

print("预测耗时:%6.5f 秒" % (xg_cl_prediction_time))

运行代码,我得到了这个错误

AttributeError:“time.struct_time”对象没有属性“perf_counter”

0 投票
2 回答
210 浏览

renpy - “没有名为集合的模块”ren'py

好的,我正在翻译一个游戏,一部名为“katawa shoujo”的视觉小说,确切地说是该游戏的测试版,它不是西班牙语的我得到了测试版文件并将它们移动到 ren'py(它的创建位置)在 ren'py 中运行它时出现此错误: