Comments (17)
麻烦发一下客户端输出的完整日志,我们分析一下哈
from codeanalysis.
麻烦发一下客户端输出的完整日志,我们分析一下哈
在哪里呀
from codeanalysis.
可以把最后一行正常日志以及完整的异常堆栈都截一下图
from codeanalysis.
把最后一行正常日志
2022-01-10 09:53:36,493-INFO-util.logutil: Tencent Cloud Code Analysis (OpenSource Beta)
2022-01-10 09:53:36,505-INFO-util.logutil: ------------------------------
2022-01-10 09:53:36,505-INFO-util.logutil: ####### #### #
2022-01-10 09:53:36,506-INFO-util.logutil: # # # #
2022-01-10 09:53:36,506-INFO-util.logutil: # # ###
2022-01-10 09:53:36,506-INFO-util.logutil: # # # #
2022-01-10 09:53:36,506-INFO-util.logutil: # # #####
2022-01-10 09:53:36,506-INFO-util.logutil: # # # # #
2022-01-10 09:53:36,506-INFO-util.logutil: # #### ## ##
2022-01-10 09:53:36,507-INFO-util.logutil: ------------------------------
2022-01-10 09:53:36,829-INFO-util.logutil: using config file: /home/test/CodeAnalysis/client/codedog.ini
2022-01-10 09:53:36,833-INFO-util.logutil: connect to server: http://192.168.7.244:88/
2022-01-10 09:53:37,738-INFO-util.logutil: scan plan(默认) already exists: http://192.168.7.244:88/t/UGCRO9Lf4U/p/test/code-analysis/repos/1/schemes/1/basic
2022-01-10 09:53:37,835-INFO-util.logutil: Use the already existed project(id: 1).
2022-01-10 09:53:38,367-INFO-util.logutil: Project url: http://192.168.7.244:88/t/UGCRO9Lf4U/p/test/code-analysis/repos/1/projects/1/overview
2022-01-10 09:53:39,008-INFO-util.logutil: Job starts ...
2022-01-10 09:53:39,044-INFO-util.logutil: Initing 10 tools, please wait a minute ...
[Tools init]: 100%|██████████████████████████████████████████████| 10/10 [00:00<00:00, 52167.96it/s]
2022-01-10 09:53:39,052-INFO-util.logutil: Initialize tools done.(use time: 0.01s)
2022-01-10 09:53:39,277-INFO-util.logutil: run cmd: ['python3', '-m', 'flake8', '--version']
2022-01-10 09:53:39,353-INFO-util.logutil: /usr/local/bin/python3: No module named flake8
2022-01-10 09:53:39,378-INFO-util.logutil: 建议客户本地安装flake8工具,安装命令:pip install flake8 && pip install flake8-json
2022-01-10 09:53:39,379-INFO-util.logutil: 正在启用CodeDog内置的Python环境
2022-01-10 09:53:39,481-INFO-util.logutil: run cmd: ['python3', '-m', 'flake8', '--version']
2022-01-10 09:53:39,854-INFO-util.logutil: 3.7.9 (mccabe: 0.6.1, pycodestyle: 2.5.0, pyflakes: 2.1.1) CPython 3.7.2 on Linux
2022-01-10 09:53:40,096-INFO-util.logutil: run cmd: ['python3', '-m', 'pylint', '--version']
2022-01-10 09:53:41,124-INFO-util.logutil: pylint 2.6.0
2022-01-10 09:53:41,125-INFO-util.logutil: astroid 2.5
2022-01-10 09:53:41,125-INFO-util.logutil: Python 3.7.0 (default, Jan 6 2022, 15:33:43)
2022-01-10 09:53:41,125-INFO-util.logutil: [GCC 4.8.5 20150623 (Red Hat 4.8.5-44)]
2022-01-10 09:53:41,510-INFO-util.logutil: Start to count code lines...
2022-01-10 09:53:41,512-INFO-util.logutil: Codemetric only scans main code (exclude test_source, auto_generate_source, third_party_source).
2022-01-10 09:53:41,513-INFO-util.logutil: Codelint only cans main code.
2022-01-10 09:53:41,576-INFO-util.logutil: [文件数]过滤前:181,过滤后:133
2022-01-10 09:53:41,577-INFO-util.logutil: ['/home/test/CodeAnalysis/client/data/tools/linux-scc/scc', '--by-file', '-c', '--no-cocomo', '-f', 'json', '-o', '/home/test/CodeAnalysis/client/data/taskdirs/task_95/scc_result_22f0de5071b811eca860002277c9372e.json', '/tmp/mini-shop-server']
2022-01-10 09:53:41,649-INFO-util.logutil: results written to /home/test/CodeAnalysis/client/data/taskdirs/task_95/scc_result_22f0de5071b811eca860002277c9372e.json
2022-01-10 09:53:41,658-INFO-util.logutil: Task_95 (Flake8) starts ...
2022-01-10 09:53:51,770-INFO-util.logutil: Task_95 is done.
2022-01-10 09:53:51,817-ERROR-util.wrapper: method(upload_file) call fails on error: Expecting value: line 1 column 1 (char 0)
2022-01-10 09:53:51,817-INFO-util.wrapper: retrying method(upload_file) after 5 seconds
2022-01-10 09:53:56,826-ERROR-util.wrapper: method(upload_file) call fails on error: Expecting value: line 1 column 1 (char 0)
2022-01-10 09:53:56,826-INFO-util.wrapper: retrying method(upload_file) after 5 seconds
2022-01-10 09:54:01,835-ERROR-util.wrapper: method(upload_file) call fails on error: Expecting value: line 1 column 1 (char 0)
2022-01-10 09:54:01,835-WARNING-util.wrapper: method(upload_file) call still fails after 2 retries
2022-01-10 09:54:01,836-INFO-util.logutil:
代码分析结果:
JSONDecodeError: Expecting value: line 1 column 1 (char 0)
2022-01-10 09:54:01,836-INFO-util.logutil: json report: /home/test/CodeAnalysis/client/scan_status.json
2022-01-10 09:54:01,836-ERROR-util.logutil: JSONDecodeError: Expecting value: line 1 column 1 (char 0)
Traceback (most recent call last):
File "/home/test/CodeAnalysis/client/node/localrunner.py", line 386, in run
run_task_mgr.scan_project(cur_execute_request_list, proj_conf)
File "/home/test/CodeAnalysis/client/node/localtask/runlocaltask.py", line 90, in scan_project
self._proj_id).run()
File "/home/test/CodeAnalysis/client/node/localtask/runtask.py", line 164, in run
ResultCheck.upload_task_result(task, self._proj_id)
File "/home/test/CodeAnalysis/client/node/localtask/runtask.py", line 91, in upload_task_result
data_url, log_url = TaskRunner.upload_result_detail(proj_id, task.task_id, task_dir, data, task.task_log)
File "node/taskrunner.py", line 59, in node.taskrunner.TaskRunner.upload_result_detail
File "util/wrapper.py", line 51, in util.wrapper._RetryMethod.call
File "util/wrapper.py", line 107, in util.wrapper.Retry.__retry_call
File "util/wrapper.py", line 92, in util.wrapper.Retry.__retry_call
File "/home/test/CodeAnalysis/client/util/api/fileserver.py", line 97, in upload_file
return self.__upload_data(fp, rel_url, headers)
File "/home/test/CodeAnalysis/client/util/api/fileserver.py", line 81, in __upload_data
HttpClient(self._server_url, rel_url, headers=headers, data=data, proxies=self._proxies).put()
File "/home/test/CodeAnalysis/client/util/api/httpclient.py", line 76, in put
result = HttpRequest.request(url=self.url, headers=self.headers, body=self.data, method="PUT")
File "/home/test/CodeAnalysis/client/util/api/httpclient.py", line 39, in request
dict_result = json.loads(str_result)
File "/usr/local/python3/lib/python3.7/json/init.py", line 348, in loads
return _default_decoder.decode(s)
File "/usr/local/python3/lib/python3.7/json/decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/local/python3/lib/python3.7/json/decoder.py", line 355, in raw_decode
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
from codeanalysis.
config.ini文件中配置的文件服务器url与server url的域名是否一致呢?
from codeanalysis.
config.ini文件中配置的文件服务器url与server url的域名是否一致呢?
是一样的URL=http://192.168.7.244:88/server/files/
from codeanalysis.
from codeanalysis.
目前能正常运行了么?
如果报错了,可以看一下analysis-worker是否正常运行
from codeanalysis.
目前能正常运行了么? 如果报错了,可以看一下analysis-worker是否正常运行
最后会报错第三方依赖文件服务器异常,入库失败。请问我这个config.ini中的地址是否填写正确:
[SERVER_URL]
; [必填]请将<Server IP地址>替换为实际的tca server地址
URL=http://192.168.7.244:88/server/main/
[FILE_SERVER]
; [必填]文件服务器地址,请将<Server IP地址>替换为实际的tca server地址
URL=http://192.168.7.244:8888/server/files/
web平台访问的地址是http://192.168.7.244:88/
from codeanalysis.
文件服务器FILE_SERVER的链接可以调整为 URL=http://192.168.7.244:88/server/files/
from codeanalysis.
文件服务器FILE_SERVER的链接可以调整为
URL=http://192.168.7.244:88/server/files/
这两个端口是需要对外开放吗?还是一直卡在query result from server不动
from codeanalysis.
同样卡在这里
from codeanalysis.
不需要对外,这里可以检查一下analysis-worker
的日志,看看是什么问题
docker-compose exec analysis-worker /bin/bash
tail -F -n 1000 log/codedog.log
from codeanalysis.
-2022-01-12 10:19:18,813-INFO-util.fileserver: Downloading file from http://192.168.7.244:88/server/files/taskdata/projects/1/task_180/ee26bccc734b11ecb0a5002277c9372e/tmp_dir.zip to /var/www/django/codedog/tempdata/a523b62ae4126341c7d8946d7301636cb74f21c6/tmp_dir.zip
-2022-01-12 10:19:19,818-WARNING-urllib3.connectionpool: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7ffb32d48810>: Failed to establish a new connection: [Errno 113] No route to host')': /server/files/taskdata/projects/1/task_180/ee26bccc734b11ecb0a5002277c9372e/tmp_dir.zip
是不是因为是内网的docker部署的,没有ip地址所以报错?docker访问内网192.168.7.244是不通的
from codeanalysis.
@Lingghh 有空帮忙确认一下呀
from codeanalysis.
-2022-01-12 10:19:18,813-INFO-util.fileserver: Downloading file from http://192.168.7.244:88/server/files/taskdata/projects/1/task_180/ee26bccc734b11ecb0a5002277c9372e/tmp_dir.zip to /var/www/django/codedog/tempdata/a523b62ae4126341c7d8946d7301636cb74f21c6/tmp_dir.zip -2022-01-12 10:19:19,818-WARNING-urllib3.connectionpool: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7ffb32d48810>: Failed to establish a new connection: [Errno 113] No route to host')': /server/files/taskdata/projects/1/task_180/ee26bccc734b11ecb0a5002277c9372e/tmp_dir.zip
是不是因为是内网的docker部署的,没有ip地址所以报错?docker访问内网192.168.7.244是不通的
是这个原因导致的,目前这里是有什么限制么?为什么docker访问内网192.168.7.244是不通的呢?
from codeanalysis.
这里可以关闭宿主机的防火墙试试
from codeanalysis.
Related Issues (20)
- 【BUG】安装TCA插件,配置TCA 测试任务,一触发任务jenkins就会shutdown,且所触发的构建#N在界面上会消失 HOT 3
- 【咨询】如何查看当前的扫描日志或是扫描状态 HOT 1
- 【需求】与LDAP集成
- 【需求】项目普通成员可配置是否允许标记处理 或是 提供类似read_only的角色 HOT 1
- Gitlab Oauth 500 HOT 1
- 团队管理禁用团队失败 HOT 1
- 【bug】路径过滤与tscan_cpp扫描的问题
- helm-charts安装遇到一些问题及使用上的建议 HOT 1
- 日志显示异常 HOT 2
- Unable to obtain the worker node HOT 1
- 安卓代码在git仓库src时下执行androidlint失败 HOT 2
- tscan_lua工具扫描出问题后,会导致所有问题被关闭 HOT 1
- Bug 在分析方案列表中,点击一个分析方案时,如果它的方案描述里有内容,接着点其他分析方案时,其方案描述也会有和前面一样的内容,实际上后面的分析方案并没有设置方案描述,刷新页面就会正常
- localscan时可以取消代码统计任务吗?该任务结果似乎对MR扫描没有什么用,有点浪费时间 HOT 5
- 扫描失败,提示SCM鉴权失败 账号密码错误 HOT 3
- 关于扫描速度缓慢问题 HOT 5
- 同一个问题在不同的扫描id下会出现上一个扫描已经标注处理过,下次扫描又出现相同的问题 HOT 2
- 代码库及账号不匹配 HOT 4
- v1.9.0分析android 语言Kotlin 执行结果失败
- 乌班图部署client报错
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from codeanalysis.