diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 4f047854..c7b23bb0 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -1 +1,2 @@ -* @esfoobar-usds @vim-usds @emma-nechamkin +* @esfoobar-usds @vim-usds @emma-nechamkin @mattbowen-usds + diff --git a/.github/workflows/deploy_fe_staging.yml b/.github/workflows/deploy_fe_staging.yml index 58d8ea9d..0ddc1f86 100644 --- a/.github/workflows/deploy_fe_staging.yml +++ b/.github/workflows/deploy_fe_staging.yml @@ -50,7 +50,7 @@ jobs: - name: Check for security vulnerabilities run: npm audit --production - name: Cypress / Gherkin integration tests 馃寖 - uses: cypress-io/github-action@v2 + uses: cypress-io/github-action@v4 with: working-directory: ${{env.WORKING_DIRECTORY}} browser: chrome diff --git a/.github/workflows/tribal-deploy.yml b/.github/workflows/tribal-deploy.yml new file mode 100644 index 00000000..f8b05ad7 --- /dev/null +++ b/.github/workflows/tribal-deploy.yml @@ -0,0 +1,86 @@ +name: Tribal Layer Deploy +on: + workflow_dispatch: + inputs: + confirm-action: + description: This will deploy tribal map layer, are you sure you want to proceed? (Y/n) + default: n + required: true +env: + BE_CDN_ID: E1324VDMNCO97N +jobs: + deploy_data: + runs-on: ubuntu-latest + defaults: + run: + working-directory: data/data-pipeline + strategy: + matrix: + python-version: [3.9] + steps: + - name: Checkout source + uses: actions/checkout@v2 + - name: Print variables to help debug + uses: hmarr/debug-action@v2 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - name: Load cached Poetry installation + uses: actions/cache@v2 + id: cached-poetry-dependencies + with: + path: ~/.cache/pypoetry/virtualenvs + key: env-${{ runner.os }}-${{ matrix.python-version }}-${{ hashFiles('**/poetry.lock') }}-${{ hashFiles('.github/workflows/combine-tilefy.yml') }} + - name: Install poetry + uses: snok/install-poetry@v1 + - name: Print Poetry settings + run: poetry show -v + - name: Install dependencies + run: poetry add s4cmd && poetry install + if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true' + - name: Install GDAL/ogr2ogr + run: | + sudo add-apt-repository ppa:ubuntugis/ppa + sudo apt-get update + sudo apt-get -y install gdal-bin + ogrinfo --version + - name: Set timezone for tippecanoe + uses: szenius/set-timezone@v1.0 + with: + timezoneLinux: "America/Los_Angeles" + - name: Get tippecanoe + run: | + sudo apt-get install -y software-properties-common libsqlite3-dev zlib1g-dev + sudo apt-add-repository -y ppa:git-core/ppa + sudo mkdir -p /tmp/tippecanoe-src + sudo git clone https://github.com/mapbox/tippecanoe.git /tmp/tippecanoe-src + - name: Make tippecanoe + working-directory: /tmp/tippecanoe-src + run: | + sudo /usr/bin/bash -c make + mkdir -p /usr/local/bin + cp tippecanoe /usr/local/bin/tippecanoe + tippecanoe -v + - name: Run Scripts + run: | + poetry run python3 data_pipeline/application.py etl-run --dataset tribal + poetry run python3 data_pipeline/application.py generate-map-tiles --generate-tribal-layer + - name: Configure AWS Credentials + uses: aws-actions/configure-aws-credentials@v1 + with: + aws-access-key-id: ${{ secrets.DATA_DEV_AWS_ACCESS_KEY_ID }} + aws-secret-access-key: ${{ secrets.DATA_DEV_AWS_SECRET_ACCESS_KEY }} + aws-region: us-east-1 + - name: Deploy to Geoplatform AWS + run: | + poetry run s4cmd put ./data_pipeline/data/tribal/geojson/ s3://justice40-data/data-pipeline/data/tribal/geojson --recursive --force --API-ACL=public-read --num-threads=250 + poetry run s4cmd put ./data_pipeline/data/tribal/tiles/ s3://justice40-data/data-pipeline/data/tribal/tiles --recursive --force --API-ACL=public-read --num-threads=250 + - name: Invalidate cache on AWS CDNs + uses: chetan/invalidate-cloudfront-action@master + env: + DISTRIBUTION: ${{env.BE_CDN_ID}} + PATHS: "/*" + AWS_REGION: "us-east-1" + AWS_ACCESS_KEY_ID: ${{ secrets.DATA_DEV_AWS_ACCESS_KEY_ID }} + AWS_SECRET_ACCESS_KEY: ${{ secrets.DATA_DEV_AWS_SECRET_ACCESS_KEY }} diff --git a/client/.generate_component/README.md b/client/.generate_component/README.md new file mode 100644 index 00000000..132e0643 --- /dev/null +++ b/client/.generate_component/README.md @@ -0,0 +1,13 @@ +# README + +Creating all the various parts of a React component each time a new component is needed is cumbersome and error-prone. + +This folder follows this [link](https://levelup.gitconnected.com/how-to-generate-react-components-from-your-terminal-a27741a5b862) to allow the developer to create a new React component (along with sass, tests and barrell) with a single command. The command is + +`npm run gc ` + +For example: to create a new React component called MapGeolocate: + +`npm run gc MapGeolocate` + +Note: gc stands for generate component \ No newline at end of file diff --git a/client/.generate_component/component_templates.js b/client/.generate_component/component_templates.js new file mode 100644 index 00000000..ec28110d --- /dev/null +++ b/client/.generate_component/component_templates.js @@ -0,0 +1,64 @@ + +// component.tsx +exports.component = name => `import React from 'react'; + +import * as styles from './${name}.module.scss'; + +export interface I${name}Props {} + +const ${name} = ({}: I${name}Props) => { + return ( +
+ Hello 馃憢, I am a ${name} component. +
+ ) +}; + +export default ${name}; +`; + +// component.module.scss +exports.sass = name => `@use '../../styles/design-system.scss' as *; + +.${name[0].toLowerCase() + name.slice(1)}Container{ + +} +`; + +// component.module.scss.d.ts +exports.sassType = name => `declare namespace ${name}Namespace { + export interface I${name}Scss { + ${name[0].toLowerCase() + name.slice(1)}Container: string; + } + } + +declare const ${name}ScssModule: ${name}Namespace.I${name}Scss & { + /** WARNING: Only available when "css-loader" is used without "style-loader" or "mini-css-extract-plugin" */ + locals: ${name}Namespace.I${name}Scss; + }; + + export = ${name}ScssModule; +`; + +// component.test.tsx +exports.test = name => `import React from 'react'; +import { render } from '@testing-library/react'; +import {LocalizedComponent} from '../../test/testHelpers'; +import ${name} from './${name}'; + +describe('rendering of ${name} Component', () => { + const {asFragment} = render( + + <${name} /> + , + ); + it('checks if component renders', () => { + expect(asFragment()).toMatchSnapshot(); + }); +}); +`; + +// index.ts +exports.barrel = name => `import ${name} from './${name}'; +export default ${name}; +`; \ No newline at end of file diff --git a/client/.generate_component/index.js b/client/.generate_component/index.js new file mode 100644 index 00000000..61fb065d --- /dev/null +++ b/client/.generate_component/index.js @@ -0,0 +1,55 @@ +const fs = require('fs'); +const { component, sass, sassType, test, barrel } = require('./component_templates.js'); + +// grab component name from terminal argument +const [name] = process.argv.slice(2); +if (!name) throw new Error('You must include a component name.'); + +const dir = `./src/components/${name}/`; + +// throw an error if the file already exists +if (fs.existsSync(dir)) throw new Error('A component with that name already exists.'); + +// create the folder +fs.mkdirSync(dir); + +function writeFileErrorHandler(err) { + if (err) throw err; +} + +// component.tsx +fs.writeFile(`${dir}/${name}.tsx`, component(name), writeFileErrorHandler); +// component.module.scss +fs.writeFile(`${dir}/${name}.module.scss`, sass(name), writeFileErrorHandler); +// component.module.scss.d.ts +fs.writeFile(`${dir}/${name}.module.scss.d.ts`, sassType(name), writeFileErrorHandler); +// test.tsx +fs.writeFile(`${dir}/${name}.test.tsx`, test(name), writeFileErrorHandler); +// index.tsx +fs.writeFile(`${dir}/index.ts`, barrel(name), writeFileErrorHandler); + +//////////////// +/// Optional /// +//////////////// + +// insert new component into 'components/index.ts file + +/* fs.readFile('./src/components/index.ts', 'utf8', function(err, data) { + if (err) throw err; + + // grab all components and combine them with new component + const currentComponents = data.match(/(?<=import )(.*?)(?= from)/g); + const newComponents = [name, ...currentComponents].sort(); + + // create the import and export statements + const importStatements = newComponents + .map(importName => `import ${importName} from './${importName}';\n`) + .join(''); + const exportStatements = `export {\n${newComponents + .map(component => ` ${component},\n`) + .join('')}};\n`; + + const fileContent = `${importStatements}\n${exportStatements}`; + + fs.writeFile(`./src/components/index.ts`, fileContent, writeFileErrorHandler); +}); */ \ No newline at end of file diff --git a/client/README.md b/client/README.md index 27c2da6a..42b468cd 100644 --- a/client/README.md +++ b/client/README.md @@ -6,6 +6,7 @@ This README contains the following content: - [Installing and running the client site](#installing-and-running-the-client-site) +- [Generating React components](#generating-react-components) - [Linting and Formatting](#linting-and-formatting) - [Testing](#testing) - [Localization](#localization) @@ -93,6 +94,12 @@ DATA_SOURCE env variable in the docker-compose.yml. See [environment variables]( See [VIEW_MAP_DATA.md](./VIEW_MAP_DATA.md) for more details on this. +## Generating React components +Each React component requires a barrell, test, sass file and sass types file. You can run the auto-generated component +to ensure you are following the style guide on creating React component for J40. + +Please see this [README](./.generate_component/README.md) for more information + ## Linting and Formatting This project uses [ESLint](https://eslint.org/) for code linting and [Prettier](https://prettier.io/) for formatting. They are integrated via [gatsby-plugin-prettier-eslint](https://www.gatsbyjs.com/plugins/gatsby-plugin-prettier-eslint/). diff --git a/client/gatsby-config.js b/client/gatsby-config.js index f1536616..dbbe34ae 100644 --- a/client/gatsby-config.js +++ b/client/gatsby-config.js @@ -101,7 +101,7 @@ module.exports = { { resolve: '@sentry/gatsby', options: { - dsn: 'https://da0c28c22c9e4ff69d81650cabdec3d9@o1022662.ingest.sentry.io/5989007', + dsn: process.env.SENTRY_DSN, sampleRate: 0.7, }, }, diff --git a/client/package-lock.json b/client/package-lock.json index 7767109c..98a13bc7 100644 --- a/client/package-lock.json +++ b/client/package-lock.json @@ -10,7 +10,7 @@ "license": "CC0-1.0", "dependencies": { "-": "^0.0.1", - "@sentry/gatsby": "^6.19.1", + "@sentry/gatsby": "^7.7.0", "@trussworks/react-uswds": "^2.9.0", "@turf/bbox": "^6.5.0", "d3-ease": "^3.0.1", @@ -3122,17 +3122,17 @@ } }, "node_modules/@sentry/browser": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/browser/-/browser-6.19.1.tgz", - "integrity": "sha512-nU73PecOoMwrsw2WRJW+oQSSfgGkcY3So3JH7qwRHnnk4Gx56TkDfS0AOrNRsSpIQXj1UbSFIWKzz6ajsOg9OA==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/browser/-/browser-7.7.0.tgz", + "integrity": "sha512-oyzpWcsjVZTaf14zAL89Ng1DUHlbjN+V8pl8dR9Y9anphbzL5BK9p0fSK4kPIrO4GukK+XrKnLJDPuE/o7WR3g==", "dependencies": { - "@sentry/core": "6.19.1", - "@sentry/types": "6.19.1", - "@sentry/utils": "6.19.1", + "@sentry/core": "7.7.0", + "@sentry/types": "7.7.0", + "@sentry/utils": "7.7.0", "tslib": "^1.9.3" }, "engines": { - "node": ">=6" + "node": ">=8" } }, "node_modules/@sentry/browser/node_modules/tslib": { @@ -3141,9 +3141,9 @@ "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" }, "node_modules/@sentry/cli": { - "version": "1.74.2", - "resolved": "https://registry.npmjs.org/@sentry/cli/-/cli-1.74.2.tgz", - "integrity": "sha512-J1P66/4yNN55PMO70+QQXeS87r4O9nYuJqZ29HJCPA/ih57jbMFRw9Wp9XLuO/QtpF8Yl7FvOwya/nImTOVOkA==", + "version": "1.74.5", + "resolved": "https://registry.npmjs.org/@sentry/cli/-/cli-1.74.5.tgz", + "integrity": "sha512-Ze1ec306ZWHtrxKypOJ8nhtFqkrx2f/6bRH+DcJzEQ3bBePQ0ZnqJTTe4BBHADYBtxFIaUWzCZ6DquLz2Zv/sw==", "hasInstallScript": true, "dependencies": { "https-proxy-agent": "^5.0.0", @@ -3162,18 +3162,17 @@ } }, "node_modules/@sentry/core": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/core/-/core-6.19.1.tgz", - "integrity": "sha512-ZSIFnwYCzABK1jX1iMwUbaAoWbbJear0wM+gSZvJpSUJ1dAXV1OZyL7kXtEJRtATahIlcrMou5ewIoeJizeWAw==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/core/-/core-7.7.0.tgz", + "integrity": "sha512-Z15ACiuiFINFcK4gbMrnejLn4AVjKBPJOWKrrmpIe8mh+Y9diOuswt5mMUABs+jhpZvqht3PBLLGBL0WMsYMYA==", "dependencies": { - "@sentry/hub": "6.19.1", - "@sentry/minimal": "6.19.1", - "@sentry/types": "6.19.1", - "@sentry/utils": "6.19.1", + "@sentry/hub": "7.7.0", + "@sentry/types": "7.7.0", + "@sentry/utils": "7.7.0", "tslib": "^1.9.3" }, "engines": { - "node": ">=6" + "node": ">=8" } }, "node_modules/@sentry/core/node_modules/tslib": { @@ -3182,33 +3181,35 @@ "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" }, "node_modules/@sentry/gatsby": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/gatsby/-/gatsby-6.19.1.tgz", - "integrity": "sha512-Gk+dj13BIyKH1qbwSFC2pjq7/xTzhMyjRn8VRWr4tqCK8TTAkCC6+TSLOLtmR4XaywJSj8g+JVVRRg3E2pAFDA==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/gatsby/-/gatsby-7.7.0.tgz", + "integrity": "sha512-RyCJNgVduK12tywzT4aJoRwsOGCPHvhY4X90wNZAOsFPhrB20UQGw3mULDfOBqvqwLN1QCKIi90zSdoVp5hQEA==", "dependencies": { - "@sentry/react": "6.19.1", - "@sentry/tracing": "6.19.1", - "@sentry/webpack-plugin": "1.18.8" + "@sentry/react": "7.7.0", + "@sentry/tracing": "7.7.0", + "@sentry/types": "7.7.0", + "@sentry/utils": "7.7.0", + "@sentry/webpack-plugin": "1.18.9" }, "engines": { - "node": ">=6" + "node": ">=8" }, "peerDependencies": { "gatsby": "^2.0.0 || ^3.0.0 || ^4.0.0", - "react": "15.x || 16.x || 17.x" + "react": "15.x || 16.x || 17.x || 18.x" } }, "node_modules/@sentry/hub": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/hub/-/hub-6.19.1.tgz", - "integrity": "sha512-BgUwdxxXntGohAYrXtYrYBA6QzOeRz3NINuS838n7SRTkGf9gBJ/Rd3dyOWUrzJciKty7rmvYIwTA0oo91AMkw==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/hub/-/hub-7.7.0.tgz", + "integrity": "sha512-6gydK234+a0nKhBRDdIJ7Dp42CaiW2juTiHegUVDq+482balVzbZyEAmESCmuzKJhx5BhlCElVxs/cci1NjMpg==", "dependencies": { - "@sentry/types": "6.19.1", - "@sentry/utils": "6.19.1", + "@sentry/types": "7.7.0", + "@sentry/utils": "7.7.0", "tslib": "^1.9.3" }, "engines": { - "node": ">=6" + "node": ">=8" } }, "node_modules/@sentry/hub/node_modules/tslib": { @@ -3216,41 +3217,22 @@ "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" }, - "node_modules/@sentry/minimal": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/minimal/-/minimal-6.19.1.tgz", - "integrity": "sha512-Xre3J6mjWEcQhDmQ3j4g71J8f0nDgg2p7K41SngibfZVYSOe8jAowxSI9JuWD7juuwT5GVRVCqLs+Y6mWDBaoQ==", - "dependencies": { - "@sentry/hub": "6.19.1", - "@sentry/types": "6.19.1", - "tslib": "^1.9.3" - }, - "engines": { - "node": ">=6" - } - }, - "node_modules/@sentry/minimal/node_modules/tslib": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", - "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" - }, "node_modules/@sentry/react": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/react/-/react-6.19.1.tgz", - "integrity": "sha512-/fBuRTZzMlXunoFJLmvlFzjEte3MCbU2t3Pihr5idMlWBddfJiaM1j9N6+SugVpYoeLfRwxq/ZWV/4wVOb7T3Q==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/react/-/react-7.7.0.tgz", + "integrity": "sha512-93Khad3YAln6mKU9E15QH09XC1ARIOpNTRpnBl6AGl3bVhSdLExsbKDLa7Rx0mW2j4z/prOC6VEHf5mBvg4mPg==", "dependencies": { - "@sentry/browser": "6.19.1", - "@sentry/minimal": "6.19.1", - "@sentry/types": "6.19.1", - "@sentry/utils": "6.19.1", + "@sentry/browser": "7.7.0", + "@sentry/types": "7.7.0", + "@sentry/utils": "7.7.0", "hoist-non-react-statics": "^3.3.2", "tslib": "^1.9.3" }, "engines": { - "node": ">=6" + "node": ">=8" }, "peerDependencies": { - "react": "15.x || 16.x || 17.x" + "react": "15.x || 16.x || 17.x || 18.x" } }, "node_modules/@sentry/react/node_modules/tslib": { @@ -3259,18 +3241,17 @@ "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" }, "node_modules/@sentry/tracing": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/tracing/-/tracing-6.19.1.tgz", - "integrity": "sha512-o34+h0j70dszcIwpCIbmO4UauPurpqLvcPO3JsFhRdxQhwQaQgMwhFklbAt7al9oEDYkjlS0gzhhlOCz4IS9kA==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/tracing/-/tracing-7.7.0.tgz", + "integrity": "sha512-HNmvTwemuc21q/K6HXsSp9njkne6N1JQ71TB+QGqYU5VtxsVgYSUhhYqV6WcHz7LK4Hj6TvNFoeu69/rO0ysgw==", "dependencies": { - "@sentry/hub": "6.19.1", - "@sentry/minimal": "6.19.1", - "@sentry/types": "6.19.1", - "@sentry/utils": "6.19.1", + "@sentry/hub": "7.7.0", + "@sentry/types": "7.7.0", + "@sentry/utils": "7.7.0", "tslib": "^1.9.3" }, "engines": { - "node": ">=6" + "node": ">=8" } }, "node_modules/@sentry/tracing/node_modules/tslib": { @@ -3279,23 +3260,23 @@ "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" }, "node_modules/@sentry/types": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/types/-/types-6.19.1.tgz", - "integrity": "sha512-ovmNYdqD2MKLmru4calxetX1xjJdYim+HEI/GzwvVUYshsaXRq4EiQ17h3DAy90MV7JH279PmMoPGDTOpufq+Q==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/types/-/types-7.7.0.tgz", + "integrity": "sha512-4x8O7uerSGLnYC10krHl9t8h7xXHn5FextqKYbTCXCnx2hC8D+9lz8wcbQAFo0d97wiUYqI8opmEgFVGx7c5hQ==", "engines": { - "node": ">=6" + "node": ">=8" } }, "node_modules/@sentry/utils": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/utils/-/utils-6.19.1.tgz", - "integrity": "sha512-mWcQbQ1yO7PooLpJpQK84+wOfxGeb8iUKRb8inO+2Eg6VksDbXRuJ89Yd4APBTRxBj5Wihy48bPuVfKtovtm8g==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/utils/-/utils-7.7.0.tgz", + "integrity": "sha512-fD+ROSFpeJlK7bEvUT2LOW7QqgjBpXJwVISKZ0P2fuzclRC3KoB2pbZgBM4PXMMTiSzRGWhvfRRjBiBvQJBBJQ==", "dependencies": { - "@sentry/types": "6.19.1", + "@sentry/types": "7.7.0", "tslib": "^1.9.3" }, "engines": { - "node": ">=6" + "node": ">=8" } }, "node_modules/@sentry/utils/node_modules/tslib": { @@ -3304,11 +3285,11 @@ "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" }, "node_modules/@sentry/webpack-plugin": { - "version": "1.18.8", - "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-1.18.8.tgz", - "integrity": "sha512-PtKr0NL62b5L3kPFGjwSNbIUwwcW5E5G6bQxAYZGpkgL1MFPnS4ND0SAsySuX0byQJRFFium5A19LpzyvQZSlQ==", + "version": "1.18.9", + "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-1.18.9.tgz", + "integrity": "sha512-+TrenJrgFM0QTOwBnw0ZXWMvc0PiOebp6GN5EbGEx3JPCQqXOfXFzCaEjBtASKRgcNCL7zGly41S25YR6Hm+jw==", "dependencies": { - "@sentry/cli": "^1.73.0" + "@sentry/cli": "^1.74.4" }, "engines": { "node": ">= 8" @@ -6905,7 +6886,7 @@ "node_modules/code-point-at": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", - "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=", + "integrity": "sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==", "engines": { "node": ">=0.10.0" } @@ -7176,7 +7157,7 @@ "node_modules/console-control-strings": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", - "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=" + "integrity": "sha512-ty/fTekppD2fIwRvnZAVdeOiGd1c7YXEixbgJTNzqcxJWKQnjJ/V1bNEEE6hygpM3WjwHFUVK6HTjWSzV4a8sQ==" }, "node_modules/constants-browserify": { "version": "1.0.0", @@ -8410,7 +8391,7 @@ "node_modules/delegates": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz", - "integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o=" + "integrity": "sha512-bd2L678uiWATM6m5Z1VzNCErI3jiGzt6HGY8OVICs40JQq/HALfbyNJmp0UDakEY4pMMaN0Ly5om/B1VI/+xfQ==" }, "node_modules/depd": { "version": "1.1.2", @@ -10802,9 +10783,9 @@ } }, "node_modules/file-type": { - "version": "16.5.3", - "resolved": "https://registry.npmjs.org/file-type/-/file-type-16.5.3.tgz", - "integrity": "sha512-uVsl7iFhHSOY4bEONLlTK47iAHtNsFHWP5YE4xJfZ4rnX7S1Q3wce09XgqSC7E/xh8Ncv/be1lNoyprlUH/x6A==", + "version": "16.5.4", + "resolved": "https://registry.npmjs.org/file-type/-/file-type-16.5.4.tgz", + "integrity": "sha512-/yFHK0aGjFEgDJjEKP0pWCplsPFPhwyfwevf/pVxiN0tmE4L9LmwWxWukdJSHdoCli4VgQLehjJtwQBnqmsKcw==", "dependencies": { "readable-web-to-node-stream": "^3.0.0", "strtok3": "^6.2.4", @@ -12376,7 +12357,7 @@ "node_modules/gauge": { "version": "2.7.4", "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", - "integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=", + "integrity": "sha512-14x4kjc6lkD3ltw589k0NrPD6cCNTD6CWoVUNpB85+DrtONoZn+Rug6xZU5RvSC4+TZPxA5AnBibQYAvZn41Hg==", "dependencies": { "aproba": "^1.0.3", "console-control-strings": "^1.0.0", @@ -12391,7 +12372,7 @@ "node_modules/gauge/node_modules/ansi-regex": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", "engines": { "node": ">=0.10.0" } @@ -12399,7 +12380,7 @@ "node_modules/gauge/node_modules/is-fullwidth-code-point": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", - "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", + "integrity": "sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==", "dependencies": { "number-is-nan": "^1.0.0" }, @@ -12410,7 +12391,7 @@ "node_modules/gauge/node_modules/string-width": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", - "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", + "integrity": "sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==", "dependencies": { "code-point-at": "^1.0.0", "is-fullwidth-code-point": "^1.0.0", @@ -12423,7 +12404,7 @@ "node_modules/gauge/node_modules/strip-ansi": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", "dependencies": { "ansi-regex": "^2.0.0" }, @@ -13090,7 +13071,7 @@ "node_modules/has-unicode": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", - "integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk=" + "integrity": "sha512-8Rf9Y83NBReMnx0gFzA8JImQACstCYWUplepDa9xprwwtmgEZUF0h/i5xSA625zB/I37EtrswSST6OXxwaaIJQ==" }, "node_modules/has-value": { "version": "1.0.0", @@ -18024,9 +18005,9 @@ } }, "node_modules/moment": { - "version": "2.29.2", - "resolved": "https://registry.npmjs.org/moment/-/moment-2.29.2.tgz", - "integrity": "sha512-UgzG4rvxYpN15jgCmVJwac49h9ly9NurikMWGPdVxm8GZD6XjkKPxDTjQQ43gtGgnV3X0cAyWDdP2Wexoquifg==", + "version": "2.29.4", + "resolved": "https://registry.npmjs.org/moment/-/moment-2.29.4.tgz", + "integrity": "sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w==", "engines": { "node": "*" } @@ -18383,7 +18364,7 @@ "node_modules/number-is-nan": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", - "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", + "integrity": "sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==", "engines": { "node": ">=0.10.0" } @@ -19118,13 +19099,13 @@ } }, "node_modules/parse-url": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/parse-url/-/parse-url-6.0.0.tgz", - "integrity": "sha512-cYyojeX7yIIwuJzledIHeLUBVJ6COVLeT4eF+2P6aKVzwvgKQPndCBv3+yQ7pcWjqToYwaligxzSYNNmGoMAvw==", + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/parse-url/-/parse-url-6.0.2.tgz", + "integrity": "sha512-uCSjOvD3T+6B/sPWhR+QowAZcU/o4bjPrVBQBGFxcDF6J6FraCGIaDBsdoQawiaaAVdHvtqBe3w3vKlfBKySOQ==", "dependencies": { "is-ssh": "^1.3.0", "normalize-url": "^6.1.0", - "parse-path": "^4.0.0", + "parse-path": "^4.0.4", "protocols": "^1.4.0" } }, @@ -28785,13 +28766,13 @@ } }, "@sentry/browser": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/browser/-/browser-6.19.1.tgz", - "integrity": "sha512-nU73PecOoMwrsw2WRJW+oQSSfgGkcY3So3JH7qwRHnnk4Gx56TkDfS0AOrNRsSpIQXj1UbSFIWKzz6ajsOg9OA==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/browser/-/browser-7.7.0.tgz", + "integrity": "sha512-oyzpWcsjVZTaf14zAL89Ng1DUHlbjN+V8pl8dR9Y9anphbzL5BK9p0fSK4kPIrO4GukK+XrKnLJDPuE/o7WR3g==", "requires": { - "@sentry/core": "6.19.1", - "@sentry/types": "6.19.1", - "@sentry/utils": "6.19.1", + "@sentry/core": "7.7.0", + "@sentry/types": "7.7.0", + "@sentry/utils": "7.7.0", "tslib": "^1.9.3" }, "dependencies": { @@ -28803,9 +28784,9 @@ } }, "@sentry/cli": { - "version": "1.74.2", - "resolved": "https://registry.npmjs.org/@sentry/cli/-/cli-1.74.2.tgz", - "integrity": "sha512-J1P66/4yNN55PMO70+QQXeS87r4O9nYuJqZ29HJCPA/ih57jbMFRw9Wp9XLuO/QtpF8Yl7FvOwya/nImTOVOkA==", + "version": "1.74.5", + "resolved": "https://registry.npmjs.org/@sentry/cli/-/cli-1.74.5.tgz", + "integrity": "sha512-Ze1ec306ZWHtrxKypOJ8nhtFqkrx2f/6bRH+DcJzEQ3bBePQ0ZnqJTTe4BBHADYBtxFIaUWzCZ6DquLz2Zv/sw==", "requires": { "https-proxy-agent": "^5.0.0", "mkdirp": "^0.5.5", @@ -28817,14 +28798,13 @@ } }, "@sentry/core": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/core/-/core-6.19.1.tgz", - "integrity": "sha512-ZSIFnwYCzABK1jX1iMwUbaAoWbbJear0wM+gSZvJpSUJ1dAXV1OZyL7kXtEJRtATahIlcrMou5ewIoeJizeWAw==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/core/-/core-7.7.0.tgz", + "integrity": "sha512-Z15ACiuiFINFcK4gbMrnejLn4AVjKBPJOWKrrmpIe8mh+Y9diOuswt5mMUABs+jhpZvqht3PBLLGBL0WMsYMYA==", "requires": { - "@sentry/hub": "6.19.1", - "@sentry/minimal": "6.19.1", - "@sentry/types": "6.19.1", - "@sentry/utils": "6.19.1", + "@sentry/hub": "7.7.0", + "@sentry/types": "7.7.0", + "@sentry/utils": "7.7.0", "tslib": "^1.9.3" }, "dependencies": { @@ -28836,39 +28816,24 @@ } }, "@sentry/gatsby": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/gatsby/-/gatsby-6.19.1.tgz", - "integrity": "sha512-Gk+dj13BIyKH1qbwSFC2pjq7/xTzhMyjRn8VRWr4tqCK8TTAkCC6+TSLOLtmR4XaywJSj8g+JVVRRg3E2pAFDA==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/gatsby/-/gatsby-7.7.0.tgz", + "integrity": "sha512-RyCJNgVduK12tywzT4aJoRwsOGCPHvhY4X90wNZAOsFPhrB20UQGw3mULDfOBqvqwLN1QCKIi90zSdoVp5hQEA==", "requires": { - "@sentry/react": "6.19.1", - "@sentry/tracing": "6.19.1", - "@sentry/webpack-plugin": "1.18.8" + "@sentry/react": "7.7.0", + "@sentry/tracing": "7.7.0", + "@sentry/types": "7.7.0", + "@sentry/utils": "7.7.0", + "@sentry/webpack-plugin": "1.18.9" } }, "@sentry/hub": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/hub/-/hub-6.19.1.tgz", - "integrity": "sha512-BgUwdxxXntGohAYrXtYrYBA6QzOeRz3NINuS838n7SRTkGf9gBJ/Rd3dyOWUrzJciKty7rmvYIwTA0oo91AMkw==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/hub/-/hub-7.7.0.tgz", + "integrity": "sha512-6gydK234+a0nKhBRDdIJ7Dp42CaiW2juTiHegUVDq+482balVzbZyEAmESCmuzKJhx5BhlCElVxs/cci1NjMpg==", "requires": { - "@sentry/types": "6.19.1", - "@sentry/utils": "6.19.1", - "tslib": "^1.9.3" - }, - "dependencies": { - "tslib": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", - "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" - } - } - }, - "@sentry/minimal": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/minimal/-/minimal-6.19.1.tgz", - "integrity": "sha512-Xre3J6mjWEcQhDmQ3j4g71J8f0nDgg2p7K41SngibfZVYSOe8jAowxSI9JuWD7juuwT5GVRVCqLs+Y6mWDBaoQ==", - "requires": { - "@sentry/hub": "6.19.1", - "@sentry/types": "6.19.1", + "@sentry/types": "7.7.0", + "@sentry/utils": "7.7.0", "tslib": "^1.9.3" }, "dependencies": { @@ -28880,14 +28845,13 @@ } }, "@sentry/react": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/react/-/react-6.19.1.tgz", - "integrity": "sha512-/fBuRTZzMlXunoFJLmvlFzjEte3MCbU2t3Pihr5idMlWBddfJiaM1j9N6+SugVpYoeLfRwxq/ZWV/4wVOb7T3Q==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/react/-/react-7.7.0.tgz", + "integrity": "sha512-93Khad3YAln6mKU9E15QH09XC1ARIOpNTRpnBl6AGl3bVhSdLExsbKDLa7Rx0mW2j4z/prOC6VEHf5mBvg4mPg==", "requires": { - "@sentry/browser": "6.19.1", - "@sentry/minimal": "6.19.1", - "@sentry/types": "6.19.1", - "@sentry/utils": "6.19.1", + "@sentry/browser": "7.7.0", + "@sentry/types": "7.7.0", + "@sentry/utils": "7.7.0", "hoist-non-react-statics": "^3.3.2", "tslib": "^1.9.3" }, @@ -28900,14 +28864,13 @@ } }, "@sentry/tracing": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/tracing/-/tracing-6.19.1.tgz", - "integrity": "sha512-o34+h0j70dszcIwpCIbmO4UauPurpqLvcPO3JsFhRdxQhwQaQgMwhFklbAt7al9oEDYkjlS0gzhhlOCz4IS9kA==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/tracing/-/tracing-7.7.0.tgz", + "integrity": "sha512-HNmvTwemuc21q/K6HXsSp9njkne6N1JQ71TB+QGqYU5VtxsVgYSUhhYqV6WcHz7LK4Hj6TvNFoeu69/rO0ysgw==", "requires": { - "@sentry/hub": "6.19.1", - "@sentry/minimal": "6.19.1", - "@sentry/types": "6.19.1", - "@sentry/utils": "6.19.1", + "@sentry/hub": "7.7.0", + "@sentry/types": "7.7.0", + "@sentry/utils": "7.7.0", "tslib": "^1.9.3" }, "dependencies": { @@ -28919,16 +28882,16 @@ } }, "@sentry/types": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/types/-/types-6.19.1.tgz", - "integrity": "sha512-ovmNYdqD2MKLmru4calxetX1xjJdYim+HEI/GzwvVUYshsaXRq4EiQ17h3DAy90MV7JH279PmMoPGDTOpufq+Q==" + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/types/-/types-7.7.0.tgz", + "integrity": "sha512-4x8O7uerSGLnYC10krHl9t8h7xXHn5FextqKYbTCXCnx2hC8D+9lz8wcbQAFo0d97wiUYqI8opmEgFVGx7c5hQ==" }, "@sentry/utils": { - "version": "6.19.1", - "resolved": "https://registry.npmjs.org/@sentry/utils/-/utils-6.19.1.tgz", - "integrity": "sha512-mWcQbQ1yO7PooLpJpQK84+wOfxGeb8iUKRb8inO+2Eg6VksDbXRuJ89Yd4APBTRxBj5Wihy48bPuVfKtovtm8g==", + "version": "7.7.0", + "resolved": "https://registry.npmjs.org/@sentry/utils/-/utils-7.7.0.tgz", + "integrity": "sha512-fD+ROSFpeJlK7bEvUT2LOW7QqgjBpXJwVISKZ0P2fuzclRC3KoB2pbZgBM4PXMMTiSzRGWhvfRRjBiBvQJBBJQ==", "requires": { - "@sentry/types": "6.19.1", + "@sentry/types": "7.7.0", "tslib": "^1.9.3" }, "dependencies": { @@ -28940,11 +28903,11 @@ } }, "@sentry/webpack-plugin": { - "version": "1.18.8", - "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-1.18.8.tgz", - "integrity": "sha512-PtKr0NL62b5L3kPFGjwSNbIUwwcW5E5G6bQxAYZGpkgL1MFPnS4ND0SAsySuX0byQJRFFium5A19LpzyvQZSlQ==", + "version": "1.18.9", + "resolved": "https://registry.npmjs.org/@sentry/webpack-plugin/-/webpack-plugin-1.18.9.tgz", + "integrity": "sha512-+TrenJrgFM0QTOwBnw0ZXWMvc0PiOebp6GN5EbGEx3JPCQqXOfXFzCaEjBtASKRgcNCL7zGly41S25YR6Hm+jw==", "requires": { - "@sentry/cli": "^1.73.0" + "@sentry/cli": "^1.74.4" } }, "@sideway/address": { @@ -31851,7 +31814,7 @@ "code-point-at": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", - "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=" + "integrity": "sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==" }, "coffeeify": { "version": "3.0.1", @@ -32073,7 +32036,7 @@ "console-control-strings": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", - "integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4=" + "integrity": "sha512-ty/fTekppD2fIwRvnZAVdeOiGd1c7YXEixbgJTNzqcxJWKQnjJ/V1bNEEE6hygpM3WjwHFUVK6HTjWSzV4a8sQ==" }, "constants-browserify": { "version": "1.0.0", @@ -33029,7 +32992,7 @@ "delegates": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz", - "integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o=" + "integrity": "sha512-bd2L678uiWATM6m5Z1VzNCErI3jiGzt6HGY8OVICs40JQq/HALfbyNJmp0UDakEY4pMMaN0Ly5om/B1VI/+xfQ==" }, "depd": { "version": "1.1.2", @@ -34887,9 +34850,9 @@ } }, "file-type": { - "version": "16.5.3", - "resolved": "https://registry.npmjs.org/file-type/-/file-type-16.5.3.tgz", - "integrity": "sha512-uVsl7iFhHSOY4bEONLlTK47iAHtNsFHWP5YE4xJfZ4rnX7S1Q3wce09XgqSC7E/xh8Ncv/be1lNoyprlUH/x6A==", + "version": "16.5.4", + "resolved": "https://registry.npmjs.org/file-type/-/file-type-16.5.4.tgz", + "integrity": "sha512-/yFHK0aGjFEgDJjEKP0pWCplsPFPhwyfwevf/pVxiN0tmE4L9LmwWxWukdJSHdoCli4VgQLehjJtwQBnqmsKcw==", "requires": { "readable-web-to-node-stream": "^3.0.0", "strtok3": "^6.2.4", @@ -36077,7 +36040,7 @@ "gauge": { "version": "2.7.4", "resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz", - "integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=", + "integrity": "sha512-14x4kjc6lkD3ltw589k0NrPD6cCNTD6CWoVUNpB85+DrtONoZn+Rug6xZU5RvSC4+TZPxA5AnBibQYAvZn41Hg==", "requires": { "aproba": "^1.0.3", "console-control-strings": "^1.0.0", @@ -36092,12 +36055,12 @@ "ansi-regex": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=" + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==" }, "is-fullwidth-code-point": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", - "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", + "integrity": "sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==", "requires": { "number-is-nan": "^1.0.0" } @@ -36105,7 +36068,7 @@ "string-width": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", - "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", + "integrity": "sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==", "requires": { "code-point-at": "^1.0.0", "is-fullwidth-code-point": "^1.0.0", @@ -36115,7 +36078,7 @@ "strip-ansi": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", "requires": { "ansi-regex": "^2.0.0" } @@ -36623,7 +36586,7 @@ "has-unicode": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", - "integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk=" + "integrity": "sha512-8Rf9Y83NBReMnx0gFzA8JImQACstCYWUplepDa9xprwwtmgEZUF0h/i5xSA625zB/I37EtrswSST6OXxwaaIJQ==" }, "has-value": { "version": "1.0.0", @@ -40276,9 +40239,9 @@ } }, "moment": { - "version": "2.29.2", - "resolved": "https://registry.npmjs.org/moment/-/moment-2.29.2.tgz", - "integrity": "sha512-UgzG4rvxYpN15jgCmVJwac49h9ly9NurikMWGPdVxm8GZD6XjkKPxDTjQQ43gtGgnV3X0cAyWDdP2Wexoquifg==" + "version": "2.29.4", + "resolved": "https://registry.npmjs.org/moment/-/moment-2.29.4.tgz", + "integrity": "sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w==" }, "mri": { "version": "1.2.0", @@ -40561,7 +40524,7 @@ "number-is-nan": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", - "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=" + "integrity": "sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==" }, "nwsapi": { "version": "2.2.0", @@ -41111,13 +41074,13 @@ } }, "parse-url": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/parse-url/-/parse-url-6.0.0.tgz", - "integrity": "sha512-cYyojeX7yIIwuJzledIHeLUBVJ6COVLeT4eF+2P6aKVzwvgKQPndCBv3+yQ7pcWjqToYwaligxzSYNNmGoMAvw==", + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/parse-url/-/parse-url-6.0.2.tgz", + "integrity": "sha512-uCSjOvD3T+6B/sPWhR+QowAZcU/o4bjPrVBQBGFxcDF6J6FraCGIaDBsdoQawiaaAVdHvtqBe3w3vKlfBKySOQ==", "requires": { "is-ssh": "^1.3.0", "normalize-url": "^6.1.0", - "parse-path": "^4.0.0", + "parse-path": "^4.0.4", "protocols": "^1.4.0" } }, diff --git a/client/package.json b/client/package.json index 7f079e2e..b4de4d1a 100644 --- a/client/package.json +++ b/client/package.json @@ -28,7 +28,8 @@ "intl:removeNesting": "node src/intl/removeNesting.js", "intl:compile-en": "formatjs compile src/intl/en.json --ast --out-file compiled-lang/en.json", "test:intl-extraction": "node src/intl/testIntlExtraction", - "prepare": "cd .. && husky install client/.husky" + "prepare": "cd .. && husky install client/.husky", + "gc": "node .generate_component $1" }, "devDependencies": { "@formatjs/cli": "^4.8.2", @@ -75,7 +76,7 @@ }, "dependencies": { "-": "^0.0.1", - "@sentry/gatsby": "^6.19.1", + "@sentry/gatsby": "^7.7.0", "@trussworks/react-uswds": "^2.9.0", "@turf/bbox": "^6.5.0", "d3-ease": "^3.0.1", diff --git a/client/src/components/Indicator/Indicator.test.tsx b/client/src/components/Indicator/Indicator.test.tsx index 1561e039..3f06bf77 100644 --- a/client/src/components/Indicator/Indicator.test.tsx +++ b/client/src/components/Indicator/Indicator.test.tsx @@ -6,25 +6,45 @@ import {indicatorInfo} from '../AreaDetail/AreaDetail'; import * as EXPLORE_COPY from '../../data/copy/explore'; -const highSchool:indicatorInfo = { - label: 'some label', - description: 'some description', - value: .97, - isDisadvagtaged: true, - isPercent: true, - threshold: 20, -}; describe('rendering of the Indicator', () => { - const {asFragment} = render( - - - , - ); - it('checks if component renders', () => { + const highSchool:indicatorInfo = { + label: 'some label', + description: 'some description', + value: .97, + isDisadvagtaged: true, + isPercent: true, + threshold: 20, + }; + const {asFragment} = render( + + + , + ); expect(asFragment()).toMatchSnapshot(); }); + + it('checks if the flooring function works', () => { + const expectedFloorPercent = '42%'; + + const highSchool:indicatorInfo = { + label: 'some label', + description: 'some description', + value: .426, + isDisadvagtaged: true, + isPercent: true, + threshold: 20, + }; + const {asFragment} = render( + + + , + ); + expect(asFragment()).toMatchSnapshot(); + const container = document.querySelectorAll('li[data-cy="indicatorBox"] span'); + expect(container[0].textContent).toBe(expectedFloorPercent); + }); }); describe('test rendering of Indicator value icons', () => { diff --git a/client/src/components/Indicator/Indicator.tsx b/client/src/components/Indicator/Indicator.tsx index 5094d82d..f69657e3 100644 --- a/client/src/components/Indicator/Indicator.tsx +++ b/client/src/components/Indicator/Indicator.tsx @@ -150,7 +150,7 @@ export const IndicatorValue = ({isPercent, displayStat}:IIndicatorValue) => { const i18nOrdinalSuffix: string = intl.formatMessage( { - id: 'explore.tool.page.side.panel.indicator.percentile.value.ordinal.suffix', + id: 'explore.map.page.side.panel.indicator.percentile.value.ordinal.suffix', // eslint-disable-next-line max-len description: `Navigate to the explore the tool page. Click on the map. The side panel will show categories. Open a category. This will define the indicator value's ordinal suffix. For example the st in 91st, the rd in 23rd, and the th in 26th, etc.`, defaultMessage: ` @@ -188,7 +188,7 @@ export const IndicatorValue = ({isPercent, displayStat}:IIndicatorValue) => { */ const Indicator = ({indicator}:IIndicator) => { // Convert the decimal value to a stat to display - const displayStat = indicator.value !== null ? Math.round(indicator.value * 100) : null; + const displayStat = indicator.value !== null ? Math.floor(indicator.value * 100) : null; // If the threshold exists, set it, otherwise set it to the default value const threshold = indicator.threshold ? indicator.threshold : constants.DEFAULT_THRESHOLD_PERCENTILE; diff --git a/client/src/components/Indicator/__snapshots__/Indicator.test.tsx.snap b/client/src/components/Indicator/__snapshots__/Indicator.test.tsx.snap index 98271566..b1e1697a 100644 --- a/client/src/components/Indicator/__snapshots__/Indicator.test.tsx.snap +++ b/client/src/components/Indicator/__snapshots__/Indicator.test.tsx.snap @@ -42,6 +42,48 @@ exports[`rendering of the Indicator checks if component renders 1`] = ` `; +exports[`rendering of the Indicator checks if the flooring function works 1`] = ` + +
  • +
    +
    + some label +
    + some description +
    +
    +
    +
    +
    + + 42% + +
    +
    + an icon for the up arrow +
    +
    +
    +
    + above + + 20% + + percent +
    +
    +
    +
    +
  • +
    +`; + exports[`test rendering of Indicator value icons renders the down arrow when the value is above the threshold 1`] = ` { const filter = useMemo(() => ['in', constants.GEOID_PROPERTY, selectedFeatureId], [selectedFeature]); const zoomLatLngHash = mapRef.current?.getMap()._hash._getCurrentHash(); + /** * This function will return the bounding box of the current map. Comment in when needed. * { @@ -169,28 +170,28 @@ const J40Map = ({location}: IJ40Interface) => { switch (buttonID) { case '48': - goToPlace(constants.LOWER_48_BOUNDS); + goToPlace(constants.LOWER_48_BOUNDS, true); break; case 'AK': - goToPlace(constants.ALASKA_BOUNDS); + goToPlace(constants.ALASKA_BOUNDS, true); break; case 'HI': - goToPlace(constants.HAWAII_BOUNDS); + goToPlace(constants.HAWAII_BOUNDS, true); break; case 'PR': - goToPlace(constants.PUERTO_RICO_BOUNDS); + goToPlace(constants.PUERTO_RICO_BOUNDS, true); break; case 'GU': - goToPlace(constants.GUAM_BOUNDS); + goToPlace(constants.GUAM_BOUNDS, true); break; case 'AS': - goToPlace(constants.AMERICAN_SAMOA_BOUNDS); + goToPlace(constants.AMERICAN_SAMOA_BOUNDS, true); break; case 'MP': - goToPlace(constants.MARIANA_ISLAND_BOUNDS); + goToPlace(constants.MARIANA_ISLAND_BOUNDS, true); break; case 'VI': - goToPlace(constants.US_VIRGIN_ISLANDS_BOUNDS); + goToPlace(constants.US_VIRGIN_ISLANDS_BOUNDS, true); break; default: @@ -200,10 +201,32 @@ const J40Map = ({location}: IJ40Interface) => { // This else clause will fire when the ID is null or empty. This is the case where the map is clicked // @ts-ignore const feature = event.features && event.features[0]; - console.log(feature); + if (feature) { + // Get the current selected feature's bounding box: const [minLng, minLat, maxLng, maxLat] = bbox(feature); + + // Set the selectedFeature ID + if (feature.id !== selectedFeatureId) { + setSelectedFeature(feature); + } else { + setSelectedFeature(undefined); + } + + // Go to the newly selected feature + goToPlace([ + [minLng, minLat], + [maxLng, maxLat], + ]); + + + /** + * The following logic is used for the popup for the fullscreen feature + */ + // Create a new viewport using the current viewport dimnesions: const newViewPort = new WebMercatorViewport({height: viewport.height!, width: viewport.width!}); + + // Fit the viewport to the new bounds and return a long, lat and zoom: const {longitude, latitude, zoom} = newViewPort.fitBounds( [ [minLng, minLat], @@ -213,22 +236,21 @@ const J40Map = ({location}: IJ40Interface) => { padding: 40, }, ); - if (feature.id !== selectedFeatureId) { - setSelectedFeature(feature); - } else { - setSelectedFeature(undefined); - } + + // Save the popupInfo const popupInfo = { longitude: longitude, latitude: latitude, zoom: zoom, properties: feature.properties, }; - goToPlace([ - [minLng, minLat], - [maxLng, maxLat], - ]); + + // Update the DetailedView state variable with the new popupInfo object: setDetailViewData(popupInfo); + + /** + * End Fullscreen feature specific logic + */ } } }; @@ -242,17 +264,44 @@ const J40Map = ({location}: IJ40Interface) => { }; - const goToPlace = (bounds: LngLatBoundsLike ) => { - const {longitude, latitude, zoom} = new WebMercatorViewport({height: viewport.height!, width: viewport.width!}) - .fitBounds(bounds as [[number, number], [number, number]], { - padding: 20, - offset: [0, -100], - }); + /** + * This function will move the map (with easing) to the given lat/long bounds. + * + * When a user clicks on a tracts vs a territory button, the zoom level returned by the fitBounds + * function differ. Given that we want to handle the zoom differently depending on these two cases, we + * introduce a boolean, isTerritory that will allow the zoom level to be set depending on what the user + * is interacting with, namely a tract vs a territory button. + * + * @param {LngLatBoundsLike} bounds + * @param {boolean} isTerritory + */ + const goToPlace = (bounds: LngLatBoundsLike, isTerritory = false ) => { + const newViewPort = new WebMercatorViewport({height: viewport.height!, width: viewport.width!}); + const {longitude, latitude, zoom} = newViewPort.fitBounds( + bounds as [[number, number], [number, number]], { + // padding: 200, // removing padding and offset in favor of a zoom offset below + // offset: [0, -100], + }); + + /** + * When some tracts are selected, they end up too far zoomed in, causing some census tracts to + * only show a portion of the tract in the viewport. We reduce the zoom level by 1 to allow + * more space around the selected tract. + * + * Given that the high zoom tiles only go to zoom level 5, if the corrected zoom level (zoom - 1) is + * less than MIN_ZOOM_FEATURE_BORDER, then we floor the zoom to MIN_ZOOM_FEATURE_BORDER + .1 (which + * is 5.1 as of this comment) + */ + // eslint-disable-next-line max-len + const featureSelectionZoomLevel = (zoom - 1) < constants.GLOBAL_MIN_ZOOM_FEATURE_BORDER + .1 ? + constants.GLOBAL_MIN_ZOOM_FEATURE_BORDER : + zoom - 1; + setViewport({ ...viewport, longitude, latitude, - zoom, + zoom: isTerritory ? zoom : featureSelectionZoomLevel, transitionDuration: 1000, transitionInterpolator: new FlyToInterpolator(), transitionEasing: d3.easeCubic, @@ -434,7 +483,26 @@ const J40Map = ({location}: IJ40Interface) => { /> - {/* Enable fullscreen behind a feature flag */} + {/* This will add the navigation controls of the zoom in and zoom out buttons */} + { windowWidth > constants.USWDS_BREAKPOINTS.MOBILE_LG && } + + {/* This will show shortcut buttons to pan/zoom to US territories */} + + + {/* This places Geolocation behind a feature flag */} + {'gl' in flags ? : ''} + {geolocationInProgress ?
    Geolocation in progress...
    : ''} + + {/* Enable fullscreen pop-up behind a feature flag */} {('fs' in flags && detailViewData && !transitionInProgress) && ( { )} - - {/* This will add the navigation controls of the zoom in and zoom out buttons */} - { windowWidth > constants.USWDS_BREAKPOINTS.MOBILE_LG && } - - {/* This places Geolocation behind a feature flag */} - {'gl' in flags ? : ''} - {geolocationInProgress ?
    Geolocation in progress...
    : ''} - - {/* This will show shortcut buttons to pan/zoom to US territories */} - - {'fs' in flags ? :'' } diff --git a/client/src/data/blankCEJST/index.html b/client/src/data/blankCEJST/index.html index 7f5efce2..a981107c 100644 --- a/client/src/data/blankCEJST/index.html +++ b/client/src/data/blankCEJST/index.html @@ -14,6 +14,6 @@ - + \ No newline at end of file diff --git a/client/src/data/constants.tsx b/client/src/data/constants.tsx index 91bf7d4d..09f38ba4 100644 --- a/client/src/data/constants.tsx +++ b/client/src/data/constants.tsx @@ -204,11 +204,14 @@ export const SCORE_PROPERTY_HIGH = 'SM_PFS'; // Zoom export const GLOBAL_MIN_ZOOM = 3; export const GLOBAL_MAX_ZOOM = 22; + export const GLOBAL_MIN_ZOOM_LOW = 3; -export const GLOBAL_MAX_ZOOM_LOW = 7; -export const GLOBAL_MIN_ZOOM_HIGH = 7; +export const GLOBAL_MAX_ZOOM_LOW = 5; + +export const GLOBAL_MIN_ZOOM_HIGH = 5; export const GLOBAL_MAX_ZOOM_HIGH = 11; -export const GLOBAL_MIN_ZOOM_FEATURE_BORDER = 8; + +export const GLOBAL_MIN_ZOOM_FEATURE_BORDER = 5; export const GLOBAL_MAX_ZOOM_FEATURE_BORDER = 22; // Opacity diff --git a/client/src/data/copy/explore.tsx b/client/src/data/copy/explore.tsx index f6e58b54..00c6f52c 100644 --- a/client/src/data/copy/explore.tsx +++ b/client/src/data/copy/explore.tsx @@ -385,7 +385,7 @@ export const SIDE_PANEL_CATEGORY = defineMessages({ `, }, CLEAN_WATER: { - id: 'explore.tool.page.side.panel.indicator.title.clean.water', + id: 'explore.map.page.side.panel.indicator.title.clean.water', defaultMessage: 'Clean water and wastewater infrastructure', description: `Navigate to the explore the tool page. When the map is in view, click on the map. The side panel will show Clean water and waste title `, diff --git a/client/src/intl/en.json b/client/src/intl/en.json index 45e1f5e7..ebe6156f 100644 --- a/client/src/intl/en.json +++ b/client/src/intl/en.json @@ -639,6 +639,10 @@ "defaultMessage": "Median home value", "description": "Navigate to the explore the map page. When the map is in view, click on the map. The side panel will show Housing cost burden" }, + "explore.map.page.side.panel.indicator.percentile.value.ordinal.suffix": { + "defaultMessage": "{indicatorValue, selectordinal, one {#st} two {#nd} =3 {#rd} other {#th} }", + "description": "Navigate to the explore the tool page. Click on the map. The side panel will show categories. Open a category. This will define the indicator value's ordinal suffix. For example the st in 91st, the rd in 23rd, and the th in 26th, etc." + }, "explore.map.page.side.panel.indicator.pm25": { "defaultMessage": "PM2.5 in the air", "description": "Navigate to the explore the map page. When the map is in view, click on the map. The side panel will show PM2.5 in the air" @@ -667,6 +671,10 @@ "defaultMessage": "Clean transit", "description": "Navigate to the explore the map page. When the map is in view, click on the map. The side panel will show Clean transportation title\n" }, + "explore.map.page.side.panel.indicator.title.clean.water": { + "defaultMessage": "Clean water and wastewater infrastructure", + "description": "Navigate to the explore the tool page. When the map is in view, click on the map. The side panel will show Clean water and waste title\n" + }, "explore.map.page.side.panel.indicator.title.climate": { "defaultMessage": "Climate change", "description": "Navigate to the explore the map page. When the map is in view, click on the map. The side panel will show Climate change title\n" @@ -859,14 +867,6 @@ "defaultMessage": "The map covers all U.S. census tracts, including those located within Tribal Nations, to the extent that data is available (see our Methodology & data page for more information). CEQ is engaging in consultation and coordination with Tribal Nations on the beta version of the map to provide Tribal Nations with meaningful opportunities for input, consistent with CEQ鈥檚 Action Plan for Consultation and Coordination with Tribal Nations, President Biden鈥檚 Memorandum on Tribal Consultation and Strengthening Nation-to-Nation Consultation, and Executive Order 13175 on Consultation and Coordination With Indian Tribal Governments.", "description": "Navigate to the explore the map page. Under the map, you will see tribal nations paragraph 1" }, - "explore.tool.page.side.panel.indicator.percentile.value.ordinal.suffix": { - "defaultMessage": "{indicatorValue, selectordinal, one {#st} two {#nd} =3 {#rd} other {#th} }", - "description": "Navigate to the explore the tool page. Click on the map. The side panel will show categories. Open a category. This will define the indicator value's ordinal suffix. For example the st in 91st, the rd in 23rd, and the th in 26th, etc." - }, - "explore.tool.page.side.panel.indicator.title.clean.water": { - "defaultMessage": "Clean water and wastewater infrastructure", - "description": "Navigate to the explore the tool page. When the map is in view, click on the map. The side panel will show Clean water and waste title\n" - }, "fab.survey.text": { "defaultMessage": "Help improve the site & data", "description": "Navigate to the public engagement page, this will be the text for floating action button" diff --git a/client/src/intl/es.json b/client/src/intl/es.json index 6d825486..2d18c567 100644 --- a/client/src/intl/es.json +++ b/client/src/intl/es.json @@ -161,7 +161,7 @@ "explore.map.page.side.panel.indicator.low.income": "Bajos ingresos", "explore.map.page.side.panel.indicator.low.med.income": "Mediana de bajos ingresos", "explore.map.page.side.panel.indicator.med.home.val": "Mediana del valor de la vivienda", - "explore.map.page.side.panel.indicator.percentile.value.ordinal.suffix": "{indicatorValue, selectordinal, one {#st} two {#nd} =3 {#rd} other {#th} }", + "explore.map.page.side.panel.indicator.percentile.value.ordinal.suffix": "{indicatorValue, selectordinal, one {#.a} two {#.a} =3 {#.a} other {#.a} }", "explore.map.page.side.panel.indicator.pm25": "PM2.5 en el aire", "explore.map.page.side.panel.indicator.poverty": "Pobreza", "explore.map.page.side.panel.indicator.prox.haz": "Proximidad a instalaciones para manejo de residuos peligrosos", @@ -219,7 +219,6 @@ "explore.map.page.under.map.note.on.territories.para.4": "Actualmente, se lleva a cabo la identificaci贸n de las comunidades desfavorecidas y la actualizaci贸n correspondiente de la herramienta para Guam y las Islas V铆rgenes de los Estados Unidos.", "explore.map.page.under.map.note.on.tribal.nations.intro": "Observaciones sobre las naciones tribales", "explore.map.page.under.map.note.on.tribal.nations.para.1": "La herramienta incluye todos los grupos de bloques del censo de los EE.聽UU., incluidos los que est谩n ubicados en naciones tribales, en la medida en que se dispone de datos (consulte m谩s informaci贸n en la p谩gina Metodolog铆a y datos). El Consejo sobre la Calidad del Medio Ambiente (CEQ, por sus siglas en ingl茅s) participa en la consulta y la coordinaci贸n con las naciones tribales sobre la versi贸n beta de la herramienta para dar a esas naciones oportunidades valiosas para hacer aportes, conforme al Plan de acci贸n para la consulta y la coordinaci贸n con las naciones tribales del CEQ, el Memorando del presidente Biden sobre Consulta de las naciones tribales y fortalecimiento de las consultas entre naciones y la Orden ejecutiva聽13175 sobre Consulta y coordinaci贸n con los gobiernos de las tribus indias.", - "explore.tool.page.side.panel.indicator.percentile.value.ordinal.suffix": "{indicatorValue, selectordinal, one {#.a} two {#.a} =3 {#.a} other {#.a} }", "fab.survey.text": "Ayude a mejorar el sitio web y los datos", "faqs.page.coming.soon.text": "隆Pr贸ximamente!", "faqs.page.title.text": "Preguntas frecuentes", diff --git a/data/data-pipeline/.vscode/launch.json b/data/data-pipeline/.vscode/launch.json index 6dcae4dd..e5839379 100644 --- a/data/data-pipeline/.vscode/launch.json +++ b/data/data-pipeline/.vscode/launch.json @@ -68,7 +68,7 @@ ] }, { - "name": "Generate Map Tiles", + "name": "Generate Score Tiles", "type": "python", "request": "launch", "module": "data_pipeline.application", @@ -76,6 +76,16 @@ "generate-map-tiles" ] }, + { + "name": "Generate Tribal Tiles", + "type": "python", + "request": "launch", + "module": "data_pipeline.application", + "args": [ + "generate-map-tiles", + "-t" + ] + }, { "name": "ETL Run", "type": "python", @@ -85,6 +95,37 @@ "etl-run" ] }, + { + "name": "ETL Run NRI", + "type": "python", + "request": "launch", + "module": "data_pipeline.application", + "args": [ + "etl-run", + "--dataset", + "national_risk_index" + ] + }, + { + "name": "ETL Run Tribal", + "type": "python", + "request": "launch", + "module": "data_pipeline.application", + "args": [ + "etl-run", + "--dataset", + "tribal" + ] + }, + { + "name": "Data Full Run", + "type": "python", + "request": "launch", + "module": "data_pipeline.application", + "args": [ + "data-full-run", + ] + }, { "name": "poetry install", "type": "python", diff --git a/data/data-pipeline/data_pipeline/application.py b/data/data-pipeline/data_pipeline/application.py index cd4e5e96..630d7ea8 100644 --- a/data/data-pipeline/data_pipeline/application.py +++ b/data/data-pipeline/data_pipeline/application.py @@ -13,6 +13,9 @@ from data_pipeline.etl.sources.census.etl_utils import ( reset_data_directories as census_reset, zip_census_data, ) +from data_pipeline.etl.sources.tribal.etl_utils import ( + reset_data_directories as tribal_reset, +) from data_pipeline.tile.generate import generate_tiles from data_pipeline.utils import ( data_folder_cleanup, @@ -57,6 +60,7 @@ def data_cleanup(): census_reset(data_path) data_folder_cleanup() + tribal_reset(data_path) score_folder_cleanup() temp_folder_cleanup() @@ -168,13 +172,21 @@ def geo_score(data_source: str): @cli.command( - help="Generate map tiles", + help="Generate map tiles. Pass -t to generate tribal layer as well.", ) -def generate_map_tiles(): +@click.option( + "-t", + "--generate-tribal-layer", + default=False, + required=False, + is_flag=True, + type=bool, +) +def generate_map_tiles(generate_tribal_layer): """CLI command to generate the map tiles""" data_path = settings.APP_ROOT / "data" - generate_tiles(data_path) + generate_tiles(data_path, generate_tribal_layer) sys.exit() @@ -271,7 +283,7 @@ def data_full_run(check: bool, data_source: str): score_geo(data_source) logger.info("*** Generating Map Tiles") - generate_tiles(data_path) + generate_tiles(data_path, True) file = "first_run.txt" cmd = f"touch {data_path}/{file}" diff --git a/data/data-pipeline/data_pipeline/data/tribal/__init__.py b/data/data-pipeline/data_pipeline/data/tribal/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/data/data-pipeline/data_pipeline/data/tribal/csv/__init__.py b/data/data-pipeline/data_pipeline/data/tribal/csv/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/data/data-pipeline/data_pipeline/data/tribal/geojson/__init__.py b/data/data-pipeline/data_pipeline/data/tribal/geojson/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/data/data-pipeline/data_pipeline/data/tribal/tiles/__init__.py b/data/data-pipeline/data_pipeline/data/tribal/tiles/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/data/data-pipeline/data_pipeline/etl/constants.py b/data/data-pipeline/data_pipeline/etl/constants.py index 1dc6697c..2136c675 100644 --- a/data/data-pipeline/data_pipeline/etl/constants.py +++ b/data/data-pipeline/data_pipeline/etl/constants.py @@ -125,8 +125,15 @@ DATASET_LIST = [ "class_name": "MarylandEJScreenETL", }, ] + CENSUS_INFO = { "name": "census", "module_dir": "census", "class_name": "CensusETL", } + +TRIBAL_INFO = { + "name": "tribal", + "module_dir": "tribal", + "class_name": "TribalETL", +} diff --git a/data/data-pipeline/data_pipeline/etl/runner.py b/data/data-pipeline/data_pipeline/etl/runner.py index 40710142..5e9230bb 100644 --- a/data/data-pipeline/data_pipeline/etl/runner.py +++ b/data/data-pipeline/data_pipeline/etl/runner.py @@ -22,7 +22,9 @@ def _get_datasets_to_run(dataset_to_run: str) -> typing.List[dict]: None """ dataset_list = constants.DATASET_LIST - etls_to_search = dataset_list + [constants.CENSUS_INFO] + etls_to_search = ( + dataset_list + [constants.CENSUS_INFO] + [constants.TRIBAL_INFO] + ) if dataset_to_run: dataset_element = next( diff --git a/data/data-pipeline/data_pipeline/etl/sources/census/etl.py b/data/data-pipeline/data_pipeline/etl/sources/census/etl.py index 5f1398b6..8b340d0b 100644 --- a/data/data-pipeline/data_pipeline/etl/sources/census/etl.py +++ b/data/data-pipeline/data_pipeline/etl/sources/census/etl.py @@ -3,8 +3,8 @@ import json import subprocess from enum import Enum from pathlib import Path - import geopandas as gpd + from data_pipeline.etl.base import ExtractTransformLoad from data_pipeline.utils import get_module_logger, unzip_file_from_url diff --git a/data/data-pipeline/data_pipeline/etl/sources/maryland_ejscreen/README.md b/data/data-pipeline/data_pipeline/etl/sources/maryland_ejscreen/README.md index b64fd996..e76fc47f 100644 --- a/data/data-pipeline/data_pipeline/etl/sources/maryland_ejscreen/README.md +++ b/data/data-pipeline/data_pipeline/etl/sources/maryland_ejscreen/README.md @@ -1,10 +1,10 @@ # Maryland EJSCREEN -The Maryland EJSCREEN application and tool can be found [here](https://p1.cgis.umd.edu/mdejscreen/). +The Maryland EJSCREEN application and tool can be found [here](https://www.ceejh.center/md-ejscreen-1). ### Methodology Summary -According to the [documentation](https://p1.cgis.umd.edu/mdejscreen/help.html): +According to the documentation: There exist two data categories: Population Burden and Population Characteristics. diff --git a/data/data-pipeline/data_pipeline/etl/sources/tribal/__init__.py b/data/data-pipeline/data_pipeline/etl/sources/tribal/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/data/data-pipeline/data_pipeline/etl/sources/tribal/etl.py b/data/data-pipeline/data_pipeline/etl/sources/tribal/etl.py new file mode 100644 index 00000000..7b184316 --- /dev/null +++ b/data/data-pipeline/data_pipeline/etl/sources/tribal/etl.py @@ -0,0 +1,195 @@ +from pathlib import Path +import geopandas as gpd +import pandas as pd + +from data_pipeline.etl.base import ExtractTransformLoad +from data_pipeline.utils import get_module_logger, unzip_file_from_url + +logger = get_module_logger(__name__) + + +class TribalETL(ExtractTransformLoad): + def __init__(self): + self.GEOJSON_BASE_PATH = self.DATA_PATH / "tribal" / "geojson" + self.CSV_BASE_PATH = self.DATA_PATH / "tribal" / "csv" + self.NATIONAL_TRIBAL_GEOJSON_PATH = self.GEOJSON_BASE_PATH / "usa.json" + self.USA_TRIBAL_DF_LIST = [] + + def extract(self) -> None: + """Extract the tribal geojson zip files from Justice40 S3 data folder + + Returns: + None + """ + logger.info("Downloading Tribal Data") + + bia_geojson_url = "https://justice40-data.s3.amazonaws.com/data-sources/BIA_National_LAR_json.zip" + alaska_geojson_url = "https://justice40-data.s3.amazonaws.com/data-sources/Alaska_Native_Villages_json.zip" + + unzip_file_from_url( + bia_geojson_url, + self.TMP_PATH, + self.DATA_PATH / "tribal" / "geojson" / "bia_national_lar", + ) + + unzip_file_from_url( + alaska_geojson_url, + self.TMP_PATH, + self.DATA_PATH / "tribal" / "geojson" / "alaska_native_villages", + ) + pass + + def _transform_bia_national_lar(self, tribal_geojson_path: Path) -> None: + """Transform the Tribal BIA National Lar Geodataframe and appends it to the + national Tribal Dataframe List + + Args: + tribal_geojson_path (Path): the Path to the Tribal Geojson + + Returns: + None + """ + + bia_national_lar_df = gpd.read_file(tribal_geojson_path) + + bia_national_lar_df.drop( + ["OBJECTID", "GISAcres", "Shape_Length", "Shape_Area"], + axis=1, + inplace=True, + ) + + bia_national_lar_df.rename( + columns={"TSAID": "tribalId", "LARName": "landAreaName"}, + inplace=True, + ) + + self.USA_TRIBAL_DF_LIST.append(bia_national_lar_df) + + def _transform_bia_aian_supplemental( + self, tribal_geojson_path: Path + ) -> None: + """Transform the Tribal BIA Supplemental Geodataframe and appends it to the + national Tribal Dataframe List + + Args: + tribal_geojson_path (Path): the Path to the Tribal Geojson + + Returns: + None + """ + + bia_aian_supplemental_df = gpd.read_file(tribal_geojson_path) + + bia_aian_supplemental_df.drop( + ["OBJECTID", "GISAcres", "Source", "Shape_Length", "Shape_Area"], + axis=1, + inplace=True, + ) + + bia_aian_supplemental_df.rename( + columns={"Land_Area_": "landAreaName"}, + inplace=True, + ) + + self.USA_TRIBAL_DF_LIST.append(bia_aian_supplemental_df) + + def _transform_bia_tsa(self, tribal_geojson_path: Path) -> None: + """Transform the Tribal BIA TSA Geodataframe and appends it to the + national Tribal Dataframe List + + Args: + tribal_geojson_path (Path): the Path to the Tribal Geojson + + Returns: + None + """ + + bia_tsa_df = gpd.read_file(tribal_geojson_path) + + bia_tsa_df.drop( + ["OBJECTID", "GISAcres", "Shape_Length", "Shape_Area"], + axis=1, + inplace=True, + ) + + bia_tsa_df.rename( + columns={"TSAID": "tribalId", "LARName": "landAreaName"}, + inplace=True, + ) + + self.USA_TRIBAL_DF_LIST.append(bia_tsa_df) + + def _transform_alaska_native_villages( + self, tribal_geojson_path: Path + ) -> None: + """Transform the Alaska Native Villages Geodataframe and appends it to the + national Tribal Dataframe List + + Args: + tribal_geojson_path (Path): the Path to the Tribal Geojson + + Returns: + None + """ + + alaska_native_villages_df = gpd.read_file(tribal_geojson_path) + + alaska_native_villages_df.rename( + columns={ + "GlobalID": "tribalId", + "TRIBALOFFICENAME": "landAreaName", + }, + inplace=True, + ) + + self.USA_TRIBAL_DF_LIST.append(alaska_native_villages_df) + + def transform(self) -> None: + """Transform the tribal geojson files to generate national CSVs and GeoJSONs + + Returns: + None + """ + logger.info("Transforming Tribal Data") + + # load the geojsons + bia_national_lar_geojson = ( + self.GEOJSON_BASE_PATH / "bia_national_lar" / "BIA_TSA.json" + ) + bia_aian_supplemental_geojson = ( + self.GEOJSON_BASE_PATH + / "bia_national_lar" + / "BIA_AIAN_Supplemental.json" + ) + bia_tsa_geojson_geojson = ( + self.GEOJSON_BASE_PATH / "bia_national_lar" / "BIA_TSA.json" + ) + alaska_native_villages_geojson = ( + self.GEOJSON_BASE_PATH + / "alaska_native_villages" + / "AlaskaNativeVillages.gdb.geojson" + ) + + self._transform_bia_national_lar(bia_national_lar_geojson) + self._transform_bia_aian_supplemental(bia_aian_supplemental_geojson) + self._transform_bia_tsa(bia_tsa_geojson_geojson) + self._transform_alaska_native_villages(alaska_native_villages_geojson) + + def load(self) -> None: + """Create tribal national CSV and GeoJSON + + Returns: + None + """ + logger.info("Saving Tribal GeoJson and CSV") + + usa_tribal_df = gpd.GeoDataFrame( + pd.concat(self.USA_TRIBAL_DF_LIST, ignore_index=True) + ) + usa_tribal_df = usa_tribal_df.to_crs( + "+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs" + ) + logger.info("Writing national geojson file") + usa_tribal_df.to_file( + self.NATIONAL_TRIBAL_GEOJSON_PATH, driver="GeoJSON" + ) diff --git a/data/data-pipeline/data_pipeline/etl/sources/tribal/etl_utils.py b/data/data-pipeline/data_pipeline/etl/sources/tribal/etl_utils.py new file mode 100644 index 00000000..4e122018 --- /dev/null +++ b/data/data-pipeline/data_pipeline/etl/sources/tribal/etl_utils.py @@ -0,0 +1,28 @@ +from pathlib import Path + +from data_pipeline.utils import ( + get_module_logger, + remove_all_from_dir, + remove_files_from_dir, +) + + +logger = get_module_logger(__name__) + + +def reset_data_directories( + data_path: Path, +) -> None: + """Empties all tribal files""" + tribal_data_path = data_path / "tribal" + + # csv + csv_path = tribal_data_path / "csv" + remove_files_from_dir( + csv_path, + ".csv", + ) + + # geojson + geojson_path = tribal_data_path / "geojson" + remove_all_from_dir(geojson_path) diff --git a/data/data-pipeline/data_pipeline/ipython/TractArea.ipynb b/data/data-pipeline/data_pipeline/ipython/TractArea.ipynb new file mode 100644 index 00000000..d4b678c1 --- /dev/null +++ b/data/data-pipeline/data_pipeline/ipython/TractArea.ipynb @@ -0,0 +1,418 @@ +{ + "cells": [ + { + "cell_type": "code", + "execution_count": 54, + "id": "df048f08", + "metadata": {}, + "outputs": [], + "source": [ + "import geopandas as gpd\n", + "import pathlib" + ] + }, + { + "cell_type": "code", + "execution_count": 55, + "id": "62366f7d", + "metadata": {}, + "outputs": [], + "source": [ + "lowJson = pathlib.Path() / 'usa-low.json'\n", + "assert lowJson.exists()\n", + "highJson = pathlib.Path() / 'usa-high.json'\n", + "assert highJson.exists()" + ] + }, + { + "cell_type": "code", + "execution_count": 50, + "id": "4077ed78", + "metadata": {}, + "outputs": [], + "source": [ + "gdf = gpd.read_file(highJson)" + ] + }, + { + "cell_type": "code", + "execution_count": 56, + "id": "d4abfc64", + "metadata": {}, + "outputs": [], + "source": [ + "gdf['area'] = gdf.apply(lambda row : gpd.GeoSeries(row['geometry']).area, axis = 1)" + ] + }, + { + "cell_type": "markdown", + "id": "5077d9ef", + "metadata": {}, + "source": [ + "Add `zlfc` = *zoom level full containment*, This field will indicate the maximum zoom level the user can go up to while still keeping the entire tract in view. Below, we sample a few tracts to get an idea of the relationship between zoom level and area" + ] + }, + { + "cell_type": "code", + "execution_count": 89, + "id": "a1234574", + "metadata": {}, + "outputs": [ + { + "data": { + "text/html": [ + "
    \n", + "\n", + "\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + "
    GEOID10SFCFareazlfc
    984602185000200AlaskaNorth Slope Borough53.3237024.45
    993702290000100AlaskaYukon-Koyukuk Census Area21.6531545.50
    985702188000100AlaskaNorthwest Arctic Borough21.1881595.50
    993502290000200AlaskaYukon-Koyukuk Census Area20.7447705.38
    993402290000300AlaskaYukon-Koyukuk Census Area17.1408260.00
    993602290000400AlaskaYukon-Koyukuk Census Area14.6874485.77
    989302180000100AlaskaNome Census Area13.3778170.00
    984702164000100AlaskaLake and Peninsula Borough13.0616445.33
    991802261000100AlaskaValdez-Cordova Census Area11.1188350.00
    994502050000100AlaskaBethel Census Area10.9518880.00
    984102270000100AlaskaWade Hampton Census Area8.7718060.00
    983902240000100AlaskaSoutheast Fairbanks Census Area8.6136900.00
    984302070000100AlaskaDillingham Census Area8.5753070.00
    994702050000300AlaskaBethel Census Area8.4080400.00
    989902170000101AlaskaMatanuska-Susitna Borough6.4804440.00
    994402068000100AlaskaDenali Borough5.9972360.00
    983602013000100AlaskaAleutians East Borough5.4877260.00
    992102122000100AlaskaKenai Peninsula Borough4.8318316.10
    985102150000100AlaskaKodiak Island Borough4.6640090.00
    985002105000300AlaskaHoonah-Angoon Census Area4.3057160.00
    983802016000100AlaskaAleutians West Census Area4.0535200.00
    991702282000100AlaskaYakutat City and Borough3.9261820.00
    992002261000300AlaskaValdez-Cordova Census Area3.2854820.00
    984002240000400AlaskaSoutheast Fairbanks Census Area3.2339610.00
    991902261000200AlaskaValdez-Cordova Census Area3.1563170.00
    1035441045970900OregonMalheur County2.7317190.00
    988802198000100AlaskaPrince of Wales-Hyder Census Area2.6062860.00
    1021241025960200OregonHarney County2.5689437.08
    984402185000300AlaskaNorth Slope Borough2.4631650.00
    985802130000100AlaskaKetchikan Gateway Borough2.4400510.00
    \n", + "
    " + ], + "text/plain": [ + " GEOID10 SF CF area zlfc\n", + "9846 02185000200 Alaska North Slope Borough 53.323702 4.45\n", + "9937 02290000100 Alaska Yukon-Koyukuk Census Area 21.653154 5.50\n", + "9857 02188000100 Alaska Northwest Arctic Borough 21.188159 5.50\n", + "9935 02290000200 Alaska Yukon-Koyukuk Census Area 20.744770 5.38\n", + "9934 02290000300 Alaska Yukon-Koyukuk Census Area 17.140826 0.00\n", + "9936 02290000400 Alaska Yukon-Koyukuk Census Area 14.687448 5.77\n", + "9893 02180000100 Alaska Nome Census Area 13.377817 0.00\n", + "9847 02164000100 Alaska Lake and Peninsula Borough 13.061644 5.33\n", + "9918 02261000100 Alaska Valdez-Cordova Census Area 11.118835 0.00\n", + "9945 02050000100 Alaska Bethel Census Area 10.951888 0.00\n", + "9841 02270000100 Alaska Wade Hampton Census Area 8.771806 0.00\n", + "9839 02240000100 Alaska Southeast Fairbanks Census Area 8.613690 0.00\n", + "9843 02070000100 Alaska Dillingham Census Area 8.575307 0.00\n", + "9947 02050000300 Alaska Bethel Census Area 8.408040 0.00\n", + "9899 02170000101 Alaska Matanuska-Susitna Borough 6.480444 0.00\n", + "9944 02068000100 Alaska Denali Borough 5.997236 0.00\n", + "9836 02013000100 Alaska Aleutians East Borough 5.487726 0.00\n", + "9921 02122000100 Alaska Kenai Peninsula Borough 4.831831 6.10\n", + "9851 02150000100 Alaska Kodiak Island Borough 4.664009 0.00\n", + "9850 02105000300 Alaska Hoonah-Angoon Census Area 4.305716 0.00\n", + "9838 02016000100 Alaska Aleutians West Census Area 4.053520 0.00\n", + "9917 02282000100 Alaska Yakutat City and Borough 3.926182 0.00\n", + "9920 02261000300 Alaska Valdez-Cordova Census Area 3.285482 0.00\n", + "9840 02240000400 Alaska Southeast Fairbanks Census Area 3.233961 0.00\n", + "9919 02261000200 Alaska Valdez-Cordova Census Area 3.156317 0.00\n", + "10354 41045970900 Oregon Malheur County 2.731719 0.00\n", + "9888 02198000100 Alaska Prince of Wales-Hyder Census Area 2.606286 0.00\n", + "10212 41025960200 Oregon Harney County 2.568943 7.08\n", + "9844 02185000300 Alaska North Slope Borough 2.463165 0.00\n", + "9858 02130000100 Alaska Ketchikan Gateway Borough 2.440051 0.00" + ] + }, + "execution_count": 89, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "gdf['zlfc'] = 0\n", + "gdf.at[9846, 'zlfc'] = 4.45\n", + "gdf.at[10212, 'zlfc'] = 7.08\n", + "gdf.at[9937, 'zlfc'] = 5.5\n", + "gdf.at[9857, 'zlfc'] = 5.5\n", + "gdf.at[9935, 'zlfc'] = 5.38\n", + "gdf.at[9936, 'zlfc'] = 5.77\n", + "gdf.at[9921, 'zlfc'] = 6.1\n", + "gdf.at[9847, 'zlfc'] = 5.33\n", + "gdf_short = gdf[[\"GEOID10\", \"SF\", \"CF\", \"area\", \"zlfc\"]]\n", + "gdf_short_sorted = gdf_short.sort_values(by='area', ascending=False);\n", + "gdf_short_sorted.head(30)" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "id": "5930de0e", + "metadata": {}, + "outputs": [], + "source": [] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python 3 (ipykernel)", + "language": "python", + "name": "python3" + }, + "language_info": { + "codemirror_mode": { + "name": "ipython", + "version": 3 + }, + "file_extension": ".py", + "mimetype": "text/x-python", + "name": "python", + "nbconvert_exporter": "python", + "pygments_lexer": "ipython3", + "version": "3.9.13" + } + }, + "nbformat": 4, + "nbformat_minor": 5 +} diff --git a/data/data-pipeline/data_pipeline/tile/generate.py b/data/data-pipeline/data_pipeline/tile/generate.py index 328555b0..df37c175 100644 --- a/data/data-pipeline/data_pipeline/tile/generate.py +++ b/data/data-pipeline/data_pipeline/tile/generate.py @@ -7,55 +7,96 @@ from data_pipeline.utils import get_module_logger, remove_all_from_dir logger = get_module_logger(__name__) -def generate_tiles(data_path: Path) -> None: +def generate_tiles(data_path: Path, generate_tribal_layer: bool) -> None: + """Generates map tiles from geojson files - score_tiles_path = data_path / "score" / "tiles" - high_tile_path = score_tiles_path / "high" - low_tile_path = score_tiles_path / "low" - score_geojson_dir = data_path / "score" / "geojson" + Args: + data_path (Path): Path to data folder + generate_tribal_layer (bool): If true, generate the tribal layer of the map - USA_HIGH_MIN_ZOOM = 5 - USA_HIGH_MAX_ZOOM = 11 - USA_LOW_MIN_ZOOM = 0 - USA_LOW_MAX_ZOOM = 7 + Returns: + None + """ - # remove existing mbtiles file - remove_all_from_dir(score_tiles_path) + def _generate_score_tiles() -> None: + """Generates score map tiles""" + score_tiles_path = data_path / "score" / "tiles" + high_tile_path = score_tiles_path / "high" + low_tile_path = score_tiles_path / "low" + score_geojson_dir = data_path / "score" / "geojson" - # create dirs - os.mkdir(high_tile_path) - os.mkdir(low_tile_path) + USA_HIGH_MIN_ZOOM = 5 + USA_HIGH_MAX_ZOOM = 11 + USA_LOW_MIN_ZOOM = 0 + USA_LOW_MAX_ZOOM = 7 - # generate high mbtiles file - logger.info("Generating USA High mbtiles file") - cmd = "tippecanoe " - cmd += f"--minimum-zoom={USA_HIGH_MIN_ZOOM} --maximum-zoom={USA_HIGH_MAX_ZOOM} --layer=blocks " - cmd += f"--output={high_tile_path}/usa_high.mbtiles " - cmd += str(score_geojson_dir / "usa-high.json") - call(cmd, shell=True) + # remove existing mbtiles file + remove_all_from_dir(score_tiles_path) - # generate high mvts - logger.info("Generating USA High mvt folders and files") - cmd = "tippecanoe " - cmd += f"--minimum-zoom={USA_HIGH_MIN_ZOOM} --maximum-zoom={USA_HIGH_MAX_ZOOM} --no-tile-compression " - cmd += "--drop-densest-as-needed " - cmd += f"--output-to-directory={high_tile_path} --layer=blocks " - cmd += str(score_geojson_dir / "usa-high.json") - call(cmd, shell=True) + # create dirs + os.mkdir(high_tile_path) + os.mkdir(low_tile_path) - # generate low mbtiles file - logger.info("Generating USA Low mbtiles file") - cmd = "tippecanoe " - cmd += f"--minimum-zoom={USA_LOW_MIN_ZOOM} --maximum-zoom={USA_LOW_MAX_ZOOM} --layer=blocks " - cmd += f"--output={low_tile_path}/usa_low.mbtiles " - cmd += str(score_geojson_dir / "usa-low.json") - call(cmd, shell=True) + # generate high mbtiles file + logger.info("Generating USA High mbtiles file") + cmd = "tippecanoe " + cmd += f"--minimum-zoom={USA_HIGH_MIN_ZOOM} --maximum-zoom={USA_HIGH_MAX_ZOOM} --layer=blocks " + cmd += f"--output={high_tile_path}/usa_high.mbtiles " + cmd += str(score_geojson_dir / "usa-high.json") + call(cmd, shell=True) - # generate low mvts - logger.info("Generating USA Low mvt folders and files") - cmd = "tippecanoe " - cmd += f"--minimum-zoom={USA_LOW_MIN_ZOOM} --maximum-zoom={USA_LOW_MAX_ZOOM} --no-tile-compression " - cmd += "--drop-densest-as-needed " - cmd += f"--output-to-directory={low_tile_path} --layer=blocks " - cmd += str(score_geojson_dir / "usa-low.json") - call(cmd, shell=True) + # generate high mvts + logger.info("Generating USA High mvt folders and files") + cmd = "tippecanoe " + cmd += f"--minimum-zoom={USA_HIGH_MIN_ZOOM} --maximum-zoom={USA_HIGH_MAX_ZOOM} --no-tile-compression " + cmd += "--drop-densest-as-needed " + cmd += f"--output-to-directory={high_tile_path} --layer=blocks " + cmd += str(score_geojson_dir / "usa-high.json") + call(cmd, shell=True) + + # generate low mbtiles file + logger.info("Generating USA Low mbtiles file") + cmd = "tippecanoe " + cmd += f"--minimum-zoom={USA_LOW_MIN_ZOOM} --maximum-zoom={USA_LOW_MAX_ZOOM} --layer=blocks " + cmd += f"--output={low_tile_path}/usa_low.mbtiles " + cmd += str(score_geojson_dir / "usa-low.json") + call(cmd, shell=True) + + # generate low mvts + logger.info("Generating USA Low mvt folders and files") + cmd = "tippecanoe " + cmd += f"--minimum-zoom={USA_LOW_MIN_ZOOM} --maximum-zoom={USA_LOW_MAX_ZOOM} --no-tile-compression " + cmd += "--drop-densest-as-needed " + cmd += f"--output-to-directory={low_tile_path} --layer=blocks " + cmd += str(score_geojson_dir / "usa-low.json") + call(cmd, shell=True) + + def _generate_tribal_tiles() -> None: + """Generates tribal layer tiles""" + tribal_tiles_path = data_path / "tribal" / "tiles" + tribal_geojson_dir = data_path / "tribal" / "geojson" + + # remove existing mbtiles file + remove_all_from_dir(tribal_tiles_path) + + # generate mbtiles file + logger.info("Generating Tribal mbtiles file") + cmd = "tippecanoe " + cmd += "--layer=blocks " + cmd += f"--output={tribal_tiles_path}/usa.mbtiles " + cmd += str(tribal_geojson_dir / "usa.json") + call(cmd, shell=True) + + # generate mvts + logger.info("Generating Tribal mvt folders and files") + cmd = "tippecanoe " + cmd += "--no-tile-compression " + cmd += "--drop-densest-as-needed " + cmd += f"--output-to-directory={tribal_tiles_path} --layer=blocks " + cmd += str(tribal_geojson_dir / "usa.json") + call(cmd, shell=True) + + if generate_tribal_layer: + _generate_tribal_tiles() + else: + _generate_score_tiles() diff --git a/data/data-pipeline/poetry.lock b/data/data-pipeline/poetry.lock index 13fd97dc..606386e5 100644 --- a/data/data-pipeline/poetry.lock +++ b/data/data-pipeline/poetry.lock @@ -840,7 +840,7 @@ toml = "*" [[package]] name = "lxml" -version = "4.8.0" +version = "4.9.1" description = "Powerful and Pythonic XML processing library combining libxml2/libxslt with the ElementTree API." category = "main" optional = false @@ -1083,11 +1083,11 @@ python-versions = ">=3.5" [[package]] name = "notebook" -version = "6.4.10" +version = "6.4.12" description = "A web-based notebook environment for interactive computing" category = "main" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] argon2-cffi = "*" @@ -1109,7 +1109,7 @@ traitlets = ">=4.2.1" [package.extras] docs = ["sphinx", "nbsphinx", "sphinxcontrib-github-alt", "sphinx-rtd-theme", "myst-parser"] json-logging = ["json-logging"] -test = ["pytest", "coverage", "requests", "nbval", "selenium", "pytest-cov", "requests-unixsocket"] +test = ["pytest", "coverage", "requests", "testpath", "nbval", "selenium", "pytest-cov", "requests-unixsocket"] [[package]] name = "numpy" @@ -2385,67 +2385,76 @@ liccheck = [ {file = "liccheck-0.6.5.tar.gz", hash = "sha256:d4009f1876eb7e4228ecf495e36573ef5b8a226d4cd91235138e417f990a67e8"}, ] lxml = [ - {file = "lxml-4.8.0-cp27-cp27m-macosx_10_14_x86_64.whl", hash = "sha256:e1ab2fac607842ac36864e358c42feb0960ae62c34aa4caaf12ada0a1fb5d99b"}, - {file = "lxml-4.8.0-cp27-cp27m-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:28d1af847786f68bec57961f31221125c29d6f52d9187c01cd34dc14e2b29430"}, - {file = "lxml-4.8.0-cp27-cp27m-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:b92d40121dcbd74831b690a75533da703750f7041b4bf951befc657c37e5695a"}, - {file = "lxml-4.8.0-cp27-cp27m-win32.whl", hash = "sha256:e01f9531ba5420838c801c21c1b0f45dbc9607cb22ea2cf132844453bec863a5"}, - {file = "lxml-4.8.0-cp27-cp27m-win_amd64.whl", hash = "sha256:6259b511b0f2527e6d55ad87acc1c07b3cbffc3d5e050d7e7bcfa151b8202df9"}, - {file = "lxml-4.8.0-cp27-cp27mu-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:1010042bfcac2b2dc6098260a2ed022968dbdfaf285fc65a3acf8e4eb1ffd1bc"}, - {file = "lxml-4.8.0-cp27-cp27mu-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:fa56bb08b3dd8eac3a8c5b7d075c94e74f755fd9d8a04543ae8d37b1612dd170"}, - {file = "lxml-4.8.0-cp310-cp310-macosx_10_15_x86_64.whl", hash = "sha256:31ba2cbc64516dcdd6c24418daa7abff989ddf3ba6d3ea6f6ce6f2ed6e754ec9"}, - {file = "lxml-4.8.0-cp310-cp310-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:31499847fc5f73ee17dbe1b8e24c6dafc4e8d5b48803d17d22988976b0171f03"}, - {file = "lxml-4.8.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.manylinux_2_24_aarch64.whl", hash = "sha256:5f7d7d9afc7b293147e2d506a4596641d60181a35279ef3aa5778d0d9d9123fe"}, - {file = "lxml-4.8.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:a3c5f1a719aa11866ffc530d54ad965063a8cbbecae6515acbd5f0fae8f48eaa"}, - {file = "lxml-4.8.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:6268e27873a3d191849204d00d03f65c0e343b3bcb518a6eaae05677c95621d1"}, - {file = "lxml-4.8.0-cp310-cp310-win32.whl", hash = "sha256:330bff92c26d4aee79c5bc4d9967858bdbe73fdbdbacb5daf623a03a914fe05b"}, - {file = "lxml-4.8.0-cp310-cp310-win_amd64.whl", hash = "sha256:b2582b238e1658c4061ebe1b4df53c435190d22457642377fd0cb30685cdfb76"}, - {file = "lxml-4.8.0-cp35-cp35m-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:a2bfc7e2a0601b475477c954bf167dee6d0f55cb167e3f3e7cefad906e7759f6"}, - {file = "lxml-4.8.0-cp35-cp35m-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:a1547ff4b8a833511eeaceacbcd17b043214fcdb385148f9c1bc5556ca9623e2"}, - {file = "lxml-4.8.0-cp35-cp35m-win32.whl", hash = "sha256:a9f1c3489736ff8e1c7652e9dc39f80cff820f23624f23d9eab6e122ac99b150"}, - {file = "lxml-4.8.0-cp35-cp35m-win_amd64.whl", hash = "sha256:530f278849031b0eb12f46cca0e5db01cfe5177ab13bd6878c6e739319bae654"}, - {file = "lxml-4.8.0-cp36-cp36m-macosx_10_14_x86_64.whl", hash = "sha256:078306d19a33920004addeb5f4630781aaeabb6a8d01398045fcde085091a169"}, - {file = "lxml-4.8.0-cp36-cp36m-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:86545e351e879d0b72b620db6a3b96346921fa87b3d366d6c074e5a9a0b8dadb"}, - {file = "lxml-4.8.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:24f5c5ae618395ed871b3d8ebfcbb36e3f1091fd847bf54c4de623f9107942f3"}, - {file = "lxml-4.8.0-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:bbab6faf6568484707acc052f4dfc3802bdb0cafe079383fbaa23f1cdae9ecd4"}, - {file = "lxml-4.8.0-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:7993232bd4044392c47779a3c7e8889fea6883be46281d45a81451acfd704d7e"}, - {file = "lxml-4.8.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:6d6483b1229470e1d8835e52e0ff3c6973b9b97b24cd1c116dca90b57a2cc613"}, - {file = "lxml-4.8.0-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:ad4332a532e2d5acb231a2e5d33f943750091ee435daffca3fec0a53224e7e33"}, - {file = "lxml-4.8.0-cp36-cp36m-win32.whl", hash = "sha256:db3535733f59e5605a88a706824dfcb9bd06725e709ecb017e165fc1d6e7d429"}, - {file = "lxml-4.8.0-cp36-cp36m-win_amd64.whl", hash = "sha256:5f148b0c6133fb928503cfcdfdba395010f997aa44bcf6474fcdd0c5398d9b63"}, - {file = "lxml-4.8.0-cp37-cp37m-macosx_10_14_x86_64.whl", hash = "sha256:8a31f24e2a0b6317f33aafbb2f0895c0bce772980ae60c2c640d82caac49628a"}, - {file = "lxml-4.8.0-cp37-cp37m-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:719544565c2937c21a6f76d520e6e52b726d132815adb3447ccffbe9f44203c4"}, - {file = "lxml-4.8.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.manylinux_2_24_aarch64.whl", hash = "sha256:c0b88ed1ae66777a798dc54f627e32d3b81c8009967c63993c450ee4cbcbec15"}, - {file = "lxml-4.8.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:fa9b7c450be85bfc6cd39f6df8c5b8cbd76b5d6fc1f69efec80203f9894b885f"}, - {file = "lxml-4.8.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:e9f84ed9f4d50b74fbc77298ee5c870f67cb7e91dcdc1a6915cb1ff6a317476c"}, - {file = "lxml-4.8.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:1d650812b52d98679ed6c6b3b55cbb8fe5a5460a0aef29aeb08dc0b44577df85"}, - {file = "lxml-4.8.0-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:80bbaddf2baab7e6de4bc47405e34948e694a9efe0861c61cdc23aa774fcb141"}, - {file = "lxml-4.8.0-cp37-cp37m-win32.whl", hash = "sha256:6f7b82934c08e28a2d537d870293236b1000d94d0b4583825ab9649aef7ddf63"}, - {file = "lxml-4.8.0-cp37-cp37m-win_amd64.whl", hash = "sha256:e1fd7d2fe11f1cb63d3336d147c852f6d07de0d0020d704c6031b46a30b02ca8"}, - {file = "lxml-4.8.0-cp38-cp38-macosx_10_14_x86_64.whl", hash = "sha256:5045ee1ccd45a89c4daec1160217d363fcd23811e26734688007c26f28c9e9e7"}, - {file = "lxml-4.8.0-cp38-cp38-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:0c1978ff1fd81ed9dcbba4f91cf09faf1f8082c9d72eb122e92294716c605428"}, - {file = "lxml-4.8.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.manylinux_2_24_aarch64.whl", hash = "sha256:52cbf2ff155b19dc4d4100f7442f6a697938bf4493f8d3b0c51d45568d5666b5"}, - {file = "lxml-4.8.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:ce13d6291a5f47c1c8dbd375baa78551053bc6b5e5c0e9bb8e39c0a8359fd52f"}, - {file = "lxml-4.8.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:e11527dc23d5ef44d76fef11213215c34f36af1608074561fcc561d983aeb870"}, - {file = "lxml-4.8.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:60d2f60bd5a2a979df28ab309352cdcf8181bda0cca4529769a945f09aba06f9"}, - {file = "lxml-4.8.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:62f93eac69ec0f4be98d1b96f4d6b964855b8255c345c17ff12c20b93f247b68"}, - {file = "lxml-4.8.0-cp38-cp38-win32.whl", hash = "sha256:20b8a746a026017acf07da39fdb10aa80ad9877046c9182442bf80c84a1c4696"}, - {file = "lxml-4.8.0-cp38-cp38-win_amd64.whl", hash = "sha256:891dc8f522d7059ff0024cd3ae79fd224752676447f9c678f2a5c14b84d9a939"}, - {file = "lxml-4.8.0-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:b6fc2e2fb6f532cf48b5fed57567ef286addcef38c28874458a41b7837a57807"}, - {file = "lxml-4.8.0-cp39-cp39-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:74eb65ec61e3c7c019d7169387d1b6ffcfea1b9ec5894d116a9a903636e4a0b1"}, - {file = "lxml-4.8.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.manylinux_2_24_aarch64.whl", hash = "sha256:627e79894770783c129cc5e89b947e52aa26e8e0557c7e205368a809da4b7939"}, - {file = "lxml-4.8.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:545bd39c9481f2e3f2727c78c169425efbfb3fbba6e7db4f46a80ebb249819ca"}, - {file = "lxml-4.8.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:5a58d0b12f5053e270510bf12f753a76aaf3d74c453c00942ed7d2c804ca845c"}, - {file = "lxml-4.8.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:ec4b4e75fc68da9dc0ed73dcdb431c25c57775383fec325d23a770a64e7ebc87"}, - {file = "lxml-4.8.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:5804e04feb4e61babf3911c2a974a5b86f66ee227cc5006230b00ac6d285b3a9"}, - {file = "lxml-4.8.0-cp39-cp39-win32.whl", hash = "sha256:aa0cf4922da7a3c905d000b35065df6184c0dc1d866dd3b86fd961905bbad2ea"}, - {file = "lxml-4.8.0-cp39-cp39-win_amd64.whl", hash = "sha256:dd10383f1d6b7edf247d0960a3db274c07e96cf3a3fc7c41c8448f93eac3fb1c"}, - {file = "lxml-4.8.0-pp37-pypy37_pp73-macosx_10_14_x86_64.whl", hash = "sha256:2403a6d6fb61c285969b71f4a3527873fe93fd0abe0832d858a17fe68c8fa507"}, - {file = "lxml-4.8.0-pp37-pypy37_pp73-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:986b7a96228c9b4942ec420eff37556c5777bfba6758edcb95421e4a614b57f9"}, - {file = "lxml-4.8.0-pp37-pypy37_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:6fe4ef4402df0250b75ba876c3795510d782def5c1e63890bde02d622570d39e"}, - {file = "lxml-4.8.0-pp38-pypy38_pp73-macosx_10_14_x86_64.whl", hash = "sha256:f10ce66fcdeb3543df51d423ede7e238be98412232fca5daec3e54bcd16b8da0"}, - {file = "lxml-4.8.0-pp38-pypy38_pp73-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:730766072fd5dcb219dd2b95c4c49752a54f00157f322bc6d71f7d2a31fecd79"}, - {file = "lxml-4.8.0-pp38-pypy38_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:8b99ec73073b37f9ebe8caf399001848fced9c08064effdbfc4da2b5a8d07b93"}, - {file = "lxml-4.8.0.tar.gz", hash = "sha256:f63f62fc60e6228a4ca9abae28228f35e1bd3ce675013d1dfb828688d50c6e23"}, + {file = "lxml-4.9.1-cp27-cp27m-macosx_10_15_x86_64.whl", hash = "sha256:98cafc618614d72b02185ac583c6f7796202062c41d2eeecdf07820bad3295ed"}, + {file = "lxml-4.9.1-cp27-cp27m-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:c62e8dd9754b7debda0c5ba59d34509c4688f853588d75b53c3791983faa96fc"}, + {file = "lxml-4.9.1-cp27-cp27m-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:21fb3d24ab430fc538a96e9fbb9b150029914805d551deeac7d7822f64631dfc"}, + {file = "lxml-4.9.1-cp27-cp27m-win32.whl", hash = "sha256:86e92728ef3fc842c50a5cb1d5ba2bc66db7da08a7af53fb3da79e202d1b2cd3"}, + {file = "lxml-4.9.1-cp27-cp27m-win_amd64.whl", hash = "sha256:4cfbe42c686f33944e12f45a27d25a492cc0e43e1dc1da5d6a87cbcaf2e95627"}, + {file = "lxml-4.9.1-cp27-cp27mu-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:dad7b164905d3e534883281c050180afcf1e230c3d4a54e8038aa5cfcf312b84"}, + {file = "lxml-4.9.1-cp27-cp27mu-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:a614e4afed58c14254e67862456d212c4dcceebab2eaa44d627c2ca04bf86837"}, + {file = "lxml-4.9.1-cp310-cp310-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:f9ced82717c7ec65a67667bb05865ffe38af0e835cdd78728f1209c8fffe0cad"}, + {file = "lxml-4.9.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.manylinux_2_24_aarch64.whl", hash = "sha256:d9fc0bf3ff86c17348dfc5d322f627d78273eba545db865c3cd14b3f19e57fa5"}, + {file = "lxml-4.9.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:e5f66bdf0976ec667fc4594d2812a00b07ed14d1b44259d19a41ae3fff99f2b8"}, + {file = "lxml-4.9.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:fe17d10b97fdf58155f858606bddb4e037b805a60ae023c009f760d8361a4eb8"}, + {file = "lxml-4.9.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:8caf4d16b31961e964c62194ea3e26a0e9561cdf72eecb1781458b67ec83423d"}, + {file = "lxml-4.9.1-cp310-cp310-win32.whl", hash = "sha256:4780677767dd52b99f0af1f123bc2c22873d30b474aa0e2fc3fe5e02217687c7"}, + {file = "lxml-4.9.1-cp310-cp310-win_amd64.whl", hash = "sha256:b122a188cd292c4d2fcd78d04f863b789ef43aa129b233d7c9004de08693728b"}, + {file = "lxml-4.9.1-cp311-cp311-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:be9eb06489bc975c38706902cbc6888f39e946b81383abc2838d186f0e8b6a9d"}, + {file = "lxml-4.9.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:f1be258c4d3dc609e654a1dc59d37b17d7fef05df912c01fc2e15eb43a9735f3"}, + {file = "lxml-4.9.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:927a9dd016d6033bc12e0bf5dee1dde140235fc8d0d51099353c76081c03dc29"}, + {file = "lxml-4.9.1-cp35-cp35m-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:9232b09f5efee6a495a99ae6824881940d6447debe272ea400c02e3b68aad85d"}, + {file = "lxml-4.9.1-cp35-cp35m-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:04da965dfebb5dac2619cb90fcf93efdb35b3c6994fea58a157a834f2f94b318"}, + {file = "lxml-4.9.1-cp35-cp35m-win32.whl", hash = "sha256:4d5bae0a37af799207140652a700f21a85946f107a199bcb06720b13a4f1f0b7"}, + {file = "lxml-4.9.1-cp35-cp35m-win_amd64.whl", hash = "sha256:4878e667ebabe9b65e785ac8da4d48886fe81193a84bbe49f12acff8f7a383a4"}, + {file = "lxml-4.9.1-cp36-cp36m-macosx_10_15_x86_64.whl", hash = "sha256:1355755b62c28950f9ce123c7a41460ed9743c699905cbe664a5bcc5c9c7c7fb"}, + {file = "lxml-4.9.1-cp36-cp36m-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:bcaa1c495ce623966d9fc8a187da80082334236a2a1c7e141763ffaf7a405067"}, + {file = "lxml-4.9.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6eafc048ea3f1b3c136c71a86db393be36b5b3d9c87b1c25204e7d397cee9536"}, + {file = "lxml-4.9.1-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:13c90064b224e10c14dcdf8086688d3f0e612db53766e7478d7754703295c7c8"}, + {file = "lxml-4.9.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:206a51077773c6c5d2ce1991327cda719063a47adc02bd703c56a662cdb6c58b"}, + {file = "lxml-4.9.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:e8f0c9d65da595cfe91713bc1222af9ecabd37971762cb830dea2fc3b3bb2acf"}, + {file = "lxml-4.9.1-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:8f0a4d179c9a941eb80c3a63cdb495e539e064f8054230844dcf2fcb812b71d3"}, + {file = "lxml-4.9.1-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:830c88747dce8a3e7525defa68afd742b4580df6aa2fdd6f0855481e3994d391"}, + {file = "lxml-4.9.1-cp36-cp36m-win32.whl", hash = "sha256:1e1cf47774373777936c5aabad489fef7b1c087dcd1f426b621fda9dcc12994e"}, + {file = "lxml-4.9.1-cp36-cp36m-win_amd64.whl", hash = "sha256:5974895115737a74a00b321e339b9c3f45c20275d226398ae79ac008d908bff7"}, + {file = "lxml-4.9.1-cp37-cp37m-macosx_10_15_x86_64.whl", hash = "sha256:1423631e3d51008871299525b541413c9b6c6423593e89f9c4cfbe8460afc0a2"}, + {file = "lxml-4.9.1-cp37-cp37m-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:2aaf6a0a6465d39b5ca69688fce82d20088c1838534982996ec46633dc7ad6cc"}, + {file = "lxml-4.9.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.manylinux_2_24_aarch64.whl", hash = "sha256:9f36de4cd0c262dd9927886cc2305aa3f2210db437aa4fed3fb4940b8bf4592c"}, + {file = "lxml-4.9.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:ae06c1e4bc60ee076292e582a7512f304abdf6c70db59b56745cca1684f875a4"}, + {file = "lxml-4.9.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:57e4d637258703d14171b54203fd6822fda218c6c2658a7d30816b10995f29f3"}, + {file = "lxml-4.9.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:6d279033bf614953c3fc4a0aa9ac33a21e8044ca72d4fa8b9273fe75359d5cca"}, + {file = "lxml-4.9.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:a60f90bba4c37962cbf210f0188ecca87daafdf60271f4c6948606e4dabf8785"}, + {file = "lxml-4.9.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:6ca2264f341dd81e41f3fffecec6e446aa2121e0b8d026fb5130e02de1402785"}, + {file = "lxml-4.9.1-cp37-cp37m-win32.whl", hash = "sha256:27e590352c76156f50f538dbcebd1925317a0f70540f7dc8c97d2931c595783a"}, + {file = "lxml-4.9.1-cp37-cp37m-win_amd64.whl", hash = "sha256:eea5d6443b093e1545ad0210e6cf27f920482bfcf5c77cdc8596aec73523bb7e"}, + {file = "lxml-4.9.1-cp38-cp38-macosx_10_15_x86_64.whl", hash = "sha256:f05251bbc2145349b8d0b77c0d4e5f3b228418807b1ee27cefb11f69ed3d233b"}, + {file = "lxml-4.9.1-cp38-cp38-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:487c8e61d7acc50b8be82bda8c8d21d20e133c3cbf41bd8ad7eb1aaeb3f07c97"}, + {file = "lxml-4.9.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.manylinux_2_24_aarch64.whl", hash = "sha256:8d1a92d8e90b286d491e5626af53afef2ba04da33e82e30744795c71880eaa21"}, + {file = "lxml-4.9.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:b570da8cd0012f4af9fa76a5635cd31f707473e65a5a335b186069d5c7121ff2"}, + {file = "lxml-4.9.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:5ef87fca280fb15342726bd5f980f6faf8b84a5287fcc2d4962ea8af88b35130"}, + {file = "lxml-4.9.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:93e414e3206779ef41e5ff2448067213febf260ba747fc65389a3ddaa3fb8715"}, + {file = "lxml-4.9.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:6653071f4f9bac46fbc30f3c7838b0e9063ee335908c5d61fb7a4a86c8fd2036"}, + {file = "lxml-4.9.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:32a73c53783becdb7eaf75a2a1525ea8e49379fb7248c3eeefb9412123536387"}, + {file = "lxml-4.9.1-cp38-cp38-win32.whl", hash = "sha256:1a7c59c6ffd6ef5db362b798f350e24ab2cfa5700d53ac6681918f314a4d3b94"}, + {file = "lxml-4.9.1-cp38-cp38-win_amd64.whl", hash = "sha256:1436cf0063bba7888e43f1ba8d58824f085410ea2025befe81150aceb123e345"}, + {file = "lxml-4.9.1-cp39-cp39-macosx_10_15_x86_64.whl", hash = "sha256:4beea0f31491bc086991b97517b9683e5cfb369205dac0148ef685ac12a20a67"}, + {file = "lxml-4.9.1-cp39-cp39-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:41fb58868b816c202e8881fd0f179a4644ce6e7cbbb248ef0283a34b73ec73bb"}, + {file = "lxml-4.9.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.manylinux_2_24_aarch64.whl", hash = "sha256:bd34f6d1810d9354dc7e35158aa6cc33456be7706df4420819af6ed966e85448"}, + {file = "lxml-4.9.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:edffbe3c510d8f4bf8640e02ca019e48a9b72357318383ca60e3330c23aaffc7"}, + {file = "lxml-4.9.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:6d949f53ad4fc7cf02c44d6678e7ff05ec5f5552b235b9e136bd52e9bf730b91"}, + {file = "lxml-4.9.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:079b68f197c796e42aa80b1f739f058dcee796dc725cc9a1be0cdb08fc45b000"}, + {file = "lxml-4.9.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:9c3a88d20e4fe4a2a4a84bf439a5ac9c9aba400b85244c63a1ab7088f85d9d25"}, + {file = "lxml-4.9.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:4e285b5f2bf321fc0857b491b5028c5f276ec0c873b985d58d7748ece1d770dd"}, + {file = "lxml-4.9.1-cp39-cp39-win32.whl", hash = "sha256:ef72013e20dd5ba86a8ae1aed7f56f31d3374189aa8b433e7b12ad182c0d2dfb"}, + {file = "lxml-4.9.1-cp39-cp39-win_amd64.whl", hash = "sha256:10d2017f9150248563bb579cd0d07c61c58da85c922b780060dcc9a3aa9f432d"}, + {file = "lxml-4.9.1-pp37-pypy37_pp73-macosx_10_15_x86_64.whl", hash = "sha256:0538747a9d7827ce3e16a8fdd201a99e661c7dee3c96c885d8ecba3c35d1032c"}, + {file = "lxml-4.9.1-pp37-pypy37_pp73-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:0645e934e940107e2fdbe7c5b6fb8ec6232444260752598bc4d09511bd056c0b"}, + {file = "lxml-4.9.1-pp37-pypy37_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:6daa662aba22ef3258934105be2dd9afa5bb45748f4f702a3b39a5bf53a1f4dc"}, + {file = "lxml-4.9.1-pp38-pypy38_pp73-macosx_10_15_x86_64.whl", hash = "sha256:603a464c2e67d8a546ddaa206d98e3246e5db05594b97db844c2f0a1af37cf5b"}, + {file = "lxml-4.9.1-pp38-pypy38_pp73-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:c4b2e0559b68455c085fb0f6178e9752c4be3bba104d6e881eb5573b399d1eb2"}, + {file = "lxml-4.9.1-pp38-pypy38_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:0f3f0059891d3254c7b5fb935330d6db38d6519ecd238ca4fce93c234b4a0f73"}, + {file = "lxml-4.9.1-pp39-pypy39_pp73-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_24_i686.whl", hash = "sha256:c852b1530083a620cb0de5f3cd6826f19862bafeaf77586f1aef326e49d95f0c"}, + {file = "lxml-4.9.1-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl", hash = "sha256:287605bede6bd36e930577c5925fcea17cb30453d96a7b4c63c14a257118dbb9"}, + {file = "lxml-4.9.1.tar.gz", hash = "sha256:fe749b052bb7233fe5d072fcb549221a8cb1a16725c47c37e42b0b9cb3ff2c3f"}, ] markupsafe = [ {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, @@ -2603,8 +2612,8 @@ nest-asyncio = [ {file = "nest_asyncio-1.5.5.tar.gz", hash = "sha256:e442291cd942698be619823a17a86a5759eabe1f8613084790de189fe9e16d65"}, ] notebook = [ - {file = "notebook-6.4.10-py3-none-any.whl", hash = "sha256:49cead814bff0945fcb2ee07579259418672ac175d3dc3d8102a4b0a656ed4df"}, - {file = "notebook-6.4.10.tar.gz", hash = "sha256:2408a76bc6289283a8eecfca67e298ec83c67db51a4c2e1b713dd180bb39e90e"}, + {file = "notebook-6.4.12-py3-none-any.whl", hash = "sha256:8c07a3bb7640e371f8a609bdbb2366a1976c6a2589da8ef917f761a61e3ad8b1"}, + {file = "notebook-6.4.12.tar.gz", hash = "sha256:6268c9ec9048cff7a45405c990c29ac9ca40b0bc3ec29263d218c5e01f2b4e86"}, ] numpy = [ {file = "numpy-1.22.3-cp310-cp310-macosx_10_14_x86_64.whl", hash = "sha256:92bfa69cfbdf7dfc3040978ad09a48091143cffb778ec3b03fa170c494118d75"},