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

update dev instructions #147

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

oliver-sanders
Copy link
Member

No description provided.

@oliver-sanders oliver-sanders self-assigned this Mar 3, 2022
@oliver-sanders oliver-sanders requested a review from datamel March 3, 2022 14:21
Copy link
Contributor

@datamel datamel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm getting some inconsistent behaviour which is resulting in build errors.
Installing environment with -f conda-environment.yml

$ pipdeptree -r -p rx
rx==3.2.0
  - graphql-core==2.2 [requires: rx>=1.6.0]
    - graphene==2.1.9 [requires: graphql-core>=2.1,<3]
      - cylc-flow==8.0rc2.dev0 [requires: graphene>=2.1,<3]
    - graphql-relay==2.0.1 [requires: graphql-core>=2.2,<3]
      - graphene==2.1.9 [requires: graphql-relay>=2,<3]
        - cylc-flow==8.0rc2.dev0 [requires: graphene>=2.1,<3]

After all the pip installing everything and running cylc hub:

 Traceback (most recent call last):
  File "~/.conda/envs/env_name/bin/cylc", line 33, in <module>
    sys.exit(load_entry_point('cylc-flow', 'console_scripts', 'cylc')())
  File "/~/cylc-flow/cylc/flow/scripts/cylc.py", line 665, in main
    execute_cmd(command, *cmd_args)
  File "/~/cylc-flow/cylc/flow/scripts/cylc.py", line 285, in execute_cmd
    COMMANDS[cmd].resolve()(*args)
  File "/~/.conda/envs/env_name/lib/python3.9/site-packages/pkg_resources/__init__.py", line 2464, in resolve

However, if I don't do the -f conda install and just pip install, I get the following dep tree:

$ pipdeptree -r -p rx
rx==1.6.1
pipdeptree -r -p rx
  - graphql-core==2.3.2 [requires: rx>=1.6,<2]
    - graphene==2.1.9 [requires: graphql-core>=2.1,<3]
      - cylc-flow==8.0rc2.dev0 [requires: graphene>=2.1,<3]
    - graphql-relay==2.0.1 [requires: graphql-core>=2.2,<3]
      - graphene==2.1.9 [requires: graphql-relay>=2,<3]
        - cylc-flow==8.0rc2.dev0 [requires: graphene>=2.1,<3]

And there is no error on running cylc hub.
Would it be worth taking the graphene out of the conda-environment.yml file?

@@ -17,65 +21,105 @@
(and `configurable-http-proxy` if working with JupyterHub):

```bash
conda create -n cylc-8-dev python=3.7 configurable-http-proxy -f conda-environment.yml
conda create -n cylc-<version> python=3.7 configurable-http-proxy -f conda-environment.yml
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we want to use -f we need to use conda env create?

Suggested change
conda create -n cylc-<version> python=3.7 configurable-http-proxy -f conda-environment.yml
conda env create -n cylc-<version> -f conda-environment.yml

However, this will error with the chaining of the configurable-http-proxy. Add the configurable http proxy later, after activation?

Python version here is 3.7, however after executing this, the python version is 3.9.10. Maybe better removing the 3.7 as it is being upgraded anyway?

Also, maybe worth pointing out they should be in the cylc-flow dir, or change the -f path?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, chaining deps doesn't work here.

Would need to edit the file to add deps, which is icky.

My personal solution is a script which copies the env file, adds a few deps, lists the local Python repos I want to install, then installs from that.


3. Install Python Projects

Pip-install any Python projects you want to work with in editable mode
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Worth adding a check that master is checked out and up to date?


```bash
# clone the git repository locally then...
pip install -e "path/to/repo[all]"
pip install -e "metomi-isodatetime[all]"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Installing this, followed by cylc flow results in my editable isodatetime being overridden (confirmed with pip list before and after each install), should this order swap?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confusingly no, the issue is that cylc-flow does not support isodatetime@master ATM.

pip install -e "cylc-flow[all]"
pip install -e "cylc-uiserver[all]"
pip install -e "metomi-rose[all]"
pip install -e "cylc-rose[all]"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we want to add cylc-sphinx extensions and cylc-doc or keep it to the core repos?

@hjoliver hjoliver force-pushed the master branch 2 times, most recently from df91eda to 00058b8 Compare March 15, 2023 02:35
@hjoliver hjoliver force-pushed the master branch 2 times, most recently from 94820ae to 7fc73b8 Compare April 21, 2023 23:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants