Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue running the base example on Windows #226

Closed
EmilNichita opened this issue Dec 2, 2024 · 4 comments · Fixed by #228
Closed

Issue running the base example on Windows #226

EmilNichita opened this issue Dec 2, 2024 · 4 comments · Fixed by #228
Labels
bug Something isn't working

Comments

@EmilNichita
Copy link

EmilNichita commented Dec 2, 2024

Polaris version

0.9.1

Python Version

3.11

Operating System

Windows

Installation

Using pip into a conda env

Description

Running the first example in the docs, after successfully logging in, gives an error on a Windows 11 machine.

Steps to reproduce

import polaris as po

dataset = po.load_dataset("polaris/hello-world")
File [~\.conda\envs\molgp\Lib\site-packages\polaris\hub\storage.py:74](http://localhost:8888/lab/tree/notebooks/~/.conda/envs/polaris-test/Lib/site-packages/polaris/hub/storage.py#line=73), in S3Store.__init__(self, path, access_key, secret_key, token, endpoint_url, part_size, content_type)
      63 def __init__(
      64     self,
      65     path: str,
    (...)
      71     content_type: str = "application/octet-stream",
      72 ) -> None:
 ---> 74     bucket_name, prefix = path.split("/", 1)
      77     self.s3_client = boto3.client(
      78         "s3",
      79         aws_access_key_id=access_key,
    (...)
      82         endpoint_url=endpoint_url,
      83     )
      84     self.bucket_name = bucket_name
 
 ValueError: not enough values to unpack (expected 2, got 1)

Adding a print statement to the path variable, gives path=polaris\dataset\polaris\hello-world. Windows/Unix path differences strike again :( .

Quick fix suggestion for enabling Windows users: use proper handling of paths (built-in path library, one of the dozens local&cloud path handlers).

Looking forward to trying the library again once this is solved!

Additional output

No response

@EmilNichita EmilNichita added the bug Something isn't working label Dec 2, 2024
@cwognum
Copy link
Collaborator

cwognum commented Dec 2, 2024

Thanks for reporting this, @EmilNichita ! We'll look into it.

We should also look into running the test suite on Windows through the Github CICD. Most maintainers of Polaris work on Unix, so Windows is a bit of a blind spot. We also don't have integration tests setup yet for the client-hub communication, but now that #221 is merged this is something we should do as well.

@cwognum
Copy link
Collaborator

cwognum commented Dec 4, 2024

Hey @EmilNichita, it should be fixed with #228 . We also added Windows to our CICD and added an integration test with the Hub, so we'll spot this sooner next time. Thanks again for raising this! I'll release a new Polaris version soon!

@cwognum
Copy link
Collaborator

cwognum commented Dec 4, 2024

Just released 0.9.3 with the fix. Let me know if you run into any other issues. Thanks again! 👍

@EmilNichita
Copy link
Author

Can confirm the 0.9.3 version works as expected, thanks again for solving this so quickly!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
2 participants