Opened 13 months ago
Closed 11 months ago
#30457 closed enhancement (fixed)
fix typos in occurrence, occurred, occurring
Reported by:  chapoton  Owned by:  

Priority:  minor  Milestone:  sage9.3 
Component:  documentation  Keywords:  
Cc:  Merged in:  
Authors:  Frédéric Chapoton  Reviewers:  Samuel Lelièvre 
Report Upstream:  N/A  Work issues:  
Branch:  2459cd8 (Commits, GitHub, GitLab)  Commit:  2459cd806a5a8ed4ad2da5fe884fbe21672d21a1 
Dependencies:  Stopgaps: 
Description
Change History (19)
comment:1 Changed 13 months ago by
 Branch set to u/chapoton/30457
 Commit set to 7d629a2f0572aab41778a5e6f7c5eff9278ec39b
 Status changed from new to needs_review
comment:2 Changed 13 months ago by
 Commit changed from 7d629a2f0572aab41778a5e6f7c5eff9278ec39b to c4ee43b00a3ffcd18d204f793052dac838b2ef46
Branch pushed to git repo; I updated commit sha1. New commits:
c4ee43b  some pyflakes details in modified files

comment:3 Changed 13 months ago by
 Reviewers set to Samuel Lelièvre
Agree with all the occur*
fixes here.
One comment about the removal of the CommonR = ...
line at the end of this if/else block:
if hasattr(PARENT,'_P'):
CommonR = PARENT._P
else:
VarList = set([])
for P in TODO:
if P._p!=0:
if P.is_unit(): # self generates all of PARENT
if RStrat is not None:
RStrat.add_generator(PARENT(1))
return SymmetricIdeal(PARENT,[PARENT(1)], coerce=False)
VarList = VarList.union(P._p.parent().variable_names())
VarList = list(VarList)
if not VarList:
return SymmetricIdeal(PARENT,[0])
VarList.sort(key=PARENT.varname_key, reverse=True)
from sage.rings.polynomial.polynomial_ring_constructor import PolynomialRing
 CommonR = PolynomialRing(self.base_ring(), VarList, order=self.ring()._order)
This block is at lines 502518 of src/sage/rings/polynomial/symmetric_ideal.py
.
Since the value of CommonR
set in this block is not used after that
(whether it was set in the "if" or in the "else" part), and neither
is the value of VarList
, the whole if/else block could become:
if not hasattr(PARENT, '_P'): VarList = set() for P in TODO: if P._p != 0: if P.is_unit(): # self generates all of PARENT if RStrat is not None: RStrat.add_generator(PARENT(1)) return SymmetricIdeal(PARENT, [PARENT(1)], coerce=False) VarList = VarList.union(P._p.parent().variable_names()) VarList = list(VarList) if not VarList: return SymmetricIdeal(PARENT, [0])
This could be done here or elsewhere, as quite distinct from the rest of the present ticket.
Possibly PARENT(1)
should be PARENT.one()
.
comment:4 Changed 13 months ago by
 Commit changed from c4ee43b00a3ffcd18d204f793052dac838b2ef46 to 9fab3e1e08e2441eb92cdc5e1b176ea31d317890
Branch pushed to git repo; I updated commit sha1. New commits:
9fab3e1  fixing pyflakes warnings in symmetric ideals

comment:5 Changed 13 months ago by
Voilà, voilà. Merci pour la suggestion.
comment:6 Changed 13 months ago by
fully green bot, please review
comment:7 Changed 13 months ago by
In src/sage/graphs/generic_graph.py
, while we're at it, maybe fix plural:
 # We count the number of occurrence of each distinct label + # We count the number of occurrences of each distinct label
comment:8 Changed 13 months ago by
And regarding R(1)
vs R.one()
here is one more:
 return SymmetricIdeal(self.ring(), [self.ring()(1)], + return SymmetricIdeal(self.ring(), [self.ring().one()],
comment:9 Changed 13 months ago by
Maybe fix "can not" > "cannot"? or maybe do that at a wider scale in another ticket.
Then positive review.
comment:10 Changed 13 months ago by
Changing R(1)
to R.one()
and R(0)
to R.zero()
at scale could also be another ticket.
comment:11 Changed 13 months ago by
 Commit changed from 9fab3e1e08e2441eb92cdc5e1b176ea31d317890 to bc66b56c0ada7294961273c6d09351a56593ddc4
Branch pushed to git repo; I updated commit sha1. New commits:
bc66b56  extra details

comment:12 Changed 13 months ago by
Et voilà. C'est bon, maintenant ?
comment:14 Changed 13 months ago by
 Commit changed from bc66b56c0ada7294961273c6d09351a56593ddc4 to 724ad120ee82340b47b8da1598d59f7aeed31a1d
 Status changed from positive_review to needs_review
Branch pushed to git repo; I updated commit sha1 and set ticket back to needs_review. New commits:
724ad12  Merge branch 'u/chapoton/30457' in 9.2.b12

comment:15 Changed 13 months ago by
 Status changed from needs_review to positive_review
rebase, just fixing an easy conflict in combinatorial_face.pyx
setting back to positive
comment:16 Changed 11 months ago by
 Milestone changed from sage9.2 to sage9.3
comment:17 Changed 11 months ago by
 Commit changed from 724ad120ee82340b47b8da1598d59f7aeed31a1d to 2459cd806a5a8ed4ad2da5fe884fbe21672d21a1
 Status changed from positive_review to needs_review
Branch pushed to git repo; I updated commit sha1 and set ticket back to needs_review. New commits:
2459cd8  Merge branch 'u/chapoton/30457' in 9.3.b0

comment:18 Changed 11 months ago by
 Status changed from needs_review to positive_review
trivial rebase, set back to positive
comment:19 Changed 11 months ago by
 Branch changed from u/chapoton/30457 to 2459cd806a5a8ed4ad2da5fe884fbe21672d21a1
 Resolution set to fixed
 Status changed from positive_review to closed
New commits:
fix typos in occurrence, occurred, occurring (all take two r)