git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] advice: refactor advise API

From
Taylor Blau <me@ttaylorr.com>
Date
Feb 12, 2020, 20:57 UTC
Message-ID
<20200212205725.GF4364@syl.local>
In-Reply-To
<CACg5j26ROdUAqCNPMRoORweEEDaUyeZvSPKS0bYLt9qYART4bA@mail.gmail.com>
On Tue, Feb 11, 2020 at 01:08:48PM +1300, Heba Waly wrote:
Show 13 quoted lines
> On Tue, Feb 11, 2020 at 8:42 AM Taylor Blau <me@ttaylorr.com> wrote:
> >
> > On Mon, Feb 10, 2020 at 11:30:46AM -0800, Junio C Hamano wrote:
> > > Another thing.
> > >
> > > advise_ng() may have been a good name for illustration but is a
> > > horrible name for real-world use (imagine we need to revamp the API
> > > one more time in the future---what would it be called, which has to
> > > say that it is newer than the "next generation"?
> > > advise_3rd_try()?).
>
> As I mentioned earlier, this patch is meant to be used as a transition
> between the current advise() and the refactored one.

Ah, thanks for pointing it out, and I'm sorry that I missed reading it in my first review. Your idea sounds quite good to me, and thanks for working on this.

Show 35 quoted lines
> So the name is just temporary and it'll be renamed to advise() once
> the transition is done.
> But if we want to keep both functions, or want a better name because
> it's an open-source project and the author might not complete the
> transition, then I'll try to think of another name.
>
> > What about calling this new API 'advise()'? The first patch could call
> > it 'advise_ng' or whatever other temporary name we feel comfortable
> > using, and then each subsequent patch would update callers of 'advise()'
> > to use 'advise_ng()'. Once those patches have been applied, and no other
> > callers of 'advise()' exist, a final patch can be applied on top to
> > rename 'advise_ng()' to 'advise()', and update the names of all of the
> > callers.
> >
>
> Yes, that's what I would like to do.
>
> > This makes for a rather noisy final patch, but the intermediate states
> > are much clearer, and it would make this series rather self-contained.
> >
> > On the other hand, having a version of 'advise_ng()' on master makes
> > this topic more incremental, meaning that we can pick it up and put it
> > down at ease and have more self-contained projects.
> >
> > I don't really have a preference between the two approaches, but if we
> > go with the latter, I do think we need something better than
> > 'advise_ng'. Maybe 'advise_warn'? I don't know.
> >
> > > Thanks.
> >
> > Thanks,
> > Taylor
>
> Thanks,
> Heba

Thanks, Taylor

Previous: Heba WalyNext: Heba Waly
Message 7 of 76 in “advice: refactor advise API”
  1. advice: refactor advise APIHeba Waly via GitGitGadget, Feb 10, 2020
  2. Derrick StoleeFeb 10, 2020
  3. Junio C HamanoFeb 10, 2020
  4. Taylor BlauFeb 10, 2020
  5. Emily ShafferFeb 10, 2020
  6. Heba WalyFeb 11, 2020
  7. Taylor BlauFeb 12, 2020
  8. Heba WalyFeb 10, 2020
  9. Derrick StoleeFeb 11, 2020
  10. Jeff KingFeb 10, 2020
  11. Emily ShafferFeb 10, 2020
  12. Heba WalyFeb 11, 2020
  13. Jeff KingFeb 11, 2020
  14. Jeff KingFeb 11, 2020
  15. Heba WalyFeb 11, 2020
  16. Junio C HamanoFeb 10, 2020
  17. Heba WalyFeb 11, 2020
  18. Junio C HamanoFeb 11, 2020
  19. 0/2 [RFC][Outreachy] advice: refactor advise APIHeba Waly via GitGitGadget, Feb 16, 2020
  20. 2/2 advice: extract vadvise() from advise()Heba Waly via GitGitGadget, Feb 16, 2020
  21. 1/2 advice: refactor advise APIHeba Waly via GitGitGadget, Feb 16, 2020
  22. Junio C HamanoFeb 17, 2020
  23. Heba WalyFeb 17, 2020
  24. Heba WalyFeb 19, 2020
  25. Junio C HamanoFeb 17, 2020
  26. 0/2 [Outreachy] advice: revamp advise APIHeba Waly via GitGitGadget, Feb 19, 2020
  27. 2/2 advice: extract vadvise() from advise()Heba Waly via GitGitGadget, Feb 19, 2020
  28. Emily ShafferFeb 20, 2020
  29. Heba WalyFeb 21, 2020
  30. 1/2 advice: revamp advise APIHeba Waly via GitGitGadget, Feb 19, 2020
  31. Emily ShafferFeb 20, 2020
  32. Heba WalyFeb 21, 2020
  33. 0/3 [Outreachy] advice: revamp advise APIHeba Waly via GitGitGadget, Feb 24, 2020
  34. 1/3 advice: extract vadvise() from advise()Heba Waly via GitGitGadget, Feb 24, 2020
  35. Emily ShafferFeb 24, 2020
  36. 3/3 tag: use new advice API to check visibilityHeba Waly via GitGitGadget, Feb 24, 2020
  37. Junio C HamanoFeb 24, 2020
  38. Emily ShafferFeb 24, 2020
  39. 2/3 advice: revamp advise APIHeba Waly via GitGitGadget, Feb 24, 2020
  40. Junio C HamanoFeb 24, 2020
  41. Eric SunshineFeb 24, 2020
  42. Heba WalyFeb 24, 2020
  43. Heba WalyFeb 24, 2020
  44. Emily ShafferFeb 24, 2020
  45. 0/3 [Outreachy] advice: revamp advise APIHeba Waly via GitGitGadget, Feb 25, 2020
  46. 1/3 advice: extract vadvise() from advise()Heba Waly via GitGitGadget, Feb 25, 2020
  47. 2/3 advice: revamp advise APIHeba Waly via GitGitGadget, Feb 25, 2020
  48. Junio C HamanoFeb 25, 2020
  49. Emily ShafferFeb 25, 2020
  50. Junio C HamanoFeb 25, 2020
  51. Junio C HamanoFeb 25, 2020
  52. Heba WalyFeb 25, 2020
  53. Junio C HamanoFeb 25, 2020
  54. Heba WalyFeb 26, 2020
  55. Junio C HamanoFeb 26, 2020
  56. Heba WalyFeb 26, 2020
  57. Junio C HamanoFeb 26, 2020
  58. Jonathan TanFeb 26, 2020
  59. 3/3 tag: use new advice API to check visibilityHeba Waly via GitGitGadget, Feb 25, 2020
  60. Junio C HamanoFeb 25, 2020
  61. 0/4 [Outreachy] advice: revamp advise APIHeba Waly via GitGitGadget, Feb 27, 2020
  62. 1/4 advice: extract vadvise() from advise()Heba Waly via GitGitGadget, Feb 27, 2020
  63. 2/4 advice: change "setupStreamFailure" to "setUpstreamFailure"Heba Waly via GitGitGadget, Feb 27, 2020
  64. Junio C HamanoFeb 27, 2020
  65. 3/4 advice: revamp advise APIHeba Waly via GitGitGadget, Feb 27, 2020
  66. Junio C HamanoFeb 27, 2020
  67. Heba WalyFeb 29, 2020
  68. 4/4 tag: use new advice API to check visibilityHeba Waly via GitGitGadget, Feb 27, 2020
  69. 0/4 [Outreachy] advice: revamp advise APIHeba Waly via GitGitGadget, Mar 2, 2020
  70. 1/4 advice: extract vadvise() from advise()Heba Waly via GitGitGadget, Mar 2, 2020
  71. 2/4 advice: change "setupStreamFailure" to "setUpstreamFailure"Heba Waly via GitGitGadget, Mar 2, 2020
  72. 4/4 tag: use new advice API to check visibilityHeba Waly via GitGitGadget, Mar 2, 2020
  73. 3/4 advice: revamp advise APIHeba Waly via GitGitGadget, Mar 2, 2020
  74. Junio C HamanoMar 2, 2020
  75. Junio C HamanoMar 3, 2020
  76. Heba WalyMar 4, 2020

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.