Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
395246e
feat: setting for sentry DSN
RiedleroD Oct 4, 2025
c03c43d
Merge branch 'main' into EDUPL-26-sentry-api
RiedleroD Oct 5, 2025
379508d
feat: added sentry to dependencies + composer setup
RiedleroD Oct 5, 2025
1a5e448
fix: settings off-by-one
RiedleroD Oct 5, 2025
04233ce
feat: initial impl of sentry callback
RiedleroD Oct 9, 2025
f1227b9
fix: fixed minimum php version at 8.1.0
RiedleroD Oct 9, 2025
dc600a8
docs: setup and packaging instructions
RiedleroD Oct 9, 2025
cb9a82b
fix: add gitkeep to vendor dir so it sticks around
RiedleroD Oct 9, 2025
9f03299
chore: pacified moodle codechecker
RiedleroD Oct 9, 2025
9fb9987
chore: pacified PHPDoc checker
RiedleroD Oct 9, 2025
18eea0b
Merge branch 'main' into EDUPL-26-sentry-api
RiedleroD Oct 9, 2025
0ff367f
chore: kill yourself
RiedleroD Oct 9, 2025
073e634
feat: set release and environment for sentry
RiedleroD Oct 29, 2025
6645bce
chore: removed psr/log from vendor folder
RiedleroD Oct 29, 2025
b40a607
feat: get dependencies when making dist package
RiedleroD Oct 29, 2025
ce8bc28
feat: first draft of sentry tracing
RiedleroD Oct 29, 2025
347417f
chore: relicensed lib.php to pallasys
RiedleroD Oct 29, 2025
38b0cb8
chore: less funky docstring, to pacify phpdoc checker
RiedleroD Oct 29, 2025
d0b54a9
chore: pacify code checker
RiedleroD Oct 29, 2025
bcca1cf
Merge branch 'main' into EDUPL-26-sentry-api
RiedleroD Oct 29, 2025
22cd3c7
feat: well-placed sentry tracing
RiedleroD Oct 30, 2025
17b1964
fix: oops, syntax err at the very end
RiedleroD Oct 30, 2025
290fe54
fix: remove duplicate & broken data from sentry call
RiedleroD Nov 1, 2025
0281035
fix: assocarr instead of indarr in sentry setData
RiedleroD Nov 1, 2025
e713104
chore: put in another span for perf tracking
RiedleroD Nov 1, 2025
fa6be26
chore: made more keys into global constants
RiedleroD Nov 1, 2025
07cd6aa
feat: tell sentry FULL version number in dev env
RiedleroD Nov 1, 2025
48bbf97
fix: set int./ext. paths for sentry
RiedleroD Nov 6, 2025
420efcd
chore: appease code checker
RiedleroD Nov 6, 2025
8b26322
fix: exclude moodle from being marked "in-app" in sentry
RiedleroD Nov 10, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 14 additions & 1 deletion .github/workflows/package-and-attach-to-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,26 @@ jobs:
- name: Checkout
uses: actions/checkout@v5.0.0

- name: Set environment to prod
run: |
sed -i "s/set_config(CONFKEY::SENTRY_ENV, ENVIRONMENT::DEV, 'local_lbplanner')/set_config(CONFKEY::SENTRY_ENV, ENVIRONMENT::PROD, 'local_lbplanner')/g" "$TARGET_FOLDER/version.php"

- name: Extract version
id: version
run: |
version=$(grep -oP '\$plugin->version\s*=\s*\K[0-9]+' "$TARGET_FOLDER/version.php")

echo "version=$version" >> $GITHUB_OUTPUT


- name: Setup PHP ${{ matrix.php }}
uses: shivammathur/setup-php@v2
with: # see gha.dist.yml
php-version: '8.1'
coverage: none
- name: Get php libs
run: |
composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist

- name: Create ZIP file
run: |
ZIP_NAME="${MOODLE_INSTALL_DIR}_${PACKAGE_NAME}_${VERSION}.zip"
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ moodle
*.zip
lbplanner.dart/test/env.dart
example
.idea
.idea
lbplanner/vendor
2 changes: 1 addition & 1 deletion .kateproject
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"settings": {
"intelephense": {
"environment": {
"phpVersion": "8.0.0"
"phpVersion": "8.1.0"
}
}
}
Expand Down
26 changes: 26 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,29 @@
# LB Planer Plugin

This repository contains the source code for the LB Planer Moodle plugin. Api endpoints are documented [here](https://necodeit.github.io/lb_planner_docs/moodle/index.html)

## Setup

### Bundled Dependencies

Run `composer up` here to download dependencies to the vendor folder.
Note that dependencies already present in moodle are excluded from the tree.

### Dev Env

You can do this multiple ways, but we personally have a directory structure like so:

```
-root ← top folder. any name works
|-plugin ← this folder
|-moodle ← folder with moodle in it
|-local ← moodle's plugin folder
|-lbplanner ← symlink to the lbplanner folder
|-modcustomfields ← a dependency of ours (get at https://gitlab.com/adapta/moodle-local_modcustomfields/)
```

Using [kate](https://kate-editor.org/) with [intelephense](https://intelephense.com/) is recommended.

## Packaging

Zip the lbplanner folder. as shrimple as that.
20 changes: 20 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"require": {
"sentry/sentry": "^4.16",
"php": ">=8.1"
},
"replace": {
"symfony/deprecation-contracts": "*",
"guzzlehttp/psr7": "*",
"psr/http-factory": "*",
"psr/http-message": "*",
"psr/log": "*",
"ralouphie/getallheaders": "*"
},
"config": {
"vendor-dir": "lbplanner/vendor",
"platform": {
"php": "8.1.0"
}
}
}
294 changes: 294 additions & 0 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading