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

Help needed: how to contribute to the cpp project? Missing 'CONTRIBUTING' kind of guide. #253

Open
daantimmer opened this issue Jun 17, 2024 · 8 comments

Comments

@daantimmer
Copy link

🤔 What's the problem you've observed?

I would like to contribute to the cpp project. But am not able to spin up a development environment (easily).

We don't have a development environment on our machines. All development is done through devcontainers. Setting up a container for the cpp project seems tedious and there are undocumented dependencies in order to build the cpp project.

✨ Do you have a proposal for making it better?

Add a devcontainer configuration for the cpp project. With dependencies either pre-installed or through a shell script.

📚 Any additional context?

No response

@daantimmer
Copy link
Author

Tagging @chybz since they are the original authors of the cpp project.

@chybz I would like to contribute some possible improvements on an API/structure level. But setting up an environment where I can build and test the cpp project seems quite tedious. Please advice :-)

@chybz
Copy link
Contributor

chybz commented Jun 17, 2024

Hey @daantimmer ! Thanks for your message and suggestion. While I may not have the time right now to author a CONTRIBUTING.md(should be possible at the end of this week), do you think looking at test-cpp.yml could help you in any way ?

@daantimmer
Copy link
Author

Hello @chybz do you happen to have a more direct way of contact not via github? I have some thoughts I would like to discuss, but preferably via some other medium.

To respond to your suggestion. Yes, test-cpp.yml was of help. Although for some reason the cc build failed with linker errors. clang worked fine. Probably the (g)cc issue is on my side. Something something PEBKAC.

Some questions regarding the build environment:

  • what is cmate, google isn't helpful

  • instead of using cmate, you can use FetchContent(_Declare) to get both the cucumber_messages and nlohmann_json dependencies.

    • this allows configuring/building directly without the need for an additional 'get dependency' step.
  • in general it is ill advised to use globbing for source/header files

  • in some preliminary testing I've found it is easier to not use the cmake/cmate tools, and use what cmake has to offer directly:

    • use fetchcontent as above
    • use CMakePreset.json. Example:
      • cmake --preset host. <- to configure for:
      • cmake --build --preset host-release. (Build only) or
      • cmake --build --preset host-install. (Build and install)
  • The code/api suggestions that I have are more related to the way cucumber/messages/cpp works. Shall I discuss those here or there?

@luke-hill
Copy link
Contributor

ping @ursfassler - You were working on some cpp stuff recently.

Which area/s are you looking to work on @daantimmer - If you come to slack there may be people who can give some bits of help.

For example the cpp implementation of cucumber uses cucumber ruby wire and cucumber ruby, which I could help with

@chybz
Copy link
Contributor

chybz commented Jul 8, 2024

@luke-hill I think @daantimmer was referring to the new stuff I added in the cpp directory recently, which he started using a few months ago. I definitely need to polish some things around usability and documentation, that's a sure thing. Hope to have that out in the near future.

@daantimmer
Copy link
Author

For example the cpp implementation of cucumber uses cucumber ruby wire and cucumber ruby, which I could help with

We need a pure C++ runner implementation. Much like Specflow. Therefore I am using the cpp implementation to build one. I am willing to contribute where I can to that project. But not to the wire proxy runner version.

@luke-hill
Copy link
Contributor

@daantimmer - In the short term (Lets say 6-12months), this won't change. The reasons for this were discussed in the relevant c++ repos.

I believe the next steps are updating the cpp implementation of cucumber to use the latest versions - currently many revisions are using cucumber-ruby v2 which is ancient.

Once this is done (Which owing to the fact most are volunteers, may take some time). Then I think the next steps would be to consider using a full cpp library and implementation of cucumber - NB: Doing this will require a lot of work

@daantimmer
Copy link
Author

No problem at all. I fully understand, and respect, the fact things will take time because if volunteers. I'll happily continue with my cpp-runner version based on the existing gherkin-cpp and messages-cpp implementation.

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

No branches or pull requests

3 participants