question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ravel and unravel are synonyms

See original GitHub issue

Ravel and unravel are synonyms, but the methods where they appear accomplish inverse operations. See my SO question for details and example.

Can you consider introducing alternative methods that contain unravel in their name (even functions containing ravel are IMHO not a happy choice)?

I propose to change e.g.

before after
unravel_index() index_to_coord()
ravel_multi_index() index_to_flat

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
okomarovcommented, Sep 2, 2015

Python is not a stranger to duality, see 2.* and 3.* and all the burden it imposes with the virtual environments etc… Hence, chances are that even without this renaming, a script written 10 years ago won’t work with the new release of the language. But then, of course, less hassle is always preferable.

I’ll just leave my last two cents on the matter, as a potential workflow, and we can close this issue afterwards:

  1. Create a deprecation plan with explicit deadlines, that have to be checked as new releases of numpy come out.
  2. For this type of cosmetic deprecations, you move the actual code of th old function in the new one, so that you do it now, when the reason is fresh, rather than in e.g.10 years.
  3. The old function now calls the new one, with appropriate warnings. If the API changes, you need to warn the user that the old function does NOT support the .e.g new option.
  4. The docs shift to the new function. The old function will only be in an older version of the docs ONLY, and will have deprecation warnings, so that the old function does not get immediate visibility.

With a deprecation plan, the changes all happen now, the development continues inside the newly renamed function and when the deadline hits, in 10 years, you just do not package it anymore.

0reactions
pvcommented, Sep 2, 2015

Two years is a short time, 1.7.1 was released 2 yrs ago (the newest RHEL has it), and ubuntu 12LTS is still at 1.6.2 from 4 years ago. Now, imagine running a script you wrote 10 years ago, and having to fix multiple of these renamed functions.

Although there’s no policy about exactly on this, I would personally prefer to avoid changes unless there is a pressing need to make them.

Read more comments on GitHub >

github_iconTop Results From Across the Web

46 Synonyms & Antonyms for UNRAVEL - Thesaurus.com
unravel ; undo · disentangle · free · separate · unknot · unsnarl · unwind ; decipher · resolve · solve · undo...
Read more >
Synonyms of ravel - Merriam-Webster Thesaurus
Synonyms for RAVEL: unravel, unwind, unsnarl, untangle, disentangle, unbraid, unlace, untie; Antonyms of RAVEL: bind, tie, knot, fasten, wind, lash, braid, ...
Read more >
Terms Ravel out and Unravel have similar meaning
Mutual synonyms · unwind · undo · disentangle · untangle · untie · ravel · unroll · fray.
Read more >
What is the difference between 'ravel' and 'unravel'? - Quora
First note that no one uses the word "ravel" these days (except maybe in knitting or something), but "unravel" is common. Anything that...
Read more >
Ravel - Definition, Meaning & Synonyms - Vocabulary.com
verb. disentangle. synonyms: ravel out, unravel. see moresee less. Antonyms: knot, tangle. tangle or complicate · verb. tangle or complicate. “a ravelled story”....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found