Skip to content

Conversation

@vincent-aviva
Copy link

@vincent-aviva vincent-aviva commented Mar 11, 2025

  • Upgrade .Net version to v8
  • Upgrade packages to latest versions
  • Rename ProjectId to EnvironmentId

Motivation

#193 Updated the .Net versions to .Net 8 because .net 6 is out of support

Updated the packages to use the latest, the only exeption is FluentAssertions because starting of version 8 you need to have a license. Therefore i set it to not use version 8 by setting the version to [7.2.0,8.0.0).

#194 With the update of the packages, also the Kontent packages where updated and these contained the change from ProjectId to EnvironmentId.
For the commandline i took the liberty of adding the -i (from id) as an argument because -e was already in use.

Checklist

  • Code follows coding conventions held in this repo
  • Automated tests have been added
  • Tests are passing
  • Docs have been updated (if applicable)
  • Temporary settings (e.g. variables used during development and testing) have been reverted to defaults

How to test

If manual testing is required, what are the steps?

Vincent van der Laan added 2 commits March 11, 2025 13:24
Rename ProjectId to EnvironmentId
@vincent-aviva vincent-aviva requested review from a team and pokornyd as code owners March 11, 2025 12:36
@pokornyd
Copy link
Member

hello Vincent, thank you very much for your submission. allow me to review the code and get back to you with updates

@pokornyd
Copy link
Member

thank you for your remarks. I took the liberty of further refactoring the code and replacing old references to projectId, incorrectly changing the mappings in the process. I restored them to your previous, backwards compatible version.

@vincent-aviva
Copy link
Author

thank you for your remarks. I took the liberty of further refactoring the code and replacing old references to projectId, incorrectly changing the mappings in the process. I restored them to your previous, backwards compatible version.

Your welcome, and indeed saw that you reverted some things.
For the rest the further refactorings also are looking good, but i did not want to change things like primary constructors because i did not knew if Kontent wanted to use it.

Thank you for further picking up the work, looking to forward to update the tool soon :)

Copy link
Member

@pokornyd pokornyd left a comment

Choose a reason for hiding this comment

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

I further simplified some leftover legacy initializations.

Since this will be a breaking change, I went through the other submitted issues to see if we could include in in this release, though I'll need a clarification on those from our development. it appears some of the issues may no longer be relevant.

either way, I'd be creating a separate PR for those. feel free to go through my changes and let me know if you have any remarks, otherwise, we can merge this

@vincent-aviva
Copy link
Author

@pokornyd I would say, lets merge :)

@pokornyd pokornyd merged commit ad6104f into kontent-ai:master Apr 3, 2025
1 check passed
@pokornyd
Copy link
Member

pokornyd commented Apr 3, 2025

Hello again @vincent-aviva. I merged the changes only to discover we have an intermittent issue with one of the tests. specifically, userMessageLogger tests and StringWriter used within them can sometime get polluted from a previously run test that uses Console.Error.Writeline. I believe it's because the stringwriter and the usermessagelogger (which still uses Console.Error.Writeline under the hood) make use of underlying .NET TextWriter, which doesn't flush and can sometimes leave a leftover string, effectively failing the string comparison tests. I will debug this further and fix it before releasing version 9.0.0, thanks for your patience.

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.

Use Environment ID instead of Project ID Add compatibility for .Net 8.0

2 participants