From 0ebf715dab16d6c2eebe18e12720b20cf224a2b3 Mon Sep 17 00:00:00 2001 From: Marinaa-Emad <84817975+Marinaa-Emad@users.noreply.github.com> Date: Sun, 3 Nov 2024 14:33:12 +0200 Subject: [PATCH 01/11] Development selenium add stats page tests 1 (#3313) * development_selenium_add_stats_page_tests * development_selenium_add_stats_page_tests_1 * development_selenium_add_stats_page_tests * remove all whitespace * remove all whitespace * remove all whitespace * remove all whitespace * remove all whitespace * remove unwanted cache files and increase timeout duration * change the network to dev * bring back config * spilt test into 2 tests * fix Codacy issues * add docstring, comments and improve code * correct convertation of GB to byte --------- Co-authored-by: A-Harby --- .../tests/frontend_selenium/Config.ini | 2 +- .../frontend_selenium/pages/statistics.py | 89 +++++++++++++++++++ .../tests/TFGrid/test_statistics.py | 63 +++++++++++++ .../frontend_selenium/utils/grid_proxy.py | 35 +++++++- .../tests/frontend_selenium/utils/utils.py | 34 +++++-- 5 files changed, 211 insertions(+), 12 deletions(-) create mode 100644 packages/playground/tests/frontend_selenium/pages/statistics.py create mode 100644 packages/playground/tests/frontend_selenium/tests/TFGrid/test_statistics.py diff --git a/packages/playground/tests/frontend_selenium/Config.ini b/packages/playground/tests/frontend_selenium/Config.ini index 3f63d2c549..2222b381f4 100644 --- a/packages/playground/tests/frontend_selenium/Config.ini +++ b/packages/playground/tests/frontend_selenium/Config.ini @@ -5,4 +5,4 @@ net = dev seed = node_seed = address = -email = +email = \ No newline at end of file diff --git a/packages/playground/tests/frontend_selenium/pages/statistics.py b/packages/playground/tests/frontend_selenium/pages/statistics.py new file mode 100644 index 0000000000..e537943b26 --- /dev/null +++ b/packages/playground/tests/frontend_selenium/pages/statistics.py @@ -0,0 +1,89 @@ +from selenium import webdriver +from selenium.webdriver.common.by import By +from selenium.webdriver.common.keys import Keys +from selenium.webdriver.support.ui import WebDriverWait +from selenium.webdriver.support import expected_conditions as EC +from selenium.common.exceptions import TimeoutException + + + +class StatisticsPage: + + logout_button = (By.XPATH, "//button[.//span[text()=' Logout ']]") + tfgrid_button = (By.XPATH, "//span[text()='TFGrid']") + grid_status_button = (By.XPATH, "//span[text()='Grid Status']") + node_monitoring_button = (By.XPATH, "//span[text()='Node Monitoring']") + statistics_button = (By.XPATH, "//span[text()='Node Statistics']") + statistics_label = (By.XPATH, "//*[contains(text(), 'Statistics')]") + map = (By.XPATH,"//button[contains(@class, 'btn-main-container')]") + nodes_online = (By.XPATH, "//span[text()='Nodes Online']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + dedicated_machines = (By.XPATH, "//span[text()='Dedicated Machines']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + farms = (By.XPATH, "//span[text()='Farms']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + countries = (By.XPATH, "//span[text()='Countries']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + cpus = (By.XPATH, "//span[text()='CPUs']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + ssd_storage = (By.XPATH, "//span[text()='SSD Storage']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + hdd_storage = (By.XPATH, "//span[text()='HDD Storage']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + ram = (By.XPATH, "//span[text()='RAM']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + gpus = (By.XPATH, "//span[text()='GPUs']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + access_nodes = (By.XPATH, "//span[text()='Access Nodes']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + gateways = (By.XPATH, "//span[text()='Gateways']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + twins = (By.XPATH, "//span[text()='Twins']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + public_ips = (By.XPATH, "//span[text()='Public IPs']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + conracts = (By.XPATH, "//span[text()='Contracts']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + number_of_workloads = (By.XPATH, "//span[text()='Number of workloads']/ancestor::div/following-sibling::div[@class='v-card-text card-body']") + + + def __init__(self, browser): + self.browser = browser + + def navigate(self): + webdriver.ActionChains(self.browser).send_keys(Keys.ESCAPE).perform() + self.browser.find_element(*self.tfgrid_button).click() + self.browser.find_element(*self.statistics_button).click() + WebDriverWait(self.browser, 60).until(EC.visibility_of_element_located(self.statistics_label)) + + def statistics_detials(self): + details = {} + wait = WebDriverWait(self.browser, 60) # Increased wait time to 60 seconds + elements_to_fetch = { + "nodes": self.nodes_online, + "dedicatedNodes": self.dedicated_machines, + "farms": self.farms, + "countries": self.countries, + "totalCru": self.cpus, + "totalSru": self.ssd_storage, + "totalHru": self.hdd_storage, + "totalMru": self.ram, + "gpus": self.gpus, + "accessNodes": self.access_nodes, + "gateways": self.gateways, + "twins": self.twins, + "publicIps": self.public_ips, + "contracts": self.conracts, + "workloads_number": self.number_of_workloads + } + + for key, locator in elements_to_fetch.items(): + try: + element_text = wait.until(EC.visibility_of_element_located(locator)).text + details[key] = element_text + except TimeoutException: + details[key] = None # Add None or some default value to maintain dictionary consistency + + return details + + def get_link(self): + WebDriverWait(self.browser, 30).until(EC.number_of_windows_to_be(2)) + self.browser.switch_to.window(self.browser.window_handles[1]) + url = self.browser.current_url + self.browser.close() + self.browser.switch_to.window(self.browser.window_handles[0]) + return url + + def grid_status_link(self): + self.browser.find_element(*self.grid_status_button).click() + return self.get_link() + + def node_monitoring_link(self): + self.browser.find_element(*self.node_monitoring_button).click() + return self.get_link() \ No newline at end of file diff --git a/packages/playground/tests/frontend_selenium/tests/TFGrid/test_statistics.py b/packages/playground/tests/frontend_selenium/tests/TFGrid/test_statistics.py new file mode 100644 index 0000000000..5be61dab99 --- /dev/null +++ b/packages/playground/tests/frontend_selenium/tests/TFGrid/test_statistics.py @@ -0,0 +1,63 @@ +import math +from utils.utils import byte_converter,convert_to_scaled_float +from pages.statistics import StatisticsPage +from utils.grid_proxy import GridProxy +from pages.dashboard import DashboardPage + +def before_test_setup(browser): + statistics_page = StatisticsPage(browser) + dashboard_page = DashboardPage(browser) + dashboard_page.open_and_load() + statistics_page.navigate() + return statistics_page + + +def test_statistics_details(browser): + """ + TC1503 - Verify Statistics + Steps: + - Navigate to the dashboard. + - Click on TFGrid from side menu. + - Click on Stats. + Result: Assert that the displayed values should match the data from the grid proxy. + """ + statistics_page = before_test_setup(browser) + grid_proxy = GridProxy(browser) + statistics_details = statistics_page.statistics_detials() + grid_statistics_details = grid_proxy.get_stats() + # Convert necessary values from string to integer for comparison, but keeping the dictionary structure + statistics_details_converted = { + key: int(value.replace(',', '')) if value is not None and value.replace(',', '').isdigit() else value + for key, value in statistics_details.items() + } + # Full set of assertions, comparing UI stats with proxy stats + assert grid_statistics_details['nodes'] == statistics_details_converted['nodes'] + assert grid_statistics_details['dedicatedNodes'] == statistics_details_converted['dedicatedNodes'] + assert grid_statistics_details['farms'] == statistics_details_converted['farms'] + assert grid_statistics_details['countries'] == statistics_details_converted['countries'] + assert grid_statistics_details['totalCru'] == statistics_details_converted['totalCru'] + assert math.isclose(convert_to_scaled_float(grid_statistics_details['totalSru']), convert_to_scaled_float(byte_converter(statistics_details_converted['totalSru'])), abs_tol=0.002) + assert math.isclose(convert_to_scaled_float(grid_statistics_details['totalHru']), convert_to_scaled_float(byte_converter(statistics_details_converted['totalHru'])), abs_tol=0.002) + assert math.isclose(convert_to_scaled_float(grid_statistics_details['totalMru']), convert_to_scaled_float(byte_converter(statistics_details_converted['totalMru'])), abs_tol=0.002) + assert grid_statistics_details['gpus'] == statistics_details_converted['gpus'] + assert grid_statistics_details['accessNodes'] == statistics_details_converted['accessNodes'] + assert grid_statistics_details['gateways'] == statistics_details_converted['gateways'] + assert grid_statistics_details['twins'] == statistics_details_converted['twins'] + assert grid_statistics_details['publicIps'] == statistics_details_converted['publicIps'] + assert grid_statistics_details['contracts'] == statistics_details_converted['contracts'] + assert grid_statistics_details['workloads_number'] == statistics_details_converted['workloads_number'] + + +def test_tfgrid_links(browser): + """ + TC2867 - Verify TFGrid links + Steps: + - Navigate to the dashboard. + - Click on TFGrid from side menu. + - Click on Grid Status. + - Click on Node Monitoring. + Result: Assert that The links match the pages. + """ + statistics_page = before_test_setup(browser) + assert statistics_page.grid_status_link() == 'https://status.grid.tf/status/threefold/' + assert statistics_page.node_monitoring_link() == 'https://metrics.grid.tf/d/rYdddlPWkfqwf/zos-host-metrics?orgId=2&refresh=30s/' \ No newline at end of file diff --git a/packages/playground/tests/frontend_selenium/utils/grid_proxy.py b/packages/playground/tests/frontend_selenium/utils/grid_proxy.py index 6ead105842..55ee69ba7f 100644 --- a/packages/playground/tests/frontend_selenium/utils/grid_proxy.py +++ b/packages/playground/tests/frontend_selenium/utils/grid_proxy.py @@ -62,7 +62,36 @@ def get_twin_node(self, twin_id): details = r.json() return details + def get_stats(self): - r = requests.post('https://stats.' + Base.net + '.grid.tf/api/stats-summary') - stats_json = r.json() - return list(stats_json.values()) \ No newline at end of file + up = requests.get(Base.gridproxy_url + 'stats?status=up', timeout=10).json() + standby = requests.get(Base.gridproxy_url + 'stats?status=standby', timeout=10).json() + # Initialize a dictionary to store the merged data + merged_data = {} + # Merge simple values, summing if they differ + keys_to_sum = ['nodes', 'accessNodes', 'totalCru', 'totalSru', 'totalMru', 'totalHru', 'gpus', 'dedicatedNodes', 'workloads_number'] + for key in keys_to_sum: + merged_data[key] = up[key] + standby[key] + # Merge the "farms", "publicIps", "gateways", "twins", and "contracts" fields (they are the same) + keys_to_add_once = ['farms', 'publicIps', 'gateways', 'twins', 'contracts'] + for key in keys_to_add_once: + merged_data[key] = up[key] + # Merge nodesDistribution and calculate unique and common countries + up_distribution = up['nodesDistribution'] + standby_distribution = standby['nodesDistribution'] + merged_distribution = {} + common_countries = 0 + for country, up_count in up_distribution.items(): + standby_count = standby_distribution.get(country, 0) + merged_distribution[country] = up_count + standby_count + if standby_count > 0: + common_countries += 1 + for country, standby_count in standby_distribution.items(): + if country not in merged_distribution: + merged_distribution[country] = standby_count + merged_data['nodesDistribution'] = merged_distribution + # Calculate the total countries: all unique countries minus common countries + total_countries = len(merged_distribution) # Total unique countries + merged_data['countries'] = total_countries + # Return the dictionary directly + return merged_data \ No newline at end of file diff --git a/packages/playground/tests/frontend_selenium/utils/utils.py b/packages/playground/tests/frontend_selenium/utils/utils.py index d2f717831d..89c7a17ffb 100644 --- a/packages/playground/tests/frontend_selenium/utils/utils.py +++ b/packages/playground/tests/frontend_selenium/utils/utils.py @@ -176,16 +176,34 @@ def randomize_public_ipv4(): ip_subnet = ip + '/' + random.choice(['26', '27', '28', '29']) return ip_subnet, ip + +def convert_to_scaled_float(number): + str_number = str(number) + if '.' in str_number: + decimal_index = str_number.index('.') + else: + decimal_index = len(str_number) + divisor = 10 ** decimal_index + scaled_number = number / divisor + return scaled_number + + def byte_converter(value): + # Define the unit and the numeric value before checking conditions + unit = value[-2].upper() # Last character represents the unit (P, T, G) + number_str = value[:-3].strip() # Everything except the last two characters is the number + if value != '0': - if value[-2] == 'P': - return float(value[:-3])*(1024*2) - elif value[-2] == 'T': - return float(value[:-3])*1024 - else: - return float(value[:-3]) - else: - return float(value) + # Convert based on the unit + if unit == 'P': # Petabytes + return float(number_str) * (1024 ** 5) + elif unit == 'T': # Terabytes + return float(number_str) * (1024 ** 4) + elif unit == 'G': # Gigabytes + return float(number_str) * (1024 ** 3) + + return float(value) + def get_min(nodes, resource): min = nodes[0][resource] From ffbb7508d569493e37f982c4b3ee3e12b14e2e10 Mon Sep 17 00:00:00 2001 From: Amira <56790126+amiraabouhadid@users.noreply.github.com> Date: Sun, 3 Nov 2024 16:16:30 +0200 Subject: [PATCH 02/11] update max timeout message (#3574) --- packages/playground/src/views/settings.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/playground/src/views/settings.vue b/packages/playground/src/views/settings.vue index 1af0a12c60..e53bc262d9 100644 --- a/packages/playground/src/views/settings.vue +++ b/packages/playground/src/views/settings.vue @@ -115,7 +115,7 @@ validators.required('Query timeout is required.'), validators.isInt('Timeout must be a valid integer.'), validators.min(`Query timeout should be at least 3 second.`, 3), - validators.max('Query timeout maximum limit exceeded', 3 * 60), + validators.max('Query timeout maximum limit is 180 seconds', 3 * 60), ]" #="{ props }" ref="timeoutQueryInput" @@ -145,7 +145,7 @@ validators.required('Deployment timeout is required.'), validators.isInt('Timeout must be a valid integer.'), validators.min(`Deployment timeout should be at least 3 second.`, 3), - validators.max('Deployment timeout maximum limit exceeded', 30 * 60), + validators.max('Deployment timeout maximum limit is 1800 seconds', 30 * 60), ]" #="{ props }" ref="timeoutDeploymentInput" From d66572424893833816a8a5bba0411d7bc208a93c Mon Sep 17 00:00:00 2001 From: Omar Kassem Date: Mon, 4 Nov 2024 10:45:31 +0200 Subject: [PATCH 03/11] refactor: KYC health (#3582) update the KYC client to parse the status from result key update kycMonitor to parse the status from result key --- packages/grid_client/src/clients/kyc/client.ts | 2 +- packages/monitoring/src/serviceMonitor/kyc.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/grid_client/src/clients/kyc/client.ts b/packages/grid_client/src/clients/kyc/client.ts index c4b307b9dc..b247e2bb40 100644 --- a/packages/grid_client/src/clients/kyc/client.ts +++ b/packages/grid_client/src/clients/kyc/client.ts @@ -188,7 +188,7 @@ export class KYC { async isHealthy(): Promise { try { const res = await axios.get(urlJoin("https://", this.apiDomain, API_PREFIX, "health")); - const { status } = res.data; + const { status } = res.data.result; if (status !== `Healthy`) return false; return true; } catch (error) { diff --git a/packages/monitoring/src/serviceMonitor/kyc.ts b/packages/monitoring/src/serviceMonitor/kyc.ts index 273595b777..61874d05a9 100644 --- a/packages/monitoring/src/serviceMonitor/kyc.ts +++ b/packages/monitoring/src/serviceMonitor/kyc.ts @@ -11,8 +11,8 @@ export class KYCMonitor extends ServiceBase implements ILivenessChecker { try { const res = await fetch(urlJoin(url, "/api/v1/health")); if (!res?.ok) throw Error(`HTTP Response Code: ${res?.status}`); - const { status } = await res.json(); - if (status !== "Healthy") throw Error(`Status: ${status}`); + const { result } = await res.json(); + if (result.status !== "Healthy") throw Error(`Status: ${result.status}`); return { alive: true }; } catch (error) { return { alive: false, error }; From 52a5a7008fb2164b47ea996ed517a28587b28c97 Mon Sep 17 00:00:00 2001 From: Amira <56790126+amiraabouhadid@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:28:51 +0200 Subject: [PATCH 04/11] fix domain list error on reload (#3583) * add no error msg handlinng * update err handling on reload * add failedToListGws and erroMessage reset at start of load func --- .../playground/src/components/manage_gateway_dialog.vue | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/packages/playground/src/components/manage_gateway_dialog.vue b/packages/playground/src/components/manage_gateway_dialog.vue index 7da8e680cb..5279cd07f1 100644 --- a/packages/playground/src/components/manage_gateway_dialog.vue +++ b/packages/playground/src/components/manage_gateway_dialog.vue @@ -324,14 +324,18 @@ export default { gateways.value = []; gatewaysToDelete.value = []; loadingGateways.value = true; + failedToListGws.value = []; + errorMessage.value = ""; + updateGrid(grid, { projectName: props.vm ? props.vm.projectName : props.k8s!.projectName }); const { gateways: gws, failedToList } = await loadDeploymentGateways(grid, { filter: gw => true, }); gateways.value = gws; - failedToListGws.value = failedToList; - if (failedToListGws.value.length) { + + if (failedToList.length != 0) { + failedToListGws.value = failedToList; errorMessage.value = `Failed to list ${failedToListGws.value.length} domains`; } } catch (error) { From a080c4de3263663798e237989162477b96c12648 Mon Sep 17 00:00:00 2001 From: Amira <56790126+amiraabouhadid@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:31:03 +0200 Subject: [PATCH 05/11] update max name length in solutions (#3549) * update max name length from 50 to 35 * change subdomain name max length * update max name length to 15 in all solutions that require domain * change subdomain max length to 35 --- packages/grid_client/src/modules/models.ts | 2 +- packages/playground/src/components/caprover_worker.vue | 2 +- packages/playground/src/components/k8s_worker.vue | 2 +- packages/playground/src/components/manage_gateway_dialog.vue | 2 +- packages/playground/src/weblets/freeflow.vue | 2 +- packages/playground/src/weblets/full_vm.vue | 4 ++-- packages/playground/src/weblets/jenkins.vue | 2 +- packages/playground/src/weblets/micro_vm.vue | 4 ++-- packages/playground/src/weblets/tf_algorand.vue | 2 +- packages/playground/src/weblets/tf_casperlabs.vue | 2 +- packages/playground/src/weblets/tf_discourse.vue | 2 +- packages/playground/src/weblets/tf_domains.vue | 2 +- packages/playground/src/weblets/tf_funkwhale.vue | 2 +- packages/playground/src/weblets/tf_jitsi.vue | 2 +- packages/playground/src/weblets/tf_kubernetes.vue | 2 +- packages/playground/src/weblets/tf_mattermost.vue | 2 +- packages/playground/src/weblets/tf_nextcloud.vue | 2 +- packages/playground/src/weblets/tf_nostr.vue | 2 +- packages/playground/src/weblets/tf_owncloud.vue | 2 +- packages/playground/src/weblets/tf_peertube.vue | 2 +- packages/playground/src/weblets/tf_presearch.vue | 2 +- packages/playground/src/weblets/tf_staticwebsite.vue | 2 +- packages/playground/src/weblets/tf_subsquid.vue | 2 +- packages/playground/src/weblets/tf_taiga.vue | 2 +- packages/playground/src/weblets/tf_umbrel.vue | 2 +- packages/playground/src/weblets/tf_wordpress.vue | 2 +- packages/playground/src/weblets/tfrobot.vue | 2 +- 27 files changed, 29 insertions(+), 29 deletions(-) diff --git a/packages/grid_client/src/modules/models.ts b/packages/grid_client/src/modules/models.ts index 46b69580c2..4d4f3fd9a7 100644 --- a/packages/grid_client/src/modules/models.ts +++ b/packages/grid_client/src/modules/models.ts @@ -25,7 +25,7 @@ import { IsAlphanumericExpectUnderscore } from "../helpers"; import { Deployment } from "../zos/deployment"; import { ZdbModes } from "../zos/zdb"; import { blockchainType } from "./blockchainInterface"; -const NameLength = 50; +const NameLength = 35; const FarmNameLength = 40; enum ContractStates { diff --git a/packages/playground/src/components/caprover_worker.vue b/packages/playground/src/components/caprover_worker.vue index 9dd94ab18d..c717e4abad 100644 --- a/packages/playground/src/components/caprover_worker.vue +++ b/packages/playground/src/components/caprover_worker.vue @@ -7,7 +7,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 35 characters.', 35), ]" :value="$props.modelValue.name" #="{ props }" diff --git a/packages/playground/src/components/k8s_worker.vue b/packages/playground/src/components/k8s_worker.vue index 232ed22dd2..437c772f06 100644 --- a/packages/playground/src/components/k8s_worker.vue +++ b/packages/playground/src/components/k8s_worker.vue @@ -8,7 +8,7 @@ (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), validators.minLength('Name minimum length is 2 chars.', 2), - validators.maxLength('Name max length is 50 chars.', 50), + validators.maxLength('Name max length is 35 chars.', 35), ]" #="{ props }" > diff --git a/packages/playground/src/components/manage_gateway_dialog.vue b/packages/playground/src/components/manage_gateway_dialog.vue index 5279cd07f1..5d7bb6f3d0 100644 --- a/packages/playground/src/components/manage_gateway_dialog.vue +++ b/packages/playground/src/components/manage_gateway_dialog.vue @@ -477,7 +477,7 @@ export default { validators.isAlphanumeric("Subdomain should consist of letters and numbers only."), (subdomain: string) => validators.isAlpha("Subdomain must start with an alphabet char.")(subdomain[0]), validators.minLength("Subdomain must be at least 4 characters.", 4), - (subdomain: string) => validators.maxLength("Subdomain cannot exceed 50 characters.", 50)(subdomain), + (subdomain: string) => validators.maxLength("Subdomain cannot exceed 35 characters.", 35)(subdomain), ]; const portRules = [validators.required("Port is required."), validators.isPort("Please provide a valid port.")]; diff --git a/packages/playground/src/weblets/freeflow.vue b/packages/playground/src/weblets/freeflow.vue index 83058900c6..439aef8214 100644 --- a/packages/playground/src/weblets/freeflow.vue +++ b/packages/playground/src/weblets/freeflow.vue @@ -20,7 +20,7 @@ validators.required('Name is required.'), validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), validators.minLength('Name must be at least 4 characters.', 4), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/full_vm.vue b/packages/playground/src/weblets/full_vm.vue index 21bcb79df6..921a576edf 100644 --- a/packages/playground/src/weblets/full_vm.vue +++ b/packages/playground/src/weblets/full_vm.vue @@ -27,7 +27,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 35 characters.', 35), ]" #="{ props }" > @@ -104,7 +104,7 @@ (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Disk name minimum length is 2 characters.', 2), validators.isAlphanumeric('Disk name only accepts alphanumeric characters.'), - validators.maxLength('Disk name maximum length is 50 characters.', 50), + validators.maxLength('Disk name maximum length is 35 characters.', 35), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/jenkins.vue b/packages/playground/src/weblets/jenkins.vue index e33912e48b..a7d1479c60 100644 --- a/packages/playground/src/weblets/jenkins.vue +++ b/packages/playground/src/weblets/jenkins.vue @@ -19,7 +19,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/micro_vm.vue b/packages/playground/src/weblets/micro_vm.vue index 62eb3abfc9..b1de6b137d 100644 --- a/packages/playground/src/weblets/micro_vm.vue +++ b/packages/playground/src/weblets/micro_vm.vue @@ -29,7 +29,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 35 characters.', 35), ]" #="{ props }" > @@ -130,7 +130,7 @@ }), validators.minLength('Disk name minimum length is 2 characters.', 2), validators.isAlphanumeric('Disk name only accepts alphanumeric characters.'), - validators.maxLength('Disk name maximum length is 50 characters.', 50), + validators.maxLength('Disk name maximum length is 35 characters.', 35), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_algorand.vue b/packages/playground/src/weblets/tf_algorand.vue index 42912327d3..7ea99ef289 100644 --- a/packages/playground/src/weblets/tf_algorand.vue +++ b/packages/playground/src/weblets/tf_algorand.vue @@ -19,7 +19,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 35 characters.', 35), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_casperlabs.vue b/packages/playground/src/weblets/tf_casperlabs.vue index 569bbb4df3..8832217257 100644 --- a/packages/playground/src/weblets/tf_casperlabs.vue +++ b/packages/playground/src/weblets/tf_casperlabs.vue @@ -20,7 +20,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_discourse.vue b/packages/playground/src/weblets/tf_discourse.vue index bd6f8c0bad..00bfb969c9 100644 --- a/packages/playground/src/weblets/tf_discourse.vue +++ b/packages/playground/src/weblets/tf_discourse.vue @@ -26,7 +26,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_domains.vue b/packages/playground/src/weblets/tf_domains.vue index 090ca17737..6c7e2bf49e 100644 --- a/packages/playground/src/weblets/tf_domains.vue +++ b/packages/playground/src/weblets/tf_domains.vue @@ -16,7 +16,7 @@ validators.isAlphanumeric('Subdomain should consist of letters and numbers only.'), subdomain => validators.isAlpha('Subdomain must start with alphabet char.')(subdomain[0]), validators.minLength('Subdomain must be at least 4 characters.', 4), - subdomain => validators.maxLength('Subdomain cannot exceed 50 characters.', 50)(subdomain), + subdomain => validators.maxLength('Subdomain cannot exceed 35 characters.', 35)(subdomain), ]" :async-rules="[validateSubdomain]" #="{ props }" diff --git a/packages/playground/src/weblets/tf_funkwhale.vue b/packages/playground/src/weblets/tf_funkwhale.vue index 4cc7aafe7e..325f11ef56 100644 --- a/packages/playground/src/weblets/tf_funkwhale.vue +++ b/packages/playground/src/weblets/tf_funkwhale.vue @@ -20,7 +20,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_jitsi.vue b/packages/playground/src/weblets/tf_jitsi.vue index 48edec2482..87046d8232 100644 --- a/packages/playground/src/weblets/tf_jitsi.vue +++ b/packages/playground/src/weblets/tf_jitsi.vue @@ -20,7 +20,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), name => validators.isAlpha('Name must start with alphabet char.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_kubernetes.vue b/packages/playground/src/weblets/tf_kubernetes.vue index cfe5329378..c8d4385b92 100644 --- a/packages/playground/src/weblets/tf_kubernetes.vue +++ b/packages/playground/src/weblets/tf_kubernetes.vue @@ -30,7 +30,7 @@ (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), validators.minLength('Name minimum length is 2 chars.', 2), - validators.maxLength('Name max length is 50 chars.', 50), + validators.maxLength('Name max length is 35 chars.', 35), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_mattermost.vue b/packages/playground/src/weblets/tf_mattermost.vue index 615da6badd..417ddceebb 100644 --- a/packages/playground/src/weblets/tf_mattermost.vue +++ b/packages/playground/src/weblets/tf_mattermost.vue @@ -27,7 +27,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_nextcloud.vue b/packages/playground/src/weblets/tf_nextcloud.vue index 2ee0911ab6..347f492299 100644 --- a/packages/playground/src/weblets/tf_nextcloud.vue +++ b/packages/playground/src/weblets/tf_nextcloud.vue @@ -20,7 +20,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_nostr.vue b/packages/playground/src/weblets/tf_nostr.vue index 2e8df05e12..46fb82946c 100644 --- a/packages/playground/src/weblets/tf_nostr.vue +++ b/packages/playground/src/weblets/tf_nostr.vue @@ -21,7 +21,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 35 characters.', 35), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_owncloud.vue b/packages/playground/src/weblets/tf_owncloud.vue index 245c903312..62a6367b86 100644 --- a/packages/playground/src/weblets/tf_owncloud.vue +++ b/packages/playground/src/weblets/tf_owncloud.vue @@ -28,7 +28,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_peertube.vue b/packages/playground/src/weblets/tf_peertube.vue index 62c32d729b..68e39d1df5 100644 --- a/packages/playground/src/weblets/tf_peertube.vue +++ b/packages/playground/src/weblets/tf_peertube.vue @@ -20,7 +20,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_presearch.vue b/packages/playground/src/weblets/tf_presearch.vue index 4bf38030d9..9cb1d8136c 100644 --- a/packages/playground/src/weblets/tf_presearch.vue +++ b/packages/playground/src/weblets/tf_presearch.vue @@ -32,7 +32,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 35 characters.', 35), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_staticwebsite.vue b/packages/playground/src/weblets/tf_staticwebsite.vue index 501b1e1a16..3e81ad2132 100644 --- a/packages/playground/src/weblets/tf_staticwebsite.vue +++ b/packages/playground/src/weblets/tf_staticwebsite.vue @@ -20,7 +20,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_subsquid.vue b/packages/playground/src/weblets/tf_subsquid.vue index fda71ecf21..f2304f4723 100644 --- a/packages/playground/src/weblets/tf_subsquid.vue +++ b/packages/playground/src/weblets/tf_subsquid.vue @@ -20,7 +20,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_taiga.vue b/packages/playground/src/weblets/tf_taiga.vue index c040db6843..73ddcc8b1c 100644 --- a/packages/playground/src/weblets/tf_taiga.vue +++ b/packages/playground/src/weblets/tf_taiga.vue @@ -27,7 +27,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_umbrel.vue b/packages/playground/src/weblets/tf_umbrel.vue index c708af7497..0a1774423c 100644 --- a/packages/playground/src/weblets/tf_umbrel.vue +++ b/packages/playground/src/weblets/tf_umbrel.vue @@ -20,7 +20,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 35 characters.', 35), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tf_wordpress.vue b/packages/playground/src/weblets/tf_wordpress.vue index 08a51ee7f3..584a2f09bb 100644 --- a/packages/playground/src/weblets/tf_wordpress.vue +++ b/packages/playground/src/weblets/tf_wordpress.vue @@ -20,7 +20,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 15 characters.', 15), ]" #="{ props }" > diff --git a/packages/playground/src/weblets/tfrobot.vue b/packages/playground/src/weblets/tfrobot.vue index 5ff90c72ec..2daedf6101 100644 --- a/packages/playground/src/weblets/tfrobot.vue +++ b/packages/playground/src/weblets/tfrobot.vue @@ -29,7 +29,7 @@ validators.IsAlphanumericExpectUnderscore('Name should consist of letters ,numbers and underscores only.'), (name: string) => validators.isAlpha('Name must start with an alphabetical character.')(name[0]), validators.minLength('Name must be at least 2 characters.', 2), - validators.maxLength('Name cannot exceed 50 characters.', 50), + validators.maxLength('Name cannot exceed 35 characters.', 35), ]" #="{ props }" > From 49541c2f0105d4099d315748a5f7ce14ed72c0c5 Mon Sep 17 00:00:00 2001 From: 0oM4R Date: Mon, 4 Nov 2024 12:38:39 +0200 Subject: [PATCH 06/11] Fix: add monitoring to grid client dependencies --- packages/grid_client/package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/grid_client/package.json b/packages/grid_client/package.json index 7a9790e65c..f944545b20 100644 --- a/packages/grid_client/package.json +++ b/packages/grid_client/package.json @@ -17,6 +17,7 @@ "@threefold/gridproxy_client": "2.6.0-rc2", "@threefold/rmb_direct_client": "2.6.0-rc2", "@threefold/tfchain_client": "2.6.0-rc2", + "@threefold/monitoring": "2.6.0-rc2", "@threefold/types": "2.6.0-rc2", "algosdk": "^1.19.0", "appdata-path": "^1.0.0", From e689ff40cd8fa40b044cc4945127a6dcbd5cf4be Mon Sep 17 00:00:00 2001 From: Omar Kassem Date: Mon, 4 Nov 2024 12:49:43 +0200 Subject: [PATCH 07/11] Fix: add monitoring to grid client dependencies (#3585) --- packages/grid_client/package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/grid_client/package.json b/packages/grid_client/package.json index 7a9790e65c..f944545b20 100644 --- a/packages/grid_client/package.json +++ b/packages/grid_client/package.json @@ -17,6 +17,7 @@ "@threefold/gridproxy_client": "2.6.0-rc2", "@threefold/rmb_direct_client": "2.6.0-rc2", "@threefold/tfchain_client": "2.6.0-rc2", + "@threefold/monitoring": "2.6.0-rc2", "@threefold/types": "2.6.0-rc2", "algosdk": "^1.19.0", "appdata-path": "^1.0.0", From bbd07712787527fb07332c819a7c7189240f9ea0 Mon Sep 17 00:00:00 2001 From: 0oM4R Date: Mon, 4 Nov 2024 12:54:19 +0200 Subject: [PATCH 08/11] Chore: update charts and values version --- packages/playground/playground-charts/Chart.yaml | 2 +- packages/playground/playground-charts/values.yaml | 2 +- packages/stats/chart/Chart.yaml | 2 +- packages/stats/chart/values.yaml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/playground/playground-charts/Chart.yaml b/packages/playground/playground-charts/Chart.yaml index 3c59ee6d75..166316cf1f 100644 --- a/packages/playground/playground-charts/Chart.yaml +++ b/packages/playground/playground-charts/Chart.yaml @@ -21,4 +21,4 @@ version: 0.1.0 # incremented each time you make changes to the application. Versions are not expected to # follow Semantic Versioning. They should reflect the version the application is using. # It is recommended to use it with quotes. -appVersion: "v2.6.0-rc2" +appVersion: "v2.6.0-rc3" diff --git a/packages/playground/playground-charts/values.yaml b/packages/playground/playground-charts/values.yaml index acb6a28684..0e4a1cdd3e 100644 --- a/packages/playground/playground-charts/values.yaml +++ b/packages/playground/playground-charts/values.yaml @@ -8,7 +8,7 @@ image: repository: ghcr.io/threefoldtech/playground pullPolicy: Always # Overrides the image tag whose default is the chart appVersion. - tag: "2.6.0-rc2" + tag: "2.6.0-rc3" env: - name: "MODE" diff --git a/packages/stats/chart/Chart.yaml b/packages/stats/chart/Chart.yaml index 090457744c..b473f5c9f9 100644 --- a/packages/stats/chart/Chart.yaml +++ b/packages/stats/chart/Chart.yaml @@ -21,4 +21,4 @@ version: 1.0.0 # incremented each time you make changes to the application. Versions are not expected to # follow Semantic Versioning. They should reflect the version the application is using. # It is recommended to use it with quotes. -appVersion: "v2.6.0-rc2" +appVersion: "v2.6.0-rc3" diff --git a/packages/stats/chart/values.yaml b/packages/stats/chart/values.yaml index 26477bca1b..06ac9bf837 100644 --- a/packages/stats/chart/values.yaml +++ b/packages/stats/chart/values.yaml @@ -4,7 +4,7 @@ image: repository: ghcr.io/threefoldtech/stats pullPolicy: Always # Overrides the image tag whose default is the chart appVersion. - tag: "2.6.0-rc2" + tag: "2.6.0-rc3" imagePullSecrets: [] nameOverride: "" From 00a0a45146bcd2e3e72e0cf18d5584feb4925455 Mon Sep 17 00:00:00 2001 From: 0oM4R Date: Mon, 4 Nov 2024 12:55:50 +0200 Subject: [PATCH 09/11] v2.6.0-rc3 --- lerna.json | 2 +- packages/UI/package.json | 2 +- packages/graphql_client/package.json | 4 ++-- packages/grid_client/package.json | 12 ++++++------ packages/grid_http_server/package.json | 4 ++-- packages/grid_rmb_server/package.json | 8 ++++---- packages/gridproxy_client/package.json | 2 +- packages/monitoring/package.json | 8 ++++---- packages/playground/package.json | 12 ++++++------ packages/rmb_direct_client/package.json | 6 +++--- packages/rmb_peer_client/package.json | 2 +- packages/rmb_peer_server/package.json | 2 +- packages/stats/package.json | 4 ++-- packages/tfchain_client/package.json | 4 ++-- packages/types/package.json | 2 +- 15 files changed, 37 insertions(+), 37 deletions(-) diff --git a/lerna.json b/lerna.json index 8ac980cb09..b7a4441b19 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { "$schema": "node_modules/lerna/schemas/lerna-schema.json", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "npmClient": "yarn" } diff --git a/packages/UI/package.json b/packages/UI/package.json index 2d05fe9cbc..326e1989d6 100644 --- a/packages/UI/package.json +++ b/packages/UI/package.json @@ -1,6 +1,6 @@ { "name": "@threefold/ui", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "private": false, "main": "dist/threefold-ui.umd.js", "publishConfig": { diff --git a/packages/graphql_client/package.json b/packages/graphql_client/package.json index a517296f12..43227a82dd 100644 --- a/packages/graphql_client/package.json +++ b/packages/graphql_client/package.json @@ -1,6 +1,6 @@ { "name": "@threefold/graphql_client", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "main": "./dist/node/index.js", "module": "./dist/es6/index.js", "exports": { @@ -18,7 +18,7 @@ "es6-build": "tsc --build tsconfig.json" }, "dependencies": { - "@threefold/types": "2.6.0-rc2", + "@threefold/types": "2.6.0-rc3", "ts-mixer": "^6.0.2" }, "devDependencies": { diff --git a/packages/grid_client/package.json b/packages/grid_client/package.json index f944545b20..c77a4f2bad 100644 --- a/packages/grid_client/package.json +++ b/packages/grid_client/package.json @@ -1,7 +1,7 @@ { "name": "@threefold/grid_client", "author": "Ahmed Hanafy", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "license": "ISC", "homepage": "https://github.com/threefoldtech/tfgrid-sdk-ts/tree/development/packages/grid_client/README.md", "repository": { @@ -14,11 +14,11 @@ "dependencies": { "@jimber/pkid": "1.0.4", "@noble/secp256k1": "^1.7.1", - "@threefold/gridproxy_client": "2.6.0-rc2", - "@threefold/rmb_direct_client": "2.6.0-rc2", - "@threefold/tfchain_client": "2.6.0-rc2", - "@threefold/monitoring": "2.6.0-rc2", - "@threefold/types": "2.6.0-rc2", + "@threefold/gridproxy_client": "2.6.0-rc3", + "@threefold/monitoring": "2.6.0-rc3", + "@threefold/rmb_direct_client": "2.6.0-rc3", + "@threefold/tfchain_client": "2.6.0-rc3", + "@threefold/types": "2.6.0-rc3", "algosdk": "^1.19.0", "appdata-path": "^1.0.0", "await-lock": "^2.2.2", diff --git a/packages/grid_http_server/package.json b/packages/grid_http_server/package.json index 393419d70b..aa81ff670a 100644 --- a/packages/grid_http_server/package.json +++ b/packages/grid_http_server/package.json @@ -1,7 +1,7 @@ { "name": "@threefold/grid_http_server", "author": "Ahmed Hanafy", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "license": "ISC", "homepage": "https://github.com/threefoldtech/tfgrid-sdk-ts/blob/development/packages/grid_http_server/README.md", "repository": { @@ -12,7 +12,7 @@ "access": "public" }, "dependencies": { - "@threefold/grid_client": "2.6.0-rc2", + "@threefold/grid_client": "2.6.0-rc3", "express": "^4.21.1", "http-server": "^14.1.1", "typescript": "^4.7.4" diff --git a/packages/grid_rmb_server/package.json b/packages/grid_rmb_server/package.json index 8ef8b33bfd..46c32a7a44 100644 --- a/packages/grid_rmb_server/package.json +++ b/packages/grid_rmb_server/package.json @@ -1,7 +1,7 @@ { "name": "@threefold/grid_rmb_server", "author": "Ahmed Hanafy", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "license": "ISC", "homepage": "https://github.com/threefoldtech/tfgrid-sdk-ts/blob/development/packages/grid_rmb_server/README.md", "repository": { @@ -12,12 +12,12 @@ "access": "public" }, "dependencies": { - "@threefold/grid_client": "2.6.0-rc2", - "@threefold/rmb_peer_server": "2.6.0-rc2", + "@threefold/grid_client": "2.6.0-rc3", + "@threefold/rmb_peer_server": "2.6.0-rc3", "typescript": "^4.7.4" }, "devDependencies": { - "@threefold/rmb_peer_client": "2.6.0-rc2", + "@threefold/rmb_peer_client": "2.6.0-rc3", "ts-node": "^10.9.1" }, "main": "./dist/index.js", diff --git a/packages/gridproxy_client/package.json b/packages/gridproxy_client/package.json index bd710d0b2d..e375b23c69 100644 --- a/packages/gridproxy_client/package.json +++ b/packages/gridproxy_client/package.json @@ -1,6 +1,6 @@ { "name": "@threefold/gridproxy_client", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "description": "gridproxy_client help to interact with gridproxy based on network", "main": "./dist/node/public_api.js", "module": "./dist/es6/public_api.js", diff --git a/packages/monitoring/package.json b/packages/monitoring/package.json index 9bfb8398ce..9bc492fbb0 100644 --- a/packages/monitoring/package.json +++ b/packages/monitoring/package.json @@ -1,6 +1,6 @@ { "name": "@threefold/monitoring", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "description": "Threefold monitoring package", "license": "Apache-2.0", "main": "./dist/node/index.js", @@ -26,9 +26,9 @@ "access": "public" }, "dependencies": { - "@threefold/rmb_direct_client": "2.6.0-rc2", - "@threefold/tfchain_client": "2.6.0-rc2", - "@threefold/types": "2.6.0-rc2", + "@threefold/rmb_direct_client": "2.6.0-rc3", + "@threefold/tfchain_client": "2.6.0-rc3", + "@threefold/types": "2.6.0-rc3", "chalk": "4.1.2", "ts-node": "^10.9.1", "typescript": "^5.3.3", diff --git a/packages/playground/package.json b/packages/playground/package.json index 9760116654..bf6de9023c 100644 --- a/packages/playground/package.json +++ b/packages/playground/package.json @@ -1,6 +1,6 @@ { "name": "@threefold/playground", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "private": true, "scripts": { "dev": "vite", @@ -13,11 +13,11 @@ "dependencies": { "@mdi/font": "^7.2.96", "@sentry/vue": "^8.19.0", - "@threefold/graphql_client": "2.6.0-rc2", - "@threefold/grid_client": "2.6.0-rc2", - "@threefold/gridproxy_client": "2.6.0-rc2", - "@threefold/monitoring": "2.6.0-rc2", - "@threefold/types": "2.6.0-rc2", + "@threefold/graphql_client": "2.6.0-rc3", + "@threefold/grid_client": "2.6.0-rc3", + "@threefold/gridproxy_client": "2.6.0-rc3", + "@threefold/monitoring": "2.6.0-rc3", + "@threefold/types": "2.6.0-rc3", "@types/ip": "^1.1.3", "@types/md5": "^2.3.5", "await-lock": "^2.2.2", diff --git a/packages/rmb_direct_client/package.json b/packages/rmb_direct_client/package.json index 76aa946a24..731feccd4d 100644 --- a/packages/rmb_direct_client/package.json +++ b/packages/rmb_direct_client/package.json @@ -1,6 +1,6 @@ { "name": "@threefold/rmb_direct_client", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "repository": { "type": "git", "url": "https://github.com/threefoldtech/tfgrid-sdk-ts.git" @@ -23,8 +23,8 @@ "dependencies": { "@noble/secp256k1": "^1.7.1", "@polkadot/api": "^8.9.1", - "@threefold/tfchain_client": "2.6.0-rc2", - "@threefold/types": "2.6.0-rc2", + "@threefold/tfchain_client": "2.6.0-rc3", + "@threefold/types": "2.6.0-rc3", "base64url": "^3.0.1", "bip39": "^3.1.0", "buffer": "^6.0.3", diff --git a/packages/rmb_peer_client/package.json b/packages/rmb_peer_client/package.json index d1f353ff2a..4f9b02e61b 100644 --- a/packages/rmb_peer_client/package.json +++ b/packages/rmb_peer_client/package.json @@ -1,7 +1,7 @@ { "name": "@threefold/rmb_peer_client", "author": "Ahmed Hanafy", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "license": "ISC", "homepage": "https://github.com/threefoldtech/tfgrid-sdk-ts/blob/development/packages/rmb_peer_client/README.md", "repository": { diff --git a/packages/rmb_peer_server/package.json b/packages/rmb_peer_server/package.json index 6ef0507399..97fd24179b 100644 --- a/packages/rmb_peer_server/package.json +++ b/packages/rmb_peer_server/package.json @@ -1,7 +1,7 @@ { "name": "@threefold/rmb_peer_server", "author": "Ahmed Hanafy", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "license": "ISC", "homepage": "https://github.com/threefoldtech/tfgrid-sdk-ts/blob/development/packages/rmb_peer_server/README.md", "repository": { diff --git a/packages/stats/package.json b/packages/stats/package.json index 3e89050af5..7663f7aa20 100644 --- a/packages/stats/package.json +++ b/packages/stats/package.json @@ -1,6 +1,6 @@ { "name": "@threefold/stats", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "private": true, "scripts": { "dev": "vite", @@ -11,7 +11,7 @@ "type-check": "vue-tsc --noEmit -p tsconfig.vitest.json --composite false" }, "dependencies": { - "@threefold/gridproxy_client": "2.6.0-rc2", + "@threefold/gridproxy_client": "2.6.0-rc3", "vue": "^3.3.5", "vuetify": "^3.3.21" }, diff --git a/packages/tfchain_client/package.json b/packages/tfchain_client/package.json index 37a5a22d49..e9ba65e69b 100644 --- a/packages/tfchain_client/package.json +++ b/packages/tfchain_client/package.json @@ -1,6 +1,6 @@ { "name": "@threefold/tfchain_client", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "description": "A client for TF chain", "private": false, "publishConfig": { @@ -48,7 +48,7 @@ }, "dependencies": { "@polkadot/api": "^8.9.1", - "@threefold/types": "2.6.0-rc2", + "@threefold/types": "2.6.0-rc3", "await-lock": "^2.2.2", "bip39": "^3.1.0", "moment": "^2.30.1" diff --git a/packages/types/package.json b/packages/types/package.json index 78647f4265..a8f825c557 100644 --- a/packages/types/package.json +++ b/packages/types/package.json @@ -1,6 +1,6 @@ { "name": "@threefold/types", - "version": "2.6.0-rc2", + "version": "2.6.0-rc3", "main": "dist/node/index.js", "types": "dist/es6/index.d.ts", "scripts": { From 9ea515504dfbe9d8aadae6e16088904135dd72d1 Mon Sep 17 00:00:00 2001 From: samaradel Date: Mon, 4 Nov 2024 16:06:23 +0200 Subject: [PATCH 10/11] Add rentableOrRentedBy query in dedicated filter --- packages/grid_client/src/modules/models.ts | 1 + packages/grid_client/src/primitives/nodes.ts | 1 + packages/playground/src/types/nodeSelector.ts | 1 + packages/playground/src/utils/nodeSelector.ts | 1 + 4 files changed, 4 insertions(+) diff --git a/packages/grid_client/src/modules/models.ts b/packages/grid_client/src/modules/models.ts index 4d4f3fd9a7..4f378a4b33 100644 --- a/packages/grid_client/src/modules/models.ts +++ b/packages/grid_client/src/modules/models.ts @@ -635,6 +635,7 @@ class FilterOptions { @Expose() @IsOptional() @Transform(({ value }) => NodeStatus[value]) @IsEnum(NodeStatus) status?: NodeStatus; @Expose() @IsOptional() @IsString() region?: string; @Expose() @IsOptional() @IsBoolean() healthy?: boolean; + @Expose() @IsOptional() @IsInt() rentableOrRentedBy?: number; } enum CertificationType { diff --git a/packages/grid_client/src/primitives/nodes.ts b/packages/grid_client/src/primitives/nodes.ts index 3c22b5eeb4..2a107bec85 100644 --- a/packages/grid_client/src/primitives/nodes.ts +++ b/packages/grid_client/src/primitives/nodes.ts @@ -423,6 +423,7 @@ class Nodes { healthy: options.healthy, sort_by: SortBy.FreeCRU, sort_order: SortOrder.Desc, + rentable_or_rented_by: options.rentableOrRentedBy, }; if (options.gateway) { diff --git a/packages/playground/src/types/nodeSelector.ts b/packages/playground/src/types/nodeSelector.ts index a349e869df..a2c519a5e5 100644 --- a/packages/playground/src/types/nodeSelector.ts +++ b/packages/playground/src/types/nodeSelector.ts @@ -23,6 +23,7 @@ export interface SelectionDetailsFilters { certified?: boolean; dedicated?: boolean; exclusiveFor?: string; + rentable_or_rented_by?: number; } export interface NumericValidator { diff --git a/packages/playground/src/utils/nodeSelector.ts b/packages/playground/src/utils/nodeSelector.ts index 1a87bacf80..6d454ed951 100644 --- a/packages/playground/src/utils/nodeSelector.ts +++ b/packages/playground/src/utils/nodeSelector.ts @@ -208,6 +208,7 @@ export function normalizeNodeFilters( country: options.location.country, gateway: options.gateway, healthy: true, + rentableOrRentedBy: filters.dedicated ? options.twinId : undefined, }; } From b186028fcbc15f01487d9bba218cc4a21ae22b2d Mon Sep 17 00:00:00 2001 From: samaradel Date: Sun, 15 Dec 2024 14:36:51 +0200 Subject: [PATCH 11/11] rm unwanted filters --- packages/playground/src/utils/nodeSelector.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/packages/playground/src/utils/nodeSelector.ts b/packages/playground/src/utils/nodeSelector.ts index 6d454ed951..dd76f11b65 100644 --- a/packages/playground/src/utils/nodeSelector.ts +++ b/packages/playground/src/utils/nodeSelector.ts @@ -201,9 +201,7 @@ export function normalizeNodeFilters( publicIPs: filters.ipv4 || undefined, hasIPv6: filters.ipv6 || undefined, hasGPU: filters.hasGPU || undefined, - rentedBy: filters.dedicated ? options.twinId : undefined, certified: filters.certified || undefined, - availableFor: options.twinId, region: options.location.region ? options.location.region : options.location.subregion, country: options.location.country, gateway: options.gateway,