Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
13 changes: 13 additions & 0 deletions app/validate.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,18 @@ def _check_source_urls(name: str, record: dict[str, Any], errors: list[str]) ->
errors.append(f"{name}: source_urls must be a non-empty list of http(s) URL strings")


def _check_storage_options_gb(name: str, record: dict[str, Any], errors: list[str]) -> None:
values = record.get("storage_options_gb")
if values is None:
return
if not isinstance(values, list):
errors.append(f"{name}: storage_options_gb must be a list of integer GB values")
return
bad = [value for value in values if not isinstance(value, int) or value < 1]
if bad:
errors.append(f"{name}: storage_options_gb contains invalid integer GB values {bad}")


def _check_variant_path(
fname: str,
rec: dict[str, Any],
Expand Down Expand Up @@ -285,6 +297,7 @@ def validate() -> list[str]:
errors.append(f"{fname}: brand '{rec.get('brand')}' not a known brand")
if rec.get("soc") is not None and rec.get("soc") not in soc_slugs:
errors.append(f"{fname}: soc '{rec.get('soc')}' not a known SoC")
_check_storage_options_gb(fname, rec, errors)
_check_variant_path(fname, rec, category, errors)

for fname, rec in gpus:
Expand Down
44 changes: 44 additions & 0 deletions data/pda/hp/2004/ipaq-h6310/hp-ipaq-h6310-scrapegsma-3824.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
{
"slug": "hp-ipaq-h6310-scrapegsma-3824",
"base_model_slug": "ipaq-h6310",
"name": "HP iPAQ h6310",
"brand": "hp",
"release_date": "2004-01-01",
"ram_gb": 0.0625,
"battery_mah": 1800,
"weight_g": 190.0,
"os": "Microsoft Windows Mobile 2003 PocketPC Phone Edition",
"verified": false,
"source_urls": [
"https://github.com/cigarplug/scrape-gsma"
],
"variant": {
"region": "global",
"source_dataset": "cigarplug/scrape-gsma",
"source_row": 3824,
"network": {
"cellular": "2G"
},
"sim": "Mini-SIM"
},
"raw_source": {
"network_technology": "GSM",
"launch_announced": "2004, Q4",
"launch_status": "Discontinued",
"memory_internal": "64 MB RAM, 64 MB ROM",
"platform_chipset": "TI OMAP 1510",
"platform_cpu": "ARM925T",
"platform_gpu": "",
"misc_models": ""
},
"display": {
"size_inch": 3.5,
"resolution": "240x320",
"type": "TFT resistive touchscreen, 65K colors"
},
"connectivity": {
"wlan": "Wi-Fi 802.11b",
"bluetooth": "1.1",
"gps": "No"
}
}
44 changes: 44 additions & 0 deletions data/pda/hp/2004/ipaq-h6315/hp-ipaq-h6315-scrapegsma-3823.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
{
"slug": "hp-ipaq-h6315-scrapegsma-3823",
"base_model_slug": "ipaq-h6315",
"name": "HP iPAQ h6315",
"brand": "hp",
"release_date": "2004-01-01",
"ram_gb": 0.0625,
"battery_mah": 1800,
"weight_g": 190.0,
"os": "Microsoft Windows Mobile 2003 PocketPC Phone Edition",
"verified": false,
"source_urls": [
"https://github.com/cigarplug/scrape-gsma"
],
"variant": {
"region": "global",
"source_dataset": "cigarplug/scrape-gsma",
"source_row": 3823,
"network": {
"cellular": "2G"
},
"sim": "Mini-SIM"
},
"raw_source": {
"network_technology": "GSM",
"launch_announced": "2004, Q4",
"launch_status": "Discontinued",
"memory_internal": "64 MB RAM, 64 MB ROM",
"platform_chipset": "TI OMAP 1510",
"platform_cpu": "ARM925T",
"platform_gpu": "",
"misc_models": ""
},
"display": {
"size_inch": 3.5,
"resolution": "240x320",
"type": "TFT resistive touchscreen, 65K colors"
},
"connectivity": {
"wlan": "Wi-Fi 802.11b",
"bluetooth": "1.1",
"gps": "No"
}
}
44 changes: 44 additions & 0 deletions data/pda/hp/2004/ipaq-h6320/hp-ipaq-h6320-scrapegsma-3822.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
{
"slug": "hp-ipaq-h6320-scrapegsma-3822",
"base_model_slug": "ipaq-h6320",
"name": "HP iPAQ h6320",
"brand": "hp",
"release_date": "2004-01-01",
"ram_gb": 0.0625,
"battery_mah": 1800,
"weight_g": 190.0,
"os": "Microsoft Windows Mobile 2003 PocketPC Phone Edition",
"verified": false,
"source_urls": [
"https://github.com/cigarplug/scrape-gsma"
],
"variant": {
"region": "global",
"source_dataset": "cigarplug/scrape-gsma",
"source_row": 3822,
"network": {
"cellular": "2G"
},
"sim": "Mini-SIM"
},
"raw_source": {
"network_technology": "GSM",
"launch_announced": "2004, Q4",
"launch_status": "Discontinued",
"memory_internal": "64 MB RAM, 64 MB ROM",
"platform_chipset": "TI OMAP 1510",
"platform_cpu": "ARM925T",
"platform_gpu": "",
"misc_models": ""
},
"display": {
"size_inch": 3.5,
"resolution": "240x320",
"type": "TFT resistive touchscreen, 65K colors"
},
"connectivity": {
"wlan": "Wi-Fi 802.11b",
"bluetooth": "1.1",
"gps": "No"
}
}
44 changes: 44 additions & 0 deletions data/pda/hp/2004/ipaq-h6325/hp-ipaq-h6325-scrapegsma-3821.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
{
"slug": "hp-ipaq-h6325-scrapegsma-3821",
"base_model_slug": "ipaq-h6325",
"name": "HP iPAQ h6325",
"brand": "hp",
"release_date": "2004-01-01",
"ram_gb": 0.0625,
"battery_mah": 1800,
"weight_g": 190.0,
"os": "Microsoft Windows Mobile 2003 PocketPC Phone Edition",
"verified": false,
"source_urls": [
"https://github.com/cigarplug/scrape-gsma"
],
"variant": {
"region": "global",
"source_dataset": "cigarplug/scrape-gsma",
"source_row": 3821,
"network": {
"cellular": "2G"
},
"sim": "Mini-SIM"
},
"raw_source": {
"network_technology": "GSM",
"launch_announced": "2004, Q4",
"launch_status": "Discontinued",
"memory_internal": "64 MB RAM, 64 MB ROM",
"platform_chipset": "TI OMAP 1510",
"platform_cpu": "ARM925T",
"platform_gpu": "",
"misc_models": ""
},
"display": {
"size_inch": 3.5,
"resolution": "240x320",
"type": "TFT resistive touchscreen, 65K colors"
},
"connectivity": {
"wlan": "Wi-Fi 802.11b",
"bluetooth": "1.1",
"gps": "No"
}
}
44 changes: 44 additions & 0 deletions data/pda/hp/2005/ipaq-hw6510/hp-ipaq-hw6510-scrapegsma-3820.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
{
"slug": "hp-ipaq-hw6510-scrapegsma-3820",
"base_model_slug": "ipaq-hw6510",
"name": "HP iPAQ hw6510",
"brand": "hp",
"release_date": "2005-01-01",
"ram_gb": 0.0625,
"battery_mah": 1200,
"weight_g": 165.0,
"os": "Microsoft Windows Mobile 2003 SE PocketPC Phone Edition",
"verified": false,
"source_urls": [
"https://github.com/cigarplug/scrape-gsma"
],
"variant": {
"region": "global",
"source_dataset": "cigarplug/scrape-gsma",
"source_row": 3820,
"network": {
"cellular": "2G"
},
"sim": "Mini-SIM"
},
"raw_source": {
"network_technology": "GSM",
"launch_announced": "2005, Q2",
"launch_status": "Discontinued",
"memory_internal": "64 MB RAM, 64 MB ROM",
"platform_chipset": "",
"platform_cpu": "Intel PXA270 312 MHz",
"platform_gpu": "",
"misc_models": ""
},
"display": {
"size_inch": 3.0,
"resolution": "240x240",
"type": "TFT resistive touchscreen, 65K colors"
},
"connectivity": {
"wlan": "No",
"bluetooth": "1.2",
"gps": "Yes"
}
}
44 changes: 44 additions & 0 deletions data/pda/hp/2005/ipaq-hw6515/hp-ipaq-hw6515-scrapegsma-3819.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
{
"slug": "hp-ipaq-hw6515-scrapegsma-3819",
"base_model_slug": "ipaq-hw6515",
"name": "HP iPAQ hw6515",
"brand": "hp",
"release_date": "2005-01-01",
"ram_gb": 0.0625,
"battery_mah": 1200,
"weight_g": 165.0,
"os": "Microsoft Windows Mobile 2003 SE PocketPC Phone Edition",
"verified": false,
"source_urls": [
"https://github.com/cigarplug/scrape-gsma"
],
"variant": {
"region": "global",
"source_dataset": "cigarplug/scrape-gsma",
"source_row": 3819,
"network": {
"cellular": "2G"
},
"sim": "Mini-SIM"
},
"raw_source": {
"network_technology": "GSM",
"launch_announced": "2005, Q2",
"launch_status": "Discontinued",
"memory_internal": "64 MB RAM, 64 MB ROM",
"platform_chipset": "",
"platform_cpu": "Intel PXA270 312 MHz",
"platform_gpu": "",
"misc_models": ""
},
"display": {
"size_inch": 3.0,
"resolution": "240x240",
"type": "TFT resistive touchscreen, 65K colors"
},
"connectivity": {
"wlan": "No",
"bluetooth": "1.2",
"gps": "Yes"
}
}
43 changes: 43 additions & 0 deletions data/pda/hp/2006/ipaq-hw6910/hp-ipaq-hw6910-scrapegsma-3818.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
"slug": "hp-ipaq-hw6910-scrapegsma-3818",
"base_model_slug": "ipaq-hw6910",
"name": "HP iPAQ hw6910",
"brand": "hp",
"release_date": "2006-02-01",
"ram_gb": 0.0625,
"battery_mah": 1200,
"weight_g": 179.0,
"os": "Microsoft Windows Mobile 2005 PocketPC",
"verified": false,
"source_urls": [
"https://github.com/cigarplug/scrape-gsma"
],
"variant": {
"region": "global",
"source_dataset": "cigarplug/scrape-gsma",
"source_row": 3818,
"network": {
"cellular": "2G"
},
"sim": "Mini-SIM"
},
"raw_source": {
"network_technology": "GSM",
"launch_announced": "2006, February",
"launch_status": "Discontinued",
"memory_internal": "64 MB RAM, 45 MB ROM",
"platform_chipset": "",
"platform_cpu": "Intel PXA 270 416 MHz",
"platform_gpu": "",
"misc_models": ""
},
"display": {
"resolution": "240x240",
"type": "TFT resistive touchscreen, 65K colors"
},
"connectivity": {
"wlan": "Wi-Fi 802.11b",
"bluetooth": "1.2",
"gps": "Yes"
}
}
43 changes: 43 additions & 0 deletions data/pda/hp/2006/ipaq-hw6915/hp-ipaq-hw6915-scrapegsma-3817.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
"slug": "hp-ipaq-hw6915-scrapegsma-3817",
"base_model_slug": "ipaq-hw6915",
"name": "HP iPAQ hw6915",
"brand": "hp",
"release_date": "2006-02-01",
"ram_gb": 0.0625,
"battery_mah": 1200,
"weight_g": 179.0,
"os": "Microsoft Windows Mobile 2005 PocketPC",
"verified": false,
"source_urls": [
"https://github.com/cigarplug/scrape-gsma"
],
"variant": {
"region": "global",
"source_dataset": "cigarplug/scrape-gsma",
"source_row": 3817,
"network": {
"cellular": "2G"
},
"sim": "Mini-SIM"
},
"raw_source": {
"network_technology": "GSM",
"launch_announced": "2006, February",
"launch_status": "Discontinued",
"memory_internal": "64 MB RAM, 45 MB ROM",
"platform_chipset": "",
"platform_cpu": "Intel PXA 270 416 MHz",
"platform_gpu": "",
"misc_models": ""
},
"display": {
"resolution": "240x240",
"type": "TFT resistive touchscreen, 65K colors"
},
"connectivity": {
"wlan": "Wi-Fi 802.11b",
"bluetooth": "1.2",
"gps": "Yes"
}
}
Loading
Loading