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

New obsoleted models added but why? #769

Closed
modelica-trac-importer opened this issue Jan 14, 2017 · 18 comments
Closed

New obsoleted models added but why? #769

modelica-trac-importer opened this issue Jan 14, 2017 · 18 comments
Assignees
Labels
bug Critical/severe issue L: Electrical.Spice3 Issue addresses Modelica.Electrical.Spice3
Milestone

Comments

@modelica-trac-importer
Copy link

Reported by dietmarw on 29 Jun 2012 16:01 UTC
In e04efb6 two models were added to the Spice3 library:

  • Spice3.Internal.BJT_obsolete
  • Spice3.Internal.ModelicardBJT_obsolete
    I'm not sure why one would add a new obsoleted class that at the same time recommends using a different class. This just doesn't make any sense and should be corrected (as should be the newly added use of those classes).

Migrated-From: https://trac.modelica.org/Modelica/ticket/769

@modelica-trac-importer modelica-trac-importer added this to the MSL3.2.1 milestone Jan 14, 2017
@modelica-trac-importer modelica-trac-importer added bug Critical/severe issue L: Electrical.Spice3 Issue addresses Modelica.Electrical.Spice3 labels Jan 14, 2017
@modelica-trac-importer
Copy link
Author

Comment by majetta on 23 Jul 2012 09:11 UTC
We did not add new obolete models. We added the new models:

  • Spice3.Internal.BJT

  • Spice3.Internal.ModelcardBJT

These models are improvements of the formerly BJT and ModelcardBJT models. Since we are not allowed to remove the old models because of backwards compatibility, we renamed the old ones to

  • Spice3.Internal.BJT_old

  • Spice3.Internal.ModelcardBJT_old

@modelica-trac-importer
Copy link
Author

Comment by otter on 23 Jul 2012 09:28 UTC
If you rename a model, it is no longer backwards compatible. Therefore, your approach is not clear:

  • If your new models have all the parameters from the old models and the new parameters have defaults, that lead to the same behavior as the old models, then the new model is backwards compatible. However, in this case, you do not need to keep the "BJT_old" models and they should be removed.
  • If the above assumption does not hold, then the "old" model must keep its name, since otherwise a user model that utilizes this "old" model would have to change its model in order that it still accesses the "old" model.
    In such a case, the "new" model must get another name, such as "Spice3.Internal.BJT2".

@modelica-trac-importer
Copy link
Author

Comment by majetta on 23 Jul 2012 09:49 UTC
Since the new models do not fullfill the first assumpetion, I now gave them the names

  • Spice3.Internal.BJT2

  • Spice3.Internal.ModelcardBJT2

and did not change the "old" names.

This was done in revision 24c2072.

@modelica-trac-importer
Copy link
Author

Comment by dietmarw on 23 Jul 2012 10:23 UTC
To also mark that one should use the BJT2 instead, you should mark the BJT models as obsoleted (extends from Modelica.Icons.Obsolete + notice in the description and info layer). This will not break existing models but make users aware of the improved version(s).

@modelica-trac-importer
Copy link
Author

Comment by dietmarw on 23 Jul 2012 10:35 UTC
Also remember the fixes have to be applied to the 3.2.1 maintenance branch too.

@modelica-trac-importer
Copy link
Author

Comment by majetta on 24 Jul 2012 10:13 UTC
I marked the BJT and the ModelcardBJT models as obsolete (9ab21fd) in the trunk-version. I also did the changes in the 3.2.1 maintenance branch (r5316).

@modelica-trac-importer
Copy link
Author

Comment by dietmarw on 24 Jul 2012 10:43 UTC
There are still some loose ends here. Could you please check again were the obsoleted versions are still used in the library and update the usage to the new type.

Also it looks like there was some confusion because Spice3.Internal.Bjt3.bjtRenameParameters uses the obsoleted version were as the as obsolete marked version Spice3.Internal.Bjt.bjtRenameParameters uses the non-obsoleted BJT2 version. Is that on purpose?

I haven't checked any further but there might be more such ill dependencies that need fixing and since you got a better grasp on the structure I'll leave that to you. In principle, nothing in the library itself should use any obsoleted classes any longer, unless they are marked as obsoleted themselves.

And don't forget to fix the icons (see #782).

@modelica-trac-importer
Copy link
Author

Comment by anonymous on 30 Jul 2012 14:31 UTC
I marked theSpice3.Internal.Bjt3.bjtRenameParameters function as obsolete. Now it is correct, that is uses the obsolete BJT version. I also marked other obsolete models as osolete (18c6f47 and 81d21e3).

@modelica-trac-importer
Copy link
Author

Comment by majetta on 30 Jul 2012 14:34 UTC
Sorry, the last comment (number 8) was from me. I forgot to login.

@modelica-trac-importer
Copy link
Author

Comment by dietmarw on 30 Jul 2012 14:38 UTC
Remember the changes done in 18c6f47 and 81d21e3 still need to be applied to the maintenance 3.2.1 branch.

@modelica-trac-importer
Copy link
Author

Comment by majetta on 31 Jul 2012 06:01 UTC
Changes 18c6f47 and 81d21e3 are done in maintenance 3.2.1 (r5332)

@modelica-trac-importer
Copy link
Author

Comment by dietmarw on 31 Jul 2012 06:40 UTC
Only the therm is "obsolete" and not "osolete". You might like to fix that.

@modelica-trac-importer
Copy link
Author

Comment by majetta on 31 Jul 2012 07:09 UTC
Typo "osolete" changed into "obsolete" (r5334).

@modelica-trac-importer
Copy link
Author

Comment by dietmarw on 2 Aug 2012 13:48 UTC
Some where overlooked (edd86ac,r5369). Otherwise this should be finally fixed.

@modelica-trac-importer
Copy link
Author

Modified by majetta on 5 Apr 2013 12:12 UTC

@modelica-trac-importer
Copy link
Author

Changelog modified by majetta on 5 Apr 2013 12:12 UTC
Minor change in Electrical.Spice3

@modelica-trac-importer
Copy link
Author

Modified by majetta on 10 Apr 2013 11:28 UTC

@modelica-trac-importer
Copy link
Author

Changelog modified by majetta on 10 Apr 2013 11:28 UTC
Improved models in the Spice3 library were added. The old versions of these models cannot be removed because of backwards compatibility.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Critical/severe issue L: Electrical.Spice3 Issue addresses Modelica.Electrical.Spice3
Projects
None yet
Development

No branches or pull requests

2 participants