File: external_remote_protocol_unable_to_parse_command.mdwn

package info (click to toggle)
git-annex 10.20230126-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 69,344 kB
  • sloc: haskell: 74,654; javascript: 9,103; sh: 1,304; makefile: 203; perl: 136; ansic: 44
file content (33 lines) | stat: -rw-r--r-- 2,335 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
### Please describe the problem.

I'm writing an [external special remote](/design/external_special_remote_protocol) and am unable to send GETSTATE in response to CHECKPRESENT, e.g.

[[!format sh """
copy foo [2022-03-21 12:31:22.499943048] (Utility.Process) process [3998210] chat: /home/ben/go/bin/git-annex-remote-blah []
[2022-03-21 12:31:22.503831297] (Annex.ExternalAddonProcess) /home/ben/go/bin/git-annex-remote-blah[1] --> VERSION 1
[2022-03-21 12:31:22.503974302] (Annex.ExternalAddonProcess) /home/ben/go/bin/git-annex-remote-blah[1] <-- EXTENSIONS INFO GETGITREMOTENAME ASYNC
[2022-03-21 12:31:22.504199734] (Annex.ExternalAddonProcess) /home/ben/go/bin/git-annex-remote-blah[1] --> UNSUPPORTED-REQUEST
[2022-03-21 12:31:22.50428745] (Annex.ExternalAddonProcess) /home/ben/go/bin/git-annex-remote-blah[1] <-- PREPARE
[2022-03-21 12:31:22.504410356] (Annex.ExternalAddonProcess) /home/ben/go/bin/git-annex-remote-blah[1] --> GETCREDS auth_token
[2022-03-21 12:31:22.504586934] (Annex.ExternalAddonProcess) /home/ben/go/bin/git-annex-remote-blah[1] <-- CREDS  ellided
[2022-03-21 12:31:22.504764648] (Annex.ExternalAddonProcess) /home/ben/go/bin/git-annex-remote-blah[1] --> PREPARE-SUCCESS
[2022-03-21 12:31:22.504835875] (Annex.ExternalAddonProcess) /home/ben/go/bin/git-annex-remote-blah[1] <-- CHECKPRESENT SHA256E-s19--3b99fd544e5e49915ca060f193c615caf82a045b1145672dd6f2181473fd516d
[2022-03-21 12:31:22.504954457] (Annex.ExternalAddonProcess) /home/ben/go/bin/git-annex-remote-blah[1] --> GETSTATE foo

  external special remote protocol error, unexpectedly received "GETSTATE foo" (unable to parse command)
[2022-03-21 12:31:22.510269196] (Utility.Process) process [3998217] chat: git ["--git-dir=.git","--work-tree=.","--literal-pathspecs","-c","annex.debug=true","cat-file","--batch"]
(unable to use special remote due to protocol error) failed
"""]]

Have I misunderstood the protocol or is this a bug?

### What version of git-annex are you using? On what operating system?

10.20220128-g7e9ebea91 on Debian


### Have you had any luck using git-annex before? (Sometimes we get tired of reading bug reports all day and a lil' positive end note does wonders)

I use git-annex successfully constantly and have done for years. :-) First time writing a special external remote, though.

> [[notabug|done]] --[[Joey]]