Error syncing a Proton Drive document

What is the problem you are having with rclone?

panic: runtime error: invalid memory address or nil pointer dereference reported when copying a Proton Drive document from the Proton Drive server to the local computer.

Note that the document is one native to Proton Drive; one creates it within the Proton Drive web application. I do not know what its underlying format is.

Run the command 'rclone version' and share the full output of the command.

rclone v1.70.2

  • os/version: ubuntu 24.04 (64 bit)
  • os/kernel: 6.11.0-29-generic (x86_64)
  • os/type: linux
  • os/arch: amd64
  • go/version: go1.24.4
  • go/linking: static
  • go/tags: none

Which cloud storage system are you using? (eg Google Drive)

Proton Drive

The command you were trying to run (eg rclone copy /tmp remote:tmp)

rclone -vv sync "remote:Temp/Hello World" ./ProtonDrive/Temp

The rclone config contents with secrets removed.

[remote]
type = protondrive
username = XXXXXXXXXXXXXX
password = XXXXXXXXXXXXXX
client_uid = XXXXXXXXXXXXXX
client_access_token = XXXXXXXXXXXXXX
client_refresh_token = XXXXXXXXXXXXXX
client_salted_key_pass = XXXXXXXXXXXXXX

A log from the command with the -vv flag

2025/07/04 23:19:55 DEBUG : rclone: Version "v1.70.2" starting with parameters ["rclone" "-vv" "sync" "remote:Temp/Hello World" "./ProtonDrive/Temp"]
2025/07/04 23:19:55 DEBUG : Creating backend with remote "remote:Temp/Hello World"
2025/07/04 23:19:55 DEBUG : Using config file from "/home/tony/.config/rclone/rclone.conf"
2025/07/04 23:19:55 DEBUG : proton drive root link ID 'Temp/Hello World': Has cached credentials
2025/07/04 23:19:57 DEBUG : proton drive root link ID 'Temp/Hello World': Used cached credential to initialize the ProtonDrive API
2025/07/04 23:19:59 DEBUG : fs cache: renaming child cache item "remote:Temp/Hello World" to be canonical for parent "remote:Temp"
2025/07/04 23:19:59 DEBUG : Creating backend with remote "./ProtonDrive/Temp"
2025/07/04 23:19:59 DEBUG : fs cache: renaming cache item "./ProtonDrive/Temp" to be canonical "/home/tony/ProtonDrive/Temp"
2025/07/04 23:20:00 DEBUG : Hello World: Need to transfer - File not found at Destination
2025/07/04 23:20:00 DEBUG : Hello World: Original file size missing
2025/07/04 23:20:00 DEBUG : Hello World: Original file size missing
2025/07/04 23:20:00 DEBUG : Hello World: file sha1 digest missing
2025/07/04 23:20:00 DEBUG : Hello World: Original file size missing
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x1a04986]

goroutine 1 [running]:
github.com/rclone/rclone/backend/protondrive.(*Object).Open(0xc000e4b040, {0x2ec1b20, 0x44c3d80}, {0xc0006ba920, 0x1, 0xc000332c40?})
	github.com/rclone/rclone/backend/protondrive/protondrive.go:877 +0x46
github.com/rclone/rclone/fs/operations.(*ReOpen).open(0xc000c462a0)
	github.com/rclone/rclone/fs/operations/reopen.go:147 +0x109
github.com/rclone/rclone/fs/operations.NewReOpen({0x2ec1b20, 0x44c3d80}, {0x2edb6b0, 0xc000e4b040}, 0xa, {0xc0006ba8e0, 0x1, 0x1})
	github.com/rclone/rclone/fs/operations/reopen.go:102 +0x4f5
github.com/rclone/rclone/fs/operations.Open({0x2ec1b20, 0x44c3d80}, {0x2edb6b0, 0xc000e4b040}, {0xc0006ba8e0, 0x1, 0x1})
	github.com/rclone/rclone/fs/operations/reopen.go:124 +0x6b
github.com/rclone/rclone/fs/operations.(*copy).manualCopy(0xc0006b9830, {0x2ec1b20, 0x44c3d80})
	github.com/rclone/rclone/fs/operations/copy.go:262 +0x4dc
github.com/rclone/rclone/fs/operations.(*copy).copy(0xc0006b9830, {0x2ec1b20, 0x44c3d80})
	github.com/rclone/rclone/fs/operations/copy.go:311 +0x170
github.com/rclone/rclone/fs/operations.Copy({0x2ec1b20, 0x44c3d80}, {0x2edab50, 0xc000e4ac80}, {0x0, 0x0}, {0x7fff7b97c133, 0xb}, {0x2edb6b0, 0xc000e4b040})
	github.com/rclone/rclone/fs/operations/copy.go:413 +0x4db
github.com/rclone/rclone/fs/operations.moveOrCopyFile({0x2ec1b20, 0x44c3d80}, {0x2edab50, 0xc000e4ac80}, {0x2edb640, 0xc0001ce370}, {0x7fff7b97c133, 0xb}, {0x7fff7b97c133, 0xb}, ...)
	github.com/rclone/rclone/fs/operations/operations.go:2093 +0xcf1
github.com/rclone/rclone/fs/operations.CopyFile(...)
	github.com/rclone/rclone/fs/operations/copy.go:418
github.com/rclone/rclone/cmd/sync.init.func1.1()
	github.com/rclone/rclone/cmd/sync/sync.go:245 +0x372
github.com/rclone/rclone/cmd.Run(0x1, 0x1, 0x44639c0, 0xc0009a9c00)
	github.com/rclone/rclone/cmd/cmd.go:255 +0x125
github.com/rclone/rclone/cmd/sync.init.func1(0x44639c0, {0xc00014aa20, 0x2, 0x3})
	github.com/rclone/rclone/cmd/sync/sync.go:229 +0xcb
github.com/spf13/cobra.(*Command).execute(0x44639c0, {0xc00014a930, 0x3, 0x3})
	github.com/spf13/cobra@v1.9.1/command.go:1019 +0xa91
github.com/spf13/cobra.(*Command).ExecuteC(0x4454d40)
	github.com/spf13/cobra@v1.9.1/command.go:1148 +0x46f
github.com/spf13/cobra.(*Command).Execute(...)
	github.com/spf13/cobra@v1.9.1/command.go:1071
github.com/rclone/rclone/cmd.Main()
	github.com/rclone/rclone/cmd/cmd.go:541 +0x31
main.main()
	github.com/rclone/rclone/rclone.go:14 +0xf

welcome to the forum,

the proton drive remote has not been updated in a long time, has bugs not getting fixed.
the primary author has not visited the forum in over a year.

This answer doesn't make any sense. If support for the proton backend was merged into rclone, then maintenance for that code becomes the responsibility of the project maintainers. Why push the responsibility back on the original developer? Their part is finished.

I should add, I am also experiencing the same problem as the OP. Any help or insights would be very much appreciated!

This is how it is. Rclone is community work - including ongoing support.

Some backends (Proton for example) are highly specialised and require intimate knowledge of inner remote workings. Original developer in order to get such remote support added to rclone commits to its maintenance. But as you can imagine there is no contract written in blood:) Most often than not it works. Unfortunately for Proton it did not.

It does not help that Proton itself does not seem to be interested in 3rd parties tools support. This remote was created using some reverse engineering which is far more complicated than using well documented API.

I think time has come to at least make a note in documentation that until somebody takes it over it is not recommended to use it any more.

Though it is clearly stated at the moment that:

Due to the fact that Proton Drive doesn't publish its API documentation, this backend is implemented with best efforts by reading the open-sourced client source code and observing the Proton Drive traffic in the browser.

NB This backend is currently in Beta. It is believed to be correct and all the integration tests pass. However the Proton Drive protocol has evolved over time there may be accounts it is not compatible with. Please post on the rclone forum if you find an incompatibility.

It should be clear for anybody that it is not ready for any production use.

welcome to the forum,

as explained by @kapitainsky, my answer makes perfect sense.


rclone is open source, you are welcome write the source code yourself
or
sponsor

1 Like

Thank you for that clarification. If I understand correctly then, backends are analogous to plugins, but merged into the main application. This organisational structure is a bit unusual in that it sounds like bug reports should be going directly to a dedicated Proton-backend project repo/forum, rather than rclone itself? Or is the backend developer considered as part of the core development team for the rclone project?

Interestingly enough, Proton has just released a preview version of the SDK that they say will be used as a future base for all of their apps. So there is now a bit of official "documentation", albeit only for JS (now) and C# (soon, apparently). Perhaps that can help someone in the future.

I'm not sure anyone in this thread is asking for production-use support. Merely reporting bugs and trying to contribute in some small way to improving rclone.

1 Like