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

test: use Nimble to manage Nim #222

Open
wants to merge 23 commits into
base: master
Choose a base branch
from
Open

Conversation

romanzac
Copy link

Test PR to understand wether we can reliably use Nimble to manage Nim.

run: |
curl -O -L -s -S https://github.com/nim-lang/nimble/releases/download/latest/nimble-linux_x64.tar.gz
tar xvfz nimble-linux_x64.tar.gz
./nimble install nim
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

broadly, we should be able to use nimble setup here, which should install a package-local version of nim that nimble test later uses

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Author

@romanzac romanzac Jun 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nimble install [email protected] also worked out when full version tag was specified. Effective Nimble version during test run was however nimble v0.13.1 compiled at 2024-06-25 17:59:37.
https://github.com/status-im/nim-stew/actions/runs/9667227572/job/26668548913

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nimble install [email protected] ended well, but similar situation with older Nim. This time instead of Nim 2.1.1 older Nim 2.0.6 was effectively used to run the tests.
https://github.com/status-im/nim-stew/actions/runs/9667421954/job/26669209430

Copy link
Author

@romanzac romanzac Jun 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What would we like to see here? Personally, I believe the easiest solution would be for Nimble to be capable of installing older versions of Nim. Additionally, we should update older Nim versions by backporting compatibility with newer versions of Nimble. Up to some limit of course.

Example:
Nim 1.6 is the last major.minor version for v1, and its fix versions (e.g., 1.6.20) could be managed by Nimble, which could also handle Nim v2 versions.

This would be beneficial for developers who need to stick with Nim 1.6 for a long time, potentially extending its lifetime by 2+ years. Downside is a growing technical debt when finally moving to Nim 2.0.

If this approach is too complex or slows down innovation, we might consider following the rustc and cargo approach. This involves moving faster through versions and having the same versioning for both the compiler and the package manager. Rust also uses editions to create consistency across many versions. Is there any such promise for Nim major versions?

What are your thoughts @arnetheduck ?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've found a discussion on the related topic in "very old high priority" feature request 654 at issues at nimble at minlang. I feel like we would need to start collecting numbers and data points to give sea of opinions clarity they deserve. :)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've compiled report about what I am doing. To tidy up and have something presentable for community. https://www.notion.so/Nim-Tooling-Test-Reports-7b25687860ae41afaa2d4f22af8d07f1?pvs=4

What should we do next ? @arnetheduck

Copy link
Author

@romanzac romanzac Jun 27, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@romanzac romanzac marked this pull request as ready for review July 1, 2024 07:05
@romanzac romanzac requested a review from arnetheduck July 1, 2024 08:38
echo "PLATFORM=$PLATFORM" >> $GITHUB_ENV

ncpu=
MAKE_CMD="make"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

these make sections are not needed

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aren't they needed for Windows ?

Right now this PR is only to test and collect information. In the test report, there is only one passing combination - Test01. When Nimble installs Nim 2.0 and Nimble 0.14.2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants