A node type cannot be defined outside the kernel assembly: five of Entity's abstract members are internal
Les mainteneurs répondent en général sous 1 jour
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 5/5
- Temps estimé
- Plus d'une semaine
- Accessibilité débutants
- 35/100
- Type d'issue
- Fonctionnalité
- Clarté
- Clairement spécifiée
- Activité
- Active
- Stack technique
- csharp
- Domaine
- backend-api-design
Piste de recherche
Commencez par lire les cinq définitions de membres nommées dans Core/Entity/Entity.Definition.cs, Functions/TreeAnalyzer/Sort.Definition.cs, Functions/Evaluation/Evaluation.Definition.cs, Functions/Output/ToSympy.Definition.cs et Functions/Continuous/Solvers/InvertNode.Definition.cs, ainsi que Docs/Contributing/Packaging.md et Docs/Contributing/Trimming.md. Exécutez EveryNodeSurvivesEveryPipelineTest et examinez la barrière trimming/AOT. C’est terminé lorsqu’un contrat documenté, un test de pipeline dans un assembly séparé et le maintien des vérifications de réflexion et AOT sont présents.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
What is wrong
Entity is public abstract partial record, and its constructor is protected, which reads as an
invitation to derive from it. But a subclass in another assembly does not compile. Five of its
abstract members are internal or private protected, so an external type can never satisfy them:
| member | accessibility | where |
|---|---|---|
Priority |
internal abstract |
Core/Entity/Entity.Definition.cs:378 |
SortHashName(SortLevel) |
private protected abstract |
Functions/TreeAnalyzer/Sort.Definition.cs:19 |
IntrinsicCondition |
private protected abstract |
Functions/Evaluation/Evaluation.Definition.cs:72 |
ToSymPy() |
internal abstract |
Functions/Output/ToSympy.Definition.cs:13 |
InvertNode(Entity, Entity) |
private protected abstract |
Functions/Continuous/Solvers/InvertNode.Definition.cs:30 |
Deriving from Entity in a separate assembly fails with CS0534, naming each of those five among
the members it cannot implement. This is not a policy that could be relaxed by an
InternalsVisibleTo: a published extension package cannot be on that list.
Why it matters, and what is behind it
This is the concrete blocker under several roadmap items, and it is not the one they name.
#746 item 56 says the extensibility seam
is #338 — looking a type up so it can be
parsed from a string. That is the second half. The first half is being able to write the type at
all, and today you cannot. The same wall sits under item 53 (groups, rings and fields as
first-class, #440) and under the whole
tier-9 domain-package idea, which assumes a geometry or statistics pack can contribute node types.
It also means one thing the packaging decision cannot decide. Docs/Contributing/Packaging.md
(#746 item 78) works out which capabilities belong in the kernel and which ship separately, and its
answer for domain packages is blocked, not decided — because a package boundary is not what is
in the way here. Moving the LaTeX printer or the SymPy exporter out of the kernel runs into the same
five members from the other side: they are abstract members of Entity, so moving them means either
this contract becoming extensible or a visitor over all 68 node types.
Scope
This is a design decision before it is an implementation, and it should be argued before it is
built. The shape of the question:
- Which of the five are genuinely part of a node's public contract, and which are engine internals
that a visitor or a registry should own instead?ToSymPyandSortHashNamelook like the second
kind;PriorityandIntrinsicConditionlook like the first. - If a member becomes
publicorprotected, it becomes a compatibility surface — every future
change toSortLevel,Priorityor theInvertNodesignature is then breaking. That is the real
cost and it should be stated before the change, not discovered after. - Is the answer instead a sealed node hierarchy plus an explicit extension point — a node kind
that carries a name and an operation table — so that a domain package contributes data rather than
a subclass? That keepsEntityclosed, which is what makes exhaustive matching and the
EveryNodeSurvivesEveryPipelineTestreflection sweep work today. - Whatever is chosen must be trimming- and NativeAOT-safe: explicit registration, no runtime assembly
scanning. See #363,
#552 and
Docs/Contributing/Trimming.md.
Acceptance criteria
- A written decision in
Docs/Contributing/, saying what a node type outside the kernel may and may
not do, and which of the five members are part of the contract. - A test that compiles a node type from a separate assembly and puts it through the pipeline —
parse is not required, butToString,Latexize,InnerSimplified, substitution and structural
equality are. A test that only asserts the type exists proves nothing; this has to build. EveryNodeSurvivesEveryPipelineTeststill passes, and it is stated whether an external node is
in scope for it.- No new reflection on a hot path, and the trimming/AOT gate stays green.
Dependencies
Independent of everything currently open. It does not depend on
#338 — it is what #338 needs, not the
reverse. It is a prerequisite for #746 items 53 and 56 and for tier 9.
Found while measuring package boundaries for #746 item 78.
- Langage dominant
- C#
- Étoiles
- 832
- Forks
- 79
- Merge moyen
- 1 h 12 min
- PR mergées (30 j)
- 518
Préparer son environnement
- Aucun Dockerfile ni fichier Docker Compose
- Aucun modèle de pull request
- Lire le guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de ASC-Community/AngouriMath
-
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
ASC-Community/AngouriMath#2220 · 4 commentaires ·
Les mainteneurs répondent en général sous 1 jour
-
Opinions wanted
Difficulté 4/5 Plus d'une semaine Accessibilité débutants 15/100
ASC-Community/AngouriMath#2319 · 4 commentaires ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 4/5 3-5 jours Accessibilité débutants 18/100
ASC-Community/AngouriMath#2298 ·
Les mainteneurs répondent en général sous 1 jour
-
The kernel under WebAssembly: 1.26 MB Brotli over the bare runtime, and 0.2 s to the first SimplifyOuverte
Difficulté 3/5 Une demi-journée Accessibilité débutants 48/100
ASC-Community/AngouriMath#2296 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 5/5 Plus d'une semaine Accessibilité débutants 25/100
ASC-Community/AngouriMath#2293 · 2 commentaires ·
Les mainteneurs répondent en général sous 1 jour
Toutes les issues de ASC-Community/AngouriMath
Issues similaires
-
Difficulté 2/5 1-3 heures Accessibilité débutants 68/100
Les mainteneurs répondent en général sous 1 jour
-
Sample solution restore fails with NU1109 (Microsoft.Extensions.Logging.Abstractions downgrade)Ouverte
Difficulté 2/5 1-3 heures Accessibilité débutants 82/100
ardalis/CleanArchitecture#1150 ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 1/5 Moins d'une heure Accessibilité débutants 82/100
reacher-z/Awesome-REA#3585 ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 2/5 1-3 heures Accessibilité débutants 64/100
resend/resend-dotnet#174 ·
-
Add Vigil (BofStudios/vigil)Ouvertearea:data coverage
Difficulté 1/5 Moins d'une heure Accessibilité débutants 68/100
reacher-z/Awesome-CUA#5039 ·
Les mainteneurs répondent en général sous 19 jours