bump version beta.1

This commit is contained in:
undefined committed 2025-04-19 16:45:37 +08:00
1 parent 0bff54d568
commit 2bfac40a8b
33 files changed
+1027 -1007

No files matched your search

+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/components",
"version": "1.0.0-beta.0",
"version": "1.0.0-beta.1",
"main": "./frontend/index.ts",
"dependencies": {
"diff": "^7.0.0",
+3 -3
View File
@@ -1,14 +1,14 @@
{
"name": "@hydrooj/elastic-search",
"version": "1.2.0-beta.0",
"version": "1.2.0-beta.1",
"main": "index.ts",
"repository": "https://github.com/hydro-dev/Hydro",
"author": "undefined <i@undefined.moe>",
"license": "AGPL-3.0-or-later",
"dependencies": {
"@elastic/elasticsearch": "^8.17.1"
"@elastic/elasticsearch": "^8.18.0"
},
"engines": {
"hydrooj": ">=5.0.0-alpha.0"
"hydrooj": ">=5.0.0-alpha.1"
}
}
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/fps-importer",
"version": "1.6.0-beta.0",
"version": "1.6.0-beta.1",
"description": "Import FPS problems",
"main": "index.ts",
"repository": "https://github.com/hydro-dev/Hydro.git",
+1 -1
View File
@@ -1,7 +1,7 @@
{
"name": "@hydrooj/hydrojudge",
"bin": "bin/hydrojudge.js",
"version": "3.5.0-beta.0",
"version": "3.5.0-beta.1",
"main": "./src/index.ts",
"author": "undefined <i@undefined.moe>",
"repository": "https://github.com/hydro-dev/Hydro.git",
+9 -1
View File
@@ -193,7 +193,14 @@ export class JudgeTask {
type: 'interactor' | 'validator' | 'checker' | 'generator' | 'manager' | 'std',
source: CompilableSource, checkerType?: string,
): Promise<Execute> {
if (type === 'checker' && ['default', 'strict'].includes(checkerType)) return { execute: '', copyIn: {}, clean: () => Promise.resolve(null) };
if (type === 'checker' && ['default', 'strict'].includes(checkerType)) {
return {
execute: '',
copyIn: {},
clean: () => Promise.resolve(null),
[Symbol.asyncDispose]: () => Promise.resolve(null),
};
}
if (type === 'checker' && !checkers[checkerType]) throw new FormatError('Unknown checker type {0}.', [checkerType]);
if (this.compileCache?.[type]) {
return {
@@ -238,6 +245,7 @@ export class JudgeTask {
this.compileCache[type] = {
execute: result.execute,
copyIn: newCopyIn,
[Symbol.asyncDispose]: () => Promise.resolve(null),
};
await get((result.copyIn[result._cacheable] as PreparedFile).fileId, loc);
const currEtag = await fs.readFile(join(this.folder, 'etags'), 'utf-8');
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "hydrooj",
"version": "5.0.0-beta.0",
"version": "5.0.0-beta.1",
"bin": "bin/hydrooj.js",
"main": "src/plugin-api",
"module": "src/plugin-api",
+2 -2
View File
@@ -216,8 +216,8 @@ export class ContestProblemListHandler extends ContestDetailBaseHandler {
: [Object.fromEntries(psdocs.map((i) => [i.rid, { _id: i.rid }])), []];
if (!this.user.own(this.tdoc) && !this.user.hasPerm(PERM.PERM_EDIT_CONTEST)) {
this.response.body.rdocs = this.response.body.rdocs.map((rdoc) => contest.applyProjection(this.tdoc, rdoc, this.user));
for (const psdoc of psdocs) {
this.response.body.rdict[psdoc.rid] = contest.applyProjection(this.tdoc, this.response.body.rdict[psdoc.rid], this.user);
for (const key in this.response.body.rdict) {
this.response.body.rdict[key] = contest.applyProjection(this.tdoc, this.response.body.rdict[key], this.user);
}
for (const key in this.response.body.psdict) {
this.response.body.psdict[key] = contest.applyProjection(this.tdoc, this.response.body.psdict[key], this.user);
+2 -2
View File
@@ -3,7 +3,7 @@ import { ObjectId } from 'mongodb';
import { OplogDoc } from '../interface';
import bus from '../service/bus';
import db from '../service/db';
import type { Handler } from '../service/server';
import type { ConnectionHandler, Handler } from '../service/server';
export const coll = db.collection('oplog');
@@ -37,7 +37,7 @@ function safeKeys(data: any) {
return data;
}
export async function log<T extends Handler>(handler: T, type: string, data: any) {
export async function log<T extends Handler | ConnectionHandler>(handler: T, type: string, data: any) {
const args = safeKeys(cloneDeep(handler.args));
await bus.parallel('oplog/log', type, handler, args, data);
const res = await coll.insertOne({
+2 -2
View File
@@ -1,7 +1,7 @@
import {
BSON, Db, Filter, ObjectId, OnlyFieldsOfType,
} from 'mongodb';
import type { Handler } from '@hydrooj/framework';
import type { ConnectionHandler, Handler } from '@hydrooj/framework';
import pm2 from '@hydrooj/utils/lib/locate-pm2';
import { Context } from '../context';
import type {
@@ -84,7 +84,7 @@ export interface EventMap {
'contest/balloon': (domainId: string, tid: ObjectId, bdoc: ContestBalloonDoc) => VoidReturn
'contest/del': (domainId: string, tid: ObjectId) => VoidReturn
'oplog/log': (type: string, handler: Handler<Context>, args: any, data: any) => VoidReturn;
'oplog/log': (type: string, handler: Handler<Context> | ConnectionHandler<Context>, args: any, data: any) => VoidReturn;
'training/list': (query: Filter<TrainingDoc>, handler: any) => VoidReturn
'training/get': (tdoc: TrainingDoc, handler: any) => VoidReturn
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/import-hoj",
"version": "0.0.6-beta.0",
"version": "0.0.6-beta.1",
"description": "Import HOJ problem export",
"main": "index.ts",
"repository": "https://github.com/hydro-dev/Hydro.git",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/import-qduoj",
"version": "1.6.0-beta.0",
"version": "1.6.0-beta.1",
"description": "Import QDUOJ problem export",
"main": "index.ts",
"repository": "https://github.com/hydro-dev/Hydro.git",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/login-with-github",
"version": "0.3.0-beta.0",
"version": "0.3.0-beta.1",
"main": "index.ts",
"repository": "git@github.com:hydro-dev/Hydro.git",
"author": "undefined <i@undefined.moe>",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/migrate",
"version": "0.5.0-beta.0",
"version": "0.5.0-beta.1",
"main": "index.ts",
"repository": "git@github.com:hydro-dev/Hydro.git",
"author": "undefined <i@undefined.moe>",
+3 -1
View File
@@ -113,7 +113,7 @@ export function apply(ctx: Context) {
const groupId = {};
let gid = 1;
for (const i of relatedGroups) groupId[i] = `group-${gid++}`;
const organizations = teams.flatMap((i) => i.organization);
const organizations = Array.from(new Set(teams.flatMap((i) => i.organization)));
const orgId = {};
let oid = 1;
for (const i of organizations) orgId[i] = `org-${oid++}`;
@@ -256,9 +256,11 @@ export function apply(ctx: Context) {
zip.add('organizations/', null, { directory: true }),
]);
await Promise.all(teams.map(async (i) => {
await zip.add(`teams/${i.team_id}/`, null, { directory: true });
await zip.add(`teams/${i.team_id}/photo.download.txt`, new Zip.TextReader(i.avatar));
}));
await Promise.all(organizations.map(async (i) => {
await zip.add(`organizations/${orgId[i]}/`, null, { directory: true });
await zip.add(`organizations/${orgId[i]}/photo.download.txt`, new Zip.TextReader(avatar(teams.find((j) => j.organization === i)?.avatar || 'no photo, find and download it yourself')));
}));
this.binary(await zip.close(), `contest-${tdoc._id}-cdp.zip`);
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/onsite-toolkit",
"version": "0.1.0-beta.0",
"version": "0.1.0-beta.1",
"dependencies": {
"@react-spring/web": "^9.7.5",
"react-use": "^17.6.0"
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/prom-client",
"version": "0.2.0-beta.0",
"version": "0.2.0-beta.1",
"main": "index.ts",
"dependencies": {
"prom-client": "^15.1.3"
+1 -1
View File
@@ -1,7 +1,7 @@
{
"name": "@hydrooj/scoreboard-xcpcio",
"license": "AGPL-3.0-or-later",
"version": "0.0.5-beta.0",
"version": "0.0.5-beta.1",
"main": "index.ts",
"scripts": {
"postinstall": "node -r @hydrooj/register install.ts"
+1 -1
View File
@@ -1,4 +1,4 @@
{
"name": "@hydrooj/telegram",
"version": "0.0.2-beta.0"
"version": "0.0.2-beta.1"
}
@@ -22,7 +22,17 @@ const DomainSelectAutoComplete = forwardRef<AutoCompleteHandle<DomainDoc>, AutoC
queryItems={(query) => request.get('/domain/search', { q: query })}
itemText={(domain) => domain.name}
itemKey={(domain) => domain._id}
{...props}
{...{
width: '100%',
height: 'auto',
listStyle: {},
multi: false,
selectedKeys: [],
allowEmptyQuery: true,
freeSolo: false,
freeSoloConverter: (input) => input,
...props,
}}
/>
));
@@ -38,17 +48,6 @@ DomainSelectAutoComplete.propTypes = {
freeSoloConverter: PropTypes.func,
};
DomainSelectAutoComplete.defaultProps = {
width: '100%',
height: 'auto',
listStyle: {},
multi: false,
selectedKeys: [],
allowEmptyQuery: true,
freeSolo: false,
freeSoloConverter: (input) => input,
};
DomainSelectAutoComplete.displayName = 'DomainSelectAutoComplete';
export default DomainSelectAutoComplete;
@@ -29,7 +29,17 @@ const ProblemSelectAutoComplete = forwardRef<AutoCompleteHandle<ProblemDoc>, Aut
</div>
</div>
)}
{...props}
{...{
width: '100%',
height: 'auto',
listStyle: {},
multi: false,
selectedKeys: [],
allowEmptyQuery: false,
freeSolo: false,
freeSoloConverter: (input) => input,
...props,
}}
/>
));
@@ -45,17 +55,6 @@ ProblemSelectAutoComplete.propTypes = {
freeSoloConverter: PropTypes.func,
};
ProblemSelectAutoComplete.defaultProps = {
width: '100%',
height: 'auto',
listStyle: {},
multi: false,
selectedKeys: [],
allowEmptyQuery: false,
freeSolo: false,
freeSoloConverter: (input) => input,
};
ProblemSelectAutoComplete.displayName = 'ProblemSelectAutoComplete';
export default ProblemSelectAutoComplete;
@@ -8,7 +8,6 @@ const UserSelectAutoComplete = forwardRef<AutoCompleteHandle<Udoc>, AutoComplete
<AutoComplete<Udoc>
ref={ref as any}
cacheKey="user"
{...props}
queryItems={(query) => api(gql`
users(search: ${query}) {
_id
@@ -37,6 +36,17 @@ const UserSelectAutoComplete = forwardRef<AutoCompleteHandle<Udoc>, AutoComplete
</div>
</div>
)}
{...{
width: '100%',
height: 'auto',
listStyle: {},
multi: false,
selectedKeys: [],
allowEmptyQuery: false,
freeSolo: false,
freeSoloConverter: (input) => input,
...props,
}}
/>
));
@@ -52,17 +62,6 @@ UserSelectAutoComplete.propTypes = {
freeSoloConverter: PropTypes.func,
};
UserSelectAutoComplete.defaultProps = {
width: '100%',
height: 'auto',
listStyle: {},
multi: false,
selectedKeys: [],
allowEmptyQuery: false,
freeSolo: false,
freeSoloConverter: (input) => input,
};
UserSelectAutoComplete.displayName = 'UserSelectAutoComplete';
export default UserSelectAutoComplete;
@@ -3,7 +3,7 @@ import { omit } from 'lodash';
import React from 'react';
export default function DomComponent(props: React.HTMLAttributes<HTMLDivElement> & { childDom: HTMLElement }) {
const ref = React.useRef<HTMLDivElement>();
const ref = React.useRef<HTMLDivElement>(null);
React.useEffect(() => {
ref.current.appendChild(props.childDom);
return () => {
+4 -4
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/ui-default",
"version": "4.58.0-beta.0",
"version": "4.58.0-beta.1",
"author": "undefined <i@undefined.moe>",
"license": "AGPL-3.0",
"main": "index.ts",
@@ -21,7 +21,7 @@
"@fontsource/source-code-pro": "^5.2.5",
"@fontsource/ubuntu-mono": "^5.2.5",
"@hydrooj/utils": "workspace:^",
"@sentry/browser": "^9.12.0",
"@sentry/browser": "^9.13.0",
"@sentry/webpack-plugin": "^3.3.1",
"@simplewebauthn/browser": "13.1.0",
"@svgr/webpack": "^8.1.0",
@@ -67,7 +67,7 @@
"jquery.easing": "^1.4.1",
"jquery.transit": "^0.9.12",
"matchmedia-polyfill": "^0.3.2",
"md-editor-rt": "^5.4.5",
"md-editor-rt": "^5.5.0",
"mini-css-extract-plugin": "^2.9.2",
"moment": "^2.30.1",
"monaco-editor": "0.52.2",
@@ -116,7 +116,7 @@
"timeago.js": "^4.0.2",
"ts-loader": "^9.5.2",
"web-streams-polyfill": "^4.1.0",
"webpack": "^5.99.5",
"webpack": "^5.99.6",
"webpack-bundle-analyzer": "^4.10.2",
"webpack-dev-server": "^5.2.1",
"webpack-manifest-plugin": "^5.0.1",
+1 -1
View File
@@ -16,6 +16,6 @@
"@types/react": "^19.1.2",
"@types/react-dom": "^19.1.2",
"@vitejs/plugin-react-swc": "^3.9.0",
"vite": "^6.2.6"
"vite": "^6.3.2"
}
}
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/utils",
"version": "1.4.34-beta.0",
"version": "1.4.34-beta.1",
"description": "hydrooj utils",
"main": "lib/utils.ts",
"repository": "https://github.com/hydro-dev/Hydro.git",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@hydrooj/vjudge",
"version": "1.10.0-beta.0",
"version": "1.10.0-beta.1",
"description": "Submit problems to remote oj",
"main": "./src/index.ts",
"repository": "https://github.com/hydro-dev/Hydro.git",