Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

storage.Move() fails to move directories #5493

Closed
2 tasks done
rad756 opened this issue Feb 3, 2025 · 1 comment
Closed
2 tasks done

storage.Move() fails to move directories #5493

rad756 opened this issue Feb 3, 2025 · 1 comment
Labels
blocker Items that would block a forthcoming release bug Something isn't working

Comments

@rad756
Copy link

rad756 commented Feb 3, 2025

Checklist

  • I have searched the issue tracker for open issues that relate to the same problem, before opening a new one.
  • This issue only relates to a single bug. I will open new issues for any other problems.

Describe the bug

$path is just the path of the folder/directory

On Linux:
write $path: copy_file_range: is a directory

On Windows:
read $path: Incorrect function.

How to reproduce

When trying to use the move function on a directory/folder, I get the following error listed above

Screenshots

The code below results with RootURI looking like this on Linux
Image

Example code

package main

import (
	"fmt"

	"fyne.io/fyne/v2/app"
	"fyne.io/fyne/v2/storage"
)

func main() {
	fyneApp := app.NewWithID("MoveFailTestCode")

	path, err := storage.Child(fyneApp.Storage().RootURI(), "Folder")
	fmt.Println(err)

	exists, err := storage.Exists(path)
	fmt.Println(err)

	if !exists {
		err := storage.CreateListable(path)

		if err != nil {
			fmt.Println(err)
		}
	}

	newPath, err := storage.Child(fyneApp.Storage().RootURI(), "RenamedFolder")
	fmt.Println(err)

	err = storage.Move(path, newPath)
	fmt.Println(err)
}

Fyne version

2.5.4

Go compiler version

1.23.4

Operating system and version

Linux OpenSuse Tumbleweed && Windows 10

Additional Information

No response

@rad756 rad756 added the unverified A bug that has been reported but not verified label Feb 3, 2025
@andydotxyz andydotxyz added bug Something isn't working blocker Items that would block a forthcoming release and removed unverified A bug that has been reported but not verified labels Feb 5, 2025
@andydotxyz andydotxyz added this to the "F" release, Early 2025 milestone Feb 5, 2025
@andydotxyz
Copy link
Member

That's now resolved on develop branch

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocker Items that would block a forthcoming release bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants