redhat-developer / redhat-developer/vscode-java

Annotation Processor works strange

未关闭
#2,333 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

annotation-processing Maven
主要语言
TypeScript
星标
2.3k
派生
546
平均合并
20 小时 1 分钟
30 天内合并 PR
11

描述

I am writing an anotation processor, add test the vscode support. In idea it works fine.
I write some log logic (write log information to a file with absolute path, and in the init method and static method, log something too) in the apt to promise I can judge whether it runs.
The pom setting works fine, because the maven clean install works fine with the log print out.
However my apt not runs in vscode. No log file is generated. (It will be created if non-exist).
On the other hand, If I write some space in the pom.xml and save. The log file generated, and show some initialized information. It seems my apt run when the vscode find pom.xml changed.
But when I change some code and run the changed code , no log out, it seems that my apt not run at all.

Environment
  • Operating System: windows
  • JDK version: 11
  • Visual Studio Code version: 1.64.2
  • Java extension version: 1.3.0
Steps To Reproduce
  1. change maven pom.xml with annotaton processing support
  2. save the change
  3. change some code
  4. run

The apt projcet
Please use the asm branch
The log file path define here, I have changed it to ~/jasync.log for device independent.
The test project

Current Result

After step 2, my apt runs.
After step 4, my apt not runs.

Expected Result

After step 2, my apt runs.
After step 4, my apt runs.

Additional Informations

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

从报告中的复现开始:检查 asm 分支中的 Maven pom.xml,以及第 19 行的注解处理器 Logger.java,然后跟踪 VS Code Java 扩展的注解处理入口点。使用 JDK 11 和 VS Code 1.64.2 重现步骤 1–4;完成的标准是处理器在代码更改后运行并记录日志,而不仅仅是在 pom.xml 更改后运行并记录日志。

由索引模型根据 Issue 内容生成。

评估

技术栈
java, vscode
领域
developer-experience, devtools
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
需要澄清
新手友好度
25/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。