text:
Export Folder Structure

I'm trying to do the following: I have this folder structure:
parent
|__ sass
|    |__ folder1
|    |    |__ file1.scss
|    |    |__ file2.scss
|    |__ folder2
|    |    |__ file1.scss
|    |    |__ file2.scss
And I want it to be exported to that folder structure:
parent
|__ sass
|    |__ folder1
|    |    |__ file1.scss
|    |    |__ file2.scss
|    |__ folder2
|    |    |__ file1.scss
|    |    |__ file2.scss
|__ css
|    |__ folder1
|    |    |__ file1.css
|    |    |__ file2.css
|    |__ folder2
|    |    |__ file1.css
|    |    |__ file2.css
Is that somehow possible? I read the settings documentation, but at least to me it wasn't very obviouse what I have to do.

Thanks for the quick response! No I get this error: "Live Sass Compiler: Unhandled error while compiling all files. Error message: EROFS: read-only file system, mkdir '/html'".

Hmm, that's not an error I've seen before. Seems like an issue with where it's trying to save to rather than an issue with the extension. However, just in case, can I see your settings.json file and your file structure? Also, do you have the project open anywhere different/special or just in one of your user folders?

{
	"workbench.startupEditor": "newUntitledFile",
	"workbench.colorCustomizations": {
		"[Material Theme Palenight High Contrast]": {}
	},
	"workbench.iconTheme": "material-icon-theme",
	"workbench.colorTheme": "Material Theme Palenight High Contrast",
	"workbench.editor.untitled.hint": "hidden",
	"editor.fontSize": 14,
	"editor.formatOnSave": true,
	"editor.largeFileOptimizations": false,
	"editor.defaultFormatter": "esbenp.prettier-vscode",
	"prettier.enableDebugLogs": true,
	"prettier.endOfLine": "auto",
	"prettier.useTabs": true,
	"files.autoSave": "onWindowChange",
	"explorer.confirmDragAndDrop": false,
	"explorer.confirmDelete": false,
	"discord.lowerDetailsEditing": "{workspace_and_folder}",
	"git.enableSmartCommit": true,
	"git.confirmSync": false,
	"liveServer.settings.CustomBrowser": "firefox",
	"liveServer.settings.useWebExt": true,
	"liveServer.settings.AdvanceCustomBrowserCmdLine": "",
	"liveServer.settings.donotShowInfoMsg": true,
	"liveServer.settings.donotVerifyTags": true,
	"tabnine.experimentalAutoImports": true,
	"html.format.indentInnerHtml": true,
	"liveSassCompile.settings.formats": [
		{
			"format": "compressed",
			"extensionName": ".min.css",
			"savePathReplacementPairs": {
				"/scss/compile/": "/css/"
			}
		}
	],
	"liveSassCompile.settings.autoprefix": true,
	"es6-css-minify.minifyOnSave": "yes",
	"prettier.printWidth": 500,
	"[sass]": {
		"editor.defaultFormatter": "syler.sass-indented"
	},
	"liveSassCompile.settings.showOutputWindowOn": "Trace",
	"python.defaultInterpreterPath": "python3"
}

All files are saved in my user folder (on mac).

Yeah, the setup looks okay and the folder location should be fine.
If you remove the savePathReplacementPairs setting I suggested, does it work?
What's in the output window when you save the file? As you have showOutputWindow set to trace, there is detailed output when you save a file (you may need to clear the log before you save the file)

I actually have 16 scss file and because of that the log is very long. I cut out everything from the first 15 Files (The log shows the same for all files, just different paths).
Command called: "liveSass.command.watchMySass"
--------------------
Starting to compile all files
--------------------
Changing status bar to: "Working on it..."
--------------------
Getting SASS files
Query pattern: undefined
Can be overwritten: true
--------------------
Checking folder 1 of 1
Folder: refugium
--------------------
No base folder override found. Keeping workspace folder
--------------------
Found 16 SASS files
--------------------
Compiling Sass/Scss Files:
/Users/path/to/files/scss/compile/autumn/day.scss
/Users/path/to/files/scss/compile/autumn/night.scss
/Users/path/to/files/scss/compile/autumn/sunrise.scss
/Users/path/to/files/scss/compile/autumn/sunset.scss
/Users/path/to/files/scss/compile/spring/day.scss
/Users/path/to/files/scss/compile/spring/night.scss
/Users/path/to/files/scss/compile/spring/sunrise.scss
/Users/path/to/files/scss/compile/spring/sunset.scss
/Users/path/to/files/scss/compile/winter/day.scss
/Users/path/to/files/scss/compile/winter/night.scss
/Users/path/to/files/scss/compile/winter/sunrise.scss
/Users/path/to/files/scss/compile/winter/sunset.scss
/Users/path/to/files/scss/compile/summer/day.scss
/Users/path/to/files/scss/compile/summer/night.scss
/Users/path/to/files/scss/compile/summer/sunrise.scss
/Users/path/to/files/scss/compile/summer/sunset.scss
--------------------
Starting file 16 of 16
Path: /Users/path/to/files/scss/compile/summer/sunset.scss
--------------------
Found the workspace folder
Workspace Name: refugium
--------------------
Starting format 1 of 1
Settings: {"format":"compressed","extensionName":".min.css","savePathReplacementPairs":{"/scss/compile/":"/css/"}}
--------------------
Calculating file paths
Calculating the save paths for the css and map output files
Originating path: /Users/path/to/files/scss/compile/summer/sunset.scss
--------------------
No workspace provided
Using originating path: /Users/path/to/files/scss/compile/summer/sunset.scss
--------------------
Using segment replacement
Original path: /Users/path/to/files/scss/compile/summer/sunset.scss
Applying: /scss/compile/ => /css/
Checking directory exists
Directory: /css/summer/
NO PARENT DIRECTORY
Parent directory doesn't exist, we must create it
--------------------
Checking directory exists
Directory: /css
Directory doesn't exist, creating it
--------------------
Getting SASS files
Query pattern: undefined
Can be overwritten: true
--------------------
Checking folder 1 of 1
Folder: refugium
--------------------
No base folder override found. Keeping workspace folder
--------------------
Found 16 SASS files
--------------------
Converting error to a usable object
--------------------
Logging issue
Message: Unhandled error while compiling all files. Error message: EROFS: read-only file system, mkdir '/css'
--------------------
Saving logs to storage
--------------------
Switching UI state
--------------------
Changing status bar to: Watching
--------------------
Watching...
--------------------

Also without that setting everything works perfectly fine.

UNEXPECTED ERROR
Machine & Versions

Item
Value

VS Code
v1.69.0

Platform
darwin x64

Node
16.13.2 (103)

Live Sass
5.5.0

Installed Extensions
- vscode.configuration-editing (1.0.0)- vscode.css-language-features (1.0.0)- vscode.debug-auto-launch (1.0.0)- vscode.emmet (1.0.0)- vscode.extension-editing (1.0.0)- vscode.git (1.0.0)- vscode.git-base (1.0.0)- vscode.github (0.0.1)- vscode.github-authentication (0.0.2)- vscode.ipynb (1.0.0)- vscode.json-language-features (1.0.0)- vscode.merge-conflict (1.0.0)- vscode.microsoft-authentication (0.0.1)- vscode.npm (1.0.1)- vscode.typescript-language-features (1.0.0)- Equinusocio.vsc-material-theme (33.5.0)- esbenp.prettier-vscode (9.5.0)- formulahendry.auto-rename-tag (0.1.10)- glenn2223.live-sass (5.5.0)- icrawl.discord-vscode (5.8.0)- olback.es6-css-minify (3.3.3)- PKief.material-icon-theme (4.19.0)- ritwickdey.LiveServer (5.7.5)- TabNine.tabnine-vscode (3.6.2)

LOG: 2022-07-11 15:29:20.857Z
{
    "createdAt": "2022-07-11T15:29:20.857Z",
    "event": {
        "files": [
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/autumn/day.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/autumn/night.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/autumn/sunrise.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/autumn/sunset.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/spring/day.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/spring/night.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/spring/sunrise.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/spring/sunset.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/summer/day.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/summer/night.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/summer/sunrise.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/summer/sunset.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/winter/day.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/winter/night.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/winter/sunrise.scss",
            "/Users/rebelloa/Projects/VSCode/bs-themes/refugium/scss/compile/winter/sunset.scss"
        ],
        "error": {
            "stack": "Error: EROFS: read-only file system, mkdir '/scss'\n    at Object.mkdirSync (node:fs:1334:3)\n    at Function.MakeDirIfNotAvailable (/Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4247219)\n    at Function.MakeDirIfNotAvailable (/Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4247100)\n    at Function.MakeDirIfNotAvailable (/Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4247100)\n    at AppModel.<anonymous> (/Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4273260)\n    at Generator.next (<anonymous>)\n    at /Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4261311\n    at new Promise (<anonymous>)\n    at o (/Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4260997)\n    at AppModel.generateCssAndMapUri (/Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4270662)\n    at AppModel.<anonymous> (/Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4270400)\n    at Generator.next (<anonymous>)\n    at /Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4261311\n    at new Promise (<anonymous>)\n    at o (/Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4260997)\n    at /Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4270206\n    at Array.map (<anonymous>)\n    at AppModel.<anonymous> (/Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4270194)\n    at Generator.next (<anonymous>)\n    at /Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4261311\n    at new Promise (<anonymous>)\n    at o (/Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4260997)\n    at /Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4269963\n    at Array.map (<anonymous>)\n    at AppModel.<anonymous> (/Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4269951)\n    at Generator.next (<anonymous>)\n    at fulfilled (/Users/rebelloa/.vscode/extensions/glenn2223.live-sass-5.5.0/out/extension.js:2:4261065)",
            "message": "EROFS: read-only file system, mkdir '/scss'",
            "errno": -30,
            "syscall": "mkdir",
            "code": "EROFS",
            "path": "/scss"
        }
    }
}

=======================

Yes works prefectly fine! Thanks for your help. So it was just a bug?

Yes it was. I will push oficially tonight

Okay, perfect, thanks again.


text:
Code action createMethod from jdtls fails

Describe the bug
The java language server jdtls provides a code action to create missing methods. This does not work with lspsaga: I can call the action but nothing happens. I see an exception from jdtls in the log file:

org.eclipse.text.edits.MalformedTreeException: End position lies outside document range

The same action works fine when called with :lua vim.lsp.buf.code_action().
Steps to reproduce
As the nvim-jdtls setup is not easy I can only provide debug logs.
For the example I have 2 Java files:
package demo;

/**
 * B
 */
public class B {

}

package demo;

/**
 * A
 */
public class A {

  public A() {
    B b = new B();
    B.x();
  }
}

The call to B.x(); gives a code error. The cursor is at the beginning of this line when I call the code action.
Lspsaga
After opening the code action menu:
[DEBUG][2023-03-09 11:08:30] .../lua/vim/lsp.lua:1381	"LSP[jdtls]"	"client.request"	1	"textDocument/codeAction"	{  context = {    diagnostics = { {        code = "67108964",        message = "The method x() is undefined for the type B",        range = {          ["end"] = {            character = 7,            line = 9          },          start = {            character = 6,            line = 9          }        },        severity = 1,        source = "Java"      } }  },  range = {    ["end"] = <1>{      character = 2,      line = 9    },    start = <table 1>  },  textDocument = {    uri = "file:///home/repos/local/java-demo/app/src/main/java/demo/A.java"  }}	<function 1>	1
[DEBUG][2023-03-09 11:08:30] .../vim/lsp/rpc.lua:285	"rpc.send"	{  id = 11,  jsonrpc = "2.0",  method = "textDocument/codeAction",  params = {    context = {      diagnostics = { {          code = "67108964",          message = "The method x() is undefined for the type B",          range = {            ["end"] = {              character = 7,              line = 9            },            start = {              character = 6,              line = 9            }          },          severity = 1,          source = "Java"        } }    },    range = {      ["end"] = <1>{        character = 2,        line = 9      },      start = <table 1>    },    textDocument = {      uri = "file:///home/repos/local/java-demo/app/src/main/java/demo/A.java"    }  }}
[DEBUG][2023-03-09 11:08:30] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:08:30 >> document/codeAction",    type = 3  }}
[INFO][2023-03-09 11:08:30] ...lsp/handlers.lua:489	"09.03.2023, 11:08:30 >> document/codeAction"
[DEBUG][2023-03-09 11:08:30] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  id = "8",  jsonrpc = "2.0",  method = "workspace/configuration",  params = {    items = { {        scopeUri = "file:///home/repos/local/java-demo/app/src/main/java/demo/A.java",        section = "java.format.tabSize"      }, {        scopeUri = "file:///home/repos/local/java-demo/app/src/main/java/demo/A.java",        section = "java.format.insertSpaces"      } }  }}
[DEBUG][2023-03-09 11:08:30] .../vim/lsp/rpc.lua:403	"server_request: callback result"	{  result = { 2, true },  status = true}
[DEBUG][2023-03-09 11:08:30] .../vim/lsp/rpc.lua:285	"rpc.send"	{  id = "8",  jsonrpc = "2.0",  result = { 2, true }}
[DEBUG][2023-03-09 11:08:30] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  id = 11,  jsonrpc = "2.0",  result = { {      data = {        pid = "0",        rid = "4"      },      diagnostics = { {          code = "67108964",          message = "The method x() is undefined for the type B",          range = {            ["end"] = {              character = 7,              line = 9            },            start = {              character = 6,              line = 9            }          },          severity = 1,          source = "Java"        } },      kind = "quickfix",      title = "Create method 'x()' in type 'B'"    }, {      data = {        pid = "1",        rid = "4"      },      kind = "quickassist",      title = "Add Javadoc for 'A'"    }, {      data = {        pid = "2",        rid = "4"      },      diagnostics = {},      kind = "source.organizeImports",      title = "Organize imports"    }, {      data = {        pid = "3",        rid = "4"      },      diagnostics = {},      kind = "source.generate.constructors",      title = "Generate Constructors"    }, {      data = {        pid = "4",        rid = "4"      },      diagnostics = {},      kind = "source.generate.toString",      title = "Generate toString()"    }, {      command = {        arguments = { {            context = {              diagnostics = { {                  code = "67108964",                  message = "The method x() is undefined for the type B",                  range = {                    ["end"] = {                      character = 7,                      line = 9                    },                    start = {                      character = 6,                      line = 9                    }                  },                  severity = 1,                  source = "Java"                } }            },            range = {              ["end"] = {                character = 2,                line = 9              },              start = {                character = 2,                line = 9              }            },            textDocument = {              uri = "file:///home/repos/local/java-demo/app/src/main/java/demo/A.java"            }          } },        command = "java.action.overrideMethodsPrompt",        title = "Override/Implement Methods..."      },      diagnostics = {},      kind = "source.overrideMethods",      title = "Override/Implement Methods..."    }, {      data = {        pid = "5",        rid = "4"      },      diagnostics = {},      kind = "source.generate.finalModifiers",      title = "Change modifiers to final where possible"    } }}
[DEBUG][2023-03-09 11:08:30] .../lua/vim/lsp.lua:1381	"LSP[jdtls]"	"client.request"	1	"codeAction/resolve"	{  data = {    pid = "0",    rid = "4"  },  diagnostics = { {      code = "67108964",      message = "The method x() is undefined for the type B",      range = {        ["end"] = {          character = 7,          line = 9        },        start = {          character = 6,          line = 9        }      },      severity = 1,      source = "Java"    } },  kind = "quickfix",  title = "Create method 'x()' in type 'B'"}	<function 1>	1
[DEBUG][2023-03-09 11:08:30] .../vim/lsp/rpc.lua:285	"rpc.send"	{  id = 12,  jsonrpc = "2.0",  method = "codeAction/resolve",  params = {    data = {      pid = "0",      rid = "4"    },    diagnostics = { {        code = "67108964",        message = "The method x() is undefined for the type B",        range = {          ["end"] = {            character = 7,            line = 9          },          start = {            character = 6,            line = 9          }        },        severity = 1,        source = "Java"      } },    kind = "quickfix",    title = "Create method 'x()' in type 'B'"  }}
[DEBUG][2023-03-09 11:08:30] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:08:30 >> codeAction/resolve",    type = 3  }}
[INFO][2023-03-09 11:08:30] ...lsp/handlers.lua:489	"09.03.2023, 11:08:30 >> codeAction/resolve"
[DEBUG][2023-03-09 11:08:30] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  id = 12,  jsonrpc = "2.0",  result = {    diagnostics = { {        code = "67108964",        message = "The method x() is undefined for the type B",        range = {          ["end"] = {            character = 7,            line = 9          },          start = {            character = 6,            line = 9          }        },        severity = 1,        source = "Java"      } },    edit = {      changes = vim.empty_dict(),      documentChanges = { {          edits = { {              newText = "\n\n    public static void x() {}",              range = {                ["end"] = {                  character = 16,                  line = 5                },                start = {                  character = 16,                  line = 5                }              }            } },          textDocument = {            uri = "file:///home/repos/local/java-demo/app/src/main/java/demo/B.java"          }        } }    },    kind = "quickfix",    title = "Create method 'x()' in type 'B'"  }}

After the code action:
[DEBUG][2023-03-09 11:08:40] .../lua/vim/lsp.lua:1381	"LSP[jdtls]"	"client.request"	1	"codeAction/resolve"	{  data = {    pid = "0",    rid = "4"  },  diagnostics = { {      code = "67108964",      message = "The method x() is undefined for the type B",      range = {        ["end"] = {          character = 7,          line = 9        },        start = {          character = 6,          line = 9        }      },      severity = 1,      source = "Java"    } },  kind = "quickfix",  title = "Create method 'x()' in type 'B'"}	<function 1>	1
[DEBUG][2023-03-09 11:08:40] .../vim/lsp/rpc.lua:285	"rpc.send"	{  id = 13,  jsonrpc = "2.0",  method = "codeAction/resolve",  params = {    data = {      pid = "0",      rid = "4"    },    diagnostics = { {        code = "67108964",        message = "The method x() is undefined for the type B",        range = {          ["end"] = {            character = 7,            line = 9          },          start = {            character = 6,            line = 9          }        },        severity = 1,        source = "Java"      } },    kind = "quickfix",    title = "Create method 'x()' in type 'B'"  }}
[DEBUG][2023-03-09 11:08:40] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:08:40 >> codeAction/resolve",    type = 3  }}
[DEBUG][2023-03-09 11:08:40] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:08:40 BadLocationException\nnull\norg.eclipse.jface.text.BadLocationException\n\tat org.eclipse.jface.text.TreeLineTracker.fail(TreeLineTracker.java:1054)\n\tat org.eclipse.jface.text.TreeLineTracker.lineByOffset(TreeLineTracker.java:268)\n\tat org.eclipse.jface.text.TreeLineTracker.getLineNumberOfOffset(TreeLineTracker.java:1122)\n\tat org.eclipse.jface.text.AbstractLineTracker.getLineNumberOfOffset(AbstractLineTracker.java:246)\n\tat org.eclipse.jface.text.AbstractDocument.getLineOfOffset(AbstractDocument.java:872)\n\tat org.eclipse.core.internal.filebuffers.SynchronizableDocument.getLineOfOffset(SynchronizableDocument.java:334)\n\tat org.eclipse.jdt.ls.core.internal.handlers.JsonRpcHelpers.toLine(JsonRpcHelpers.java:156)\n\tat org.eclipse.jdt.ls.core.internal.handlers.JsonRpcHelpers.toLine(JsonRpcHelpers.java:101)\n\tat org.eclipse.jdt.ls.core.internal.JDTUtils.toRange(JDTUtils.java:878)\n\tat org.eclipse.jdt.ls.core.internal.TextEditConverter.visit(TextEditConverter.java:139)\n\tat org.eclipse.text.edits.MultiTextEdit.accept0(MultiTextEdit.java:146)\n\tat org.eclipse.text.edits.TextEdit.accept(TextEdit.java:641)\n\tat org.eclipse.jdt.ls.core.internal.TextEditConverter.convert(TextEditConverter.java:63)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertTextEdit(ChangeUtil.java:272)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertTextChange(ChangeUtil.java:263)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertSingleChange(ChangeUtil.java:105)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertToWorkspaceEdit(ChangeUtil.java:94)\n\tat org.eclipse.jdt.ls.core.internal.handlers.CodeActionResolveHandler.resolve(CodeActionResolveHandler.java:49)\n\tat org.eclipse.jdt.ls.core.internal.handlers.JDTLanguageServer.lambda$16(JDTLanguageServer.java:727)\n\tat org.eclipse.jdt.ls.core.internal.BaseJDTLanguageServer.lambda$0(BaseJDTLanguageServer.java:87)\n\tat java.base/java.util.concurrent.CompletableFuture$UniApply.tryFire(CompletableFuture.java:646)\n\tat java.base/java.util.concurrent.CompletableFuture$Completion.exec(CompletableFuture.java:483)\n\tat java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373)\n\tat java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182)\n\tat java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655)\n\tat java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622)\n\tat java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165)\n",    type = 1  }}
[DEBUG][2023-03-09 11:08:40] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:08:40 Error converting TextEdits\nEnd position lies outside document range\norg.eclipse.text.edits.MalformedTreeException: End position lies outside document range\n\tat org.eclipse.text.edits.TextEditProcessor.checkIntegrityDo(TextEditProcessor.java:180)\n\tat org.eclipse.text.edits.TextEdit.dispatchCheckIntegrity(TextEdit.java:746)\n\tat org.eclipse.text.edits.TextEditProcessor.performEdits(TextEditProcessor.java:153)\n\tat org.eclipse.text.edits.TextEdit.apply(TextEdit.java:714)\n\tat org.eclipse.jdt.ls.core.internal.TextEditConverter.visit(TextEditConverter.java:141)\n\tat org.eclipse.text.edits.MultiTextEdit.accept0(MultiTextEdit.java:146)\n\tat org.eclipse.text.edits.TextEdit.accept(TextEdit.java:641)\n\tat org.eclipse.jdt.ls.core.internal.TextEditConverter.convert(TextEditConverter.java:63)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertTextEdit(ChangeUtil.java:272)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertTextChange(ChangeUtil.java:263)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertSingleChange(ChangeUtil.java:105)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertToWorkspaceEdit(ChangeUtil.java:94)\n\tat org.eclipse.jdt.ls.core.internal.handlers.CodeActionResolveHandler.resolve(CodeActionResolveHandler.java:49)\n\tat org.eclipse.jdt.ls.core.internal.handlers.JDTLanguageServer.lambda$16(JDTLanguageServer.java:727)\n\tat org.eclipse.jdt.ls.core.internal.BaseJDTLanguageServer.lambda$0(BaseJDTLanguageServer.java:87)\n\tat java.base/java.util.concurrent.CompletableFuture$UniApply.tryFire(CompletableFuture.java:646)\n\tat java.base/java.util.concurrent.CompletableFuture$Completion.exec(CompletableFuture.java:483)\n\tat java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373)\n\tat java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182)\n\tat java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655)\n\tat java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622)\n\tat java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165)\n",    type = 1  }}
[DEBUG][2023-03-09 11:08:40] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  id = 13,  jsonrpc = "2.0",  result = {    diagnostics = { {        code = "67108964",        message = "The method x() is undefined for the type B",        range = {          ["end"] = {            character = 7,            line = 9          },          start = {            character = 6,            line = 9          }        },        severity = 1,        source = "Java"      } },    kind = "quickfix",    title = "Create method 'x()' in type 'B'"  }}
[INFO][2023-03-09 11:08:40] ...lsp/handlers.lua:489	"09.03.2023, 11:08:40 >> codeAction/resolve"
[ERROR][2023-03-09 11:08:40] ...lsp/handlers.lua:485	"09.03.2023, 11:08:40 BadLocationException\nnull\norg.eclipse.jface.text.BadLocationException\n\tat org.eclipse.jface.text.TreeLineTracker.fail(TreeLineTracker.java:1054)\n\tat org.eclipse.jface.text.TreeLineTracker.lineByOffset(TreeLineTracker.java:268)\n\tat org.eclipse.jface.text.TreeLineTracker.getLineNumberOfOffset(TreeLineTracker.java:1122)\n\tat org.eclipse.jface.text.AbstractLineTracker.getLineNumberOfOffset(AbstractLineTracker.java:246)\n\tat org.eclipse.jface.text.AbstractDocument.getLineOfOffset(AbstractDocument.java:872)\n\tat org.eclipse.core.internal.filebuffers.SynchronizableDocument.getLineOfOffset(SynchronizableDocument.java:334)\n\tat org.eclipse.jdt.ls.core.internal.handlers.JsonRpcHelpers.toLine(JsonRpcHelpers.java:156)\n\tat org.eclipse.jdt.ls.core.internal.handlers.JsonRpcHelpers.toLine(JsonRpcHelpers.java:101)\n\tat org.eclipse.jdt.ls.core.internal.JDTUtils.toRange(JDTUtils.java:878)\n\tat org.eclipse.jdt.ls.core.internal.TextEditConverter.visit(TextEditConverter.java:139)\n\tat org.eclipse.text.edits.MultiTextEdit.accept0(MultiTextEdit.java:146)\n\tat org.eclipse.text.edits.TextEdit.accept(TextEdit.java:641)\n\tat org.eclipse.jdt.ls.core.internal.TextEditConverter.convert(TextEditConverter.java:63)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertTextEdit(ChangeUtil.java:272)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertTextChange(ChangeUtil.java:263)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertSingleChange(ChangeUtil.java:105)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertToWorkspaceEdit(ChangeUtil.java:94)\n\tat org.eclipse.jdt.ls.core.internal.handlers.CodeActionResolveHandler.resolve(CodeActionResolveHandler.java:49)\n\tat org.eclipse.jdt.ls.core.internal.handlers.JDTLanguageServer.lambda$16(JDTLanguageServer.java:727)\n\tat org.eclipse.jdt.ls.core.internal.BaseJDTLanguageServer.lambda$0(BaseJDTLanguageServer.java:87)\n\tat java.base/java.util.concurrent.CompletableFuture$UniApply.tryFire(CompletableFuture.java:646)\n\tat java.base/java.util.concurrent.CompletableFuture$Completion.exec(CompletableFuture.java:483)\n\tat java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373)\n\tat java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182)\n\tat java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655)\n\tat java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622)\n\tat java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165)\n"
[ERROR][2023-03-09 11:08:40] ...lsp/handlers.lua:485	"09.03.2023, 11:08:40 Error converting TextEdits\nEnd position lies outside document range\norg.eclipse.text.edits.MalformedTreeException: End position lies outside document range\n\tat org.eclipse.text.edits.TextEditProcessor.checkIntegrityDo(TextEditProcessor.java:180)\n\tat org.eclipse.text.edits.TextEdit.dispatchCheckIntegrity(TextEdit.java:746)\n\tat org.eclipse.text.edits.TextEditProcessor.performEdits(TextEditProcessor.java:153)\n\tat org.eclipse.text.edits.TextEdit.apply(TextEdit.java:714)\n\tat org.eclipse.jdt.ls.core.internal.TextEditConverter.visit(TextEditConverter.java:141)\n\tat org.eclipse.text.edits.MultiTextEdit.accept0(MultiTextEdit.java:146)\n\tat org.eclipse.text.edits.TextEdit.accept(TextEdit.java:641)\n\tat org.eclipse.jdt.ls.core.internal.TextEditConverter.convert(TextEditConverter.java:63)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertTextEdit(ChangeUtil.java:272)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertTextChange(ChangeUtil.java:263)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertSingleChange(ChangeUtil.java:105)\n\tat org.eclipse.jdt.ls.core.internal.ChangeUtil.convertToWorkspaceEdit(ChangeUtil.java:94)\n\tat org.eclipse.jdt.ls.core.internal.handlers.CodeActionResolveHandler.resolve(CodeActionResolveHandler.java:49)\n\tat org.eclipse.jdt.ls.core.internal.handlers.JDTLanguageServer.lambda$16(JDTLanguageServer.java:727)\n\tat org.eclipse.jdt.ls.core.internal.BaseJDTLanguageServer.lambda$0(BaseJDTLanguageServer.java:87)\n\tat java.base/java.util.concurrent.CompletableFuture$UniApply.tryFire(CompletableFuture.java:646)\n\tat java.base/java.util.concurrent.CompletableFuture$Completion.exec(CompletableFuture.java:483)\n\tat java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:373)\n\tat java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1182)\n\tat java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1655)\n\tat java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1622)\n\tat java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:165)\n"

Builtin vim.lsp.buf.code_action()
After opening the code action menu:
[DEBUG][2023-03-09 11:10:20] .../lua/vim/lsp.lua:1381	"LSP[jdtls]"	"client.request"	1	"textDocument/codeAction"	{  context = {    diagnostics = { {        code = "67108964",        message = "The method x() is undefined for the type B",        range = {          ["end"] = {            character = 7,            line = 9          },          start = {            character = 6,            line = 9          }        },        severity = 1,        source = "Java"      } }  },  range = {    ["end"] = <1>{      character = 2,      line = 9    },    start = <table 1>  },  textDocument = {    uri = "file:///home/repos/local/java-demo/app/src/main/java/demo/A.java"  }}	<function 1>	1
[DEBUG][2023-03-09 11:10:20] .../vim/lsp/rpc.lua:285	"rpc.send"	{  id = 14,  jsonrpc = "2.0",  method = "textDocument/codeAction",  params = {    context = {      diagnostics = { {          code = "67108964",          message = "The method x() is undefined for the type B",          range = {            ["end"] = {              character = 7,              line = 9            },            start = {              character = 6,              line = 9            }          },          severity = 1,          source = "Java"        } }    },    range = {      ["end"] = <1>{        character = 2,        line = 9      },      start = <table 1>    },    textDocument = {      uri = "file:///home/repos/local/java-demo/app/src/main/java/demo/A.java"    }  }}
[DEBUG][2023-03-09 11:10:20] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:10:20 >> document/codeAction",    type = 3  }}
[DEBUG][2023-03-09 11:10:20] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  id = "9",  jsonrpc = "2.0",  method = "workspace/configuration",  params = {    items = { {        scopeUri = "file:///home/repos/local/java-demo/app/src/main/java/demo/A.java",        section = "java.format.tabSize"      }, {        scopeUri = "file:///home/repos/local/java-demo/app/src/main/java/demo/A.java",        section = "java.format.insertSpaces"      } }  }}
[INFO][2023-03-09 11:10:20] ...lsp/handlers.lua:489	"09.03.2023, 11:10:20 >> document/codeAction"
[DEBUG][2023-03-09 11:10:20] .../vim/lsp/rpc.lua:403	"server_request: callback result"	{  result = { 2, true },  status = true}
[DEBUG][2023-03-09 11:10:20] .../vim/lsp/rpc.lua:285	"rpc.send"	{  id = "9",  jsonrpc = "2.0",  result = { 2, true }}
[DEBUG][2023-03-09 11:10:20] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  id = 14,  jsonrpc = "2.0",  result = { {      data = {        pid = "0",        rid = "5"      },      diagnostics = { {          code = "67108964",          message = "The method x() is undefined for the type B",          range = {            ["end"] = {              character = 7,              line = 9            },            start = {              character = 6,              line = 9            }          },          severity = 1,          source = "Java"        } },      kind = "quickfix",      title = "Create method 'x()' in type 'B'"    }, {      data = {        pid = "1",        rid = "5"      },      kind = "quickassist",      title = "Add Javadoc for 'A'"    }, {      data = {        pid = "2",        rid = "5"      },      diagnostics = {},      kind = "source.organizeImports",      title = "Organize imports"    }, {      data = {        pid = "3",        rid = "5"      },      diagnostics = {},      kind = "source.generate.constructors",      title = "Generate Constructors"    }, {      data = {        pid = "4",        rid = "5"      },      diagnostics = {},      kind = "source.generate.toString",      title = "Generate toString()"    }, {      command = {        arguments = { {            context = {              diagnostics = { {                  code = "67108964",                  message = "The method x() is undefined for the type B",                  range = {                    ["end"] = {                      character = 7,                      line = 9                    },                    start = {                      character = 6,                      line = 9                    }                  },                  severity = 1,                  source = "Java"                } }            },            range = {              ["end"] = {                character = 2,                line = 9              },              start = {                character = 2,                line = 9              }            },            textDocument = {              uri = "file:///home/repos/local/java-demo/app/src/main/java/demo/A.java"            }          } },        command = "java.action.overrideMethodsPrompt",        title = "Override/Implement Methods..."      },      diagnostics = {},      kind = "source.overrideMethods",      title = "Override/Implement Methods..."    }, {      data = {        pid = "5",        rid = "5"      },      diagnostics = {},      kind = "source.generate.finalModifiers",      title = "Change modifiers to final where possible"    } }}

After the code action:
[DEBUG][2023-03-09 11:10:25] .../lua/vim/lsp.lua:1381	"LSP[jdtls]"	"client.request"	1	"codeAction/resolve"	{  data = {    pid = "0",    rid = "5"  },  diagnostics = { {      code = "67108964",      message = "The method x() is undefined for the type B",      range = {        ["end"] = {          character = 7,          line = 9        },        start = {          character = 6,          line = 9        }      },      severity = 1,      source = "Java"    } },  kind = "quickfix",  title = "Create method 'x()' in type 'B'"}	<function 1>	1
[DEBUG][2023-03-09 11:10:25] .../vim/lsp/rpc.lua:285	"rpc.send"	{  id = 15,  jsonrpc = "2.0",  method = "codeAction/resolve",  params = {    data = {      pid = "0",      rid = "5"    },    diagnostics = { {        code = "67108964",        message = "The method x() is undefined for the type B",        range = {          ["end"] = {            character = 7,            line = 9          },          start = {            character = 6,            line = 9          }        },        severity = 1,        source = "Java"      } },    kind = "quickfix",    title = "Create method 'x()' in type 'B'"  }}
[DEBUG][2023-03-09 11:10:25] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:10:25 >> codeAction/resolve",    type = 3  }}
[INFO][2023-03-09 11:10:25] ...lsp/handlers.lua:489	"09.03.2023, 11:10:25 >> codeAction/resolve"
[DEBUG][2023-03-09 11:10:25] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  id = 15,  jsonrpc = "2.0",  result = {    diagnostics = { {        code = "67108964",        message = "The method x() is undefined for the type B",        range = {          ["end"] = {            character = 7,            line = 9          },          start = {            character = 6,            line = 9          }        },        severity = 1,        source = "Java"      } },    edit = {      changes = vim.empty_dict(),      documentChanges = { {          edits = { {              newText = "\n\n    public static void x() {}",              range = {                ["end"] = {                  character = 16,                  line = 5                },                start = {                  character = 16,                  line = 5                }              }            } },          textDocument = {            uri = "file:///home/repos/local/java-demo/app/src/main/java/demo/B.java"          }        } }    },    kind = "quickfix",    title = "Create method 'x()' in type 'B'"  }}
[DEBUG][2023-03-09 11:10:25] .../vim/lsp/rpc.lua:285	"rpc.send"	{  jsonrpc = "2.0",  method = "textDocument/didChange",  params = {    contentChanges = { {        range = {          ["end"] = {            character = 16,            line = 5          },          start = {            character = 16,            line = 5          }        },        rangeLength = 0,        text = "\n\n    public static void x() {}"      } },    textDocument = {      uri = "file:///home/repos/local/java-demo/app/src/main/java/demo/B.java",      version = 9    }  }}
[DEBUG][2023-03-09 11:10:25] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:10:25 >> document/didChange",    type = 3  }}
[DEBUG][2023-03-09 11:10:25] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "$/progress",  params = {    token = "f4d5b78b-d4ad-4f0d-81df-fee975167432",    value = {      kind = "begin",      message = "Validate documents",      title = "Validate documents"    }  }}
[DEBUG][2023-03-09 11:10:25] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "$/progress",  params = {    token = "f4d5b78b-d4ad-4f0d-81df-fee975167432",    value = {      kind = "report",      message = "Validate documents",      percentage = 0    }  }}
[DEBUG][2023-03-09 11:10:25] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:10:25 Reconciled 1. Took 1 ms",    type = 3  }}
[DEBUG][2023-03-09 11:10:25] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "$/progress",  params = {    token = "f4d5b78b-d4ad-4f0d-81df-fee975167432",    value = {      kind = "end",      message = "Validate documents"    }  }}
[INFO][2023-03-09 11:10:25] ...lsp/handlers.lua:489	"09.03.2023, 11:10:25 >> document/didChange"
[INFO][2023-03-09 11:10:25] ...lsp/handlers.lua:489	"09.03.2023, 11:10:25 Reconciled 1. Took 1 ms"
[DEBUG][2023-03-09 11:10:25] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "$/progress",  params = {    token = "3b408fdf-8eb0-40c8-8405-29e2e66f235b",    value = {      kind = "begin",      message = "Building",      title = "Building"    }  }}
[DEBUG][2023-03-09 11:10:25] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "$/progress",  params = {    token = "3b408fdf-8eb0-40c8-8405-29e2e66f235b",    value = {      kind = "report",      message = "Building",      percentage = 0    }  }}
[DEBUG][2023-03-09 11:10:25] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "$/progress",  params = {    token = "3b408fdf-8eb0-40c8-8405-29e2e66f235b",    value = {      kind = "end",      message = "Building"    }  }}
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "$/progress",  params = {    token = "41c19d9c-27b9-46c0-aeb5-38085440d90b",    value = {      kind = "begin",      message = "Publish Diagnostics",      title = "Publish Diagnostics"    }  }}
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "$/progress",  params = {    token = "41c19d9c-27b9-46c0-aeb5-38085440d90b",    value = {      kind = "report",      message = "Publish Diagnostics",      percentage = 0    }  }}
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:10:26 begin problem for /B.java",    type = 3  }}
[INFO][2023-03-09 11:10:26] ...lsp/handlers.lua:489	"09.03.2023, 11:10:26 begin problem for /B.java"
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:10:26 0 problems reported for /B.java",    type = 3  }}
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "textDocument/publishDiagnostics",  params = {    diagnostics = {},    uri = "file:///home/repos/local/java-demo/app/src/main/java/demo/B.java"  }}
[INFO][2023-03-09 11:10:26] ...lsp/handlers.lua:489	"09.03.2023, 11:10:26 0 problems reported for /B.java"
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:10:26 begin problem for /A.java",    type = 3  }}
[INFO][2023-03-09 11:10:26] ...lsp/handlers.lua:489	"09.03.2023, 11:10:26 begin problem for /A.java"
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:10:26 1 problems reported for /A.java",    type = 3  }}
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "textDocument/publishDiagnostics",  params = {    diagnostics = { {        code = "536870973",        message = "The value of the local variable b is not used",        range = {          ["end"] = {            character = 7,            line = 8          },          start = {            character = 6,            line = 8          }        },        severity = 2,        source = "Java",        tags = { 1 }      } },    uri = "file:///home/repos/local/java-demo/app/src/main/java/demo/A.java"  }}
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "window/logMessage",  params = {    message = "09.03.2023, 11:10:26 Validated 2. Took 58 ms",    type = 3  }}
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "$/progress",  params = {    token = "41c19d9c-27b9-46c0-aeb5-38085440d90b",    value = {      kind = "end",      message = "Publish Diagnostics"    }  }}
[INFO][2023-03-09 11:10:26] ...lsp/handlers.lua:489	"09.03.2023, 11:10:26 1 problems reported for /A.java"
[INFO][2023-03-09 11:10:26] ...lsp/handlers.lua:489	"09.03.2023, 11:10:26 Validated 2. Took 58 ms"
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "$/progress",  params = {    token = "7d2cd000-9ed2-401e-a0f3-32bafdf9ddd5",    value = {      kind = "begin",      message = "Building",      title = "Building"    }  }}
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "$/progress",  params = {    token = "7d2cd000-9ed2-401e-a0f3-32bafdf9ddd5",    value = {      kind = "report",      message = "Building",      percentage = 0    }  }}
[DEBUG][2023-03-09 11:10:26] .../vim/lsp/rpc.lua:388	"rpc.receive"	{  jsonrpc = "2.0",  method = "$/progress",  params = {    token = "7d2cd000-9ed2-401e-a0f3-32bafdf9ddd5",    value = {      kind = "end",      message = "Building"    }  }}

Expected behavior
Lspsaga should create a new method in the class file B.java just like the build in LSP handler.
Neovim version (nvim -v)
0.8.3
lspsaga commit
109286f8def4187c3a35494b8760fd14105e9d8c
Terminal name/version
Gnome Terminal 3.44.0

Awesome. Thanks yet again for the quick fix.

source: gharchive/issue

license: MIT

license_type: permissive

license_source: github-api


text:
Quick get started guide?

Hi!
Stumbled onto this project last week and it would be very complimentary to another project i am working on. I'm having a little difficulty getting started though. I can create a project and add j-antplus as a maven dependence, but i'm not sure of the next steps to make proper use of the functionality.
Would it be possible to provide a quick "get started" example of an application that would use this library? Let's say, simply outputting HRM data to the console for example.
Thanks, much appreciated!

Deleted my previous comment. I've played around a bit more and have figured out how to use the lib. Cheers!

repo: glever/j-antplus


text:
Handling of ConfigureNotify should use XTranslateCoordinates

Certain window managers reparent windows (for example when resizing) so the xconfigure.x and xconfigure.y will be the position relative to the parent, not what the user wants. XtranslateCoordinates could be used to get the position of the window in the root window, that is the position of the window in the screen.

What version of what window manager are you using?

I'm on Cinnamon, so it should be Muffin ~= Mutter; I'll check the exact version today.

Couldn't reproduce this on my Cinnamon. I'll be away until Tuesday.

The exact version of muffin is 2.2.6-4+gg1 and I have been able to repro with the events test application:
0000009a to 1 at 3.195: Window position: 706 292
0000009b to 1 at 3.228: Window position: 707 292
0000009c to 1 at 3.245: Window position: 706 292
0000009d to 1 at 3.280: Window position: 707 292 // Stopped moving the window around and started resizing
0000009e to 1 at 6.867: Framebuffer size: 641 482
0000009f to 1 at 6.871: Window size: 641 482
000000a0 to 1 at 6.871: Window position: 10 41 // The reparenting occured
000000a1 to 1 at 6.871: Window refresh
000000a2 to 1 at 7.033: Framebuffer size: 647 495
000000a3 to 1 at 7.038: Window size: 647 495
000000a4 to 1 at 7.039: Window refresh
000000a5 to 1 at 7.199: Framebuffer size: 651 509
000000a6 to 1 at 7.219: Window size: 651 509
000000a7 to 1 at 7.219: Window refresh
000000a8 to 1 at 7.383: Framebuffer size: 654 515
000000a9 to 1 at 7.388: Window size: 654 515
000000aa to 1 at 7.388: Window refresh
000000ab to 1 at 7.566: Framebuffer size: 660 517
000000ac to 1 at 7.572: Window size: 660 517
000000ad to 1 at 7.572: Window refresh
000000ae to 1 at 7.883: Framebuffer size: 662 517
000000af to 1 at 7.888: Window size: 662 517
000000b0 to 1 at 7.888: Window refresh
000000b1 to 1 at 8.067: Framebuffer size: 667 514
000000b2 to 1 at 8.088: Window size: 667 514
000000b3 to 1 at 8.088: Window refresh
000000b4 to 1 at 9.544: Window position: 706 293 // Stopped resizing and started moving around again, the window is reparented no more
000000b5 to 1 at 9.567: Window position: 704 293
000000b6 to 1 at 9.584: Window position: 703 294

I'm on 14.10, which has Muffin 2.2.6-2.

Hello,
I've got a good news for you, you'lllike it for sure, read it here please http://ntuwibatre.makeupbizz.com/aetavy
In haste, acreator@blueyonder.co.uk

authors: Kangz dedred elmindreda

repo: glfw/glfw

license: Zlib


text:
SERVICE_IP interpolation in consul script check showing host ip when using -internal flag

Shouldn't the interpolated $SERVICE_IP in the consul script checks be the container ip, not the host ip, when using the -internal flag?
Otherwise, would it be possible to add another interpolated value, like $SERVICE_CONTAINER_IP or similar, to supply this value for script checks?

Same as/part of #233 via #130 AFAICT

authors: byrnedo ianmcorvidae

repo: gliderlabs/registrator

license: mit

license_source: bigquery


text:
ci: add goreleaser

Signed-off-by: Boris Glimcher 36732377+glimchb@users.noreply.github.com

Codecov Report

:exclamation: No coverage uploaded for pull request base (main@e292bc4). Click here to learn what that means.
The diff coverage is n/a.

:mega: This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more
@@          Coverage Diff           @@
##             main      #1   +/-   ##
======================================
  Coverage        ?   0.00%
======================================
  Files           ?       3
  Lines           ?     453
  Branches        ?       0
======================================
  Hits            ?       0
  Misses          ?     453
  Partials        ?       0

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

source: gharchive/pull-request

authors: codecov-commenter glimchb

repo: glimchb/opi-marvell-bridge


text:
🛑 INTG-APP is down

In 32c47e1, INTG-APP ($SITE_6) was down:

HTTP code: 403
Response time: 161 ms

Resolved: INTG-APP is back up in 82a664a after 45 minutes.

repo: glo-markoaular/status-navigate


text:
no output on command line

there is no output 👍
$ cat t.glu
let prelude = import! "std/prelude.glu"
let io = import! "std/io.glu"

let run x : () -> IO () =
    io.println "gluon (:h for help, :q to quit)"
run

$ ./target/debug/gluon t.glu

Thanks for reporting! It appears that running files from the command line has regressed so that it no longer runs IO expressions. Fairly simple to fix but I will do some cleanup of the API being used as well.
Note that you actually have a bug in the example  you posted. The run function must be called as well or else the IO action won't be executed (you only return the function run as it is currently).
let prelude = import! "std/prelude.glu"
let io = import! "std/io.glu"

let run x : () -> IO () =
    io.println "gluon (:h for help, :q to quit)"
run ()
 // ^ here

authors: Marwes srctxt

repo: gluon-lang/gluon


text:
Fix PrepareRenameResponse casing issue

The default_behaviour field in PrepareRenameResponse is not being renamed to camel_case, see: https://github.com/gluon-lang/lsp-types/blob/master/src/rename.rs#L80
Adding a serde annotation solves this.

That is rather strange, I would have expected the attribute on the enum would handle this https://serde.rs/container-attrs.html#rename_all

It's probably related to https://github.com/serde-rs/serde/issues/1061?

Ah, :/

Thanks for the merge! Also, thanks for this crate. I've been using it pretty extensively and this is the only glitch I've uncovered, so kudos :)

authors: Marwes sagacity

repo: gluon-lang/lsp-types


text:
runme.sh: Start VM if it is not running

Fix https://github.com/gmacario/easy-jenkins/issues/2
Signed-off-by: Gianpaolo Macario gmacario@gmail.com

LGTM, merging

repo: gmacario/easy-jenkins


text:
added ability to subscribe to ChangeSetListener events

It would be nice to have the ability to subscribe to ChangeSetListener events.
@mdproctor may i ask you to take a look ?

Instead of changing ChangeSetListener, I wonder if it would be best to make a composite listener, which takes 1..n child listeners. So it could take the ChangeSetListener, plus your own.

What's the advantage of this versus registering a DirectoryChangeListener directly? It looks like you would just get a ChangeSet with a single entry each time.

Closing this since it seems to be inactive, but if you're still interested please feel free to continue the discussion.

authors: gmethvin mdproctor treblereel

repo: gmethvin/directory-watcher


text:
🛑 課程系統 is down

In 5f5b1c1, 課程系統 (https://aps.ntut.edu.tw/course/tw/course.jsp) was down:

HTTP code: 0
Response time: 0 ms

Resolved: 課程系統 is back up in 01d3b4b.

repo: gnehs/ntut-uptime


text:
Enable generic detected wallet module in onboard.js

Overview
https://github.com/blocknative/onboard/releases/tag/1.29.0
The main feature of this release is a generic detected wallet module. It can be added to your project by adding the following wallet object to your wallets array when initializing Onboard: { walletName: 'detectedwallet' }. If a user then visits your app and they have a wallet provider injected in to the page that is not recognized by Onboard, it will try to pull the name from the provider and will display it as an option so that any injected wallet that conforms to the EIP-1193 standard can connect to your app.
Goals
Allow users to use their injected web3 browser, instead of forcing users to choose one of the listed ones.
Requirements
It can be added to your project by adding the following wallet object to your wallets array when initializing Onboard: { walletName: 'detectedwallet' }.

"Detected Wallet" is now enabled by default (it's actually doesn't seem possible to disable it 😄).
Thanks!

repo: gnosis/safe-react


text:
Update zio, zio-test, zio-test-magnolia, ... to 2.1.5

About this PR
📦 Updates

dev.zio:zio
dev.zio:zio-test
dev.zio:zio-test-magnolia
dev.zio:zio-test-sbt

from 2.1.1 to 2.1.5
📜 GitHub Release Notes - Version Diff
Usage
✅ Please merge!
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

⚙ Adjust future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "dev.zio" } ]

Or, add this to slow down future updates of this dependency:
dependencyOverrides = [{
  pullRequests = { frequency = "30 days" },
  dependency = { groupId = "dev.zio" }
}]

labels: library-update, early-semver-patch, semver-spec-patch, commit-count:1

Superseded by #66.

repo: gnp/zio-quickstart-https


text:
起 docker 报错

2021/10/29 07:22:55 ParseConfig: 1 error(s) decoding:

cannot parse 'MySQL.ConnMaxLifeTime' as int: strconv.ParseInt: parsing "60m": invalid syntax

已修复。如果docker里没有表，也可以自行导入一下，地址：https://github.com/go-eagle/eagle/blob/master/deploy/docker/mysql/init.sql

authors: convee qloog

repo: go-eagle/eagle


text:
インターフェースがinlineで作成されないオプションの追加

外部パッケージのオブジェクトがinlineで展開されてしまうためそれをしないようにするオプションの追加

Fixed in v1.0.0


text:
[API] Authorization token documentation incorrect

(basic Auth allowed only!)
swagger docs:
curl -X GET "http://localhost:3000/api/v1/users/test01/tokens" -H "accept: application/json" -H "Authorization: dGVzdDAxOnRlc3QwMQ=="
working solution:
curl -X GET "http://localhost:3000/api/v1/users/test01/tokens" -H "accept: application/json" -H "authorization: Basic dGVzdDAxOnRlc3QwMQ=="

@lunny can you add lable kind/api pleace?

It's wrong documentation. I think I've tried looking into fixing this before and couldn't.

ping @stale

Some Notes from discord:

It looks like swagger-ui return wrong curl suggestion

we should add docu about basicAuth to https://github.com/go-gitea/gitea/blob/master/routers/api/v1/api.go#L32 and below

rename reqToken to make it clear that it acept token and basic auth

handle authorization case-insensitive (https://www.w3.org/Protocols/rfc2616/rfc2616-sec4.html#sec4.2)

reverences:
https://tools.ietf.org/html/rfc7617
https://swagger.io/docs/specification/2-0/authentication/basic-authentication/

we should add docu about basicAuth to https://github.com/go-gitea/gitea/blob/master/routers/api/v1/api.go#L32 and below

We can't add anything to that yaml bit AFAIU. The spec does not allow for a desc on type: basic.

handle authorization case-insensitive

AFAICS we already do.

repo: go-gitea/gitea


text:
After install the Gitea, start/enable gitea.service do not work!!!

Gitea version (or commit ref): Gitea version 1.12.4 built with GNU Make 4.3, go1.15.1 : bindata, sqlite, sqlite_unlock_notify, pam
Git version: 2.28.0
Operating system: ArchLinuxARM
Database (use [x]):

[ ] PostgreSQL
[ ] MySQL
[ ] MSSQL
[x] SQLite

Can you reproduce the bug at https://try.gitea.io:

[ ] Yes (provide example URL)
[ ] No
[ ] Not relevant

Log gist:

Started Gitea (Git with a cup of tea).
systemd[480]: gitea.service: Changing to the requested working directory failed: Permission denied
systemd[480]: gitea.service: Failed at step CHDIR spawning /usr/bin/gitea: Permission denied
systemd[1]: gitea.service: Main process exited, code=exited, status=200/CHDIR
systemd[1]: gitea.service: Failed with result 'exit-code'.
systemd[1]: gitea.service: Scheduled restart job, restart counter is at 20.
systemd[1]: Stopped Gitea (Git with a cup of tea).
Description
After install the Gitea, start/enable gitea.service do not work!!!
Screenshots

First of all you should definitly add more exclamation marks to your issue title, it is very importent to have enough of those in your title and description.
Joking aside.
The error message clearly states the problem, I dont even know how to express this any better.

systemd[480]: gitea.service: Changing to the requested working directory failed: Permission denied
systemd[480]: gitea.service: Failed at step CHDIR spawning /usr/bin/gitea: Permission denied

The user you are running gitea with does not have the permission to use the working directory /usr/bin/gitea.
So either you entered the wrong directory in your config, or the directorys ownership/permissions are wrong.

@Masgalor:
Yes, thank you very much!
I know it’s a permission problem, but I tried to change the permissions and owners of some files, but it’s still useless, and it doesn’t seem to find the root cause.
Today I tried to change the content of the ‘gitea.service’ file again, and then after using ‘systemctl daemon-reload’, I restarted the service and it worked correctly!!!
I seem to have forgotten to use ‘systemctl daemon-reload’ before.
According to what you said the 'user' don't have permission to use /usr/bin/gitea, it should work if its owner is changed. I will try this way later.
Thanks again! ! !

Closing this, seems you found a solution. 🙂

authors: GitYun Masgalor jolheiser


text:
OAuth Provider - Add Org/Team membership to userinfo endpoint

Gitea version (or commit ref): 1.15.0
Git version: N/A
Operating system: Linux
Database (use [x]): N/A

[ ] PostgreSQL
[ ] MySQL
[ ] MSSQL
[x] SQLite

Description
When Gitea is acting as an OAuth provider, it would be nice if the /login/oauth/userinfo endpoint would return the orgs/teams to which a user is assigned if the "profile" scope is set. This would allow the client to parse this information and could possibly map it to a user group.
One implementation might add a new claim for each org, using the org name as the key for the claim.  The claim would be an array of team names to which the user belonged for that org.
Another implementation would be to add a "teams" claim containing an array of [org_name]:[team_name] strings (where the org name and team name are concatenated together, separated by a colon or dash).
Thoughts on this?  I am willing to submit a PR.

Resolved by #17367

authors: bminer lunny


text:
Disabling basic auth does not remove login form

Description
I have the following in my config, so people can only login via the configured OpenID-provider:
service:
  ENABLE_BASIC_AUTHENTICATION: false

according to https://docs.gitea.io/en-us/config-cheat-sheet/#service-service
Screenshots
Nonetheless, there is a username-password prompt:

Gitea Version
Powered by Gitea Version: 1.16.8
Can you reproduce the bug on the Gitea demo site?
No
Operating System
No response
Browser Version
Firefox

It is configured from kubernetes via the helm chart, even these lines in the app.ini change nothing:
[service]
DISABLE_REGISTRATION        = true
ENABLE_BASIC_AUTHENTICATION = false

[openid]
ENABLE_OPENID_SIGNUP = true

Basic Authentication means Disable HTTP BASIC Authentication, and specifically for the API.

so how do I remove email-password-signin?

authors: techknowlogick xeruf


text:
Gitea can't automatically create table for session storage in MySQL database

Gitea version (or commit ref): 1.8.2
Git version:
Operating system:
Database (use [x]):

[ ] PostgreSQL
[x] MySQL
[ ] MSSQL
[ ] SQLite

Can you reproduce the bug at https://try.gitea.io:

[ ] Yes (provide example URL)
[ ] No
[x] Not relevant

Greetings!
I'm using Gitea v.1.8.2 in my setup and have recently ran into strange behaviour: when changing session storage from files to MySQL Gitea doesn't create the needed table in the database. All other tables are being created normally, though (if database was initially empty). Here are some errors from logs, that could be seen right after changing session storage in clean installation from file to MySQL and restarting:
May 23 22:09:31 testing gitea[3984]: [Macaron] 2019-05-23 22:09:31: Started GET /metrics for 123.123.123.123
May 23 22:09:31 testing gitea[3984]: [Macaron] PANIC: session/mysql: error checking existence: Error 1146: Table 'testing.session' doesn't exist
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/github.com/go-macaron/session/mysql/mysql.go:152 (0xa4cdc3)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/modules/session/virtual.go:67 (0xb3563a)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/github.com/go-macaron/session/session.go:290 (0x9e70c0)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/github.com/go-macaron/session/session.go:160 (0x9e8379)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/context.go:79 (0x9c8580)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/github.com/go-macaron/inject/inject.go:157 (0x9998e0)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/github.com/go-macaron/inject/inject.go:135 (0x99960a)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/context.go:121 (0x9c86d9)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/context.go:112 (0x9da13f)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/recovery.go:161 (0x9da12d)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/logger.go:40 (0x9cc373)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/github.com/go-macaron/inject/inject.go:157 (0x9998e0)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/github.com/go-macaron/inject/inject.go:135 (0x99960a)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/context.go:121 (0x9c86d9)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/context.go:112 (0x9d9460)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/logger.go:52 (0x9d944b)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/logger.go:40 (0x9cc373)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/github.com/go-macaron/inject/inject.go:157 (0x9998e0)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/github.com/go-macaron/inject/inject.go:135 (0x99960a)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/context.go:121 (0x9c86d9)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/router.go:187 (0x9db386)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/router.go:294 (0x9d4e9d)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/gopkg.in/macaron.v1/macaron.go:220 (0x9cd74c)
May 23 22:09:31 testing gitea[3984]: /go/src/code.gitea.io/gitea/vendor/github.com/gorilla/context/context.go:141 (0xcdbd9a)
May 23 22:09:31 testing gitea[3984]: /usr/local/go/src/net/http/server.go:1995 (0x6ef443)
May 23 22:09:31 testing gitea[3984]: /usr/local/go/src/net/http/server.go:2774 (0x6f2717)
May 23 22:09:31 testing gitea[3984]: /usr/local/go/src/net/http/server.go:1878 (0x6ee400)
May 23 22:09:31 testing gitea[3984]: /usr/local/go/src/runtime/asm_amd64.s:1337 (0x4620e0)
May 23 22:09:31 testing gitea[3984]: [Macaron] 2019-05-23 22:09:31: Completed GET /metrics 500 Internal Server Error in 833.331�s

It's hard to find anywhere the right table structure needed for session table. As workaround I'm creating the table manually on each of mine Gitea instances (using the query from documentation of go-macaron framework):
CREATE TABLE IF NOT EXISTS `database_name`.`session` ( `key` CHAR(16) NOT NULL, `data` BLOB, `expiry` INT(11) UNSIGNED NOT NULL, PRIMARY KEY (`key`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8;"

Is this a normal behaviour? If not - can u please fix this in future releases (considering that there are no problems with creating all other tables automatically)?
Steps to reproduce

There should be no session table in the database being used
Switch session storage to MySQL in Gitea cfg (app.ini), for example:

PROVIDER        = mysql
PROVIDER_CONFIG = testing:somepassword@tcp(srv-mysql:3306)/testing

Restart Gitea for changes to take effect

We need a table named session with three columns named key,data,expiry .

Should this be handled upstream?

Yes however, it may be that we need to provide then with a patch and or fork.

This seems to be still causing issues if someone wants to use a DB as session provider: [Macaron] PANIC: session/postgres: error checking existence: pq: relation "session" does not exist. Is then any update? Even if this could not be fixed upstream (I guess that means go-macaron?) why could gitea not take care of it and prepare a session table like very other required table ready to use if someone configures a DB session provider?

Although we could get the macaron session provider software to create the db table - I think we'd be better off creating a Xorm session provider that just creates the session table as appropriate.

Doing it this way, would it be possible to re-use the specified DB parameters from the [database] section instead of adding a (somehow duplicated) PROVIDER_CONFIG?

yes

authors: Ziars lunny techknowlogick xoxys zeripath


text:
Introduce NotifySubjectType

use a string "enum" to represent notification subject type

ok now it should be ready :D

Codecov Report

Merging #16320 (4bd082f) into main (ce286f9) will increase coverage by 0.01%.
The diff coverage is 25.00%.

@@            Coverage Diff             @@
##             main   #16320      +/-   ##
==========================================
+ Coverage   45.41%   45.43%   +0.01%
==========================================
  Files         709      709
  Lines       83611    83611
==========================================
+ Hits        37974    37990      +16
+ Misses      39549    39532      -17
- Partials     6088     6089       +1

Impacted Files
Coverage Δ

modules/convert/notification.go
48.93% <25.00%> (ø)

modules/process/manager.go
72.83% <0.00%> (-2.47%)
:arrow_down:

services/pull/pull.go
41.99% <0.00%> (ø)

routers/api/v1/repo/pull.go
28.74% <0.00%> (+0.59%)
:arrow_up:

modules/queue/workerpool.go
53.81% <0.00%> (+0.76%)
:arrow_up:

models/repo_list.go
77.82% <0.00%> (+0.77%)
:arrow_up:

modules/notification/mail/mail.go
38.23% <0.00%> (+1.96%)
:arrow_up:

modules/queue/manager.go
68.36% <0.00%> (+2.82%)
:arrow_up:

modules/avatar/avatar.go
52.27% <0.00%> (+4.54%)
:arrow_up:

services/mailer/mail_comment.go
85.18% <0.00%> (+7.40%)
:arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ce286f9...4bd082f. Read the comment docs.


text:
Accounts with WebAuthn only (no TOTP) now exist ... fix code to handle that case

as title

we should seperate twofactor auth and TOTP things!!!
at the moment TOTP is referenced as twofactor in the code a lot ... but it's just one of two auth sources who are for 2fa !!!

Codecov Report

:exclamation: No coverage uploaded for pull request base (main@a5e8dae). Click here to learn what that means.
The diff coverage is 38.46%.

@@           Coverage Diff           @@
##             main   #18897   +/-   ##
=======================================
  Coverage        ?   46.62%
=======================================
  Files           ?      854
  Lines           ?   122585
  Branches        ?        0
=======================================
  Hits            ?    57154
  Misses          ?    58533
  Partials        ?     6898

Impacted Files
Coverage Δ

routers/web/admin/users.go
38.99% <13.04%> (ø)

models/user/list.go
87.75% <75.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a5e8dae...049f5d4. Read the comment docs.

:rocket:

-> #18964


text:
Replace Less with CSS

Backport https://github.com/go-gitea/gitea/pull/23481 and https://github.com/go-gitea/gitea/pull/23504 to 1.19, just so we have an easier time with future backports.
Seems to work on a basic level. There was a merge conflict in RepoActionView.vue, otherwise it merged cleanly.

Would appreciate if someone could confirm that RepoActionView.vue has not regressed in styling.

Tested that, and it looks normal.

authors: HesterG silverwind


text:
Fix gitea-action user avatar broken on edited menu

Fix #29178

I was unable to create a backport for 1.21. @yp05327, please send one manually. :tea:
go run ./contrib/backport 29190
...  // fix git conflicts if any
go run ./contrib/backport --continue

No conflicts but giteabot can not create the backport?


text:
Fix: Abnormal strings appear when comments are saved after editing

Partially resolved（The second problem）：   #29986
Before
HTML strings appear when comments are saved after editing

After
https://github.com/go-gitea/gitea/assets/37935145/525601f9-3ee1-4266-9105-36d82b91b1c8

I don't know whether it's realted.

I don't think so, how to reproduce?

I cannot reproduce it any more.

 I don't know whether it's realted.

This is either web_src/js/features/repo-legacy.js:354 or web_src/js/features/repo-legacy.js and likely a separate issue.

Merged too fast...

authors: HEREYUA lunny silverwind yardenshoham


text:
Fix repo indexer and submodule bug

Fixes #3098. Also removes an unused struct.

Codecov Report

Merging #3107 into master will decrease coverage by 0.04%.
The diff coverage is 0%.

@@            Coverage Diff             @@
##           master    #3107      +/-   ##
==========================================
- Coverage   34.08%   34.03%   -0.05%
==========================================
  Files         273      273
  Lines       40018    40022       +4
==========================================
- Hits        13639    13623      -16
- Misses      24443    24460      +17
- Partials     1936     1939       +3

Impacted Files
Coverage Δ

models/repo_indexer.go
44.66% <0%> (-6.33%)
:arrow_down:

models/repo_list.go
65.62% <0%> (-1.57%)
:arrow_down:

models/repo.go
38.15% <0%> (-0.19%)
:arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 7ec6cdd...9be930b. Read the comment docs.

LGTM

LGTM

@ethantkoenig please send a backport to release/v1.3

authors: codecov-io ethantkoenig lafriks lunny


text:
How to Use 1-Many (yes, I read the docs carefully)

Your Question

I'm at a loss how to make this work. I've extensively experimented, and reviewed the documentation, and I'm just not seeing how to make this go. I'm trying to embed a user's roles in the User model, and it's returning null.  I have two models:
type User struct {
	ID        uint      `gorm:"primaryKey" json:"id"`
	UserName     string    `json:"user_name,omitempty"`
	FullName     string    `json:"full_name,omitempty"`
	EmailAddress string    `json:"email_address,omitempty"`
	Password     string    `json:"password,omitempty"`
	ApiKey       string    `json:"api_key,omitempty"`
	Enabled      bool      `json:"enabled,omitempty"`
	LastSignin   time.Time `json:"last_signin,omitempty"`
    Roles        []UserRole `json:"roles"`
}

and:
type UserRole struct {
	UserID uint `gorm:"primaryKey" json:"user_id"`
	RoleID uint `gorm:"primaryKey" json:"role_id"`
    Role string `gorm:"->" json:"role"`
}

func (UserRole) TableName() string {
    return "vuserroles"
}

vUserRoles is:
CREATE TABLE system_roles (
    id BIGINT NOT NULL DEFAULT NEXTVAL('systemroles_seq'),
    role VARCHAR(64),
    created_at TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT CURRENT_TIMESTAMP,
    updated_at TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT CURRENT_TIMESTAMP,
    CONSTRAINT PK_USERROLES PRIMARY KEY (id),
    CONSTRAINT UQ_USERROLES_ROLE UNIQUE (role)
    );

CREATE TABLE user_roles (
    user_id BIGINT NOT NULL,
    role_id BIGINT NOT NULL,
    CONSTRAINT PK_USER_ROLES PRIMARY KEY (user_id, role_id),
    CONSTRAINT FK_USER_ROLES_USERS FOREIGN KEY (user_id) REFERENCES users ON DELETE CASCADE,
    constraint FK_USER_ROLES_ROLES FOREIGN KEY (role_id) REFERENCES system_roles ON DELETE CASCADE
    );

CREATE VIEW vUserRoles AS
    SELECT user_roles.*,
        systemroles.role
    FROM user_roles
        INNER JOIN system_roles
        ON system_roles.id=user_roles.role_id;

I can retrieve the roles directly:
	cfg := config.GetConfig()
	db, err := gorm.Open(postgres.Open(cfg.GetDatabaseDSN()), &gorm.Config{})
	if err != nil {
		fmt.Println(err)
	}
	id := ctx.Param("id")
	var roles []models.UserRole
	db.Where("user_id=?",id).Find(&roles)

returns:
    {
        "user_id": 1,
        "role_id": 1,
        "role": "admin"
    },
    {
        "user_id": 1,
        "role_id": 2,
        "role": "editor"
    }

I tried defining:
    Roles        []UserRole `gorm:"foreignKey:UserID" json:"roles"`

as well as:
    Roles        []UserRole `gorm:"foreignKey:user_id" json:"roles"`

and it doesn't work. They don't generate an error, but roles is null.
   Roles        []UserRole `gorm:"foreignKey:UserIDXX" json:"roles"`.

generates an error.
The document you expected this should be explained

https://gorm.io/docs/has_many.html
Expected answer

I'd like to know how to have the value for roles populate. I'd really appreciate some help with this. Thanks.

i don't understand your question.
Is AutoMigrate not working as expected? Or is the query result not as expected? Or wondering how to use View in gorm?

@a631807682  What's not working is that when I query User, to return an instance, the value for Roles is not populated. I'm following the documentation for how to setup 1->Many as specified in the documentation, and it doesn't work.
I'd like to know how to make it work. In particular, I don't understand how I can query the roles and get data as expected but when I'm embedding the Roles onto the user, it doesn't even though it's precisely following the example (credit cards) in the documentation.

One additional note.
I revisited the has_many page, and notice that it calls a "Preload()" method to indicate the linked slice should be loaded. I added a Preload() to my statement and it didn't make any difference. My current query statement is:
e := db.Model(&ifType).Order(sort).Preload("Roles").Find(&values).Error
and for the single record:
err = db.Model(&v).Preload("Roles").First(&v, id).Error

@a631807682 I have a different test case that doesn't involve the view. I have my user model as documented above. Then, I have another model, ItemChecksum
type ItemChecksum struct {
	gorm.Model
	SomeField string
	LastEditedByUserID uint   `json:"last_edited_by_user_id,omitempty"`
	LastEditedBy       User   `gorm:"foreignKey:LastEditedByUserID"`
}

when I query, I get:
    ...
    "last_edited_by_user_id": 7778015,
    "LastEditedBy": {
        "ID": 0,
        "CreatedAt": "0001-01-01T00:00:00Z",
        "UpdatedAt": "0001-01-01T00:00:00Z",
        "DeletedAt": null,
        "enabled": false,
        "last_signin": "0001-01-01T00:00:00Z",
        "roles": null
    }

So it's working better, in that the LastEditedBy JSON object is present, but it doesn't have any data. I've confirmed the record is present in the DB:
{
    "id": 7778015,
    "created_at": "2023-04-20T14:47:01-06:00",
    "updated_at": "2023-04-20T14:47:01-06:00",
    "user_name": "hguy",
    "full_name": "herbert guy",
    "email_address": "herbert@domain.com",
    "enabled": false,
    "last_signin": "2023-08-04T09:50:09Z",
    "roles": null
}

I've tried every combination that I can think of for foreignKey and references and I can't seem to figure it out.
Perhaps if you can help me with this, the other would work.
Just to confirm something: The auto migrate calls really only update the schema to match the model correct? There's not a dependency on calling AutoMigrate to populate some sort of information/linkage table right?

There's not a dependency on calling AutoMigrate to populate some sort of information/linkage table right?

Yes, we determine the table relationship based on parsing struct and tag, AutoMigrate is not necessary.

I've tried every combination that I can think of for foreignKey and references and I can't seem to figure it out. I also tried calling Preload with clause.Associations per the docs, and that didn't change anything either.

If your table relationships match what we parsed, Preload should work.
It seems to me that what you describe is part of the thing and not the whole thing, so I hope you can provide easy reproduction code, including
table ddl, model definition, and query code

@a631807682 You're correct. I wasn't showing the whole picture. I made a simplified test case and was able to sort out the problem.
What I was trying to do was use interfaces to create a generic REST API endpoint. Here's an example:

type GormModelAI struct {
	ID        uint      `gorm:"primaryKey;autoincrement" json:"id"`
	CreatedAt time.Time `json:"created_at"`
	UpdatedAt time.Time `json:"updated_at"`
}

type Team struct {
	GormModelAI
	TeamName string `json:"team_name"`
}

type Player struct {
	GormModelAI
	UserName string `json:"user_name"`
	FullName string `json:"full_name"`
	TeamID   uint   `json:"team_id"`
	Team     Team `json:"team"`
}

func getInterfaces() (interface{}, interface{}) {
	v := &models.Player{}
	sl := make([]models.Player, 0)

	return v, sl
}

The code to do the queries was:
	singlePlayer, pls := getInterfaces()

	err = db.Preload("Team").Find(&pls).Error

	if err == nil {
		jtext, _ :=json.MarshalIndent(pls,"","\t")
		fmt.Printf("\nMarshalled string=%s\n",jtext)
	} else {
		fmt.Println(err)
	}

	fmt.Printf("Type of singlePlayer=%T\nType of &singlePlayer=%T",singlePlayer,&singlePlayer)
	db.Preload("Team").First(&singlePlayer, 2)

This code actually worked in that I would get a single player, or a collection of players, but the Team value wasn't loaded.
In my production code, I had two problems. The first was I had a function:
func getInterfaces() (v interface{},sl interface{}) {
	v = &models.Player{}
	sl = make([]models.Player, 0)

	return v, sl
}

what I found is that the type of v and sl was *interface{}. Evidently, when named results are used, the variables are initialized to zero of the type. In this case, for the interface, the dynamic type was *interface{} and the value was initially nil.
When  this code is used:
func getInterfaces() (interface{},interface{}) {
	v = &models.Player{}
	sl = make([]models.Player, 0)
	return v, &sl
}

then v is *models.Player, and sl is *[]models.Player.
Once I had that, and understood the types I was returning, then I saw that I needed to change the calls to:
db.Preload("Team").First(singlePlayer, 2)

repo: go-gorm/gorm


text:
Feature/json

[] Do only one thing
[] Non breaking API changes
[] Tested

What did this pull request do?

User Case Description

suggest to use it like https://github.com/go-gorm/datatypes/blob/master/json.go

Hi! Actually I accidentally raised this PR, I intended to raise it against my forked master :)
My change have a bit different purpose, but I will try to clean it up and raise later.

authors: buger jinzhu