Граф коммитов

62 Коммитов

Автор SHA1 Сообщение Дата
Joel Maher f1a6c9dfd5
Remove Glean from Treeherder (#8267) 2024-11-01 08:54:59 -07:00
Sebastian Hengst 219073f0e1 Bug 1810048 - add ui/glean/generated/ to .gitignore 2023-01-13 11:52:35 +01:00
ionutgoldan 10ccd44545
Bug 1649387 - Provide enhanced management script for Bugzilla formulas 2020-07-17 08:57:11 +03:00
ionutgoldan 2fbe6d3260
Bug 1642554 - Implement model for engineer traction formula 2020-06-12 11:27:57 +03:00
Armen Zambrano 5ca21043df
Make poetry the default method for generating the docs (#6424)
This makes sure that serving the documentation via poetry does not regress
and we have a single way of generating them.

Setting the build backend in `pyproject.toml` makes `pip` to use `poetry` to install the dependencies. By doing so, readthedocs will be able to install the required dependencies to generate the docs (since they don't support poetry directly).
2020-05-15 15:12:35 -04:00
Shubhank Saxena 1892968e10
Document Tox as a requirement for running tests (#6338) 2020-04-22 11:15:44 -04:00
Kyle Lahnakoski 64efbc2caf
Bug 1617674 - BigQuery Extraction - include commits in push (#6093)
add commit records to push records
2020-03-03 17:30:18 -05:00
Kyle Lahnakoski 7f7ce81589
Support test environment outside of Docker container (#5716)
Work to support running Python tests outside of the Docker container.
This also helps with integration with IDEs and is prework for using Git hooks for precommit/prepush features.
2020-02-05 14:55:03 -05:00
Armen Zambrano 82efbe2967
Add Python test coverage to codecov (#5921)
Fixes #5853 

Co-authored-by: Shubhank Saxena <saxena.shubhank.19@gmail.com>
2020-02-03 12:03:17 -05:00
Armen Zambrano G f482d2a359 Report code coverage results to codecov 2019-09-10 08:45:22 -04:00
Armen Zambrano deaf8c850c Bug 1169263 - Switch from Vagrant to docker-compose (#4901)
* Change permissions for docker/entrypoint.sh
* Allow using Django in localhost
* Documentation changes
Allow running shellcheck tests
Use docker-compose for the Selenium tests
Install docs updates
Switch to yarn cache instead of npm
Install UI dependencies
* Add ability to override DATABASE_URL and use a .env file
2019-05-16 14:56:02 -07:00
Cameron Dawson 3267f191bb
Bug 1056865 - Add support for custom env file in Vagrant that is ignored by git (#4857) 2019-04-04 12:18:48 -07:00
Ed Morley 3decefed0b
Clean up the location of generated output directories (#4289)
So that their purposes are clearer and it's easier to differentiate
between generated content and files committed to the repository.

* Neutrino build: `build/` -> `.build/`
* Sphinx build: `_build/` -> `.build-docs/`
* Django collectstatic: `treeherder/static/` -> `.django-static/`
2018-11-16 19:18:18 +00:00
Ed Morley 565ae4c13e
Bug 1364894 - Upgrade from Neutrino 4 to 9 (#4216)
Neutrino controls our frontend linting, transpilation, source-maps,
testing, dev-server and optimisation of production builds.

Highlights of the upgrade are:

* Major version updates to the individual tools within (such as webpack,
  Babel and ESLint), significantly improving performance, fixing
  transpilation/minification correctness bugs, adding support for newer
  ECMAScript features, and increasing linter coverage.
* Hot reloading in the dev server now works for all entry-points and not
  just the jobs view, shortening the feedback cycle.
* Reduced bundle size due to webpack 4's tree shaking, scope hoisting,
  automatic shared/vendor code chunk splitting (no need for the manually
  maintained 'vendor' list).
* CSS is now extracted out of JS, which improves performance, reduces
  bundle size and prevents the initial white flash of un-styled content.
* Support for dynamic imports/code splitting (needed for bug 1502192).
* Support for Jest via a new Jest preset (unblocks bug 1364045).
* Support for public class field declarations (unblocks bug 1480166).
* Improved source-maps (increases the quality of production exception
  trace-backs and fixes several debugger breakpoint bugs).
* Reduced amount of custom configuration required for our fairly complex
  frontend needs, reducing maintenance burden and allowing for easier
  future Neutrino upgrades.

In addition this PR:

* Fixes the WhiteNoise `immutable_file_test()` regex, so that it now
  correctly enables browser caching of images, fonts and source maps.
* Enables webpack-dev-server's overlay feature, which displays any
  compilation errors in the browser, saving having to switch back
  to the console (this can be enabled for warnings too if desired).
* Enables webpack-dev-server's automatic browser-opening feature,
  which saves having to manually navigate to `localhost:5000` after
  running `yarn start`.
* Switches Karma tests to run Firefox in headless mode, reducing the
  workflow disruption when running `yarn test`.
* Uses the new webpack `performance` option to enable maximum asset
  file size thresholds, to help prevent bundle-size regressions.
* Rewrites the `package.json` script commands so that they now work
  correctly on Windows, even when setting environment variables.

Performance comparison:

* Local `yarn build`:
  - Cached: 2m34s -> 23s
  - Uncached: 2m34s -> 58s
* Local `yarn start`:
  - Cached: 34.5s -> 13.6s
  - Uncached: 34.5s -> 31.3s
* Local `yarn test`
  - Cached: 61.5s -> 19.8s
  - Uncached: 61.5s -> 22.0s
* Local `yarn lint`
  - Cached: 3.8s -> 1.8s
  - Uncached: 13.7s -> 13.4s
* Travis end-to-end time:
  9 minutes -> 6 minutes
* Heroku deploy end-to-end time:
  14 minutes -> 9 minutes
2018-11-02 18:48:28 +00:00
Ed Morley e22b90d80c
Clean up .gitignore (#3820)
The coverage directory and local config file no longer exist.
2018-07-26 18:38:10 +02:00
Ed Morley d3c18b3bc5 Bug 1478711 - Correct docs build directory path in .gitignore
After the move in #3813.
2018-07-26 18:24:57 +02:00
Ed Morley e1822b5f0a
Bug 1468650 - Use caching with ESLint & lint more files (#3663)
Enabling the ESLint caching reduces `yarn lint` time by 60%. See:
https://eslint.org/docs/user-guide/command-line-interface#caching

This also adds JS files in the repo root to the list of files that
are linted, and fixes a subsequent lint error in `.eslintrc.js`.
2018-06-13 22:39:55 -07:00
Ed Morley 4e8b7e39a9 Bug 1436598 - Remove unnecessary empty static files directory
Django creates this directory when collectstatic is run, so no need
to pre-create it via a `.gitkeep` file.
2018-02-12 17:03:53 +00:00
Ed Morley 610c824c94 Bug 1436598 - Removed unused Django media configuration
Since we don't allow user uploads.
2018-02-12 17:03:53 +00:00
pyup.io bot 95141689e8 Update pytest to 3.4.0 (#3179)
And update pytest cache .gitignore entry for pytest v3.4.0,
since the directory name has been changed:
cd0b2ace67
2018-01-31 01:22:32 +00:00
Ed Morley 27dbf288d5 Bug 1353014 - Add {yarn,npm}-error.log to .gitignore 2017-04-27 11:48:52 +01:00
Casey Williams a448fe0db6 Bug 1336556 - Add karma coverage directory to .gitignore 2017-03-01 21:35:55 +00:00
Ed Morley 422cd3390b Bug 1328469 - Remove the now unused logslice API
The new log viewer loads the logs directly in the client from wherever
they are stored, so doesn't need Treeherder's API to proxy them.

The logslice API was the only user of the Django filesystem cache, so
that has also been removed.
2017-01-05 23:41:43 +00:00
Ed Morley 21657c373b Bug 1308354 - Remove SCL3 leftover from .gitignore 2016-11-29 19:18:16 +00:00
Ed Morley 5dfb9782a2 Bug 1318021 - Vagrant: Remove support for settings_local.py
Since it is footgun-prone, discourages upstreaming of useful development
tricks & is unnecessary in an environment variable centric world.

The one remaining `BZ_API_URL` setting isn't actively used, and if this
changes in the future, it should be set via an environment variable
instead.
2016-11-29 19:18:16 +00:00
Kris Rivera 508c9b5931 Add the .vscode directory to .gitignore (#1921)
https://code.visualstudio.com/Docs/customization/userandworkspace#_settings-file-locations
2016-10-13 12:49:41 +01:00
Ed Morley 1b4010f728 Bug 1297666 - Remove supervisord configs/documentation
Since it's a non-default workflow that isn't kept up to date, and is
going to be even less relevant once we switch to tooling that uses the
Procfile.
2016-08-26 15:56:53 +01:00
James Graham 48af61f729 Bug 1252850 - gitignore emacs temp files 2016-03-02 13:39:21 +00:00
Ed Morley 61d596267a Bug 1212937 - Remove API support for OAuth credentials
Since they are deprecated and all submitters have switched over to using
Hawk credentials instead.

The automatically created migrations file was edited to remove the
unused `models` import, since otherwise flake8 complains. We could
alternatively exclude the migrations directory from flake8, however we
would then miss linter errors in any hand-written migrations files.

In addition, Django have fixed the issue in 1.9:
a7bc00e17b
2015-12-16 18:12:41 +00:00
Ed Morley 31c5bdca67 Bug 1228739 - Remove unnecessary .gitignore entries & clean up ordering
Removed:
*.mo
*.py[od]
.coverage
.mr.developer.cfg
.project
.pydevproject
.tmp/
.tox
htmlcov/
LOGFILE
nosetests.xml
pip-log.txt
supervisor*.log
test.log
treeherder*.log
treeherder.log.*
2015-11-28 16:02:30 +00:00
Kyle Lahnakoski 899aeb45fc ignore ide files 2015-11-24 10:31:17 -05:00
Ed Morley 2227dc3d0e Bug 1223824 - Add the new pytest .cache/ directory to .gitignore
https://pytest.org/latest/cache.html
2015-11-16 17:45:27 +00:00
Ed Morley f059f88d85 Bug 1205758 - Run `grunt build` as part of the stage/prod deploy
In update.py, the line outputting revision.txt has to be moved later,
since the `dist/` directory won't exist until grunt build has run. In
addition, since `grunt build` removes the entire `dist/` directory, we
no longer need to manually remove *.gz.

We use the `--production` options for both `npm install` and
`grunt build`, so that the `devDependencies` in package.json are
ignored, and we only install/load the ones listed under `dependencies`
in package.json - since that's all that is required for the build.

We have to use `./node_modules/.bin/grunt` rather than `grunt`, since
grunt-cli is not installed globally on the treeherder admin machine for
greater isolation between stage and production.
2015-10-31 16:06:08 +00:00
Ed Morley 8ae9071901 Bug 1197186 - Move settings to treeherder/config/
Since they're not specific to the Django app 'webapp'.

Whilst we're there, the local & example settings files have been
renamed. In the future I'd like to combine settings_local.example.py
with puppet/files/treeherder/local.vagrant.py, but I'll do that in
another bug.
2015-10-08 19:59:46 +01:00
Ed Morley 5892c72eb2 Bug 1197796 - Make WhiteNoise serve the static assets gzipped
On Heroku, there is no load balancer or Varnish-like cache in front of
gunicorn, so we must handle gzipping responses in the app.

In order for WhiteNoise to serve gzipped static content, assets must be
gzipped on disk in advance (doing so on-demand in Python would not be
as performant). WhiteNoise will then serve the `.gz` version of files in
preference to the original, if the client indicated it supported gzip.

For assets covered by Django's collectstatic, gzipping the assets only
requires using WhiteNoise's GzipManifestStaticFilesStorage backend,
which wraps Django's ManifestStaticFilesStorage to create hashed+gzipped
versions of static assets:
http://whitenoise.evans.io/en/latest/django.html#add-gzip-and-caching-support

The collectstatic generated files will then contain the file hash in
their filename, so WhiteNoise can also serve them with a large max-age
to avoid further requests if the file contents have not changed.

For the UI files under `dist/`, we cannot rely on the Django storage
backend, since the directory isn't covered by STATICFILES_DIRS (it is
instead made known to WhiteNoise via `WHITENOISE_ROOT`). As such, files
under `dist/` are gzipped via an additional step during deployment. See:
http://whitenoise.evans.io/en/latest/base.html#gzip-support

Files whose extension is on the blacklist, or that are not >5% smaller
when compressed, are skipped during compression.
2015-08-26 22:10:05 +01:00
Mauro Doglio b008a335ef Bug 1124382 - Move static and media folders to treeherder/ 2015-08-26 21:56:39 +01:00
Ed Morley 90576b9fd9 Bug 1198452 - Save the deployed revision to <site-root>/revision.txt
Since WhiteNoise won't serve files from /media/, so the existing file
in `treeherder/webapp/media/` 404s when accessed via:
https://treeherder.{mozilla,allizom}.org/media/revision

IMO the site root makes more sense for this file anyway, so let's just
save it under `dist/`. Also adds a .txt extension for clarity.

The old file has been left for now to ease the transition, and will be
deleted once the IRC pushbots config and What's Deployed URLs have been
updated.
2015-08-25 21:37:48 +01:00
Ed Morley b9855cb9f9 Bug 1178832 - Cleanup leftovers from using Cython
Also remove some .gitignore entries from when we had a vendor directory.
2015-07-01 00:21:36 +01:00
Ed Morley 9210d9bf27 Bug 1056877 - Merge .gitignore and .gitignore-ui 2015-05-20 12:34:15 +01:00
Ed Morley 21328551fa Bug 1066266 - Add some stage/prod specific files to gitignore
To ignore:
deployment/update/commander_settings.py
treeherder/webapp/media/revision
2015-02-13 18:38:46 +00:00
Ed Morley cf06199a67 Bug 1132893 - Move the Builds4hAnalyzer blacklist inline
A json file is overkill, and it is currently in a directory intended for
production-specific files, so move the blacklist inline. We should
probably move the whole analyser to another file, but that can be done
later.

Also store the analyser output in the root of the media directory, since
a subdirectory is unnecessary. The media directory is now empty, so we
must use .gitkeep to ensure it is created.
2015-02-13 18:38:46 +00:00
Ed Morley 107a30e46d Bug 1114366 - Add celerybeat-schedule to .gitignore 2015-01-17 11:26:32 +00:00
Cameron Dawson 0be2592885 fix bug 1059222 - refresh flat_exclusions on save 2014-09-04 17:56:30 -07:00
pnispel 1a7a9e5c64 changed directory for log cache from /var/tmp to webapp/log_cache 2014-05-22 14:24:37 -07:00
Cameron Dawson d9429382cb adding supervisord logs to ignore list 2014-04-01 12:06:04 -07:00
Jonathan Eads 044217b997 removed manage.py command to write out credentials 2014-02-04 15:23:01 -08:00
Jonathan Eads ab83b849b3 Merge branch 'master' of ssh://github.com/mozilla/treeherder-service into oauth-implementation 2014-01-28 14:33:54 -08:00
Cameron Dawson 75428584bc new files to ignore 2014-01-16 12:00:08 -08:00
Jonathan Eads 601f46a22b added oauth requirements 2014-01-08 17:23:57 -08:00
Jonathan Eads 1d3631b8ba added buildername blacklist 2013-12-10 12:01:52 -08:00