import pkg_resources

try:
    __version__ = pkg_resources.get_distribution(__name__).version
except pkg_resources.DistributionNotFound:
    __version__ = None

import pkg_resources

try:
    __version__ = pkg_resources.get_distribution(__name__).version
except pkg_resources.DistributionNotFound:  # pragma: no cover
    __version__ = None

Add "no cover" pragma to version setting code
Add "no cover" pragma to version setting code

  import pkg_resources
  
  try:
      __version__ = pkg_resources.get_distribution(__name__).version
- except pkg_resources.DistributionNotFound:
+ except pkg_resources.DistributionNotFound:  # pragma: no cover
      __version__ = None
  
Add "no cover" pragma to version setting code
## Code Before:
import pkg_resources

try:
    __version__ = pkg_resources.get_distribution(__name__).version
except pkg_resources.DistributionNotFound:
    __version__ = None

## Instruction:
Add "no cover" pragma to version setting code
## Code After:
import pkg_resources

try:
    __version__ = pkg_resources.get_distribution(__name__).version
except pkg_resources.DistributionNotFound:  # pragma: no cover
    __version__ = None
