• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

kobotoolbox / kpi / 12126222846
82%
master: 76%

Build:
Build:
LAST BUILD BRANCH: dev-1261-remove-api_v1_submissions_endpoints
DEFAULT BRANCH: master
Ran 02 Dec 2024 07:42PM UTC
Jobs 1
Files 609
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

02 Dec 2024 07:06PM UTC coverage: 80.126% (+0.06%) from 80.063%
12126222846

push

github

web-flow
feat(accessLogExport)!: create new AccessLogExportTask to generate a csv of access logs TASK-871 (#5258)

### 👀 Preview steps

1. Ensure that the `Export all data` button for `ProjectViews` still
works as normal and that the email header has the appropriate title:
"Project View Report Complete"
2. Ensure that exports for submission data works correctly:
- make submissions to a project
- navigate to the _Project < Data < Downloads_ 
- 🟢 ensure the `Export` button is exporting data correctly
3. Preview the AccessLogExportTask from the shell:
- ℹ️ have a user 
- enter the Django shell: `./manage.py shell_plus`
- get your user: `test_user = User.objects.get(username='test')`
- create an AccessLogExportTask: 
``` 
task = AccessLogExportTask.objects.create(
           user=test_user,
           get_all_logs=False,
           data={'type': 'access_logs_export'},
  )
```
- 🟢 print the task object and notice that an AccessLogExportTask object
has been created: `print(task)`
- run the task: `task.run()`
- 🟢 print the result and notice that it generated a link to the csv
export: `print(task.result)`

### 💭 Notes
- Changed the field named `user` to `user_url` because naming it
`user` conflicts with an existing field in the `AccessLog` model
- Renamed the file titled `project_view_exports.py` to `data_exports.py`
because it now generates exports for both project view and access log
exports
- Refactored the `ProjectViewExportTask` to have a base
`CommonExportTask` which both the project view and access log export
classes inherit from
- Updated the email (in `kpi/tasks.py`) to have the correct subject
title based on the type of export report it is sending
- Alphabetized the functions in `data_exports.py`

5670 of 9151 branches covered (61.96%)

107 of 115 new or added lines in 10 files covered. (93.04%)

21699 of 27081 relevant lines covered (80.13%)

0.8 hits per line

Jobs
ID Job ID Ran Files Coverage
1 12126222846.1 02 Dec 2024 07:42PM UTC 0
80.13
Source Files on build 12126222846
Detailed source file information is not available for this build.
  • Back to Repo
  • 6992e8a0 on github
  • Prev Build on main (#12124879225)
  • Next Build on main (#12126321618)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc