这是indexloc提供的服务,不要输入任何密码
Skip to content

Empty content like space or line break raise an error #3

@DuncanNaves

Description

@DuncanNaves
./convsun ~/Platform/Projects/symfony-6-3-demo-1/
2025/01/08 15:01:59 ./convsun /Platform/Projects/symfony-6-3-demo-1/
2025/01/08 15:01:59 
convsun from ADV-initial version development

Enter the project path to convert [./]: /Platform/Projects/symfony-6-3-demo-1/
2025/01/08 15:02:04 Convert Project to Upsun...
2025/01/08 15:02:04 Discover found '.platform.app.yaml' at: /Platform/Projects/symfony-6-3-demo-1/.platform.app.yaml
2025/01/08 15:02:04 Discover found 'routes.yaml' at: /Platform/Projects/symfony-6-3-demo-1/.platform/routes.yaml
2025/01/08 15:02:04 Discover found 'services.yaml' at: /Platform/Projects/symfony-6-3-demo-1/.platform/services.yaml
WARNING: file 'applications.yaml' not found in directory '/Platform/Projects/symfony-6-3-demo-1/.platform'
panic: runtime error: index out of range [0] with length 0

goroutine 1 [running]:
github.com/upsun/lib-sun/readers.readConfigFile(0x14000175c00, {0x140001fa460, 0x4f})
	/go/pkg/mod/github.com/upsun/lib-sun@v0.3.13/readers/psh_config.go:45 +0x28c
github.com/upsun/lib-sun/readers.ReadServices(...)
	/go/pkg/mod/github.com/upsun/lib-sun@v0.3.13/readers/psh_config.go:55
github.com/upsun/convsun/internal/logic.Convert({0x14000124a00, 0x38}, {0x14000124ac0, 0x3e})
	/github/workspace/internal/logic/convert_config.go:30 +0x190
main.main()
	/github/workspace/cmd/upsun_convert.go:52 +0x1b4

Seems like having an empty file containing a space or a line break.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions