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

Exception vnext: sequence contains no elements #269

Open
camillo-positano opened this issue May 18, 2022 · 2 comments
Open

Exception vnext: sequence contains no elements #269

camillo-positano opened this issue May 18, 2022 · 2 comments
Labels
bug Something isn't working community-feedback first-timer-friendly Light and easy start help wanted You're welcome to work on it right away
Milestone

Comments

@camillo-positano
Copy link

Hello,
i noticed that if you delete the folder v.0.00 and execute vnext --major it goes in exception saying:

Diagnostics stack trace captured a Sequence contains no elements.

I decided to check where it could have generated and found out that at line 152 of WorkspaceService.cs in yuniql-core there is:
localVersions.First().Major + 1

I think the first() is what generates the exception.
It would be cool to have the ability to create a major without having to keep the v.0.00 file.

To give you some detail on how this happened:

I wanted to start a repo which began with a major.
To do so i deleted the folder and wanted to create a major release from cli, which caused the exception.

The workaround was to keep v.0.00 and delete it afterwards.

Have a nice day,
a fellow developer 😄

@rdagumampan rdagumampan added this to the v1.4 milestone May 19, 2022
@rdagumampan
Copy link
Owner

Hi @camillo-positano , thanks for reaching out and interesting find. Im always amazed of what users can do hehe. Sure there's false assumption there that everyone starts with 0.00 :). Wil fix this in next release. Btw, you can also just create a folder v1.0.0, the vnext is just a helper.

P.S. Please star our repo ICYMI. It goes a long way in getting better stats and helping more people discover this tool :) Thanks!

@rdagumampan rdagumampan added bug Something isn't working help wanted You're welcome to work on it right away first-timer-friendly Light and easy start labels May 19, 2022
@camillo-positano
Copy link
Author

Thank you @rdagumampan i just starred it 😄.

Just wanted to let you know that if a create a folder 1.0.0 and remove the 0.00 the command run will fail as well.

Saying the folder 0.00 is missing.

Have a nice day 😃

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working community-feedback first-timer-friendly Light and easy start help wanted You're welcome to work on it right away
Projects
None yet
Development

No branches or pull requests

2 participants