-
Notifications
You must be signed in to change notification settings - Fork 66
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
Upgrade to net6 #77
Upgrade to net6 #77
Conversation
SourceGrid-huanlin supports .net6
replaced System.CodeDom with Microsoft.CSharp
Thanks for this contribution. I started to upgrade to VB6 but never found the time to finish it. I will try to incorporate it into the VB6 branch in the next few days. |
Nice, but no hurry on my part so enjoy spare time/holidays the way you want |
removed warning datetime
created a new branch (github-desktop-nimrof/upgrade-to-net6) with this PR. Please test. |
I have merged the net6 support into the bugfix branch. This contains some fixes (which don't clash with your changes as far as I could see). Also support for nodeguarding. Nodeguarding was recently included in V1.3 and in the latest main branch of CANopenNode. The latest commits were for exceptions I noticed during the Net6 tests ("extensions" is a typo, sorry). If you would like to support the CANopenEditor and maybe more often, I can ask Janez to make you a contributor. Help is very welcome. |
Code looks good to me, will test a little bit.
np, it makes sense now. good catch
That sounds tempting, but just a few things i want to be open about first.
|
@CANopenNode Not a problem for me, what do you think? @nimrof The clean-up is certainly a good idea. Structurally, there is certainly room for improvement. |
Sound good too me |
Looks good to me, just a few things:
edit: clarification |
A have no problems, there is no conflict-of-interest, more CANopen is better for me. Also I would like automated build & testing, clean-up, etc. My only demand is, to have a reliable CANopenNode exporter. I'm open for other improvements. It was not my project from the beginning, I'm not very skilled with c#. Mine is importer/exporter CanOpenXDD_1_1, CanOpenNodeExporter_V4 and some improvements in other parts. That was quite robust for me. I didn't want to change other things much (for backward compatibility?). I don't like the central part, which is now eds.cs file. I would prefer to turn eds.cs into an importer/exporter and make new central part with more clear database definition, especially for object dictionary. Unfortunately, standards are not very simple, there are electronic data sheets in eds files (ini file type) or in xdd files (xml file type), different versions. But actually object dictionary database is not that complex. Currently only reliable importer/exporter is CanOpenXDD_1_1, others do not save CANopenNode specific data correctly. But this is complex file. See here for some description: https://github.com/CANopenNode/CANopenNode/blob/master/doc/objectDictionary.md#xml-device-description-xml-device-description @trojanobelix, I merged bugfix branch into main and made new branch "upgrade-to-net6" with this PR. Maybe other branches could be removed? |
Thanks for the merge. I'll tidy up the branches when I get a chance. It was on my list anyway. I'm not a C# hero either and my aim was to make the TX RX mapping tab usable. It now works satisfactorily and makes my work easier. No more and no less. I would be happy if we could get support from @nimrof. |
Hi,
Sounds good. So something like this:
I would not work directly on main branch, but i think it would be beneficial to get the test and automation working on main branch, that way we can hopefully catch bugs when they are still pr. Is that something that could be merged into main via pr. in the not so distant future ? If not then that is okay too, i am just trying to find a workflow :) |
I made some git related job:
One advantage of Net4.8 is, that binaries can be simply run in Linux in Mono. Net6 does not work there directly. But this does not matter much. Branch "Net4.8" could stay in the old version, there are possible some fixes, if necessary. So maybe it is not necessary for "main" to stick on the old version. If current "upgrade-to-net6" branch is stable enough, "main" could be set to there. However, we should take care, that "main" won't stuck on some partly finished code. Otherwise, please don't limit yourself. |
@CANopenNode Totally agree @nimrof Perhaps we should also publish binaries as stable releases and the latest version as a test release (or whatever it's called). |
|
Good point. afik you can run .net6 code that uses windows forms with wine.
maybe, i will let you and trojanobelix decide.
Agree
That make sense to me, the users are probably c/c++ developer so if we can save them from learning how to compile c# that would be a good thing Strange. |
@nimrof. Regarding your last commits: I am not an expert in the .Net environment. I am at home in the embedded world. So I am very grateful to you for supporting the project. I can therefore not contribute much to the review in this area. So don't be surprised about the lack of comments. I am very happy that things are continuing at this level and hope to see more exciting new ideas from you. |
Unfortunately, I'm not a Github guru either. I would find it very helpful to be able to provide bugfix and production releases as a binary. Shouldn't be a problem, this is Github RNS, but unfortunately I don't know the normal workflow that well. So if you already have experience with it, that would be a good thing.... If not, that's not a problem either. The project is running, we have other hobbies too ;-) |
Thanks for the kind words.
No problem :)
Thanks, but do not expect this level of commits to continue :)
I have not done it automatically before, but i need to do it on my other c# canopen project so it might be good time to take a look, just want to get the dualbuild into main first. (1-3 pr. away)
👍 |
I think, @nimrof is doing a great job. I actually never had a full track on CANopenEditor internals and so I'm very grateful for those updates, even if I can't verify everything. (With CANopenNode repository I'm much more nagging, because I don't like unnecessary changes there). My philosophy for myself and others is something like, use as low rules as possible. And to many (unnecessary) discussion just takes time and energy. So I see no problem, even if @nimrof makes some cuts if he thinks, it is useful. Anyway, in the worst scenario, it is still possible to split git repo at some point. I make some tests of binaries occasionally. As long as I get the same behavior and same outputs, nothing changes for me. About dualbuild and v4.8 support, I think, it would be nice to have it, but only, if implementation is simple. If there are complications, I suggest just to forget v4.8. I suggest one other thing for this point. There are two formats, which are obsolete:
Maybe there are some other unused parts of the code. I just prefer cleaner code, so it is easier to keep track and to maintain. And another wish, to make life easier for all of us: |
btw #94
I can take a look.
There are at least some unused reference, but i am still a little nervous to change too much before more test are in place.
That is a big job, it looks like the import/export is not that easy to move away, but agree that it is needed. |
Yes it is a big job. But I can take major part of the internals. I have some experience with the standards, usability of the CANopen elements, etc. I can do this with some cooperation/discussion, as I'm not very familiar with the (modern) approaches in dotnet. Modernization of CANopenEditor would have a great usability also for my work. With current state of CANopenEditor I was never really satisfied - it is a useful and rich tool, but it was too messy to add functionalities. For example, when I was adding V4 exporter, I had to add/duplicate some methods(add mess) in eds.cs, but never really dive into the internals. And now, before we add new functionalities, it is time to make a clear and reliable foundation. Eds file reader and generator needs a review anyway. |
I fully agree with that. At the moment, we have a usable and functioning state. But it is too opaque and complex for further developments. |
Maybe the resharper extension can take care of some of the boring stuff. Does anyone have experience with this? |
I got no experience with it. |
Closing as we now have .net 4.8.1 and 6 side by side |
No. I will give it a try. |
Upgraded to .net 6 and its a big pr. :/
did some testing and afik there are some is the only problems
no export in com, there is a loot of warnings regarding com, but it looks like it works
There is loot of warnings and messages while compiling. Have not fixed any of them as that would make this pr. bigger, but can do it now
There are also some parts of the project files that can be cleaned up, but that would also make the pr. bigger and harder to follow, but can do it now
Comments?