pybiolib 1.2.911__py3-none-any.whl → 1.2.923__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,19 @@
1
+ ---
2
+ mode: 'agent'
3
+ tools: ['githubRepo', 'codebase']
4
+ description: 'Handle onboarding and implementing code from a GitHub repository into a biolib application, with focus on creating easily editable and maintainable code structure.'
5
+ ---
6
+
7
+ # Main task
8
+ Your task is to help onboard and implement code from a GitHub repository into a biolib application. This involves understanding the repository structure, implementing the core functionality, and ensuring the code is easily editable for future iterations.
9
+ Generally, you can do this by adding the repository into an src folder as a submodule, and reading the README.md file to understand how to run the code.
10
+ You will then call the relevant functions or classes from the cloned repository in your biolib application
11
+
12
+ ## Key requirements:
13
+ - Always ask the user for the GitHub repository if not already provided. Inform them that it needs to be in the format `author/repo_name`.
14
+ - Use the #githubRepo tool to examine the repository structure, README, and key files to understand the project.
15
+ - Focus on creating code that is easily editable and maintainable, as it's likely the implementation won't be perfect on the first attempt.
16
+ - Structure the code in a modular way that allows for easy modifications and improvements.
17
+ - Include clear comments for complex logic, but avoid over-commenting obvious code.
18
+ - Follow the existing biolib application patterns and conventions.
19
+ - Ensure all dependencies are properly specified in requirements.txt with versions locked down.
@@ -0,0 +1,13 @@
1
+ import re
2
+
3
+
4
+ def normalize_for_docker_tag(name: str) -> str:
5
+ if not name:
6
+ return ''
7
+
8
+ normalized = re.sub(r'[^a-z0-9-]', '-', name.lower())
9
+
10
+ normalized = re.sub(r'-+', '-', normalized)
11
+ normalized = normalized.strip('-')
12
+
13
+ return normalized
biolib/cli/init.py CHANGED
@@ -6,6 +6,7 @@ import click
6
6
 
7
7
  from biolib import utils # Import like this to let BASE_URL_IS_PUBLIC_BIOLIB be set correctly
8
8
  from biolib._internal.add_copilot_prompts import add_copilot_prompts
9
+ from biolib._internal.string_utils import normalize_for_docker_tag
9
10
  from biolib._internal.templates import templates
10
11
  from biolib.utils import BIOLIB_PACKAGE_VERSION
11
12
 
@@ -16,6 +17,7 @@ def init() -> None:
16
17
 
17
18
  app_uri = input('What URI do you want to create the application under? (leave blank to skip): ')
18
19
  app_name = app_uri.split('/')[-1] if app_uri else None
20
+ docker_tag = normalize_for_docker_tag(app_name) if app_name else None
19
21
  if not app_uri:
20
22
  print(
21
23
  'Remember to set the app URI in the .biolib/config.yml file later, '
@@ -79,7 +81,7 @@ def init() -> None:
79
81
  new_content = new_content.replace('BIOLIB_REPLACE_APP_URI', replace_app_uri)
80
82
  new_content = new_content.replace(
81
83
  'BIOLIB_REPLACE_DOCKER_TAG',
82
- app_name if app_name else 'PUT_DOCKER_TAG_HERE',
84
+ docker_tag if docker_tag else 'PUT_DOCKER_TAG_HERE',
83
85
  )
84
86
 
85
87
  with open(destination_file, 'w') as f:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: pybiolib
3
- Version: 1.2.911
3
+ Version: 1.2.923
4
4
  Summary: BioLib Python Client
5
5
  License: MIT
6
6
  Keywords: biolib
@@ -20,10 +20,12 @@ biolib/_internal/llm_instructions/.github/instructions/style-general.instruction
20
20
  biolib/_internal/llm_instructions/.github/instructions/style-python.instructions.md,sha256=xfypuPqMsz5ejobDoVI0HjmNqksl16aFuIol1nAhpHg,1034
21
21
  biolib/_internal/llm_instructions/.github/instructions/style-react-ts.instructions.md,sha256=GQoRL-bfPwwNIW4W0yN_guVIqFNVCG2_7adOCaxiz-w,755
22
22
  biolib/_internal/llm_instructions/.github/prompts/biolib_app_inputs.prompt.md,sha256=SMzXZImdID0yKjhE1fG54VrHdD8IVuwRxRKsMF-KjWs,697
23
+ biolib/_internal/llm_instructions/.github/prompts/biolib_onboard_repo.prompt.md,sha256=BfCkVyafDHFBMu6qcvKlxpnXKJRHNDp5qR_fN4XB9pI,1515
23
24
  biolib/_internal/llm_instructions/.github/prompts/biolib_run_apps.prompt.md,sha256=-t1bmGr3zEFa6lKHaLcI98yq4Sg1TCMW8xbelNSHaOA,696
24
25
  biolib/_internal/llm_instructions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
25
26
  biolib/_internal/push_application.py,sha256=e0SnPh64X99ICUt5xPCIfbS3WHkUzMKLFFyaf6u2vqQ,18286
26
27
  biolib/_internal/runtime.py,sha256=BiHl4klUHr36MCpqKaUso4idHeBZfPAahLYRQrabFqA,486
28
+ biolib/_internal/string_utils.py,sha256=N7J7oGu6_yA_z0pOiKqxEh__lRdiDLh6kigeDkQEZ5g,265
27
29
  biolib/_internal/templates/__init__.py,sha256=NVbhLUMC8HITzkLvP88Qu7FHaL-SvQord-DX3gh1Ykk,24
28
30
  biolib/_internal/templates/init_template/.biolib/config.yml,sha256=y4ndTgbFvUE1UiGcIOqogT2Wm8jahGffeyU5rlCEltQ,427
29
31
  biolib/_internal/templates/init_template/.github/workflows/biolib.yml,sha256=sphjoiycV_oc4VbaA8wbUEokSMpnrdB6N-bYju_5Ibo,522
@@ -86,7 +88,7 @@ biolib/cli/__init__.py,sha256=IHC2bEyA27pvgp-18SGfFVJOP456elanz7suDP8D084,1316
86
88
  biolib/cli/auth.py,sha256=rpWGmXs6Fz6CGrO9K8ibPRszOdXG78Vig_boKaVCD9A,2082
87
89
  biolib/cli/data_record.py,sha256=t8DfJK2EZ_SNZ9drDA_N5Jqy8DNwf9f5SlFrIaOvtv0,3501
88
90
  biolib/cli/download_container.py,sha256=HIZVHOPmslGE5M2Dsp9r2cCkAEJx__vcsDz5Wt5LRos,483
89
- biolib/cli/init.py,sha256=_dhnKdlRMy2oSNRRsXdjFKVzayy2aiRQkeF948VCCkg,4438
91
+ biolib/cli/init.py,sha256=OMYIltLJfF8q9VAvzDwNG0-1VixDkFGEN1ic2VhrW7c,4583
90
92
  biolib/cli/lfs.py,sha256=z2qHUwink85mv9yDgifbVKkVwuyknGhMDTfly_gLKJM,4151
91
93
  biolib/cli/push.py,sha256=J8BswMYVeTacZBHbm4K4a2XbS_I8kvfgRZLoby2wi3I,1695
92
94
  biolib/cli/run.py,sha256=MCo0ZqW2pHBxOoCI3i5gAx5D0auW9fmxHqkAF4TRhms,2134
@@ -143,8 +145,8 @@ biolib/utils/cache_state.py,sha256=u256F37QSRIVwqKlbnCyzAX4EMI-kl6Dwu6qwj-Qmag,3
143
145
  biolib/utils/multipart_uploader.py,sha256=XvGP1I8tQuKhAH-QugPRoEsCi9qvbRk-DVBs5PNwwJo,8452
144
146
  biolib/utils/seq_util.py,sha256=Ozk0blGtPur_D9MwShD02r_mphyQmgZkx-lOHOwnlIM,6730
145
147
  biolib/utils/zip/remote_zip.py,sha256=0wErYlxir5921agfFeV1xVjf29l9VNgGQvNlWOlj2Yc,23232
146
- pybiolib-1.2.911.dist-info/LICENSE,sha256=F2h7gf8i0agDIeWoBPXDMYScvQOz02pAWkKhTGOHaaw,1067
147
- pybiolib-1.2.911.dist-info/METADATA,sha256=3NtKERfyMQk905_gZB2Z6T_q14CsvhRfZMgs7Ac475k,1570
148
- pybiolib-1.2.911.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
149
- pybiolib-1.2.911.dist-info/entry_points.txt,sha256=p6DyaP_2kctxegTX23WBznnrDi4mz6gx04O5uKtRDXg,42
150
- pybiolib-1.2.911.dist-info/RECORD,,
148
+ pybiolib-1.2.923.dist-info/LICENSE,sha256=F2h7gf8i0agDIeWoBPXDMYScvQOz02pAWkKhTGOHaaw,1067
149
+ pybiolib-1.2.923.dist-info/METADATA,sha256=_6O5_T5lbKG9bEy2PBkthT5GWj6KyGyCGJMd337P_eI,1570
150
+ pybiolib-1.2.923.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
151
+ pybiolib-1.2.923.dist-info/entry_points.txt,sha256=p6DyaP_2kctxegTX23WBznnrDi4mz6gx04O5uKtRDXg,42
152
+ pybiolib-1.2.923.dist-info/RECORD,,