thuml / Transfer-Learning-Library

Transfer Learning Library for Domain Adaptation, Task Adaptation, and Domain Generalization
http://transfer.thuml.ai
MIT License
3.39k stars 553 forks source link

Version string not defined #138

Closed billzhonggz closed 2 years ago

billzhonggz commented 2 years ago

Describe the bug When installing on dev-tllib branch, the following error occurs and installation aborts.

Traceback (most recent call last):
  File "C:\Users\Junru\source\Transfer-Learning-Library\setup.py", line 9, in <module>
    version = re.search(r'__version__ = \'(.*?)\'', f.read()).group(1)
AttributeError: 'NoneType' object has no attribute 'group'

To Reproduce Steps to reproduce the behavior:

  1. Clone the repository.
  2. Switch to branch dev-tllib.
  3. Run python setup.py install.
  4. See error.

Expected behavior No error during install.

Additional context Adding a version string in tllib/__init__.py fixes the issue.

thucbx99 commented 2 years ago

Thank you for pointing out this issue. The dev-tllib branch is under development and will be fixed after merging back to the main branch. For now, you can directly git clone the project.

JunguangJiang commented 2 years ago

Thanks for your advice!

Describe the bug When installing on dev-tllib branch, the following error occurs and installation aborts.

Traceback (most recent call last):
  File "C:\Users\Junru\source\Transfer-Learning-Library\setup.py", line 9, in <module>
    version = re.search(r'__version__ = \'(.*?)\'', f.read()).group(1)
AttributeError: 'NoneType' object has no attribute 'group'

To Reproduce Steps to reproduce the behavior:

  1. Clone the repository.
  2. Switch to branch dev-tllib.
  3. Run python setup.py install.
  4. See error.

Expected behavior No error during install.

Additional context Adding a version string in tllib/__init__.py fixes the issue.