<tfoot id='Q7mTQ'></tfoot>
      <bdo id='Q7mTQ'></bdo><ul id='Q7mTQ'></ul>
    1. <i id='Q7mTQ'><tr id='Q7mTQ'><dt id='Q7mTQ'><q id='Q7mTQ'><span id='Q7mTQ'><b id='Q7mTQ'><form id='Q7mTQ'><ins id='Q7mTQ'></ins><ul id='Q7mTQ'></ul><sub id='Q7mTQ'></sub></form><legend id='Q7mTQ'></legend><bdo id='Q7mTQ'><pre id='Q7mTQ'><center id='Q7mTQ'></center></pre></bdo></b><th id='Q7mTQ'></th></span></q></dt></tr></i><div id='Q7mTQ'><tfoot id='Q7mTQ'></tfoot><dl id='Q7mTQ'><fieldset id='Q7mTQ'></fieldset></dl></div>

      <legend id='Q7mTQ'><style id='Q7mTQ'><dir id='Q7mTQ'><q id='Q7mTQ'></q></dir></style></legend>
    2. <small id='Q7mTQ'></small><noframes id='Q7mTQ'>

        SonarQube Scanner 执行期间出错:java.lang.IllegalArgumentException:

        时间:2023-10-24

        • <bdo id='9xx3R'></bdo><ul id='9xx3R'></ul>

              <small id='9xx3R'></small><noframes id='9xx3R'>

                <i id='9xx3R'><tr id='9xx3R'><dt id='9xx3R'><q id='9xx3R'><span id='9xx3R'><b id='9xx3R'><form id='9xx3R'><ins id='9xx3R'></ins><ul id='9xx3R'></ul><sub id='9xx3R'></sub></form><legend id='9xx3R'></legend><bdo id='9xx3R'><pre id='9xx3R'><center id='9xx3R'></center></pre></bdo></b><th id='9xx3R'></th></span></q></dt></tr></i><div id='9xx3R'><tfoot id='9xx3R'></tfoot><dl id='9xx3R'><fieldset id='9xx3R'></fieldset></dl></div>

                  <legend id='9xx3R'><style id='9xx3R'><dir id='9xx3R'><q id='9xx3R'></q></dir></style></legend>
                    <tbody id='9xx3R'></tbody>

                  <tfoot id='9xx3R'></tfoot>
                1. 本文介绍了SonarQube Scanner 执行期间出错:java.lang.IllegalArgumentException: 79 is not a valid line offset for pointer的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  在 C# 项目上运行 SonarQube 时出现此错误消息:

                  I have this error message when running SonarQube on a C# project :

                  ...
                  
                  INFO: ------------------------------------------------------------------------
                  INFO: EXECUTION FAILURE
                  INFO: ------------------------------------------------------------------------
                  INFO: Total time: 30.377s
                  INFO: Final Memory: 58M/828M
                  INFO: ------------------------------------------------------------------------
                  ERROR: Error during SonarQube Scanner execution
                  java.lang.IllegalArgumentException: 79 is not a valid line offset for pointer. File [moduleKey=dot-net_SCHLUMBERGER-Helios, relative=wtap_nextgen/Src/Component/WebSolution/MMS/wwwroot/css/bootwatch-paper.css, basedir=/builds/dot-net/SCHLUMBERGER-Helios] has 78 character(s) at line 1
                      at org.sonar.api.internal.google.common.base.Preconditions.checkArgument(Preconditions.java:148)
                      at org.sonar.api.batch.fs.internal.DefaultInputFile.checkValid(DefaultInputFile.java:218)
                      at org.sonar.api.batch.fs.internal.DefaultInputFile.newPointer(DefaultInputFile.java:209)
                      at org.sonar.api.batch.fs.internal.DefaultInputFile.newRange(DefaultInputFile.java:240)
                      at org.sonar.css.issue.PreciseIssue.save(PreciseIssue.java:119)
                      at org.sonar.plugins.css.CssSquidSensor.saveIssues(CssSquidSensor.java:121)
                      at org.sonar.plugins.css.CssSquidSensor.save(CssSquidSensor.java:105)
                      at org.sonar.plugins.css.CssSquidSensor.analyse(CssSquidSensor.java:89)
                      at org.sonar.batch.phases.SensorsExecutor.executeSensor(SensorsExecutor.java:58)
                      at org.sonar.batch.phases.SensorsExecutor.execute(SensorsExecutor.java:50)
                      at org.sonar.batch.phases.AbstractPhaseExecutor.execute(AbstractPhaseExecutor.java:83)
                      at org.sonar.batch.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:192)
                      at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:142)
                      at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:127)
                      at org.sonar.batch.scan.ProjectScanContainer.scan(ProjectScanContainer.java:241)
                      at org.sonar.batch.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:236)
                      at org.sonar.batch.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:226)
                      at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:142)
                      at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:127)
                      at org.sonar.batch.task.ScanTask.execute(ScanTask.java:47)
                      at org.sonar.batch.task.TaskContainer.doAfterStart(TaskContainer.java:86)
                      at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:142)
                      at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:127)
                      at org.sonar.batch.bootstrap.GlobalContainer.executeTask(GlobalContainer.java:106)
                      at org.sonar.batch.bootstrapper.Batch.executeTask(Batch.java:119)
                      at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:62)
                      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
                      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
                      at java.lang.reflect.Method.invoke(Method.java:498)
                      at org.sonarsource.scanner.api.internal.IsolatedLauncherProxy.invoke(IsolatedLauncherProxy.java:60)
                      at com.sun.proxy.$Proxy0.execute(Unknown Source)
                      at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(EmbeddedScanner.java:240)
                      at org.sonarsource.scanner.api.EmbeddedScanner.runAnalysis(EmbeddedScanner.java:151)
                      at org.sonarsource.scanner.cli.Main.runAnalysis(Main.java:110)
                      at org.sonarsource.scanner.cli.Main.execute(Main.java:72)
                      at org.sonarsource.scanner.cli.Main.main(Main.java:60)
                  
                  ERROR: Build failed: exit code 1
                  

                  有人知道这是从哪里来的吗?似乎扫描仪正在尝试访问 XXX/bootwatch-paper.css 第一行的第 79 个字符,它只有 78 个字符.为什么它会尝试读取第 79 个字符?这可能是编码问题吗?如何解决这个问题?

                  Does anyone have a clue where this comes from ? It seems like the scanner is trying to access character 79 of the first line of XXX/bootwatch-paper.css, which only has 78 characters. Why would it try to read the 79th character ? Could this be an encoding issue? How to fix this ?

                  干杯!

                  推荐答案

                  我的一个 AssemblyInfo.cs 文件也有类似的问题.这绝对是编码.我在 Sublime Text 中打开文件并用不同的编码保存它,看看有什么用.这是我发现的,尽管对你来说可能会有所不同,因为我使用的是 C# 插件,而你使用的是 css 插件.

                  I had a similar issue with one of my AssemblyInfo.cs files. It was definitely the encoding. I opened the file in Sublime Text and saved it with different encodings to see what worked. Here is what I found, although it may be different for you since I was using the C# plugin and you are using the css plugin.

                  1. UTF-8 - 成功
                  2. 带有 BOM 的 UTF-8 - 成功
                  3. UTF-16 LE - 成功
                  4. 带有 BOM 的 UTF-16 LE - 失败
                  5. UTF-16 BE - 成功
                  6. UTF-16 BE 与 BOM - 失败
                  7. 西方 (Windows 1252) - 成功

                  这篇关于SonarQube Scanner 执行期间出错:java.lang.IllegalArgumentException: 79 is not a valid line offset for pointer的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:SonarQube C# 分析失败“不是指针的有效行偏移" 下一篇:没有 .pdb 文件的 C# 分析失败

                  相关文章

                  <legend id='vnIUr'><style id='vnIUr'><dir id='vnIUr'><q id='vnIUr'></q></dir></style></legend>
                    <bdo id='vnIUr'></bdo><ul id='vnIUr'></ul>
                  <i id='vnIUr'><tr id='vnIUr'><dt id='vnIUr'><q id='vnIUr'><span id='vnIUr'><b id='vnIUr'><form id='vnIUr'><ins id='vnIUr'></ins><ul id='vnIUr'></ul><sub id='vnIUr'></sub></form><legend id='vnIUr'></legend><bdo id='vnIUr'><pre id='vnIUr'><center id='vnIUr'></center></pre></bdo></b><th id='vnIUr'></th></span></q></dt></tr></i><div id='vnIUr'><tfoot id='vnIUr'></tfoot><dl id='vnIUr'><fieldset id='vnIUr'></fieldset></dl></div>
                2. <small id='vnIUr'></small><noframes id='vnIUr'>

                    <tfoot id='vnIUr'></tfoot>